Don't permasync non-looped anims

This commit is contained in:
Vortrex
2022-12-18 15:21:39 -06:00
parent 59d41f8482
commit e1f6f62ada
3 changed files with 23 additions and 15 deletions

View File

@@ -1012,7 +1012,9 @@ function sendPlayerEnterPropertyKey(client, key) {
// ===========================================================================
function makePedPlayAnimation(ped, animationSlot, positionOffset) {
setEntityData(ped, "agrp.anim", animationSlot, true);
if (getAnimationData(animationSlot).loop == true) {
setEntityData(ped, "agrp.anim", animationSlot, true);
}
sendNetworkEventToPlayer("agrp.anim", null, getPedForNetworkEvent(ped), animationSlot, positionOffset);
}