Scripting/Server/Classes/Vehicle/onPlayerEditDecal
(v0.3.5+) Result of the decal editor. pos and rot are in the VEHICLE's frame (x right, y forward, z up, metres; rotation in degrees), width / height in metres. response: EDIT_RESPONSE_CANCEL 0, EDIT_RESPONSE_FINAL 1 (already applied to the decal), EDIT_RESPONSE_UPDATE 2 (live drags, rate limited).
Syntax
onPlayerEditDecal(player, vehicle, decalId, response, pos, rot, width, height)Arguments
- Player player
- Vehicle vehicle
- int decalId
- any response
- Vector pos
- Vector rot
- float width
- float height
Example
function onPlayerCommand( player, cmd, params )
{
if ( cmd == "onplayereditdecal" )
{
onPlayerEditDecal( player, veh, 0, 0, player.Pos, Vector( 0.0, 0.0, 90.0 ), 100, 100 );
}
}This sample was generated from the signature – adapt the values to your gamemode.
Related pages
- vehicle.Remove
- vehicle.Respawn
- vehicle.Fix
- vehicle.Explode
- vehicle.SetBurstableTyres
- player.AttachTo
- object.AttachTo
- object.AttachToBone
- vehicle.SetComponentStatus
- vehicle.SetComponentStatus
- vehicle.SetComponentAngle
- vehicle.SetComponentColour
Section: Vehicle
Categories: Server methods | Vehicle