It definitely causes a crash when CharacterStatusRemoved is called during an OnCharacterStatus event (if both refer to the same status of the same character). And OnCharacterStatus seems to last until all actions of this event are executed, even if they are in a different event block or executed by another character!

Code
EVENT Status
VARS
	CHARACTER:_Char
ON
	OnCharacterStatus(_Char,STUNNED)
ACTIONS
IF "!c1"
	IsEqual(_Char,__Me)
THEN
	CharacterEvent(_Char,"Remove")
ENDIF

EVENT RemoveStatus
ON
	OnCharacterEvent(__Me,"Remove")
ACTIONS
	CharacterRemoveStatus(__Me,STUNNED)

--> crash

To see the order of executed actions:

Code
EVENT Status
VARS
	CHARACTER:_Char
ON
	OnCharacterStatus(_Char,STUNNED)
ACTIONS
	IF "!c1"
		IsEqual(_Char,__Me)
	THEN
		CharacterEvent(_Char,"Remove")
		CharacterApplyStatus(_Char,CRIPPLED)
	ENDIF

EVENT RemoveStatus
ON
	OnCharacterEvent(__Me,"Remove")
ACTIONS
	CharacterSetAnimationOverride(__Me,"cower")
	CharacterApplyStatus(__Me,DRUNK)
	CharacterApplyStatus(__Me,WEAK)

--> The result for _Char is always: (stunned,) cower, drunk, weak, crippled. CharacterApplyStatus(_Char,CRIPPLED) from __Me seems to be delayed until _Char executed all actions, triggered by the character event "Remove".

A timer can prevent the game from crashing, since the status will be removed after the OnCharacterStatus event. Why this is a problem for the engine overall I don't know. I know nothing about programming.


My mods for DOS 1 EE: FasterAnimations - QuietDay - Samaritan