mirror of
https://github.com/Michatec/wk_wars2x.git
synced 2026-04-01 08:26:27 +02:00
Added radar power functions
This commit is contained in:
15
cl_radar.lua
15
cl_radar.lua
@@ -34,6 +34,9 @@ end )
|
|||||||
------------------------------------------------------------------------]]--
|
------------------------------------------------------------------------]]--
|
||||||
RADAR.vars =
|
RADAR.vars =
|
||||||
{
|
{
|
||||||
|
-- The radar's power
|
||||||
|
power = false,
|
||||||
|
|
||||||
-- Player's vehicle speed, this is used to update the patrol vehicle speed on the radar
|
-- Player's vehicle speed, this is used to update the patrol vehicle speed on the radar
|
||||||
patrolSpeed = 0,
|
patrolSpeed = 0,
|
||||||
|
|
||||||
@@ -136,6 +139,18 @@ RADAR.sorting = {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
--[[------------------------------------------------------------------------
|
||||||
|
Radar essentials functions
|
||||||
|
------------------------------------------------------------------------]]--
|
||||||
|
function RADAR:IsPowerOn()
|
||||||
|
return self.vars.power
|
||||||
|
end
|
||||||
|
|
||||||
|
function RADAR:TogglePower()
|
||||||
|
self.vars.power = not self.vars.power
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
--[[------------------------------------------------------------------------
|
--[[------------------------------------------------------------------------
|
||||||
Radar basics functions
|
Radar basics functions
|
||||||
------------------------------------------------------------------------]]--
|
------------------------------------------------------------------------]]--
|
||||||
|
|||||||
Reference in New Issue
Block a user