- Fix for PascalImports and for GenLandPreview ios-revival
authorantonc27 <antonc27@mail.ru>
Sat, 08 Aug 2015 22:45:23 +0200
branchios-revival
changeset 11094 595b5700ebac
parent 11093 daad16c01ed7
child 11095 59fdc1ea1a4d
- Fix for PascalImports and for GenLandPreview
hedgewars/hwLibrary.pas
hedgewars/hwengine.pas
project_files/HedgewarsMobile/Classes/GameInterfaceBridge.m
project_files/HedgewarsMobile/Classes/PascalImports.h
--- a/hedgewars/hwLibrary.pas	Sat Aug 08 22:08:43 2015 +0200
+++ b/hedgewars/hwLibrary.pas	Sat Aug 08 22:45:23 2015 +0200
@@ -120,6 +120,9 @@
 {$ELSE}
 exports
     RunEngine,
+{$IFDEF MOBILE}
+    GenLandPreview,
+{$ENDIF}
     LoadLocaleWrapper,
     HW_versionInfo,
     HW_versionString,
--- a/hedgewars/hwengine.pas	Sat Aug 08 22:08:43 2015 +0200
+++ b/hedgewars/hwengine.pas	Sat Aug 08 22:45:23 2015 +0200
@@ -44,6 +44,9 @@
 procedure preInitEverything();
 procedure initEverything(complete:boolean);
 procedure freeEverything(complete:boolean);
+{$IFDEF MOBILE}
+procedure GenLandPreview; cdecl; export;
+{$ENDIF MOBILE}
 
 implementation
 {$ELSE}
@@ -540,7 +543,7 @@
 end;
 
 ///////////////////////////////////////////////////////////////////////////////
-procedure GenLandPreview;
+procedure GenLandPreview;{$IFDEF MOBILE} cdecl; export;{$ENDIF MOBILE}
 var Preview: TPreviewAlpha;
 begin
     initEverything(false);
--- a/project_files/HedgewarsMobile/Classes/GameInterfaceBridge.m	Sat Aug 08 22:08:43 2015 +0200
+++ b/project_files/HedgewarsMobile/Classes/GameInterfaceBridge.m	Sat Aug 08 22:45:23 2015 +0200
@@ -176,7 +176,7 @@
     [gameParameters release];
 
     // this is the pascal function that starts the game
-    Game(argc, argv);
+    RunEngine(argc, argv);
 
     // cleanup
     for (int i = 0; i < argc; i++)
--- a/project_files/HedgewarsMobile/Classes/PascalImports.h	Sat Aug 08 22:08:43 2015 +0200
+++ b/project_files/HedgewarsMobile/Classes/PascalImports.h	Sat Aug 08 22:45:23 2015 +0200
@@ -28,7 +28,7 @@
      * that you want to use in your non-Pascal code
      */
 
-    void Game(const int argc, const char *argv[]);
+    void RunEngine(const int argc, const char *argv[]);
     void GenLandPreview(void);
     void LoadLocaleWrapper(const char *filename);