2
0
mirror of https://github.com/AxioDL/metaforce.git synced 2025-08-06 20:15:35 +00:00

CStateMachine: Fix state name lookup

This commit is contained in:
Luke Street 2022-03-12 15:43:30 -05:00
parent a342859b51
commit ce646610cc

View File

@ -20,10 +20,10 @@ CStateMachine::CStateMachine(CInputStream& in) {
std::string name;
while (name.size() < 31) {
const auto chr = in.ReadChar();
name += chr;
if (chr == '\0') {
break;
}
name += chr;
}
CAiStateFunc func = CAi::GetStateFunc(name);
x0_states.emplace_back(func, name.c_str());