--- a/hedgewars/hwengine.pas Sat Nov 12 15:48:55 2011 +0100
+++ b/hedgewars/hwengine.pas Sat Nov 12 17:06:49 2011 +0100
@@ -116,15 +116,11 @@
s:= 'hw_' + FormatDateTime('YYYY-MM-DD_HH-mm-ss', Now()) + inttostr(GameTicks);
playSound(sndShutter);
-{$IFNDEF IPHONEOS}
- if not MakeScreenshot(s) then
- begin
+ if MakeScreenshot(s) then WriteLnToConsole('Screenshot saved: ' + s)
+ else begin
WriteLnToConsole('Screenshot failed.');
AddChatString(#5 + 'screen capture failed (lack of memory or write permissions)');
- end
- else
-{$ENDIF}
- WriteLnToConsole('Screenshot saved: ' + s);
+ end
end;
end;
@@ -149,11 +145,8 @@
///////////////////
procedure MainLoop;
-{$WARNINGS OFF}
-// disable "Some fields weren't initialized" warning
-const event: TSDL_Event = ();
-{$WARNINGS ON}
-var PrevTime, CurrTime: Longword;
+var event: TSDL_Event;
+ PrevTime, CurrTime: Longword;
{$IFDEF SDL13}
previousGameState: TGameState;
{$ELSE}
@@ -263,8 +256,10 @@
begin
{$IFDEF HWLIBRARY}
cBits:= 32;
+ cFullScreen:= false;
cTimerInterval:= 8;
- cFullScreen:= {$IFDEF MOBILE}true{$ELSE}false{$ENDIF};
+ PathPrefix:= 'Data';
+ UserPathPrefix:= '../Documents';
cShowFPS:= {$IFDEF DEBUGFILE}true{$ELSE}false{$ENDIF};
val(gameArgs[0], ipcPort);
val(gameArgs[1], cScreenWidth);