Add GetReactState to CreatureMethods and GetKnownTaxiNodes, SetKnownTaxiNodes to PlayerMethods (#285)

Co-authored-by: iThorgrim <125808072+iThorgrim@users.noreply.github.com>
This commit is contained in:
Aldori
2025-08-10 16:07:18 -04:00
committed by GitHub
parent f272b03042
commit bcfe631307
3 changed files with 86 additions and 0 deletions

View File

@@ -841,6 +841,27 @@ namespace LuaCreature
return 1;
}
/**
* Returns the [Creature]'s current ReactState.
*
* <pre>
* enum ReactState
* {
* REACT_PASSIVE = 0,
* REACT_DEFENSIVE = 1,
* REACT_AGGRESSIVE = 2
* };
* </pre>
*
* @return [ReactState] state
*/
int GetReactState(lua_State* L, Creature* creature)
{
ReactStates state = creature->GetReactState();
lua_pushinteger(L, (int)state);
return 1;
}
/**
* Sets the [Creature]'s NPC flags to `flags`.
*