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:
@@ -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`.
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user