Swagy Posted April 3, 2019 Share Posted April 3, 2019 Hey there, I was wondering if I can automate player's movement. In other words how to move a player to another position (without using setElementPosition). The player would walk till he reaches that position. ? Link to comment
Moderators Patrick Posted April 3, 2019 Moderators Share Posted April 3, 2019 You can move player with: https://wiki.multitheftauto.com/wiki/SetPedControlState If that's what you mean. Link to comment
Swagy Posted April 3, 2019 Author Share Posted April 3, 2019 1 hour ago, stPatrick said: You can move player with: https://wiki.multitheftauto.com/wiki/SetPedControlState If that's what you mean. It's kind of it, but I want to know what controls shall I use to reach "X" position and some stuff... You gave me an idea on the function tho, thanks Link to comment
Ayush Rathore Posted April 6, 2019 Share Posted April 6, 2019 On 03/04/2019 at 15:27, UDC said: It's kind of it, but I want to know what controls shall I use to reach "X" position and some stuff... You gave me an idea on the function tho, thanks https://community.multitheftauto.com/index.php?p=resources&s=details&id=347 This resource might help you. Link to comment
Swagy Posted April 6, 2019 Author Share Posted April 6, 2019 4 hours ago, Ayush Rathore said: https://community.multitheftauto.com/index.php?p=resources&s=details&id=347 This resource might help you. Actually this resource uses Slothbot, while I want to create my personal Ped Moving syste... Link to comment
Gordon_G Posted April 9, 2019 Share Posted April 9, 2019 I've worked on it, it's a very difficult subject In fact if you use setPedControlState, you'll have a lot of issue Firstly, it'll depends on client's framerate because this function is client side also you might have sync issues The best thing I could advise you is to freeze the player, then move him with setElementPosition every frame and during this process using setPedControlState to make him acts like if he was walking Or you could synchronise the position of your bots with the server so they are synchronized 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