DEADSOFTWARE

default smallmap aligh: bottom
[d2df-sdl.git] / src / engine / e_log.pas
index 4ba21561043872f9546d5e13e6760c2bb8a6d25c..22db6527781c00ec9d8301d13e2b705a5365c7e4 100644 (file)
@@ -1,4 +1,4 @@
-(* Copyright (C)  DooM 2D:Forever Developers
+(* Copyright (C)  Doom 2D: Forever Developers
  *
  * This program is free software: you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
@@ -54,7 +54,7 @@ var
 implementation
 
 uses
-  conbuf, utils;
+  SDL2, conbuf, utils;
 
 var
   FirstRecord: Boolean;
@@ -89,9 +89,22 @@ var
   ss: ShortString;
   slen: Integer;
   b: PByte;
+{$IFDEF ANDROID}
+  cstr: PChar;
+{$ENDIF}
 begin
   if (len < 1) then exit;
   b := PByte(@buf);
+
+{$IFDEF ANDROID}
+  cstr := GetMem(len + 1);
+  for slen := 0 to len - 1 do
+    cstr[slen] := Chr(b[slen]);
+  cstr[len] := #0;
+  SDL_Log(cstr, []);
+  Dispose(cstr);
+{$ENDIF}
+
   while (len > 0) do
   begin
     if (len > 255) then slen := 255 else slen := Integer(len);