← Tools
Attached object editor
Hang up to ten objects on a player’s bones, exactly as SetPlayerAttachedObject places them in the game, and get the code back. No need to join a server and copy numbers out of a log.
Loading the player…
Skin
Slots
2/10Model
19006…
Quick picks
Material colour 1
Material colour 2
Pawn code
Code for
SA-MP and open.mp take this code just as it is: the choice only picks the includes it is compiled with.
Paste your code
Paste one or more SetPlayerAttachedObject lines, straight from your script, and press Load to edit them. They replace what is above.
How attached objects are placed
- The offset is in metres along the bone’s own axes, the rotation in degrees about X, then Y, then Z, and the scale stretches the model along its own axes once it is turned. The view does the same, so what you see is what the game shows.
- SA-MP’s bone numbers are the game’s own body parts: 1 is the upper spine (the chest), 2 the head, 5 and 6 the hands. Each object hangs on the very bone the game uses.
- Pasted lines can come straight from a script: comments, a variable for the player and arguments left at their defaults are all fine. A line whose slot is a define gets the next free slot.
- Play an animation to check the object moves with the body. A walk swings the arms and the head, which shows a badly placed hat or gun at once.
- Material colours are ARGB (0xAARRGGBB) and 0 keeps the model’s own. The colour tints the texture of the model’s first and second material.
Everything happens in your browser: nothing you paste or make is uploaded.