setPedBodyShape
Shared
Changes a ped's body by a named shape, which enlarges the bones it declares.
bool setPedBodyShape(ped ped, string name, float factor)
Parameters
| Name | Type | Description |
|---|---|---|
| ped | ped | The ped or player. |
| name | string | The shape's name, as the ped's skeleton declares it in <BodyShapes>. Up to 16 characters. |
| factor | float | From 0 (no shape) to 1 (the shape at its fullest). |
Returns
true if the shape was applied, false if the ped already has 4 shapes other than 0.
A factor of 0 removes the shape from the ped. On the server, the change is sent to every client. On the client, it applies to this client only.
Example
addEventHandler("onPlayerSpawn", root, function()
setPedBodyShape(source, "muscle", 0.6)
end)