Clipper_ Posted December 11, 2017 Posted December 11, 2017 For Christmas I want to create a script which adds a Santa Hat on the head of the local player by a command. During the development, I had 2 ideas: 1. Replacing the model of an existing Hat cloth is impossible and leads to a game crash. MTA seem to not have support for clothes ID, only for texture replacement. 2. Positioning another small object (with replaced texture and model) on top of the player's head is another solution. Here, the problem is the position where the hat should be placed: getting the coordonates of the highest "bone" of the ped with getPedBonePosition leads to small changes through the vales, so the hat is not moving with the head like it should behave. If you have a solution for getting the position of any body part (in this case the head), it will be a big help I will comment with the code if needed.
itHyperoX Posted December 11, 2017 Posted December 11, 2017 (edited) replace it with 1 object createObject, attachObject, setObjectSize, Edited December 11, 2017 by TheMOG
Mahlukat Posted December 12, 2017 Posted December 12, 2017 You can check this: https://community.multitheftauto.com/index.php?p=resources&s=details&id=14125
DRW Posted December 12, 2017 Posted December 12, 2017 Use bone_attach's exported functions. https://community.multitheftauto.com/index.php?p=resources&s=details&id=2540
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