Replace remaining occurances of CVar_GetVar with CVar_Get

This commit is contained in:
Sirius902 2022-05-11 12:44:12 -07:00 committed by louist103
parent bf2825e9a5
commit c7e552fc5f
2 changed files with 2 additions and 3 deletions

View File

@ -43,7 +43,6 @@ void CVar_RegisterString(const char* name, const char* defaultValue);
#include <memory>
extern std::map<std::string, std::unique_ptr<CVar>, std::less<>> cvars;
CVar* CVar_GetVar(const char* name);
void CVar_SetFloat(const char* name, float value);
void CVar_SetString(const char* name, const char* value);
#endif

View File

@ -128,7 +128,7 @@ void Ship::GameOverlay::Draw() {
if (overlay.type == OverlayType::TEXT) {
const char* text = ImStrdup(key.c_str());
const CVar* var = CVar_GetVar(text);
const CVar* var = CVar_Get(text);
switch (var->type) {
case CVAR_TYPE_FLOAT:
@ -156,7 +156,7 @@ bool Ship::OverlayCommand(const std::vector<std::string>& args) {
return CMD_FAILED;
}
if (CVar_GetVar(args[2].c_str()) != nullptr) {
if (CVar_Get(args[2].c_str()) != nullptr) {
const char* key = args[2].c_str();
GameOverlay* overlay = SohImGui::overlay;
if (args[1] == "add") {