Suit sensor toggle

- Changes the suit sensor toggle verb to select from a list, instead of cycling through one mode at a time.
This commit is contained in:
Loganbacca
2014-02-27 17:04:37 +13:00
parent 4dba3aa7ee
commit fbfdccebaf
+8 -6
View File
@@ -285,16 +285,18 @@ BLIND // can't see anything
var/mob/M = usr
if (istype(M, /mob/dead/)) return
if (usr.stat) return
if(src.has_sensor >= 2)
if(has_sensor >= 2)
usr << "The controls are locked."
return 0
if(src.has_sensor <= 0)
if(has_sensor <= 0)
usr << "This suit does not have any sensors."
return 0
src.sensor_mode += 1
if(src.sensor_mode > 3)
src.sensor_mode = 0
switch(src.sensor_mode)
var/list/modes = list("Off", "Binary sensors", "Vitals tracker", "Tracking beacon")
var/switchMode = input("Select a sensor mode:", "Suit Sensor Mode", modes[sensor_mode + 1]) in modes
sensor_mode = modes.Find(switchMode) - 1
switch(sensor_mode)
if(0)
usr << "You disable your suit's remote sensing equipment."
if(1)