Fix AnimSet loading for effects

This commit is contained in:
Jim Shield
2025-10-06 02:28:30 +01:00
parent 9a78b057dd
commit 03ca409bf3
2 changed files with 8 additions and 5 deletions

View File

@@ -7,7 +7,10 @@ function AlienEffect()
Wait(math.random(5000, 8000)) Wait(math.random(5000, 8000))
local Ped = PlayerPedId() local Ped = PlayerPedId()
local animDict = "MOVE_M@DRUNK@VERYDRUNK" local animDict = "MOVE_M@DRUNK@VERYDRUNK"
loadAnimDict(animDict) RequestAnimSet(animDict)
while not HasAnimSetLoaded(animDict) do
Wait(100)
end
SetPedCanRagdoll(Ped, true) SetPedCanRagdoll(Ped, true)
ShakeGameplayCam('DRUNK_SHAKE', 2.80) ShakeGameplayCam('DRUNK_SHAKE', 2.80)
SetTimecycleModifier("Drunk") SetTimecycleModifier("Drunk")

View File

@@ -12,13 +12,13 @@ local maxAlcoholCount = 7
local alcoholEffectData = { local alcoholEffectData = {
levels = { levels = {
["min"] = { ["min"] = {
effect = "DrugsMichaelAliensFight", effect = "DrugsMichaelAliensFightIn",
movement = "move_m@drunk@slightlydrunk", movement = "move_m@drunk@slightlydrunk",
camShake = 0.5, camShake = 0.5,
canStumble = false, canStumble = false,
}, },
["mid"] = { ["mid"] = {
effect = "DrugsMichaelAliensFight", effect = "DrugsMichaelAliensFightIn",
movement = "move_m@drunk@moderatedrunk", movement = "move_m@drunk@moderatedrunk",
canRagdoll = true, canRagdoll = true,
camShake = 0.5, camShake = 0.5,
@@ -27,7 +27,7 @@ local alcoholEffectData = {
drunkDriving = true, drunkDriving = true,
}, },
["max"] = { ["max"] = {
effect = "DrugsMichaelAliensFight", effect = "DrugsMichaelAliensFightIn",
movement = "move_m@drunk@verydrunk", movement = "move_m@drunk@verydrunk",
canRagdoll = true, canRagdoll = true,
camShake = 2.8, camShake = 2.8,
@@ -187,7 +187,7 @@ function startAlcoholEffect(data, level)
end end
Wait(1000) Wait(1000)
end end
print("Effect loop broken") --print("Effect loop broken")
end) end)
end end