public AddState ( |
||
state | ||
overwrite | bool | |
return | void |
public void AddState(CharacterState state, bool overwrite = false) {
if (states.Contains(state) && overwrite)
{
RemoveState(state);
}
if (!states.Contains(state))
{
states.Add(state);
AddStateToHistory(state);
}
}