As the title says, the AI won't aim their weapon or change their head direction during the first loop of a playMove/playAction/etc.
This bug affects both head and weapon aiming.
Description
Description
Details
Details
- Severity
- Minor
- Resolution
- Open
- Reproducibility
- Always
- Operating System
- Windows 7
- Category
- AI Aiming / Shooting
Steps To Reproduce
Simply give an AI a playMove in a loop. E.g:
Place an AI in editor. Set his var name to "AI". Also, place an enemy unit in front of him. Name him "aiTarget".
Run this sample code in debug console:
[] spawn { _lastDir = 0; aiTarget disableAI "ALL"; ai setSkill 1; ai disableAI "MOVE"; ai doWatch aiTarget; ai doTarget aiTarget; aiTarget allowDamage false; _time = time+3; waitUntil { ai playMoveNow (["amovpercmtacsraswrfldl", "amovpercmtacsraswrfldr"] select _lastDir); ai forceWeaponFire [currentWeapon ai, currentWeaponMode ai]; ai reveal aiTarget; if (time - _time > 3) then { _time = time; aiTarget attachTo [ai, [0, 5, ([2, 5] select _lastDir)]]; }; _lastDir = 1 - _lastDir; ai setAmmo [currentWeapon ai, 10]; sleep 0.3; false } };
This will make the AI constantly shoot at the target while playing an animation in a loop.
The problem is, the AI cannot aim up or down even though the target is right in front of him.
Related Objects
Related Objects