@@ -73,7 +73,7 @@
|
||||
let currentAnim = animationSyncData.animations[index];
|
||||
let { id, name, animDict, animName, duration, loop, flag } = currentAnim;
|
||||
|
||||
if (loop && !player.isPlayingAnim(animDict, animName, 3)) {
|
||||
if (loop == true && !player.isPlayingAnim(animDict, animName, 3)) {
|
||||
loadAnimDict(animDict, function () {
|
||||
mp.players.exists(player) && 0 !== player.handle && player.taskPlayAnim(animDict, animName, 1, 0, duration, parseInt(flag), 0, !1, !1, !1)
|
||||
});
|
||||
@@ -104,22 +104,21 @@
|
||||
mp.players.exists(entity) && 0 !== entity.handle && entity.taskPlayAnim(animDict, animName, 1, 0, duration, parseInt(flag), 0, !1, !1, !1)
|
||||
});
|
||||
|
||||
if (mp.players.local == entity && loop) {
|
||||
animationBreakTimer = setInterval(() => breakAnimation(entity, id), 120000);
|
||||
}
|
||||
if (mp.players.local == entity) {
|
||||
if (loop == true) {
|
||||
animationBreakTimer = setInterval(() => breakAnimation(id), 120000);
|
||||
} else {
|
||||
let a = setInterval(function () {
|
||||
mp.events.callRemote("CLIENT:ClearAnimationData", true);
|
||||
|
||||
if (!loop) {
|
||||
let a = setInterval(function () {
|
||||
mp.events.callRemote("CLIENT:ClearAnimationData", entity);
|
||||
mp.events.callRemote("CLIENT:AnimPairTransition");
|
||||
|
||||
clearInterval(a);
|
||||
}, duration);
|
||||
clearInterval(a);
|
||||
}, duration);
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
function breakAnimation(entity, id) {
|
||||
mp.events.callRemote("CLIENT:ClearAnimationData", entity);
|
||||
function breakAnimation(id) {
|
||||
mp.events.callRemote("CLIENT:ClearAnimationData", false);
|
||||
let { animName, msg } = animationBreakMessage.find(c => mp.game.joaat(c.animName) == id)
|
||||
|
||||
if (msg)
|
||||
|
||||
Reference in New Issue
Block a user