hedgewars/uLocale.pas
changeset 3926 668b71f31e51
parent 3774 af0e68ca273e
child 3963 6090d2a2472e
--- a/hedgewars/uLocale.pas	Mon Oct 04 00:00:42 2010 +0200
+++ b/hedgewars/uLocale.pas	Wed Oct 06 02:31:04 2010 +0200
@@ -46,17 +46,16 @@
             gidDamageModifier);
 
 const MAX_EVENT_STRINGS = 100;
-var trammo: array[TAmmoStrId] of ansistring;
-    trammoc: array[TAmmoStrId] of ansistring;
-    trammod: array[TAmmoStrId] of ansistring;
-    trmsg: array[TMsgStrId] of ansistring;
-    trgoal: array[TGoalStrId] of ansistring;
+var trammo:  array[TAmmoStrId] of ansistring;   // name of the weapon
+    trammoc: array[TAmmoStrId] of ansistring;   // caption of the weapon
+    trammod: array[TAmmoStrId] of ansistring;   // description of the weapon
+    trmsg:   array[TMsgStrId]  of ansistring;   // message of the event
+    trgoal:  array[TGoalStrId] of ansistring;   // message of the goal
 
 procedure LoadLocale(FileName: shortstring);
-function Format(fmt: shortstring; var arg: shortstring): shortstring;
-function Format(fmt: ansistring; var arg: ansistring): ansistring;
-
-function GetEventString(e: TEventId): ansistring;
+function  Format(fmt: shortstring; var arg: shortstring): shortstring;
+function  Format(fmt: ansistring; var arg: ansistring): ansistring;
+function  GetEventString(e: TEventId): ansistring;
 
 implementation
 uses uMisc, uRandom;
@@ -144,4 +143,9 @@
          else Format:= copy(fmt, 1, i - 1) + arg + Format(copy(fmt, i + 2, Length(fmt) - i - 1), arg)
 end;
 
+procedure LoadLocaleWrapper(str: pchar); cdecl; export;
+begin
+    LoadLocale(Strpas(str));
+end;
+
 end.