Vehicle.Marker

From Liberty Unleashed Wiki
Jump to: navigation, search
Home   |   Squirrel Scripting   |   Server Functions   |   Server Events   |   Client Functions   |   Client Events

This function sets/returns the vehicles radar marker type.

Syntax

  1. int vehicle.Marker
  1. vehicle.Marker = int value

Arguments

  • value - The type of the blip. For reference, check here.

Example

This will tell the player the type of the marker on their vehicle when they type '/marker'.

  1.  
  2. function onPlayerCommand( plr, cmd, text )
  3. {
  4. if ( cmd == "Arrow" )
  5. {
  6. local veh = plr.Vehicle;
  7. if ( veh )
  8. veh.Marker = BLIPTYPE_ARROWONLY;
  9. else
  10. MessagePlayer( "[#00ff00]*System* [#ff0000]You are not in a vehicle", plr );
  11. }
  12. return 1;
  13. }
  14.  
  15. function onPlayerExitingVehicle( player, vehicle )
  16. {
  17. vehicle.Marker = false;
  18.  
  19. return 0;
  20. }
  21.  

Notes

The function MessagePlayer and event onPlayerCommand were used in these examples. More info about them in the corresponding pages.

Related Functions

Personal tools
Namespaces

Variants
Actions
Navigation
scripting
Toolbox