-
-
Notifications
You must be signed in to change notification settings - Fork 452
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add killPedTask function #3808
add killPedTask function #3808
Conversation
What would happen if you kill ped task while being in the air (complex jump tasks)? |
u will fall stand still the animation will stop but you have to call it in each frame like onClientRender function displayMyTask ()
killPedTask(localPlayer, "primary", 1)
local x,y = 100,200
for k=0,4 do
local a,b,c,d = getPedTask ( localPlayer, "primary", k )
dxDrawText ( "Primary task #"..k.." is "..tostring(a).." -> "..tostring(b).." -> "..tostring(c).." -> "..tostring(d).." -> ", x, y )
y = y + 15
end
y = y + 15
for k=0,5 do
local a,b,c,d = getPedTask ( localPlayer, "secondary", k )
dxDrawText ( "Secondary task #"..k.." is "..tostring(a).." -> "..tostring(b).." -> "..tostring(c).." -> "..tostring(d).." -> ", x, y )
y = y + 15
end
end
addEventHandler ( "onClientRender", root, displayMyTask ) |
Would you still continue the jump but without an animation or would the jump be cut off and instead of making the jump you will fall straight down? |
I do not know about jumping while in air do you mean jump after an object then fall in air? |
I mean, you jump then immediately after you kill the task. What would happen? Would the jump finish but without animation or would it freeze in the air for a small time and then fly straight down? |
you better test it than explain 😅 |
Thanks, please add it to wiki |
killPedTask(ped, string taskType, int taskNumber, [bool gracefully = true])
issue related #3806
exmaple kill jump task