mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-10 10:12:45 +00:00
MULE destination update
- MULE destination selection is now handled using a list
This commit is contained in:
@@ -305,7 +305,14 @@
|
||||
|
||||
if("destination")
|
||||
refresh=0
|
||||
var/new_dest = input("Enter new destination tag", "Mulebot [suffix ? "([suffix])" : ""]", destination) as text|null
|
||||
var/new_dest
|
||||
var/list/beaconlist = new()
|
||||
for(var/obj/machinery/navbeacon/N in navbeacons)
|
||||
beaconlist.Add(N.location)
|
||||
if(beaconlist.len)
|
||||
new_dest = input("Select new destination tag", "Mulebot [suffix ? "([suffix])" : ""]", destination) in beaconlist
|
||||
else
|
||||
alert("No destination beacons available.")
|
||||
refresh=1
|
||||
if(new_dest)
|
||||
set_destination(new_dest)
|
||||
@@ -741,11 +748,6 @@
|
||||
if(!on)
|
||||
return
|
||||
|
||||
/*
|
||||
world << "rec signal: [signal.source]"
|
||||
for(var/x in signal.data)
|
||||
world << "* [x] = [signal.data[x]]"
|
||||
*/
|
||||
var/recv = signal.data["command"]
|
||||
// process all-bot input
|
||||
if(recv=="bot_status" && wires.RemoteRX())
|
||||
|
||||
@@ -1,6 +1,9 @@
|
||||
// Navigation beacon for AI robots
|
||||
// Functions as a transponder: looks for incoming signal matching
|
||||
|
||||
|
||||
var/global/list/navbeacons // no I don't like putting this in, but it will do for now
|
||||
|
||||
/obj/machinery/navbeacon
|
||||
|
||||
icon = 'icons/obj/objects.dmi'
|
||||
@@ -27,6 +30,13 @@
|
||||
|
||||
var/turf/T = loc
|
||||
hide(T.intact)
|
||||
|
||||
// add beacon to MULE bot beacon list
|
||||
if(freq == 1400)
|
||||
if(!navbeacons)
|
||||
navbeacons = new()
|
||||
navbeacons += src
|
||||
|
||||
|
||||
spawn(5) // must wait for map loading to finish
|
||||
if(radio_controller)
|
||||
@@ -241,6 +251,7 @@ Transponder Codes:<UL>"}
|
||||
updateDialog()
|
||||
|
||||
/obj/machinery/navbeacon/Destroy()
|
||||
navbeacons.Remove(src)
|
||||
if(radio_controller)
|
||||
radio_controller.remove_object(src, freq)
|
||||
..()
|
||||
|
||||
4
html/changelogs/Loganbacca-QOLMULE.yml
Normal file
4
html/changelogs/Loganbacca-QOLMULE.yml
Normal file
@@ -0,0 +1,4 @@
|
||||
author: Loganbacca
|
||||
delete-after: True
|
||||
changes:
|
||||
- tweak: "Changed MULE destination selection to be list based."
|
||||
Reference in New Issue
Block a user