GIT
/
REPO
/
FRED-BOY
Projects
/
d2df-sdl.git
/ blobdiff
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
render: draw touch controls via render
[d2df-sdl.git]
/
src
/
game
/
g_netmsg.pas
diff --git
a/src/game/g_netmsg.pas
b/src/game/g_netmsg.pas
index a2e2bc944d5ec6651f93b41a55b749e431255a5d..759f4b6bd963964b6c9d76524fd178902881091b 100644
(file)
--- a/
src/game/g_netmsg.pas
+++ b/
src/game/g_netmsg.pas
@@
-284,9
+284,12
@@
function IsValidFilePath(const S: String): Boolean;
implementation
uses
implementation
uses
- Math, ENet, e_input, e_log, g_base, g_basic, r_animations, r_gfx,
+ {$IFDEF ENABLE_MENU}
+ g_gui,
+ {$ENDIF}
+ Math, ENet, e_input, e_log, g_base, g_basic,
g_textures, g_gfx, g_sound, g_console, g_options,
g_textures, g_gfx, g_sound, g_console, g_options,
- g_game, g_player, g_map, g_panel, g_items, g_weapons, g_phys,
g_gui,
+ g_game, g_player, g_map, g_panel, g_items, g_weapons, g_phys,
g_language, g_monsters, g_netmaster, utils, wadreader, MAPDEF;
const
g_language, g_monsters, g_netmaster, utils, wadreader, MAPDEF;
const
@@
-766,7
+769,7
@@
begin
if (g_Force_Model_Get() <> 0) then
TmpModel := g_Forced_Model_GetName();
if (g_Force_Model_Get() <> 0) then
TmpModel := g_Forced_Model_GetName();
- if TmpModel <> Pl.Model.
Name
then
+ if TmpModel <> Pl.Model.
GetName()
then
Pl.SetModel(TmpModel);
if (TmpWeapSwitch <> Pl.WeapSwitchMode) then
Pl.SetModel(TmpModel);
if (TmpWeapSwitch <> Pl.WeapSwitchMode) then
@@
-1406,7
+1409,7
@@
begin
NetOut.Write(PID);
NetOut.Write(Pl.Name);
if Mdl = '' then
NetOut.Write(PID);
NetOut.Write(Pl.Name);
if Mdl = '' then
- NetOut.Write(Pl.Model.
Name
)
+ NetOut.Write(Pl.Model.
GetName()
)
else
NetOut.Write(Mdl);
NetOut.Write(Pl.FColor.R);
else
NetOut.Write(Mdl);
NetOut.Write(Pl.FColor.R);
@@
-1736,40
+1739,40
@@
begin
NET_GFX_TELE:
begin
NET_GFX_TELE:
begin
-
r_GFX_OnceAnim
(R_GFX_TELEPORT_FAST, X, Y);
+
g_GFX_QueueEffect
(R_GFX_TELEPORT_FAST, X, Y);
if Ang = 1 then
g_Sound_PlayExAt('SOUND_GAME_TELEPORT', X, Y);
end;
NET_GFX_EXPLODE:
begin
if Ang = 1 then
g_Sound_PlayExAt('SOUND_GAME_TELEPORT', X, Y);
end;
NET_GFX_EXPLODE:
begin
-
r_GFX_OnceAnim
(R_GFX_EXPLODE_ROCKET, X - 64, Y - 64);
+
g_GFX_QueueEffect
(R_GFX_EXPLODE_ROCKET, X - 64, Y - 64);
if Ang = 1 then
g_Sound_PlayExAt('SOUND_WEAPON_EXPLODEROCKET', X, Y);
end;
NET_GFX_BFGEXPL:
begin
if Ang = 1 then
g_Sound_PlayExAt('SOUND_WEAPON_EXPLODEROCKET', X, Y);
end;
NET_GFX_BFGEXPL:
begin
-
r_GFX_OnceAnim
(R_GFX_EXPLODE_BFG, X - 64, Y - 64);
+
g_GFX_QueueEffect
(R_GFX_EXPLODE_BFG, X - 64, Y - 64);
if Ang = 1 then
g_Sound_PlayExAt('SOUND_WEAPON_EXPLODEBFG', X, Y);
end;
NET_GFX_BFGHIT:
begin
if Ang = 1 then
g_Sound_PlayExAt('SOUND_WEAPON_EXPLODEBFG', X, Y);
end;
NET_GFX_BFGHIT:
begin
-
r_GFX_OnceAnim
(R_GFX_BFG_HIT, X - 32, Y - 32);
+
g_GFX_QueueEffect
(R_GFX_BFG_HIT, X - 32, Y - 32);
end;
NET_GFX_FIRE:
begin
end;
NET_GFX_FIRE:
begin
-
r_GFX_OnceAnim
(R_GFX_FIRE, X, Y);
+
g_GFX_QueueEffect
(R_GFX_FIRE, X, Y);
if Ang = 1 then
g_Sound_PlayExAt('SOUND_FIRE', X, Y);
end;
NET_GFX_RESPAWN:
begin
if Ang = 1 then
g_Sound_PlayExAt('SOUND_FIRE', X, Y);
end;
NET_GFX_RESPAWN:
begin
-
r_GFX_OnceAnim
(R_GFX_ITEM_RESPAWN, X, Y);
+
g_GFX_QueueEffect
(R_GFX_ITEM_RESPAWN, X, Y);
if Ang = 1 then
g_Sound_PlayExAt('SOUND_ITEM_RESPAWNITEM', X, Y);
end;
if Ang = 1 then
g_Sound_PlayExAt('SOUND_ITEM_RESPAWNITEM', X, Y);
end;
@@
-2697,7
+2700,7
@@
begin
if (g_Force_Model_Get() <> 0) then
TmpModel := g_Forced_Model_GetName();
if (g_Force_Model_Get() <> 0) then
TmpModel := g_Forced_Model_GetName();
- if TmpModel <> Pl.Model.
Name
then
+ if TmpModel <> Pl.Model.
GetName()
then
Pl.SetModel(TmpModel);
end;
Pl.SetModel(TmpModel);
end;
@@
-2732,7
+2735,7
@@
begin
if not Quiet then
begin
g_Sound_PlayExAt('SOUND_ITEM_RESPAWNITEM', X, Y);
if not Quiet then
begin
g_Sound_PlayExAt('SOUND_ITEM_RESPAWNITEM', X, Y);
-
r_GFX_OnceAnim
(R_GFX_ITEM_RESPAWN, X+(it.Obj.Rect.Width div 2)-16, Y+(it.Obj.Rect.Height div 2)-16);
+
g_GFX_QueueEffect
(R_GFX_ITEM_RESPAWN, X+(it.Obj.Rect.Width div 2)-16, Y+(it.Obj.Rect.Height div 2)-16);
end;
end;
end;
end;
@@
-3170,7
+3173,11
@@
begin
kByte := 0;
Predict := NetPredictSelf; // and (not NetGotKeys);
kByte := 0;
Predict := NetPredictSelf; // and (not NetGotKeys);
+{$IFDEF DISABLE_MENU}
+ if (not gConsoleShow) and (not gChatShow) then
+{$ELSE}
if (not gConsoleShow) and (not gChatShow) and (g_ActiveWindow = nil) then
if (not gConsoleShow) and (not gChatShow) and (g_ActiveWindow = nil) then
+{$ENDIF}
begin
strafeDir := P1MoveButton shr 4;
P1MoveButton := P1MoveButton and $0F;
begin
strafeDir := P1MoveButton shr 4;
P1MoveButton := P1MoveButton and $0F;
DEADSOFTWARE 2012-2025