diff --git a/src/game/g_weapons.pas b/src/game/g_weapons.pas
index 81db80314333fb159b8396ad7bafabf84fa22700..3585ef2b4d136f148003fcc717d9a172bc28f4e6 100644 (file)
--- a/src/game/g_weapons.pas
+++ b/src/game/g_weapons.pas
TextureID: DWORD;
Timeout: DWORD;
Stopped: Byte;
+
+ procedure positionChanged (); //WARNING! call this after monster position was changed, or coldet will not work right!
end;
+
var
Shots: array of TShot = nil;
LastShotID: Integer = 0;
SHOT_FLAME_WIDTH = 4;
SHOT_FLAME_HEIGHT = 4;
- SHOT_FLAME_LIFETIME = 180;
+ SHOT_FLAME_LIFETIME = 180;
SHOT_SIGNATURE = $544F4853; // 'SHOT'
Obj.Y+Obj.Rect.Y+(Obj.Rect.Height div 2), X, Y);
g_Obj_PushA(@Obj, Round(15*(rad-m)/rad), _angle);
+ positionChanged(); // this updates spatial accelerators
end;
end;
end;
(ShotType <> WEAPON_FLAMETHROWER);
if Stopped = 0 then
- st := g_Obj_Move(@Obj, False, spl)
+ begin
+ st := g_Obj_Move(@Obj, False, spl);
+ end
else
+ begin
st := 0;
+ end;
+ positionChanged(); // this updates spatial accelerators
if WordBool(st and MOVE_FALLOUT) or (Obj.X < -1000) or
(Obj.X > gMapInfo.Width+1000) or (Obj.Y < -1000) then
end;
end;
+
+procedure TShot.positionChanged (); begin end;
+
+
end.