Jump to content

Attach an object to a player


Sharingan

Recommended Posts

getLocalPlayer 
getPedBonePosition 
setElementPosition 
"onClientRender"/"onClientPreRender"/setTimer 

You can do this client-side without problems. Also you can do it server-side, but it will take more CPU from both client and server, so I suggest you do this client-only.

NOTE: To make the object rotate in the direction of the bone, you must get the position of 2 bones. For example, for the right hand:

Bones.jpg

You will need to get the position of the bone 25 and the bone 23, then use THIS FUNCTION:

https://wiki.multitheftauto.com/wiki/FindRotation

Edited by Guest
Link to comment

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...