add pchar casts to make pas2c happy sdl2transition
authorsheepluva
Wed, 11 Nov 2015 21:59:06 +0100
branchsdl2transition
changeset 11367 a91c4c4fd85c
parent 11366 f1b5f1dc61a3
child 11368 c481d087f653
add pchar casts to make pas2c happy
hedgewars/uAI.pas
hedgewars/uMisc.pas
hedgewars/uStore.pas
--- a/hedgewars/uAI.pas	Wed Nov 11 20:50:01 2015 +0100
+++ b/hedgewars/uAI.pas	Wed Nov 11 21:59:06 2015 +0100
@@ -530,7 +530,7 @@
 FillBonuses(((Me^.State and gstAttacked) <> 0) and (not isInMultiShoot));
 
 SDL_LockMutex(ThreadLock);
-ThinkThread:= SDL_CreateThread(@Think, 'think', Me);
+ThinkThread:= SDL_CreateThread(@Think, PChar('think'), Me);
 SDL_UnlockMutex(ThreadLock);
 end;
 
--- a/hedgewars/uMisc.pas	Wed Nov 11 20:50:01 2015 +0100
+++ b/hedgewars/uMisc.pas	Wed Nov 11 21:59:06 2015 +0100
@@ -299,7 +299,7 @@
 image^.size:= size;
 image^.buffer:= p;
 
-SDL_CreateThread(@SaveScreenshot, 'snapshot', image);
+SDL_CreateThread(@SaveScreenshot, PChar('snapshot'), image);
 MakeScreenshot:= true; // possibly it is not true but we will not wait for thread to terminate
 end;
 
--- a/hedgewars/uStore.pas	Wed Nov 11 20:50:01 2015 +0100
+++ b/hedgewars/uStore.pas	Wed Nov 11 21:59:06 2015 +0100
@@ -984,7 +984,7 @@
 procedure InitOffscreenOpenGL;
 begin
     // create hidden window
-    SDLwindow:= SDL_CreateWindow('hedgewars video rendering (SDL2 hidden window)',
+    SDLwindow:= SDL_CreateWindow(PChar('hedgewars video rendering (SDL2 hidden window)'),
                                  SDL_WINDOWPOS_CENTERED_MASK, SDL_WINDOWPOS_CENTERED_MASK,
                                  cScreenWidth, cScreenHeight,
                                  SDL_WINDOW_HIDDEN or SDL_WINDOW_OPENGL);
@@ -1081,7 +1081,7 @@
         flags:= flags or SDL_WINDOW_FULLSCREEN;
 
     if SDLwindow = nil then
-        SDLwindow:= SDL_CreateWindow('Hedgewars', x, y, cScreenWidth, cScreenHeight, flags);
+        SDLwindow:= SDL_CreateWindow(PChar('Hedgewars'), x, y, cScreenWidth, cScreenHeight, flags);
     SDLTry(SDLwindow <> nil, 'SDL_CreateWindow', true);
 
     SetupOpenGL();