Skip to content

Commit

Permalink
Remove unnecessary bind check during demos.
Browse files Browse the repository at this point in the history
  • Loading branch information
JadingTsunami committed Nov 23, 2024
1 parent 946ac1a commit b0f820a
Showing 1 changed file with 4 additions and 8 deletions.
12 changes: 4 additions & 8 deletions prboom2/src/c_cmd.c
Original file line number Diff line number Diff line change
Expand Up @@ -1855,16 +1855,12 @@ dboolean C_ExecuteBind(int keycode, evtype_t evtype)
keybind_t* kb = keybind_head;
dboolean executed = false;

if (netgame || demorecording || demoplayback) {
return false;
}

while (kb) {
if (kb->keycode == keycode && kb->type == evtype) {
if (netgame) {
doom_printf("Binds not allowed during net play.");
return false;
} else if (demorecording || demoplayback) {
doom_printf("Binds not allowed during demos.");
return false;
}

C_ConsoleCommand(kb->cmd);
executed = true;
}
Expand Down

0 comments on commit b0f820a

Please sign in to comment.