hedgewars/uLocale.pas
changeset 6528 fb2918089225
parent 6453 11c578d30bd3
child 6580 6155187bf599
equal deleted inserted replaced
6527:d19c6af9fa48 6528:fb2918089225
    28 function  Format(fmt: shortstring; var arg: shortstring): shortstring;
    28 function  Format(fmt: shortstring; var arg: shortstring): shortstring;
    29 function  Format(fmt: ansistring; var arg: ansistring): ansistring;
    29 function  Format(fmt: ansistring; var arg: ansistring): ansistring;
    30 function  GetEventString(e: TEventId): ansistring;
    30 function  GetEventString(e: TEventId): ansistring;
    31 
    31 
    32 implementation
    32 implementation
    33 uses uRandom, uUtils, uVariables, uDebug;
    33 uses uRandom, uUtils, uVariables, uDebug, uConsole;
    34 
    34 
    35 var trevt: array[TEventId] of array [0..Pred(MAX_EVENT_STRINGS)] of ansistring;
    35 var trevt: array[TEventId] of array [0..Pred(MAX_EVENT_STRINGS)] of ansistring;
    36     trevt_n: array[TEventId] of integer;
    36     trevt_n: array[TEventId] of integer;
    37 
    37 
    38 procedure LoadLocale(FileName: shortstring);
    38 procedure LoadLocale(FileName: shortstring);
    83            3: if (b >=0) and (b <= ord(High(TAmmoStrId))) then trammoc[TAmmoStrId(b)]:= s;
    83            3: if (b >=0) and (b <= ord(High(TAmmoStrId))) then trammoc[TAmmoStrId(b)]:= s;
    84            4: if (b >=0) and (b <= ord(High(TAmmoStrId))) then trammod[TAmmoStrId(b)]:= s;
    84            4: if (b >=0) and (b <= ord(High(TAmmoStrId))) then trammod[TAmmoStrId(b)]:= s;
    85            5: if (b >=0) and (b <= ord(High(TGoalStrId))) then trgoal[TGoalStrId(b)]:= s;
    85            5: if (b >=0) and (b <= ord(High(TGoalStrId))) then trgoal[TGoalStrId(b)]:= s;
    86            end;
    86            end;
    87        end;
    87        end;
    88    Close(f)
    88    Close(f);
       
    89    WriteLnToConsole('Locale loaded "' + FileName + '"');
    89    end;
    90    end;
    90 {$I+}
    91 {$I+}
    91 end;
    92 end;
    92 
    93 
    93 function GetEventString(e: TEventId): ansistring;
    94 function GetEventString(e: TEventId): ansistring;