Kazafka Posted January 17, 2020 Share Posted January 17, 2020 (edited) Okay, I've learnt to make infinte timers, for my idle animation script, so how (if it is possible), can I reset idle time of a player, because animation is playing each 30s not each 60s. Any help? *!!!EXCEPT DISCONNECTING!!!* Edited January 17, 2020 by VaporZ Link to comment
FIY9AL Posted January 18, 2020 Share Posted January 18, 2020 16 hours ago, VaporZ said: Okay, I've learnt to make infinte timers, for my idle animation script, so how (if it is possible), can I reset idle time of a player, because animation is playing each 30s not each 60s. Any help? *!!!EXCEPT DISCONNECTING!!!* can explain more please ? i didn't understand what is idle animation, but you better see anim function in wiki: setPedAnimation bool setPedAnimation ( ped thePed [, string block = nil, string anim = nil, int time = -1, bool loop = true, bool updatePosition = true, bool interruptable = true, bool freezeLastFrame = true, int blendTime = 250, bool retainPedState = false ] ) there is [time, loop, blendTime and retainPedState] arguments it may be helpful in your case. Optional Arguments NOTE: When using optional arguments, you might need to supply all arguments before the one you wish to use. For more information on optional arguments, see optional arguments. block: the animation block's name. anim: the name of the animation within the block. time: how long the animation will run for in milliseconds. loop: indicates whether or not the animation will loop. updatePosition: will change the actual coordinates of the ped according to the animation. Use this for e.g. walking animations. interruptable: if set to false other tasks wont be able to interupt the animation. Setting this to 'false' also gives this function more power to override other animations that are running. For example, squatting after a jump can be terminated. freezeLastFrame: if set to true after animation the last frame will be frozen, otherwise the animation will end and controls will return. blendTime: how long the animation will mixed with the previous one in milliseconds. retainPedState: will restore the task which was playing before calling this function. Useful for restoring the crouch task after animation ends. This may be extended in the future to support other states/tasks. Link to comment
Kazafka Posted January 18, 2020 Author Share Posted January 18, 2020 23 minutes ago, FIY9AL said: can explain more please ? i didn't understand what is idle animation, but you better see anim function in wiki: setPedAnimation I meant, i've created my function for idle animations, not ready-to-use animations. And how can I reset players' idle time. So? WUTEVA, I DON'T NEED HELP WITH THIS ANYMORE! Link to comment
Moderators IIYAMA Posted January 18, 2020 Moderators Share Posted January 18, 2020 25 minutes ago, VaporZ said: I meant, i've created my function for idle animations, not ready-to-use animations. And how can I reset players' idle time. So? WUTEVA, I DON'T NEED HELP WITH THIS ANYMORE! Please behave yourself. We do not want to inherit your stress. 1 Link to comment
Kazafka Posted January 18, 2020 Author Share Posted January 18, 2020 4 minutes ago, IIYAMA said: Please behave yourself. We do not want to inherit your stress. Im not raged i just wanted to make this message like important, etc. xDDD Link to comment
Moderators IIYAMA Posted January 18, 2020 Moderators Share Posted January 18, 2020 10 minutes ago, VaporZ said: Im not raged i just wanted to make this message like important, etc. xDDD Ah oke Just don't add words that make it really aggressive: I meant, i've created my function for idle animations, not ready-to-use animations. And how can I reset players' idle time. So? WUTEVA, I DON'T NEED HELP WITH THIS ANYMORE! It will back fire and you get less help instead of more. 1 Link to comment
FIY9AL Posted January 18, 2020 Share Posted January 18, 2020 3 hours ago, VaporZ said: I meant, i've created my function for idle animations, not ready-to-use animations. And how can I reset players' idle time. So? WUTEVA, I DON'T NEED HELP WITH THIS ANYMORE! Please provied the codes that you have made and explain your idea more and make it clear to help you . Link to comment
JeViCo Posted January 19, 2020 Share Posted January 19, 2020 You can kill the timer and recreate it lmao use sourceTimer variable inside timer's callback function Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now