summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: dbac531)
raw | patch | inline | side by side (parent: dbac531)
author | fgsfds <pvt.fgsfds@gmail.com> | |
Sun, 9 Feb 2020 22:24:51 +0000 (01:24 +0300) | ||
committer | fgsfds <pvt.fgsfds@gmail.com> | |
Sun, 9 Feb 2020 22:24:51 +0000 (01:24 +0300) |
src/game/g_items.pas | patch | blob | history |
diff --git a/src/game/g_items.pas b/src/game/g_items.pas
index 07c4df2b1d8e929832c6ac67b97f548de27b3d4d..ae047f82b8afcc86bfa283e05012af0964c9b3a5 100644 (file)
--- a/src/game/g_items.pas
+++ b/src/game/g_items.pas
it.slotIsUsed := true;
it.ItemType := ItemType;
- if g_Game_IsServer and ((ITEM_RESPAWNTIME = 0) or not LongBool(gGameSettings.Options and GAME_OPTION_RESPAWNITEMS)) then
- it.Respawnable := False
- else
- it.Respawnable := Respawnable;
+ it.Respawnable := Respawnable;
it.InitX := X;
it.InitY := Y;
it.RespawnTime := 0;
Anim: TAnimation;
m: Word;
r, nxt: Boolean;
+ actualRespawnable: Boolean;
begin
if (ggItems = nil) then exit;
// Íàäî óáðàòü ñ êàðòû, åñëè ýòî íå êëþ÷, êîòîðûì íóæíî ïîäåëèòüñÿ ñ äðóãèì èãðîêîì
if r then
begin
- if not Respawnable then g_Items_Remove(i) else g_Items_Pick(i);
+ actualRespawnable := Respawnable
+ and ((ITEM_RESPAWNTIME > 0) and LongBool(gGameSettings.Options and GAME_OPTION_RESPAWNITEMS));
+ if not actualRespawnable then g_Items_Remove(i) else g_Items_Pick(i);
if g_Game_IsNet then MH_SEND_ItemDestroy(False, i);
nxt := True;
break;