[Quest API] Further char array cleanup. (#1634)

- Cleans up the rest of the char arrays used when exporting to events.
- Converts all events to use a similar variable name for export `export_string`.
- Needless calls to .c_str() removed.
This commit is contained in:
Kinglykrab
2021-10-24 17:06:22 -04:00
committed by GitHub
parent 624d11de4e
commit c98f3cfb4c
12 changed files with 107 additions and 99 deletions
+12 -2
View File
@@ -43,7 +43,12 @@ void CheatManager::CheatDetected(CheatTypes type, glm::vec3 position1, glm::vec3
zone->GetShortName()
);
LogCheat(message);
std::string export_string = fmt::format("{} {} {}", position1.x, position1.y, position1.z);
std::string export_string = fmt::format(
"{} {} {}",
position1.x,
position1.y,
position1.z
);
parse->EventPlayer(EVENT_WARP, m_target, export_string, 0);
}
break;
@@ -67,7 +72,12 @@ void CheatManager::CheatDetected(CheatTypes type, glm::vec3 position1, glm::vec3
zone->GetShortName()
);
LogCheat(message);
std::string export_string = fmt::format("{} {} {}", position1.x, position1.y, position1.z);
std::string export_string = fmt::format(
"{} {} {}",
position1.x,
position1.y,
position1.z
);
parse->EventPlayer(EVENT_WARP, m_target, export_string, 0);
m_time_since_last_warp_detection.Start(2500);
}