# HG changeset patch # User Wuzzy # Date 1556998642 -7200 # Node ID 4e3d81af71bff0dc1dcd368a46ec1f9dc1d1e2a3 # Parent 421eed52a8e141a220f9eb2d774e60d5fb417fd7 Some fixes to make Pas2C happy again diff -r 421eed52a8e1 -r 4e3d81af71bf hedgewars/uGears.pas --- a/hedgewars/uGears.pas Sat May 04 21:03:26 2019 +0200 +++ b/hedgewars/uGears.pas Sat May 04 21:37:22 2019 +0200 @@ -283,7 +283,7 @@ if curHandledGear^.Tex = nil then if (curHandledGear^.Karma = 1) and (not (GameType in [gmtDemo, gmtRecord])) then // Secret mine timer - curHandledGear^.Tex:= RenderStringTex(ansistring(trmsg[sidUnknownGearValue]), $ff808080, fntSmall) + curHandledGear^.Tex:= RenderStringTex(trmsg[sidUnknownGearValue], $ff808080, fntSmall) else begin // Display mine timer with up to 1 decimal point of precision (rounded down) diff -r 421eed52a8e1 -r 4e3d81af71bf hedgewars/uGearsHandlersMess.pas --- a/hedgewars/uGearsHandlersMess.pas Sat May 04 21:03:26 2019 +0200 +++ b/hedgewars/uGearsHandlersMess.pas Sat May 04 21:37:22 2019 +0200 @@ -2498,7 +2498,7 @@ if i = 1 then Gear^.Tex := RenderStringTex(ansistring(inttostr(Gear^.Health)), $ff80ff80, fnt16) else - Gear^.Tex := RenderStringTex(ansistring(trmsg[sidUnknownGearValue]), $ff80ff80, fnt16) + Gear^.Tex := RenderStringTex(trmsg[sidUnknownGearValue], $ff80ff80, fnt16) end; end; if Gear^.Timer = 500 then diff -r 421eed52a8e1 -r 4e3d81af71bf hedgewars/uSound.pas --- a/hedgewars/uSound.pas Sat May 04 21:03:26 2019 +0200 +++ b/hedgewars/uSound.pas Sat May 04 21:37:22 2019 +0200 @@ -380,6 +380,7 @@ procedure InitSound; const channels: LongInt = 2; var success: boolean; + s: shortstring; begin if not (isSoundEnabled or isMusicEnabled) then begin @@ -412,7 +413,8 @@ if (Mix_Init(MIX_INIT_OGG or MIX_INIT_OPUS) and MIX_INIT_OPUS) = 0 then begin - WriteToConsole('Cannot init OPUS: ' + SDL_GetError()); + s:= SDL_GetError(); + WriteToConsole('Cannot init OPUS: ' + s); if SDLCheck(Mix_Init(MIX_INIT_OGG) <> 0, 'Mix_Init', true) then exit; end;