SA-MP Forums

Go Back   SA-MP Forums > SA-MP > Bug Reports

Reply
 
Thread Tools Display Modes
Old 06/04/2018, 07:16 PM   #1
sOflY
Little Clucker
 
Join Date: Aug 2014
Posts: 3
Reputation: 0
Default Move actors using animations

In SAMP 0.3.DL-R1, actors can move by using this animations:
Code:
ApplyActorAnimation(actorid, !"ped", !"WALK_drunk" ,4.1,1,1,1,0,0);
ApplyActorAnimation(actorid, !"ped", !"Crouch_Roll_L" , 4.1,1,1,1,0,0);
But they can move only by using
Code:
SetActorInvulnerable(actorid, 0);
Actors can move, but their coords don't change. I don't know how it does work, but it work)
Does it bug or feature?
sOflY is offline   Reply With Quote
Old 07/04/2018, 07:11 PM   #2
Abagail
High-roller
 
Join Date: Dec 2013
Location: GetPlayerPos(playerid, pos); Scripter/Mapper.
Posts: 3,493
Reputation: 439
Default Re: Move actors using animations

Quote:
Originally Posted by sOflY View Post
In SAMP 0.3.DL-R1, actors can move by using this animations:
Code:
ApplyActorAnimation(actorid, !"ped", !"WALK_drunk" ,4.1,1,1,1,0,0);
ApplyActorAnimation(actorid, !"ped", !"Crouch_Roll_L" , 4.1,1,1,1,0,0);
But they can move only by using
Code:
SetActorInvulnerable(actorid, 0);
Actors can move, but their coords don't change. I don't know how it does work, but it work)
Does it bug or feature?
Actors aren't meant to walk, so position changes not pushed (i.e: SetActorPos) won't be synced, your client is the only one who sees the actor moving. The server has no idea they're using an animation or that their position has changed, and actors may desync positions across clients (so different players may see them at a different place under certain conditions).
Abagail is offline   Reply With Quote
Old 18/04/2018, 09:40 AM   #3
ATomas
Huge Clucker
 
Join Date: Jul 2009
Location: Czech Republic
Posts: 256
Reputation: 7
Default Re: Move actors using animations

That's great. I hope again the actor will not be frozen.

Although x and y do not change, they can be estimated by helping animation time and the surrounding environment
ATomas is offline   Reply With Quote
Old 29/04/2018, 09:24 PM   #4
sOflY
Little Clucker
 
Join Date: Aug 2014
Posts: 3
Reputation: 0
Default Re: Move actors using animations

Quote:
Originally Posted by Abagail View Post
Actors aren't meant to walk, so position changes not pushed (i.e: SetActorPos) won't be synced, your client is the only one who sees the actor moving. The server has no idea they're using an animation or that their position has changed, and actors may desync positions across clients (so different players may see them at a different place under certain conditions).
I know. I didn't wanted to say, that positions of actors isn't change, I wanted to say, that actors CAN move using animations
sOflY is offline   Reply With Quote
Old 30/04/2018, 12:09 AM   #5
MarkNelson
Huge Clucker
 
MarkNelson's Avatar
 
Join Date: Feb 2016
Location: Tunisia
Posts: 465
Reputation: 46
Default Re: Move actors using animations

what about using the walk animation and using a timer which teleports the actor by 1cm every 200 milliseconds ?
__________________
Code:
[Filterscript] Mechanic System V0.1 BETA
[Filterscript] Simple PM System
[Filterscript] Mechanic System V0.1 (Improved Version)
Please donate here:
paypal.me/Clark783
MarkNelson is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to stop actor's animation after the Player stops targetting actor? humayunaftabkhan02 Scripting Help 0 05/05/2016 08:12 PM
[HELP]: Actor Animation Profeta22 Scripting Help 11 02/02/2016 07:27 PM
Actor animation SkullFire Scripting Help 7 26/07/2015 06:03 AM
Actor Animation - It does not work the first norton2 Scripting Help 6 25/05/2015 04:55 PM


All times are GMT. The time now is 03:32 AM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.