diff --git a/src/Menu.cpp b/src/Menu.cpp index 20e5ed4..5e4a0cb 100644 --- a/src/Menu.cpp +++ b/src/Menu.cpp @@ -72,7 +72,8 @@ namespace DX11_Base ImGui::Checkbox("InfStamina", &Config.IsInfStamina); - ImGui::Checkbox("InfAmmo", &Config.IsInfinAmmo); + if (ImGui::Checkbox("InfAmmo", &Config.IsInfinAmmo)) + SetInfiniteAmmo(Config.IsInfinAmmo); ImGui::Checkbox("Godmode", &Config.IsGodMode); @@ -785,20 +786,7 @@ namespace DX11_Base // // SetDemiGodMode(Config.IsMuteki); - if (Config.GetPalPlayerCharacter() != NULL) - { - if (Config.GetPalPlayerCharacter()->ShooterComponent != NULL && Config.GetPalPlayerCharacter()->ShooterComponent->GetHasWeapon() != NULL && Config.GetPalPlayerCharacter()->ShooterComponent->CanShoot()) - { - Config.GetPalPlayerCharacter()->ShooterComponent->GetHasWeapon()->IsRequiredBullet = !Config.IsInfinAmmo; - } - } if (Config.IsGodMode) - { - if (Config.GetPalPlayerCharacter() && Config.GetPalPlayerCharacter()->CharacterParameterComponent && Config.GetPalPlayerCharacter()->CharacterParameterComponent->IndividualParameter) - { - if (Config.GetPalPlayerCharacter()->CharacterParameterComponent->IndividualParameter->GetHP().Value < INT_MAX) - Config.GetPalPlayerCharacter()->ReviveCharacter_ToServer(SDK::FFixedPoint(INT_MAX)); - } - } + ReviveLocalPlayer(); } } \ No newline at end of file