From 345926f05751c770e92ccf7f77e2117e58ca4ebf Mon Sep 17 00:00:00 2001 From: Boondorl Date: Fri, 14 Mar 2025 19:39:29 -0400 Subject: [PATCH] Fixed setinv cheat --- src/m_cheat.cpp | 2 +- wadsrc/static/zscript/actors/player/player_cheat.zs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/m_cheat.cpp b/src/m_cheat.cpp index e918c2408..9cf2314ee 100644 --- a/src/m_cheat.cpp +++ b/src/m_cheat.cpp @@ -570,7 +570,7 @@ FString cht_Morph(player_t *player, PClassActor *morphclass, bool quickundo) void cht_SetInv(player_t *player, const char *string, int amount, bool beyond) { if (!player->mo) return; - IFVIRTUALPTRNAME(player->mo, NAME_PlayerPawn, CheatTakeInv) + IFVIRTUALPTRNAME(player->mo, NAME_PlayerPawn, CheatSetInv) { FString message = string; VMValue params[] = { player->mo, &message, amount, beyond }; diff --git a/wadsrc/static/zscript/actors/player/player_cheat.zs b/wadsrc/static/zscript/actors/player/player_cheat.zs index 3fbb5f30b..25624a3b7 100644 --- a/wadsrc/static/zscript/actors/player/player_cheat.zs +++ b/wadsrc/static/zscript/actors/player/player_cheat.zs @@ -403,7 +403,7 @@ extend class PlayerPawn virtual void CheatSetInv(String strng, int amount, bool beyond) { - if (!(strng ~== "health")) + if (strng ~== "health") { if (amount <= 0) {