summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: a0b4df6)
raw | patch | inline | side by side (parent: a0b4df6)
author | Ketmar Dark <ketmar@ketmar.no-ip.org> | |
Fri, 1 Sep 2017 09:37:46 +0000 (12:37 +0300) | ||
committer | Ketmar Dark <ketmar@ketmar.no-ip.org> | |
Fri, 1 Sep 2017 19:17:53 +0000 (22:17 +0300) |
src/game/g_map.pas | patch | blob | history | |
src/game/g_panel.pas | patch | blob | history |
diff --git a/src/game/g_map.pas b/src/game/g_map.pas
index 9470057306ae27f956b9b1c01b87ca49cdf7cd79..5c3a8a17ef5ef457e970dc450bc6ef9e03c4a321 100644 (file)
--- a/src/game/g_map.pas
+++ b/src/game/g_map.pas
i := 0;
while i < Length(panels) do
begin
- if panels[i].SaveIt then
+ if true{panels[i].SaveIt} then
begin
// ID ïàíåëè:
PAMem.WriteInt(i);
for i := 0 to Length(panels)-1 do
begin
- if panels[i].SaveIt then
+ if true{panels[i].SaveIt} then
begin
// ID ïàíåëè:
PAMem.ReadInt(id);
diff --git a/src/game/g_panel.pas b/src/game/g_panel.pas
index 3b2830e634d471e3eb0796b37b5d504cf50ea1e8..634e21bfca8bd5ca3672e461352666a32f7cadec 100644 (file)
--- a/src/game/g_panel.pas
+++ b/src/game/g_panel.pas
sig: DWORD;
anim: Boolean;
begin
- if (not SaveIt) or (Mem = nil) then
- Exit;
+ if (Mem = nil) then exit;
+ //if not SaveIt then exit;
// Ñèãíàòóðà ïàíåëè:
sig := PANEL_SIGNATURE; // 'PANL'
var
sig: DWORD;
anim: Boolean;
+ ox, oy: Integer;
begin
- if (not SaveIt) or (Mem = nil) then
- Exit;
+ if (Mem = nil) then exit;
+ //if not SaveIt then exit;
// Ñèãíàòóðà ïàíåëè:
Mem.ReadDWORD(sig);
// Íîìåð òåêóùåé òåêñòóðû:
Mem.ReadInt(FCurTexture);
// Êîîðäû
+ ox := FX;
+ oy := FY;
Mem.ReadInt(FX);
Mem.ReadInt(FY);
+ //e_LogWritefln('panel %s(%s): old=(%s,%s); new=(%s,%s); delta=(%s,%s)', [arrIdx, proxyId, ox, oy, FX, FY, FX-ox, FY-oy]);
// Àíèìèðîâàííàÿ ëè òåêóùàÿ òåêñòóðà:
Mem.ReadBoolean(anim);
// Åñëè äà - çàãðóæàåì àíèìàöèþ:
Mem.ReadInt(mMovingEnd.X);
Mem.ReadInt(mMovingEnd.Y);
Mem.ReadBoolean(mMovingActive);
+
+ if (proxyId >= 0) then mapGrid.moveBody(proxyId, X, Y);
end;
end.