When enabling animation on the bot using the function:
HumanCommandActionCallback a = HumanCommandActionCallback.Cast( unit.StartCommand_Action(DayZPlayerConstants.CMD_GESTUREFB_SOS, HumanCommandActionCallback,0));
We see an error in the server logs:
SCRIPT (E): NULL pointer to instance
Class: 'DayZPlayerImplementSwimming'
Function: 'HandleSwimming'
Stack trace:
scripts/4_World/entities\dayzplayerimplementswimming.c:58
scripts/4_World/entities\dayzplayerimplement.c:1934
According to the logs, I determined that at the time of completion of the animation in HandleSwimming, the pCurrentCommandID variable returns another value of 20, but the pCMove variable is already zero, in the next frame pCurrentCommandID is already 22, as it is necessary, since the animation is already being performed.
Temporary solution:
modded class DayZPlayerImplementSwimming
{
override bool HandleSwimming(int pCurrentCommandID, HumanCommandMove pCMove, HumanMovementState pState)
{
if (pCMove == NULL)return false; return super.HandleSwimming(pCurrentCommandID,pCMove,pState);
}
}