Squirrel/Server/Functions/Vehicles/Marker
From Liberty Unleashed Wiki
(Difference between revisions)
(→Example 1. Returning) |
(→Example) |
||
Line 26: | Line 26: | ||
veh.Marker = BLIPTYPE_ARROWONLY; | veh.Marker = BLIPTYPE_ARROWONLY; | ||
else | else | ||
− | MessagePlayer( "[# | + | MessagePlayer( "[#00ff00]*System* [#ff0000]You are not in a vehicle", plr ); |
} | } | ||
Latest revision as of 14:21, 10 August 2013
This function sets/returns the vehicles radar marker type.
[edit] Syntax
int vehicle.Marker
vehicle.Marker = int value
[edit] Arguments
- value - The type of the blip. For reference, check here.
[edit] Example
This will tell the player the type of the marker on their vehicle when they type '/marker'.
function onPlayerCommand( plr, cmd, text ) { if ( cmd == "Arrow" ) { local veh = plr.Vehicle; if ( veh ) veh.Marker = BLIPTYPE_ARROWONLY; else MessagePlayer( "[#00ff00]*System* [#ff0000]You are not in a vehicle", plr ); } return 1; } function onPlayerExitingVehicle( player, vehicle ) { vehicle.Marker = false; return 0; }
[edit] Notes
The function MessagePlayer and event onPlayerCommand were used in these examples. More info about them in the corresponding pages.
[edit] Related Functions
- CreateVehicle
- FindVehicle
- GetClosestVehicle
- GetVehicleCount
- GetVehicleHandlingData
- GetVehicleIDFromName
- GetVehicleName
- SetVehicleHandlingData
- Vehicle.Alpha
- Vehicle.Angle
- Vehicle.Colour1
- Vehicle.Colour2
- Vehicle.Driver
- Vehicle.EngineDamage
- Vehicle.Explode
- Vehicle.Fix
- Vehicle.GetAddon
- Vehicle.GetPassenger
- Vehicle.GetHandlingData
- Vehicle.GetWheelStatus
- Vehicle.Health
- Vehicle.ID
- Vehicle.IdleRespawnTime
- Vehicle.IdleTime
- Vehicle.LightState
- Vehicle.Locked
- Vehicle.Marker
- Vehicle.MarkerScale
- Vehicle.MarkerSprite
- Vehicle.Model
- Vehicle.OneTime
- Vehicle.PassengerCount
- Vehicle.Pos
- Vehicle.Remove
- Vehicle.Respawn
- Vehicle.RespawnTime
- Vehicle.RGBColour1
- Vehicle.RGBColour2
- Vehicle.SetHandlingData
- Vehicle.SetWheelStatus
- Vehicle.SpawnAngle
- Vehicle.SpawnPos
- Vehicle.SetAddon
- Vehicle.SetEngineState
- Vehicle.SetRadio
- Vehicle.Siren
- Vehicle.SirenLight
- Vehicle.TaxiLight
- Vehicle.Velocity
- Vehicle.VirtualWorld
- Vehicle.Wrecked