"
temp += ""
else
- tgui_alert(usr, "You do not have the required rank to do this!")
+ alert(usr, "You do not have the required rank to do this!")
//TEMPORARY MENU FUNCTIONS
else//To properly clear as per clear screen.
temp=null
diff --git a/code/game/machinery/computer/teleporter.dm b/code/game/machinery/computer/teleporter.dm
index 0dd64bf3e8..3e9531097e 100644
--- a/code/game/machinery/computer/teleporter.dm
+++ b/code/game/machinery/computer/teleporter.dm
@@ -139,7 +139,7 @@
if(is_eligible(M))
L[avoid_assoc_duplicate_keys(M.real_name, areaindex)] = M
- var/desc = tgui_input_list(user, "Please select a location to lock in.", "Locking Computer", L)
+ var/desc = input("Please select a location to lock in.", "Locking Computer") as null|anything in L
if(!user.canUseTopic(src, !hasSiliconAccessInArea(user), NO_DEXTERY)) //check if we are still around
return
target = L[desc]
@@ -167,7 +167,7 @@
if(!L.len)
to_chat(user, "No active connected stations located.")
return
- var/desc = tgui_input_list(user, "Please select a station to lock in.", "Locking Computer", L)
+ var/desc = input("Please select a station to lock in.", "Locking Computer") as null|anything in L
if(!user.canUseTopic(src, !hasSiliconAccessInArea(user), NO_DEXTERY)) //again, check if we are still around
return
var/obj/machinery/teleport/station/target_station = L[desc]
diff --git a/code/game/machinery/cryopod.dm b/code/game/machinery/cryopod.dm
index 9474320894..b68e99bdba 100644
--- a/code/game/machinery/cryopod.dm
+++ b/code/game/machinery/cryopod.dm
@@ -101,7 +101,7 @@
updateUsrDialog()
return
- var/obj/I = tgui_input_list(user, "Please choose which object to retrieve.","Object recovery", stored_packages)
+ var/obj/I = input(user, "Please choose which object to retrieve.","Object recovery",null) as null|anything in stored_packages
playsound(src, "terminal_type", 25, 0)
if(!I)
return
@@ -158,12 +158,9 @@
name = "Circuit board (Cryogenic Oversight Console)"
build_path = "/obj/machinery/computer/cryopod"
-/obj/machinery/computer/cryopod/contents_explosion()
+/obj/machinery/computer/cryopod/contents_explosion(severity, target, origin)
return
-/obj/machinery/computer/cryopod/contents_explosion()
- return //don't blow everyone's shit up.
-
/// The box
/obj/item/storage/box/blue/cryostorage_items
w_class = WEIGHT_CLASS_HUGE
@@ -439,7 +436,7 @@
to_chat(user, "You can't put [target] into [src]. They're conscious.")
return
else if(target.client)
- if(tgui_alert(target,"Would you like to enter cryosleep?",,list("Yes","No")) == "No")
+ if(alert(target,"Would you like to enter cryosleep?",,"Yes","No") == "No")
return
var/generic_plsnoleave_message = " Please adminhelp before leaving the round, even if there are no administrators online!"
@@ -462,7 +459,7 @@
LAZYADD(caught_string, "Revolutionary")
if(caught_string)
- tgui_alert(target, "You're a [english_list(caught_string)]![generic_plsnoleave_message][addendum]")
+ alert(target, "You're a [english_list(caught_string)]![generic_plsnoleave_message][addendum]")
target.client.cryo_warned = world.time
return
diff --git a/code/game/machinery/doors/airlock.dm b/code/game/machinery/doors/airlock.dm
index 39749b33fa..982e40a79b 100644
--- a/code/game/machinery/doors/airlock.dm
+++ b/code/game/machinery/doors/airlock.dm
@@ -102,7 +102,7 @@
rad_insulation = RAD_MEDIUM_INSULATION
var/static/list/airlock_overlays = list()
-
+
/// sigh
var/unelectrify_timerid
@@ -1212,7 +1212,7 @@
else
optionlist = list("Standard", "Public", "Engineering", "Atmospherics", "Security", "Command", "Medical", "Research", "Freezer", "Science", "Virology", "Mining", "Maintenance", "External", "External Maintenance")
- var/paintjob = tgui_input_list(user, "Please select a paintjob for this airlock.", "", optionlist)
+ var/paintjob = input(user, "Please select a paintjob for this airlock.") in optionlist
if((!in_range(src, usr) && src.loc != usr) || !W.use_paint(user))
return
switch(paintjob)
diff --git a/code/game/machinery/doors/door.dm b/code/game/machinery/doors/door.dm
index 9ff03cd387..d1781d9477 100644
--- a/code/game/machinery/doors/door.dm
+++ b/code/game/machinery/doors/door.dm
@@ -407,7 +407,7 @@
if(!stat) //Opens only powered doors.
open() //Open everything!
-/obj/machinery/door/ex_act(severity, target)
+/obj/machinery/door/ex_act(severity, target, origin)
//if it blows up a wall it should blow up a door
..(severity ? max(1, severity - 1) : 0, target)
diff --git a/code/game/machinery/doors/passworddoor.dm b/code/game/machinery/doors/passworddoor.dm
index 0c64151bca..c4f01e58b5 100644
--- a/code/game/machinery/doors/passworddoor.dm
+++ b/code/game/machinery/doors/passworddoor.dm
@@ -69,7 +69,7 @@
/obj/machinery/door/password/emp_act(severity)
return
-/obj/machinery/door/password/ex_act(severity, target)
+/obj/machinery/door/password/ex_act(severity, target, origin)
return
/obj/machinery/door/password/wave_ex_act(power, datum/wave_explosion/explosion, dir)
diff --git a/code/game/machinery/doors/poddoor.dm b/code/game/machinery/doors/poddoor.dm
index 8c7fc692bc..e1c0843f55 100644
--- a/code/game/machinery/doors/poddoor.dm
+++ b/code/game/machinery/doors/poddoor.dm
@@ -68,7 +68,7 @@
return ..()
//"BLAST" doors are obviously stronger than regular doors when it comes to BLASTS.
-/obj/machinery/door/poddoor/ex_act(severity, target)
+/obj/machinery/door/poddoor/ex_act(severity, target, origin)
if(severity == 3)
return
..()
diff --git a/code/game/machinery/hologram.dm b/code/game/machinery/hologram.dm
index 5b2551fa8b..853bd73eac 100644
--- a/code/game/machinery/hologram.dm
+++ b/code/game/machinery/hologram.dm
@@ -264,7 +264,7 @@ GLOBAL_LIST_EMPTY(network_holopads)
if(A)
LAZYADD(callnames[A], I)
callnames -= get_area(src)
- var/result = tgui_input_list(usr, "Choose an area to call", "Holocall", sortNames(callnames))
+ var/result = input(usr, "Choose an area to call", "Holocall") as null|anything in sortNames(callnames)
if(QDELETED(usr) || !result || outgoing_call)
return
if(usr.loc == loc)
diff --git a/code/game/machinery/launch_pad.dm b/code/game/machinery/launch_pad.dm
index 49ff0e7609..87989b18ec 100644
--- a/code/game/machinery/launch_pad.dm
+++ b/code/game/machinery/launch_pad.dm
@@ -339,7 +339,7 @@
pad.display_name = new_name
if("remove")
. = TRUE
- if(usr && tgui_alert(usr, "Are you sure?", "Unlink Launchpad", list("I'm Sure", "Abort")) != "Abort")
+ if(usr && alert(usr, "Are you sure?", "Unlink Launchpad", "I'm Sure", "Abort") != "Abort")
pad = null
if("launch")
sending = TRUE
diff --git a/code/game/machinery/pipe/construction.dm b/code/game/machinery/pipe/construction.dm
index 4d6900983f..5b30105409 100644
--- a/code/game/machinery/pipe/construction.dm
+++ b/code/game/machinery/pipe/construction.dm
@@ -245,7 +245,7 @@ Buildable meters
disposable = FALSE
/obj/item/pipe/bluespace/attack_self(mob/user)
- var/new_name = tgui_input_text(user, "Enter identifier for bluespace pipe network", "bluespace pipe", bluespace_network_name)
+ var/new_name = input(user, "Enter identifier for bluespace pipe network", "bluespace pipe", bluespace_network_name) as text|null
if(!isnull(new_name))
bluespace_network_name = new_name
diff --git a/code/game/machinery/requests_console.dm b/code/game/machinery/requests_console.dm
index 5d1b30741b..d4807e377c 100644
--- a/code/game/machinery/requests_console.dm
+++ b/code/game/machinery/requests_console.dm
@@ -62,7 +62,7 @@ GLOBAL_LIST_EMPTY(allConsoles)
update_icon()
/obj/machinery/requests_console/update_icon_state()
- if(CHECK_BITFIELD(stat, NOPOWER))
+ if((stat & NOPOWER))
set_light(0)
else
set_light(1.4, 0.7, "#34D352")//green light
@@ -72,7 +72,7 @@ GLOBAL_LIST_EMPTY(allConsoles)
icon_state="req_comp_open"
else
icon_state="req_comp_rewired"
- else if(CHECK_BITFIELD(stat, NOPOWER))
+ else if((stat & NOPOWER))
if(icon_state != "req_comp_off")
icon_state = "req_comp_off"
else
diff --git a/code/game/machinery/syndicatebomb.dm b/code/game/machinery/syndicatebomb.dm
index 54663356c7..3bee98b51d 100644
--- a/code/game/machinery/syndicatebomb.dm
+++ b/code/game/machinery/syndicatebomb.dm
@@ -193,11 +193,11 @@
playsound(loc, 'sound/machines/click.ogg', 30, 1)
/obj/machinery/syndicatebomb/proc/settings(mob/user)
- var/new_timer = tgui_input_num(user, "Please set the timer.", "Timer", "[timer_set]")
+ var/new_timer = input(user, "Please set the timer.", "Timer", "[timer_set]") as num
if(in_range(src, user) && isliving(user)) //No running off and setting bombs from across the station
timer_set = clamp(new_timer, minimum_timer, maximum_timer)
loc.visible_message("[icon2html(src, viewers(src))] timer set for [timer_set] seconds.")
- if(tgui_alert(user,"Would you like to start the countdown now?",,list("Yes","No")) == "Yes" && in_range(src, user) && isliving(user))
+ if(alert(user,"Would you like to start the countdown now?",,"Yes","No") == "Yes" && in_range(src, user) && isliving(user))
if(defused || active)
if(defused)
visible_message("[icon2html(src, viewers(src))] Device error: User intervention required.")
@@ -270,7 +270,7 @@
var/range_light = 17
var/range_flame = 17
-/obj/item/bombcore/ex_act(severity, target) // Little boom can chain a big boom.
+/obj/item/bombcore/ex_act(severity, target, origin) // Little boom can chain a big boom.
detonate()
diff --git a/code/game/machinery/telecomms/computers/logbrowser.dm b/code/game/machinery/telecomms/computers/logbrowser.dm
index ca04009e3b..c39c4667a6 100644
--- a/code/game/machinery/telecomms/computers/logbrowser.dm
+++ b/code/game/machinery/telecomms/computers/logbrowser.dm
@@ -1,5 +1,5 @@
/*
- The log console for viewing the entire telecomms
+ The log console for viewing the entire telecomms
network log
*/
@@ -15,7 +15,7 @@
var/network = "NULL" // the network to probe
var/notice = ""
- var/universal_translate = FALSE // set to TRUE(1) if it can translate nonhuman speech
+ var/universal_translate = FALSE // set to TRUE(1) if it can translate nonhuman speech
/obj/machinery/computer/telecomms/server/ui_interact(mob/user, datum/tgui/ui)
ui = SStgui.try_update_ui(user, src, ui)
@@ -53,7 +53,7 @@
if(!LAZYLEN(SelectedMachine.log_entries))
return data_out
-
+
for(var/datum/comm_log_entry/C in SelectedMachine.log_entries)
var/list/data = list()
data["name"] = C.name //name of the file
@@ -104,7 +104,7 @@
data["message"] = C.parameters["message"]
else
data["message"] = "(unintelligible)"
-
+
data_out["selected_logs"] += list(data)
return data_out
@@ -133,7 +133,7 @@
if(LAZYLEN(machinelist) > 0)
notice = "FAILED: Cannot probe when buffer full"
return
-
+
for(var/obj/machinery/telecomms/T in GLOB.telecomms_list) //telecomms just went global!
if(T.network == network)
LAZYADD(machinelist, T)
@@ -147,7 +147,7 @@
SelectedMachine = T
break
if("delete")
- if(!src.allowed(usr) && !CHECK_BITFIELD(obj_flags, EMAGGED))
+ if(!src.allowed(usr) && !(obj_flags & EMAGGED))
to_chat(usr, "ACCESS DENIED.")
return
@@ -156,7 +156,7 @@
return
var/datum/comm_log_entry/D = locate(params["value"])
if(!istype(D))
- notice = "NOTICE: Object not found"
+ notice = "NOTICE: Object not found"
return
notice = "Deleted entry: [D.name]"
LAZYREMOVE(SelectedMachine.log_entries, D)
diff --git a/code/game/machinery/telecomms/computers/message.dm b/code/game/machinery/telecomms/computers/message.dm
index 50792205c8..b4f4b495f8 100644
--- a/code/game/machinery/telecomms/computers/message.dm
+++ b/code/game/machinery/telecomms/computers/message.dm
@@ -94,9 +94,9 @@
if(istype(S) && S.hack_software)
data_out["canhack"] = TRUE
- data_out["hacking"] = (hacking || CHECK_BITFIELD(obj_flags, EMAGGED))
+ data_out["hacking"] = (hacking || (obj_flags & EMAGGED))
if(hacking)
- data_out["borg"] = ((isAI(user) || iscyborg(user)) && !CHECK_BITFIELD(obj_flags, EMAGGED)) //even borgs can't read emag
+ data_out["borg"] = ((isAI(user) || iscyborg(user)) && !(obj_flags & EMAGGED)) //even borgs can't read emag
return data_out
data_out["servers"] = list()
@@ -316,7 +316,7 @@
// Get out list of viable PDAs
var/list/obj/item/pda/sendPDAs = get_viewable_pdas()
if(GLOB.PDAs && LAZYLEN(GLOB.PDAs) > 0)
- customrecepient = tgui_input_list(usr, "Select a PDA from the list.", "", sortNames(sendPDAs))
+ customrecepient = input(usr, "Select a PDA from the list.") as null|anything in sortNames(sendPDAs)
else
customrecepient = null
return
@@ -324,7 +324,7 @@
update_static_data(usr)
/obj/machinery/computer/message_monitor/attackby(obj/item/O, mob/living/user, params)
- if(O.tool_behaviour == TOOL_SCREWDRIVER && CHECK_BITFIELD(obj_flags, EMAGGED))
+ if(O.tool_behaviour == TOOL_SCREWDRIVER && (obj_flags & EMAGGED))
//Stops people from just unscrewing the monitor and putting it back to get the console working again.
//Why this though, you should make it emag to a board level. (i wont do it)
to_chat(user, "It is too hot to mess with!")
@@ -333,12 +333,12 @@
/obj/machinery/computer/message_monitor/emag_act(mob/user)
. = ..()
- if(CHECK_BITFIELD(obj_flags, EMAGGED))
+ if((obj_flags & EMAGGED))
return
if(isnull(linkedServer))
to_chat(user, "A no server error appears on the screen.")
return
- ENABLE_BITFIELD(obj_flags, EMAGGED)
+ obj_flags |= EMAGGED
spark_system.set_up(5, 0, src)
spark_system.start()
var/obj/item/paper/monitorkey/MK = new(loc, linkedServer)
@@ -366,7 +366,7 @@
message = ""
/obj/machinery/computer/message_monitor/proc/UnmagConsole()
- DISABLE_BITFIELD(obj_flags, EMAGGED)
+ obj_flags &= ~(EMAGGED)
message = ""
/obj/machinery/computer/message_monitor/proc/ResetMessage()
diff --git a/code/game/machinery/telecomms/machine_interactions.dm b/code/game/machinery/telecomms/machine_interactions.dm
index ab7b31f530..808dc4877b 100644
--- a/code/game/machinery/telecomms/machine_interactions.dm
+++ b/code/game/machinery/telecomms/machine_interactions.dm
@@ -177,7 +177,7 @@
links.Remove(T)
if("freq")
if("add" in params)
- var/newfreq = tgui_input_num(usr, "Specify a new frequency to filter (GHz). Decimals assigned automatically.", src.name, null)
+ var/newfreq = input("Specify a new frequency to filter (GHz). Decimals assigned automatically.", src.name, null) as null|num
if(!canAccess(usr) || !newfreq || isnull(newfreq))
return
diff --git a/code/game/machinery/telecomms/machines/relay.dm b/code/game/machinery/telecomms/machines/relay.dm
index 10328f0788..14d658e30b 100644
--- a/code/game/machinery/telecomms/machines/relay.dm
+++ b/code/game/machinery/telecomms/machines/relay.dm
@@ -84,6 +84,8 @@
icon = 'icons/obj/clockwork_objects.dmi'
hide = TRUE
autolinkers = list("h_relay")
+ flags_1 = DEFAULT_RICOCHET_1 | NODECONSTRUCT_1
+ resistance_flags = INDESTRUCTIBLE
//Generic preset relay
/obj/machinery/telecomms/relay/preset/auto
diff --git a/code/game/machinery/telecomms/telecomunications.dm b/code/game/machinery/telecomms/telecomunications.dm
index f75eef0b21..a49fb32538 100644
--- a/code/game/machinery/telecomms/telecomunications.dm
+++ b/code/game/machinery/telecomms/telecomunications.dm
@@ -119,7 +119,7 @@ GLOBAL_LIST_EMPTY(telecomms_list)
/obj/machinery/telecomms/proc/update_power()
if(toggled)
// if powered, on. if not powered, off. if too damaged, off
- if(CHECK_BITFIELD(stat, (BROKEN | NOPOWER | EMPED)))
+ if(stat &(BROKEN | NOPOWER | EMPED))
on = FALSE
else
on = TRUE
@@ -137,11 +137,11 @@ GLOBAL_LIST_EMPTY(telecomms_list)
/obj/machinery/telecomms/emp_act(severity)
. = ..()
- if(CHECK_BITFIELD(., EMP_PROTECT_SELF))
+ if((. & EMP_PROTECT_SELF))
return
if(prob(severity))
- if(!CHECK_BITFIELD(stat, EMPED))
- ENABLE_BITFIELD(stat, EMPED)
+ if(!(stat & EMPED))
+ stat |= EMPED
var/duration = severity * 35
spawn(rand(duration - 20, duration + 20)) // Takes a long time for the machines to reboot.
- DISABLE_BITFIELD(stat, EMPED)
+ stat &= ~(EMPED)
diff --git a/code/game/machinery/wishgranter.dm b/code/game/machinery/wishgranter.dm
index b2293f2125..6aeef4b6ac 100644
--- a/code/game/machinery/wishgranter.dm
+++ b/code/game/machinery/wishgranter.dm
@@ -38,7 +38,7 @@
to_chat(user, "You have a very great feeling about this!")
else
to_chat(user, "The Wish Granter awaits your wish.")
- var/wish = tgui_input_list(user, "You want...","Wish", list("Power","Wealth","The Station To Disappear","To Kill","Nothing"))
+ var/wish = input("You want...","Wish") as null|anything in list("Power","Wealth","The Station To Disappear","To Kill","Nothing")
switch(wish)
if("Power") //Gives infinite power in exchange for infinite power going off in your face!
if(charges <= 0)
diff --git a/code/game/mecha/equipment/tools/medical_tools.dm b/code/game/mecha/equipment/tools/medical_tools.dm
index 1435f78718..756cee058c 100644
--- a/code/game/mecha/equipment/tools/medical_tools.dm
+++ b/code/game/mecha/equipment/tools/medical_tools.dm
@@ -276,7 +276,7 @@
/obj/item/mecha_parts/mecha_equipment/medical/syringe_gun/critfail()
..()
if(reagents)
- DISABLE_BITFIELD(reagents.reagents_holder_flags, NO_REACT)
+ reagents.reagents_holder_flags &= ~(NO_REACT)
/obj/item/mecha_parts/mecha_equipment/medical/syringe_gun/can_attach(obj/mecha/medical/M)
if(..())
diff --git a/code/game/mecha/equipment/tools/work_tools.dm b/code/game/mecha/equipment/tools/work_tools.dm
index 4b36b298b3..1c4586205a 100644
--- a/code/game/mecha/equipment/tools/work_tools.dm
+++ b/code/game/mecha/equipment/tools/work_tools.dm
@@ -407,7 +407,7 @@
return
if(href_list["cut"])
if(cable && cable.amount)
- var/m = round(tgui_input_num(chassis.occupant,"Please specify the length of cable to cut","Cut cable",min(cable.amount,30)), 1)
+ var/m = round(input(chassis.occupant,"Please specify the length of cable to cut","Cut cable",min(cable.amount,30)) as num, 1)
m = min(m, cable.amount)
if(m)
use_cable(m)
diff --git a/code/game/mecha/mecha_defense.dm b/code/game/mecha/mecha_defense.dm
index 93a030a004..1db4cc30b9 100644
--- a/code/game/mecha/mecha_defense.dm
+++ b/code/game/mecha/mecha_defense.dm
@@ -111,23 +111,23 @@
mecha_log_message("Hit by projectile. Type: [Proj.name]([Proj.flag]).", color="red")
. = ..()
-/obj/mecha/ex_act(severity, target)
+/obj/mecha/ex_act(severity, target, origin)
mecha_log_message("Affected by explosion of severity: [severity].", color="red")
if(prob(deflect_chance))
severity++
log_append_to_last("Armor saved, changing severity to [severity].")
. = ..()
-/obj/mecha/contents_explosion(severity, target)
+/obj/mecha/contents_explosion(severity, target, origin)
severity++
for(var/X in equipment)
var/obj/item/mecha_parts/mecha_equipment/ME = X
- ME.ex_act(severity,target)
+ ME.ex_act(severity, target, origin)
for(var/Y in trackers)
var/obj/item/mecha_parts/mecha_tracking/MT = Y
- MT.ex_act(severity, target)
+ MT.ex_act(severity, target, origin)
if(occupant)
- occupant.ex_act(severity,target)
+ occupant.ex_act(severity, target, origin)
/obj/mecha/handle_atom_del(atom/A)
if(A == occupant)
diff --git a/code/game/mecha/mecha_topic.dm b/code/game/mecha/mecha_topic.dm
index 7c8324eb37..067cffd319 100644
--- a/code/game/mecha/mecha_topic.dm
+++ b/code/game/mecha/mecha_topic.dm
@@ -246,7 +246,7 @@
output_maintenance_dialog(id_card, usr)
if(href_list["set_internal_tank_valve"] && state >=1)
- var/new_pressure = tgui_input_num(usr,"Input new output pressure","Pressure setting",internal_tank_valve)
+ var/new_pressure = input(usr,"Input new output pressure","Pressure setting",internal_tank_valve) as num
if(new_pressure)
internal_tank_valve = new_pressure
to_chat(usr, "The internal pressure valve has been set to [internal_tank_valve]kPa.")
diff --git a/code/game/mecha/working/ripley.dm b/code/game/mecha/working/ripley.dm
index 5f54f0c93d..3c2f75bd6c 100644
--- a/code/game/mecha/working/ripley.dm
+++ b/code/game/mecha/working/ripley.dm
@@ -144,7 +144,7 @@
return
-/obj/mecha/working/ripley/contents_explosion(severity, target)
+/obj/mecha/working/ripley/contents_explosion(severity, target, origin)
for(var/X in cargo)
var/obj/O = X
if(prob(30/severity))
diff --git a/code/game/objects/buckling.dm b/code/game/objects/buckling.dm
index a203bd172f..afc4312779 100644
--- a/code/game/objects/buckling.dm
+++ b/code/game/objects/buckling.dm
@@ -18,7 +18,7 @@
if(act_intent == INTENT_HELP || act_intent == INTENT_GRAB)
return
if(buckled_mobs.len > 1)
- var/unbuckled = tgui_input_list(user, "Who do you wish to unbuckle?","Unbuckle Who?", buckled_mobs)
+ var/unbuckled = input(user, "Who do you wish to unbuckle?","Unbuckle Who?") as null|mob in buckled_mobs
if(user_unbuckle_mob(unbuckled,user))
return 1
else
@@ -161,6 +161,6 @@
else if(length(buckled_mobs) == 1)
return user_unbuckle_mob(buckled_mobs[1], user)
else
- var/unbuckled = tgui_input_list(user, "Who do you wish to unbuckle?","Unbuckle Who?", buckled_mobs)
+ var/unbuckled = input(user, "Who do you wish to unbuckle?","Unbuckle Who?") as null|mob in buckled_mobs
return user_unbuckle_mob(unbuckled, user)
diff --git a/code/game/objects/effects/anomalies.dm b/code/game/objects/effects/anomalies.dm
index 66579c90f3..39f68bc97c 100644
--- a/code/game/objects/effects/anomalies.dm
+++ b/code/game/objects/effects/anomalies.dm
@@ -69,7 +69,7 @@
/obj/effect/anomaly/proc/detonate()
return
-/obj/effect/anomaly/ex_act(severity, target)
+/obj/effect/anomaly/ex_act(severity, target, origin)
if(severity == 1)
qdel(src)
diff --git a/code/game/objects/effects/countdown.dm b/code/game/objects/effects/countdown.dm
index 6017e8fc07..b425946789 100644
--- a/code/game/objects/effects/countdown.dm
+++ b/code/game/objects/effects/countdown.dm
@@ -60,7 +60,7 @@
STOP_PROCESSING(SSfastprocess, src)
. = ..()
-/obj/effect/countdown/ex_act(severity, target) //immune to explosions
+/obj/effect/countdown/ex_act(severity, target, origin) //immune to explosions
return
/obj/effect/countdown/syndicatebomb
diff --git a/code/game/objects/effects/decals/cleanable.dm b/code/game/objects/effects/decals/cleanable.dm
index 5a6d5e54e9..57ad11e6c4 100644
--- a/code/game/objects/effects/decals/cleanable.dm
+++ b/code/game/objects/effects/decals/cleanable.dm
@@ -77,10 +77,10 @@
else
return ..()
-/obj/effect/decal/cleanable/ex_act()
+/obj/effect/decal/cleanable/ex_act(severity, target, origin)
if(reagents)
for(var/datum/reagent/R in reagents.reagent_list)
- R.on_ex_act()
+ R.on_ex_act(severity)
..()
/obj/effect/decal/cleanable/fire_act(exposed_temperature, exposed_volume)
diff --git a/code/game/objects/effects/decals/cleanable/gibs.dm b/code/game/objects/effects/decals/cleanable/gibs.dm
index 4b63cbecc8..09fbdb6528 100644
--- a/code/game/objects/effects/decals/cleanable/gibs.dm
+++ b/code/game/objects/effects/decals/cleanable/gibs.dm
@@ -36,7 +36,7 @@
. = ..()
return /obj/effect/decal/cleanable/blood/gibs/old
-/obj/effect/decal/cleanable/blood/gibs/ex_act(severity, target)
+/obj/effect/decal/cleanable/blood/gibs/ex_act(severity, target, origin)
return
/obj/effect/decal/cleanable/blood/gibs/Crossed(mob/living/L)
diff --git a/code/game/objects/effects/decals/cleanable/misc.dm b/code/game/objects/effects/decals/cleanable/misc.dm
index fe4ab20617..62e4dbf5f3 100644
--- a/code/game/objects/effects/decals/cleanable/misc.dm
+++ b/code/game/objects/effects/decals/cleanable/misc.dm
@@ -47,7 +47,7 @@
. = ..()
setDir(pick(GLOB.cardinals))
-/obj/effect/decal/cleanable/glass/ex_act()
+/obj/effect/decal/cleanable/glass/ex_act(severity, target, origin)
qdel(src)
/obj/effect/decal/cleanable/glass/wave_ex_act(power, datum/wave_explosion/explosion, dir)
diff --git a/code/game/objects/effects/decals/cleanable/robots.dm b/code/game/objects/effects/decals/cleanable/robots.dm
index 9dd3c2a852..1eb3533f71 100644
--- a/code/game/objects/effects/decals/cleanable/robots.dm
+++ b/code/game/objects/effects/decals/cleanable/robots.dm
@@ -32,7 +32,7 @@
if (!step_to(src, get_step(src, direction), 0))
break
-/obj/effect/decal/cleanable/robot_debris/ex_act()
+/obj/effect/decal/cleanable/robot_debris/ex_act(severity, target, origin)
return
/obj/effect/decal/cleanable/robot_debris/limb
diff --git a/code/game/objects/effects/decals/decal.dm b/code/game/objects/effects/decals/decal.dm
index 5f312f2bf3..cdf16468f4 100644
--- a/code/game/objects/effects/decals/decal.dm
+++ b/code/game/objects/effects/decals/decal.dm
@@ -17,7 +17,7 @@
/obj/effect/decal/proc/NeverShouldHaveComeHere(turf/T)
return isclosedturf(T) || isgroundlessturf(T)
-/obj/effect/decal/ex_act(severity, target)
+/obj/effect/decal/ex_act(severity, target, origin)
qdel(src)
/obj/effect/decal/fire_act(exposed_temperature, exposed_volume)
diff --git a/code/game/objects/effects/effects.dm b/code/game/objects/effects/effects.dm
index 979b811bc5..fb245f7607 100644
--- a/code/game/objects/effects/effects.dm
+++ b/code/game/objects/effects/effects.dm
@@ -30,7 +30,7 @@
/obj/effect/experience_pressure_difference()
return
-/obj/effect/ex_act(severity, target)
+/obj/effect/ex_act(severity, target, origin)
if(target == src)
qdel(src)
else
@@ -51,7 +51,7 @@
/obj/effect/ConveyorMove()
return
-/obj/effect/abstract/ex_act(severity, target)
+/obj/effect/abstract/ex_act(severity, target, origin)
return
/obj/effect/abstract/singularity_pull()
diff --git a/code/game/objects/effects/landmarks.dm b/code/game/objects/effects/landmarks.dm
index a484f78b41..8ff4017b8c 100644
--- a/code/game/objects/effects/landmarks.dm
+++ b/code/game/objects/effects/landmarks.dm
@@ -11,7 +11,7 @@
return
// Please stop bombing the Observer-Start landmark.
-/obj/effect/landmark/ex_act()
+/obj/effect/landmark/ex_act(severity, target, origin)
return
/obj/effect/landmark/singularity_pull()
diff --git a/code/game/objects/effects/temporary_visuals/temporary_visual.dm b/code/game/objects/effects/temporary_visuals/temporary_visual.dm
index 615f392a86..9a4c26111f 100644
--- a/code/game/objects/effects/temporary_visuals/temporary_visual.dm
+++ b/code/game/objects/effects/temporary_visuals/temporary_visual.dm
@@ -25,7 +25,7 @@
/obj/effect/temp_visual/singularity_pull()
return
-/obj/effect/temp_visual/ex_act()
+/obj/effect/temp_visual/ex_act(severity, target, origin)
return
/obj/effect/temp_visual/dir_setting
diff --git a/code/game/objects/items.dm b/code/game/objects/items.dm
index 53f64c57d2..96fd32401a 100644
--- a/code/game/objects/items.dm
+++ b/code/game/objects/items.dm
@@ -450,8 +450,8 @@ GLOBAL_VAR_INIT(embedpocalypse, FALSE) // if true, all items will be able to emb
A.Remove(user)
if(item_flags & DROPDEL)
qdel(src)
- DISABLE_BITFIELD(item_flags, IN_INVENTORY)
- DISABLE_BITFIELD(item_flags, IN_STORAGE)
+ item_flags &= ~(IN_INVENTORY)
+ item_flags &= ~(IN_STORAGE)
SEND_SIGNAL(src, COMSIG_ITEM_DROPPED,user)
remove_outline()
// if(!silent)
@@ -529,8 +529,8 @@ GLOBAL_VAR_INIT(embedpocalypse, FALSE) // if true, all items will be able to emb
if(item_action_slot_check(slot, user, A)) //some items only give their actions buttons when in a specific slot.
A.Grant(user)
item_flags |= IN_INVENTORY
- if(CHECK_BITFIELD(item_flags, IN_STORAGE)) // Left storage item but somehow has the bitfield active still.
- DISABLE_BITFIELD(item_flags, IN_STORAGE)
+ if((item_flags & IN_STORAGE)) // Left storage item but somehow has the bitfield active still.
+ item_flags &= ~(IN_STORAGE)
// if(!initial)
// if(equip_sound && (slot_flags & slot))
// playsound(src, equip_sound, EQUIP_SOUND_VOLUME, TRUE, ignore_walls = FALSE)
@@ -1054,7 +1054,7 @@ GLOBAL_VAR_INIT(embedpocalypse, FALSE) // if true, all items will be able to emb
*/
/obj/item/proc/set_slowdown(new_slowdown)
slowdown = new_slowdown
- if(CHECK_BITFIELD(item_flags, IN_INVENTORY))
+ if((item_flags & IN_INVENTORY))
var/mob/living/L = loc
if(istype(L))
L.update_equipment_speed_mods()
diff --git a/code/game/objects/items/AI_modules.dm b/code/game/objects/items/AI_modules.dm
index dd123c07e8..59dd420d23 100644
--- a/code/game/objects/items/AI_modules.dm
+++ b/code/game/objects/items/AI_modules.dm
@@ -229,11 +229,11 @@ AI MODULES
laws = list("")
/obj/item/aiModule/supplied/freeform/attack_self(mob/user)
- var/newpos = tgui_input_num(user, "Please enter the priority for your new law. Can only write to law sectors 15 and above.", "Law Priority (15+)", lawpos)
+ var/newpos = input("Please enter the priority for your new law. Can only write to law sectors 15 and above.", "Law Priority (15+)", lawpos) as num|null
if(newpos == null)
return
if(newpos < 15)
- var/response = tgui_alert(user, "Error: The law priority of [newpos] is invalid, Law priorities below 14 are reserved for core laws, Would you like to change that that to 15?", "Invalid law priority", list("Change to 15", "Cancel"))
+ var/response = alert("Error: The law priority of [newpos] is invalid, Law priorities below 14 are reserved for core laws, Would you like to change that that to 15?", "Invalid law priority", "Change to 15", "Cancel")
if (!response || response == "Cancel")
return
newpos = 15
@@ -264,7 +264,7 @@ AI MODULES
var/lawpos = 1
/obj/item/aiModule/remove/attack_self(mob/user)
- lawpos = tgui_input_num(user, "Please enter the law you want to delete.", "Law Number", lawpos)
+ lawpos = input("Please enter the law you want to delete.", "Law Number", lawpos) as num|null
if(lawpos == null)
return
if(lawpos <= 0)
diff --git a/code/game/objects/items/apc_frame.dm b/code/game/objects/items/apc_frame.dm
index 3640db2d8a..7e9bea2c5d 100644
--- a/code/game/objects/items/apc_frame.dm
+++ b/code/game/objects/items/apc_frame.dm
@@ -95,7 +95,7 @@
/obj/item/wallframe/apc/try_build(turf/on_wall, user)
if(!..())
return
- var/turf/T = get_turf(on_wall) //the user is not where it needs to be.
+ var/turf/T = get_turf(user)
var/area/A = get_area(T)
if(A.get_apc())
to_chat(user, "This area already has an APC!")
diff --git a/code/game/objects/items/boombox.dm b/code/game/objects/items/boombox.dm
index e0edeede22..49e2375c1a 100644
--- a/code/game/objects/items/boombox.dm
+++ b/code/game/objects/items/boombox.dm
@@ -25,7 +25,7 @@
for(var/datum/track/S in SSjukeboxes.songs)
if(istype(S) && (S.song_associated_id in availabletrackids))
tracklist[S.song_name] = S
- var/selected = tgui_input_list(user, "Play song", "Track:", tracklist)
+ var/selected = input(user, "Play song", "Track:") as null|anything in tracklist
if(QDELETED(src) || !selected || !istype(tracklist[selected], /datum/track))
return
var/jukeboxslottotake = SSjukeboxes.addjukebox(src, tracklist[selected])
diff --git a/code/game/objects/items/cards_ids.dm b/code/game/objects/items/cards_ids.dm
index ad3a6563a5..df7d6467f0 100644
--- a/code/game/objects/items/cards_ids.dm
+++ b/code/game/objects/items/cards_ids.dm
@@ -302,7 +302,7 @@
. = FALSE
var/datum/bank_account/old_account = registered_account
- var/new_bank_id = tgui_input_num(user, "Enter your account ID number.", "Account Reclamation", 111111)
+ var/new_bank_id = input(user, "Enter your account ID number.", "Account Reclamation", 111111) as num | null
if (isnull(new_bank_id))
return
@@ -344,7 +344,7 @@
registered_account.bank_card_talk("ERROR: UNABLE TO LOGIN DUE TO SCHEDULED MAINTENANCE. MAINTENANCE IS SCHEDULED TO COMPLETE IN [(registered_account.withdrawDelay - world.time)/10] SECONDS.", TRUE)
return
- var/amount_to_remove = tgui_input_num(user, "How much do you want to withdraw? Current Balance: [registered_account.account_balance]", "Withdraw Funds", 5)
+ var/amount_to_remove = input(user, "How much do you want to withdraw? Current Balance: [registered_account.account_balance]", "Withdraw Funds", 5) as num|null
if(!amount_to_remove || amount_to_remove < 0)
return
@@ -478,9 +478,9 @@
var/popup_input
if(bank_support == ID_FREE_BANK_ACCOUNT)
- popup_input = tgui_alert(user, "Choose Action", "Agent ID", list("Show", "Forge/Reset", "Change Account ID"))
+ popup_input = alert(user, "Choose Action", "Agent ID", "Show", "Forge/Reset", "Change Account ID")
else
- popup_input = tgui_alert(user, "Choose Action", "Agent ID", list("Show", "Forge/Reset"))
+ popup_input = alert(user, "Choose Action", "Agent ID", "Show", "Forge/Reset")
if(!user.canUseTopic(src, BE_CLOSE, FALSE))
return
if(popup_input == "Forge/Reset" && !forged)
@@ -843,7 +843,7 @@
if(user.incapacitated() || !istype(user))
to_chat(user, "You can't do that right now!")
return TRUE
- if(tgui_alert(user, "Are you sure you want to recolor your id?", "Confirm Repaint", list("Yes", "No")) == "Yes")
+ if(alert("Are you sure you want to recolor your id?", "Confirm Repaint", "Yes", "No") == "Yes")
var/energy_color_input = input(usr,"","Choose Energy Color",id_color) as color|null
if(!in_range(src, user) || !energy_color_input)
return TRUE
diff --git a/code/game/objects/items/chrono_eraser.dm b/code/game/objects/items/chrono_eraser.dm
index c104d5c62a..04838103f9 100644
--- a/code/game/objects/items/chrono_eraser.dm
+++ b/code/game/objects/items/chrono_eraser.dm
@@ -266,7 +266,7 @@
/obj/effect/chrono_field/singularity_pull()
return
-/obj/effect/chrono_field/ex_act()
+/obj/effect/chrono_field/ex_act(severity, target, origin)
return
/obj/effect/chrono_field/blob_act(obj/structure/blob/B)
diff --git a/code/game/objects/items/cigs_lighters.dm b/code/game/objects/items/cigs_lighters.dm
index 5e37e9d992..702cbd8d56 100644
--- a/code/game/objects/items/cigs_lighters.dm
+++ b/code/game/objects/items/cigs_lighters.dm
@@ -190,7 +190,7 @@ CIGARETTE PACKETS ARE IN FANCY.DM
qdel(src)
return
// allowing reagents to react after being lit
- DISABLE_BITFIELD(reagents.reagents_holder_flags, NO_REACT)
+ reagents.reagents_holder_flags &= ~(NO_REACT)
reagents.handle_reactions()
icon_state = icon_on
item_state = icon_on
@@ -762,7 +762,7 @@ CIGARETTE PACKETS ARE IN FANCY.DM
if(!screw)
screw = TRUE
to_chat(user, "You open the cap on [src].")
- ENABLE_BITFIELD(reagents.reagents_holder_flags, OPENCONTAINER)
+ reagents.reagents_holder_flags |= OPENCONTAINER
if(obj_flags & EMAGGED)
add_overlay("vapeopen_high")
else if(super)
@@ -772,7 +772,7 @@ CIGARETTE PACKETS ARE IN FANCY.DM
else
screw = FALSE
to_chat(user, "You close the cap on [src].")
- DISABLE_BITFIELD(reagents.reagents_holder_flags, OPENCONTAINER)
+ reagents.reagents_holder_flags &= ~(OPENCONTAINER)
cut_overlays()
if(O.tool_behaviour == TOOL_MULTITOOL)
@@ -822,7 +822,7 @@ CIGARETTE PACKETS ARE IN FANCY.DM
if(slot == SLOT_WEAR_MASK)
if(!screw)
to_chat(user, "You start puffing on the vape.")
- DISABLE_BITFIELD(reagents.reagents_holder_flags, NO_REACT)
+ reagents.reagents_holder_flags &= ~(NO_REACT)
START_PROCESSING(SSobj, src)
else //it will not start if the vape is opened.
to_chat(user, "You need to close the cap first!")
@@ -831,7 +831,7 @@ CIGARETTE PACKETS ARE IN FANCY.DM
. = ..()
var/mob/living/carbon/C = user
if(C.get_item_by_slot(SLOT_WEAR_MASK) == src)
- ENABLE_BITFIELD(reagents.reagents_holder_flags, NO_REACT)
+ reagents.reagents_holder_flags |= NO_REACT
STOP_PROCESSING(SSobj, src)
/obj/item/clothing/mask/vape/proc/hand_reagents()//had to rename to avoid duplicate error
diff --git a/code/game/objects/items/circuitboards/machine_circuitboards.dm b/code/game/objects/items/circuitboards/machine_circuitboards.dm
index 0647ec5bc0..cb1d4aae88 100644
--- a/code/game/objects/items/circuitboards/machine_circuitboards.dm
+++ b/code/game/objects/items/circuitboards/machine_circuitboards.dm
@@ -654,7 +654,7 @@
display_vending_names_paths = list()
for(var/path in vending_names_paths)
display_vending_names_paths[vending_names_paths[path]] = path
- var/choice = tgui_input_list(user,"Choose a new brand","Select an Item", sortList(display_vending_names_paths))
+ var/choice = input(user,"Choose a new brand","Select an Item") as null|anything in sortList(display_vending_names_paths)
set_type(display_vending_names_paths[choice])
else
return ..()
@@ -856,7 +856,7 @@
// /obj/item/circuitboard/machine/medical_kiosk/multitool_act(mob/living/user)
// . = ..()
-// var/new_cost = tgui_input_num(user, "Set a new cost for using this medical kiosk.","New cost", custom_cost)
+// var/new_cost = input("Set a new cost for using this medical kiosk.","New cost", custom_cost) as num|null
// if(!new_cost || (loc != user))
// to_chat(user, "You must hold the circuitboard to change its cost!")
// return
@@ -1050,7 +1050,7 @@
/obj/item/circuitboard/machine/public_nanite_chamber/multitool_act(mob/living/user)
. = ..()
- var/new_cloud = tgui_input_num(user, "Set the public nanite chamber's Cloud ID (1-100).", "Cloud ID", cloud_id)
+ var/new_cloud = input("Set the public nanite chamber's Cloud ID (1-100).", "Cloud ID", cloud_id) as num|null
if(!new_cloud || (loc != user))
to_chat(user, "You must hold the circuitboard to change its Cloud ID!")
return
diff --git a/code/game/objects/items/crab17.dm b/code/game/objects/items/crab17.dm
index b831a118de..8d55d3d5a2 100644
--- a/code/game/objects/items/crab17.dm
+++ b/code/game/objects/items/crab17.dm
@@ -14,7 +14,7 @@
if(dumped)
to_chat(user, "You already activated Protocol CRAB-17.")
return FALSE
- if(tgui_alert(user, "Are you sure you want to crash this market with no survivors?", "Protocol CRAB-17", list("Yes", "No")) == "Yes")
+ if(alert(user, "Are you sure you want to crash this market with no survivors?", "Protocol CRAB-17", "Yes", "No") == "Yes")
if(dumped || QDELETED(src)) //Prevents fuckers from cheesing alert
return FALSE
var/turf/targetturf = get_safe_random_station_turf()
diff --git a/code/game/objects/items/crayons.dm b/code/game/objects/items/crayons.dm
index aa48930d6c..42626c4a3b 100644
--- a/code/game/objects/items/crayons.dm
+++ b/code/game/objects/items/crayons.dm
@@ -72,6 +72,10 @@
var/datum/team/gang/gang //For marking territory.
var/gang_tag_delay = 30 //this is the delay for gang mode tag applications on anything that gang = true on.
+ var/precision_mode = FALSE
+ var/precision_x = 0
+ var/precision_y = 0
+
/obj/item/toy/crayon/proc/isValidSurface(surface)
return istype(surface, /turf/open/floor)
@@ -228,6 +232,12 @@
.["can_change_colour"] = can_change_colour
.["current_colour"] = paint_color
+ .["precision_mode"] = precision_mode
+ .["x"] = precision_x
+ .["y"] = precision_y
+ .["min_offset"] = -world.icon_size/2
+ .["max_offset"] = world.icon_size/2
+
/obj/item/toy/crayon/ui_act(action, list/params)
if(..())
return
@@ -256,6 +266,17 @@
. = TRUE
paint_mode = PAINT_NORMAL
drawtype = "a"
+ if("toggle_precision")
+ precision_mode = !precision_mode
+ . = TRUE
+ if("set_precision_x")
+ var/x = text2num(params["x"])
+ precision_x = x
+ . = TRUE
+ if("set_precision_y")
+ var/y = text2num(params["y"])
+ precision_y = y
+ . = TRUE
update_icon()
/obj/item/toy/crayon/proc/select_colour(mob/user)
@@ -400,8 +421,12 @@
if(PAINT_NORMAL)
var/obj/effect/decal/cleanable/crayon/C = new(target, paint_color, drawing, temp, graf_rot)
C.add_hiddenprint(user)
- C.pixel_x = clickx
- C.pixel_y = clicky
+ if(precision_mode)
+ C.pixel_x = clamp(precision_x, -(world.icon_size/2), world.icon_size/2)
+ C.pixel_y = clamp(precision_y, -(world.icon_size/2), world.icon_size/2)
+ else
+ C.pixel_x = clickx
+ C.pixel_y = clicky
affected_turfs += target
if(PAINT_LARGE_HORIZONTAL)
var/turf/left = locate(target.x-1,target.y,target.z)
@@ -738,6 +763,8 @@
if(isobj(target))
if(actually_paints)
+ if(istype(target, /obj/item/canvas)) //dont color our canvas neon green when im trying to paint please
+ return
var/list/hsl = rgb2hsl(hex2num(copytext(paint_color,2,4)),hex2num(copytext(paint_color,4,6)),hex2num(copytext(paint_color,6,8)))
var/static/whitelisted = typecacheof(list(/obj/structure/window,
/obj/effect/decal/cleanable/crayon,
diff --git a/code/game/objects/items/credit_holochip.dm b/code/game/objects/items/credit_holochip.dm
index b9cf189051..b7f7f5f2d1 100644
--- a/code/game/objects/items/credit_holochip.dm
+++ b/code/game/objects/items/credit_holochip.dm
@@ -95,7 +95,7 @@
/obj/item/holochip/AltClick(mob/user)
if(!istype(user) || !user.canUseTopic(src, BE_CLOSE, ismonkey(user)))
return
- var/split_amount = round(tgui_input_num(user,"How many credits do you want to extract from the holochip?"))
+ var/split_amount = round(input(user,"How many credits do you want to extract from the holochip?") as null|num)
if(split_amount == null || split_amount <= 0 || !user.canUseTopic(src, BE_CLOSE, ismonkey(user)))
return
else
diff --git a/code/game/objects/items/debug_items.dm b/code/game/objects/items/debug_items.dm
index f743e2e4e8..c7aaab6a26 100644
--- a/code/game/objects/items/debug_items.dm
+++ b/code/game/objects/items/debug_items.dm
@@ -21,9 +21,9 @@
/obj/item/debug/human_spawner/attack_self(mob/user)
..()
- var/choice = tgui_input_list(user, "Select a species", "Human Spawner", null, GLOB.species_list)
+ var/choice = input("Select a species", "Human Spawner", null) in GLOB.species_list
selected_species = GLOB.species_list[choice]
-
+
/* Revive this once we purge all the istype checks for tools for tool_behaviour
/obj/item/debug/omnitool
name = "omnitool"
diff --git a/code/game/objects/items/devices/PDA/PDA.dm b/code/game/objects/items/devices/PDA/PDA.dm
index f19cde7071..2339e88a76 100644
--- a/code/game/objects/items/devices/PDA/PDA.dm
+++ b/code/game/objects/items/devices/PDA/PDA.dm
@@ -144,7 +144,7 @@ GLOBAL_LIST_EMPTY(PDAs)
dat += "\n[V]: [output]"
to_chat(M, dat)
- var/choice = tgui_input_list(M, "Choose the a reskin for [src]","Reskin Object", GLOB.pda_reskins)
+ var/choice = input(M, "Choose the a reskin for [src]","Reskin Object") as null|anything in GLOB.pda_reskins
var/new_icon = GLOB.pda_reskins[choice]
if(QDELETED(src) || isnull(new_icon) || new_icon == icon || !M.canUseTopic(src, BE_CLOSE, FALSE, NO_TK))
return
@@ -619,7 +619,7 @@ GLOBAL_LIST_EMPTY(PDAs)
playsound(src, 'sound/machines/terminal_select.ogg', 15, 1)
if("Drone Phone")
- var/alert_s = tgui_input_list(U,"Alert severity level","Ping Drones", list("Low","Medium","High","Critical"))
+ var/alert_s = input(U,"Alert severity level","Ping Drones",null) as null|anything in list("Low","Medium","High","Critical")
var/area/A = get_area(U)
if(A && alert_s && !QDELETED(U))
var/msg = "NON-DRONE PING: [U.name]: [alert_s] priority alert in [A.name]!"
@@ -1147,7 +1147,7 @@ GLOBAL_LIST_EMPTY(PDAs)
plist[avoid_assoc_duplicate_keys(P.owner, namecounts)] = P
- var/c = tgui_input_list(user, "Please select a PDA", "", sortList(plist))
+ var/c = input(user, "Please select a PDA") as null|anything in sortList(plist)
if (!c)
return
@@ -1155,7 +1155,7 @@ GLOBAL_LIST_EMPTY(PDAs)
var/selected = plist[c]
if(aicamera.stored.len)
- var/add_photo = tgui_input_list(user,"Do you want to attach a photo?","Photo","No", list("Yes","No"))
+ var/add_photo = input(user,"Do you want to attach a photo?","Photo","No") as null|anything in list("Yes","No")
if(add_photo=="Yes")
var/datum/picture/Pic = aicamera.selectpicture(user)
aiPDA.picture = Pic
diff --git a/code/game/objects/items/devices/PDA/cart.dm b/code/game/objects/items/devices/PDA/cart.dm
index 8ac68b9827..4ca0b86bc0 100644
--- a/code/game/objects/items/devices/PDA/cart.dm
+++ b/code/game/objects/items/devices/PDA/cart.dm
@@ -656,10 +656,10 @@ Code:
if("alert")
post_status("alert", href_list["alert"])
if("setmsg1")
- message1 = reject_bad_text(tgui_input_text(usr, "Line 1", "Enter Message Text", message1), 40)
+ message1 = reject_bad_text(input("Line 1", "Enter Message Text", message1) as text|null, 40)
updateSelfDialog()
if("setmsg2")
- message2 = reject_bad_text(tgui_input_text(usr, "Line 2", "Enter Message Text", message2), 40)
+ message2 = reject_bad_text(input("Line 2", "Enter Message Text", message2) as text|null, 40)
updateSelfDialog()
else
post_status(href_list["statdisp"])
diff --git a/code/game/objects/items/devices/aicard.dm b/code/game/objects/items/devices/aicard.dm
index 1cb4d3be22..503e2a9473 100644
--- a/code/game/objects/items/devices/aicard.dm
+++ b/code/game/objects/items/devices/aicard.dm
@@ -84,7 +84,7 @@
if(flush)
flush = FALSE
else
- var/confirm = tgui_alert(usr, "Are you sure you want to wipe this card's memory?", name, list("Yes", "No"))
+ var/confirm = alert("Are you sure you want to wipe this card's memory?", name, "Yes", "No")
if(confirm == "Yes" && !..())
flush = TRUE
if(AI && AI.loc == src)
diff --git a/code/game/objects/items/devices/chameleonproj.dm b/code/game/objects/items/devices/chameleonproj.dm
index a45f26062b..8656cc21f1 100644
--- a/code/game/objects/items/devices/chameleonproj.dm
+++ b/code/game/objects/items/devices/chameleonproj.dm
@@ -144,8 +144,8 @@
/obj/effect/dummy/chameleon/attack_alien()
master.disrupt()
-/obj/effect/dummy/chameleon/ex_act(S, T)
- contents_explosion(S, T)
+/obj/effect/dummy/chameleon/ex_act(severity, target, origin)
+ contents_explosion(severity, target, origin)
master.disrupt()
/obj/effect/dummy/chameleon/bullet_act()
diff --git a/code/game/objects/items/devices/desynchronizer.dm b/code/game/objects/items/devices/desynchronizer.dm
index 2e8b11a64e..2cb4922f36 100644
--- a/code/game/objects/items/devices/desynchronizer.dm
+++ b/code/game/objects/items/devices/desynchronizer.dm
@@ -36,7 +36,7 @@
. = ..()
if(!istype(user) || !user.canUseTopic(src, BE_CLOSE, ismonkey(user)))
return
- var/new_duration = tgui_input_num(user, "Set the duration (5-300):", "Desynchronizer", duration / 10)
+ var/new_duration = input(user, "Set the duration (5-300):", "Desynchronizer", duration / 10) as null|num
if(new_duration)
new_duration = new_duration SECONDS
new_duration = clamp(new_duration, 50, max_duration)
diff --git a/code/game/objects/items/devices/dogborg_sleeper.dm b/code/game/objects/items/devices/dogborg_sleeper.dm
index 977029cca3..e7493efadc 100644
--- a/code/game/objects/items/devices/dogborg_sleeper.dm
+++ b/code/game/objects/items/devices/dogborg_sleeper.dm
@@ -326,7 +326,7 @@
cleaning_cycles--
cleaning = TRUE
for(var/mob/living/carbon/C in (touchable_items))
- if((C.status_flags & GODMODE) || !CHECK_BITFIELD(C.vore_flags, DIGESTABLE))
+ if((C.status_flags & GODMODE) || !(C.vore_flags & DIGESTABLE))
items_preserved += C
else
C.adjustBruteLoss(2)
@@ -335,7 +335,7 @@
var/atom/target = pick(touchable_items)
if(iscarbon(target)) //Handle the target being a mob
var/mob/living/carbon/T = target
- if(T.stat == DEAD && CHECK_BITFIELD(T.vore_flags, DIGESTABLE)) //Mob is now dead
+ if(T.stat == DEAD && (T.vore_flags & DIGESTABLE)) //Mob is now dead
message_admins("[key_name(hound)] has digested [key_name(T)] as a dogborg. ([hound ? "JMP" : "null"])")
to_chat(hound,"You feel your belly slowly churn around [T], breaking them down into a soft slurry to be used as power for your systems.")
to_chat(T,"You feel [hound]'s belly slowly churn around your form, breaking you down into a soft slurry to be used as power for [hound]'s systems.")
@@ -433,7 +433,7 @@
var/mob/living/silicon/robot/hound = get_host()
if(!hound || !istype(target) || !proximity || target.anchored)
return
- if (!CHECK_BITFIELD(target.vore_flags,DEVOURABLE))
+ if (!(target.vore_flags & DEVOURABLE))
to_chat(user, "The target registers an error code. Unable to insert into [src].")
return
if(patient)
diff --git a/code/game/objects/items/devices/doorCharge.dm b/code/game/objects/items/devices/doorCharge.dm
index c38eb46baf..5ebb34eeed 100644
--- a/code/game/objects/items/devices/doorCharge.dm
+++ b/code/game/objects/items/devices/doorCharge.dm
@@ -14,7 +14,7 @@
attack_verb = list("blown up", "exploded", "detonated")
custom_materials = list(/datum/material/iron=50, /datum/material/glass=30)
-/obj/item/doorCharge/ex_act(severity, target)
+/obj/item/doorCharge/ex_act(severity, target, origin)
switch(severity)
if(EXPLODE_DEVASTATE)
visible_message("[src] detonates!")
diff --git a/code/game/objects/items/devices/electrochromatic_kit.dm b/code/game/objects/items/devices/electrochromatic_kit.dm
index 244ca03275..d582eab00e 100644
--- a/code/game/objects/items/devices/electrochromatic_kit.dm
+++ b/code/game/objects/items/devices/electrochromatic_kit.dm
@@ -8,7 +8,7 @@
. = ..()
if(.)
return
- var/new_id = tgui_input_text(user, "Set this kit's electrochromatic ID", "Set ID", id)
+ var/new_id = input(user, "Set this kit's electrochromatic ID", "Set ID", id) as text|null
if(isnull(new_id))
return
id = new_id
diff --git a/code/game/objects/items/devices/paicard.dm b/code/game/objects/items/devices/paicard.dm
index 3a15e87bdd..d54911528d 100644
--- a/code/game/objects/items/devices/paicard.dm
+++ b/code/game/objects/items/devices/paicard.dm
@@ -87,7 +87,7 @@
pai.master_dna = M.dna.unique_enzymes
to_chat(pai, "You have been bound to a new master.")
if(href_list["wipe"])
- var/confirm = tgui_input_list(usr, "Are you CERTAIN you wish to delete the current personality? This action cannot be undone.", "Personality Wipe", list("Yes", "No"))
+ var/confirm = input("Are you CERTAIN you wish to delete the current personality? This action cannot be undone.", "Personality Wipe") in list("Yes", "No")
if(confirm == "Yes")
if(pai)
to_chat(pai, "You feel yourself slipping away from reality.")
diff --git a/code/game/objects/items/devices/pipe_painter.dm b/code/game/objects/items/devices/pipe_painter.dm
index 573e2f0194..a6323cfd7f 100644
--- a/code/game/objects/items/devices/pipe_painter.dm
+++ b/code/game/objects/items/devices/pipe_painter.dm
@@ -23,7 +23,7 @@
user.visible_message("[user] paints \the [P] [paint_color].","You paint \the [P] [paint_color].")
/obj/item/pipe_painter/attack_self(mob/user)
- paint_color = tgui_input_list(user, "Which colour do you want to use?","Pipe painter", GLOB.pipe_paint_colors)
+ paint_color = input("Which colour do you want to use?","Pipe painter") in GLOB.pipe_paint_colors
/obj/item/pipe_painter/examine(mob/user)
. = ..()
diff --git a/code/game/objects/items/devices/polycircuit.dm b/code/game/objects/items/devices/polycircuit.dm
index 3a35f7c9f8..17e364c4f3 100644
--- a/code/game/objects/items/devices/polycircuit.dm
+++ b/code/game/objects/items/devices/polycircuit.dm
@@ -18,7 +18,7 @@
else
if(zero_amount())
return
- chosen_circuit = tgui_input_list(user, "What type of circuit would you like to remove?", "Choose a Circuit Type", list("airlock","firelock","fire alarm","air alarm","APC"))
+ chosen_circuit = input("What type of circuit would you like to remove?", "Choose a Circuit Type", chosen_circuit) as null|anything in list("airlock","firelock","fire alarm","air alarm","APC")
if(zero_amount() || !chosen_circuit || !in_range(src,user))
return
switch(chosen_circuit)
diff --git a/code/game/objects/items/devices/portable_chem_mixer.dm b/code/game/objects/items/devices/portable_chem_mixer.dm
index c773699b1d..8ffd978c59 100644
--- a/code/game/objects/items/devices/portable_chem_mixer.dm
+++ b/code/game/objects/items/devices/portable_chem_mixer.dm
@@ -27,7 +27,7 @@
QDEL_NULL(beaker)
return ..()
-/obj/item/storage/portable_chem_mixer/ex_act(severity, target)
+/obj/item/storage/portable_chem_mixer/ex_act(severity, target, origin)
if(severity < 3)
..()
diff --git a/code/game/objects/items/devices/radio/radio.dm b/code/game/objects/items/devices/radio/radio.dm
index c86b9b3951..e81110425c 100644
--- a/code/game/objects/items/devices/radio/radio.dm
+++ b/code/game/objects/items/devices/radio/radio.dm
@@ -150,7 +150,7 @@
if(tune == "input")
var/min = format_frequency(freerange ? MIN_FREE_FREQ : MIN_FREQ)
var/max = format_frequency(freerange ? MAX_FREE_FREQ : MAX_FREQ)
- tune = tgui_input_num(usr, "Tune frequency ([min]-[max]):", name, format_frequency(frequency))
+ tune = input("Tune frequency ([min]-[max]):", name, format_frequency(frequency)) as null|num
if(!isnull(tune) && !..())
if (tune < MIN_FREE_FREQ && tune <= MAX_FREE_FREQ / 10)
// allow typing 144.7 to get 1447
diff --git a/code/game/objects/items/devices/scanners.dm b/code/game/objects/items/devices/scanners.dm
index 0cb31291ed..0bf7b13646 100644
--- a/code/game/objects/items/devices/scanners.dm
+++ b/code/game/objects/items/devices/scanners.dm
@@ -946,7 +946,7 @@ GENETICS SCANNER
for(var/A in buffer)
options += get_display_name(A)
- var/answer = tgui_input_list(user, "Analyze Potential", "Sequence Analyzer", sortList(options))
+ var/answer = input(user, "Analyze Potential", "Sequence Analyzer") as null|anything in sortList(options)
if(answer && ready && user.canUseTopic(src, BE_CLOSE, FALSE, NO_TK))
var/sequence
for(var/A in buffer) //this physically hurts but i dont know what anything else short of an assoc list
diff --git a/code/game/objects/items/dualsaber.dm b/code/game/objects/items/dualsaber.dm
index 0e21a2520a..9a6a87bb51 100644
--- a/code/game/objects/items/dualsaber.dm
+++ b/code/game/objects/items/dualsaber.dm
@@ -319,7 +319,7 @@
if(user.incapacitated() || !istype(user))
to_chat(user, "You can't do that right now!")
return
- if(tgui_alert(user, "Are you sure you want to recolor your blade?", "Confirm Repaint", list("Yes", "No")) == "Yes")
+ if(alert("Are you sure you want to recolor your blade?", "Confirm Repaint", "Yes", "No") == "Yes")
var/energy_color_input = input(usr,"","Choose Energy Color",light_color) as color|null
if(!energy_color_input || !user.canUseTopic(src, BE_CLOSE, FALSE) || hacked)
return
diff --git a/code/game/objects/items/dyekit.dm b/code/game/objects/items/dyekit.dm
index eea4bf65e8..43a05c7939 100644
--- a/code/game/objects/items/dyekit.dm
+++ b/code/game/objects/items/dyekit.dm
@@ -23,7 +23,7 @@
return
var/mob/living/carbon/human/human_target = target
- var/new_grad_style = tgui_input_list(usr, "Choose a color pattern:", "Character Preference", GLOB.hair_gradients_list)
+ var/new_grad_style = input(usr, "Choose a color pattern:", "Character Preference") as null|anything in GLOB.hair_gradients_list
if(!new_grad_style)
return
diff --git a/code/game/objects/items/grenades/plastic.dm b/code/game/objects/items/grenades/plastic.dm
index a30b1c40cf..23fe128fa8 100644
--- a/code/game/objects/items/grenades/plastic.dm
+++ b/code/game/objects/items/grenades/plastic.dm
@@ -95,7 +95,7 @@
if(nadeassembly)
nadeassembly.attack_self(user)
return
- var/newtime = tgui_input_num(usr, "Please set the timer.", "Timer", 10)
+ var/newtime = input(usr, "Please set the timer.", "Timer", 10) as num
if(user.get_active_held_item() == src)
newtime = clamp(newtime, 10, 60000)
det_time = newtime
diff --git a/code/game/objects/items/implants/implant_explosive.dm b/code/game/objects/items/implants/implant_explosive.dm
index 1479763efa..370924063d 100644
--- a/code/game/objects/items/implants/implant_explosive.dm
+++ b/code/game/objects/items/implants/implant_explosive.dm
@@ -33,7 +33,7 @@
return FALSE
if(cause == "action_button" && !popup)
popup = TRUE
- var/response = tgui_alert(imp_in, "Are you sure you want to activate your [name]? This will cause you to explode!", "[name] Confirmation", list("Yes", "No"))
+ var/response = alert(imp_in, "Are you sure you want to activate your [name]? This will cause you to explode!", "[name] Confirmation", "Yes", "No")
popup = FALSE
if(response == "No")
return FALSE
diff --git a/code/game/objects/items/latexballoon.dm b/code/game/objects/items/latexballoon.dm
index b2f8b4bee2..64a7973f11 100644
--- a/code/game/objects/items/latexballoon.dm
+++ b/code/game/objects/items/latexballoon.dm
@@ -31,7 +31,7 @@
user.update_inv_hands()
loc.assume_air(air_contents)
-/obj/item/latexballon/ex_act(severity, target)
+/obj/item/latexballon/ex_act(severity, target, origin)
burst()
switch(severity)
if (1)
diff --git a/code/game/objects/items/melee/energy.dm b/code/game/objects/items/melee/energy.dm
index 9f5abfcca3..275536d370 100644
--- a/code/game/objects/items/melee/energy.dm
+++ b/code/game/objects/items/melee/energy.dm
@@ -415,7 +415,7 @@
to_chat(user, "You can't do that right now!")
return TRUE
- if(tgui_alert(user, "Are you sure you want to recolor your blade?", "Confirm Repaint", list("Yes", "No")) == "Yes")
+ if(alert("Are you sure you want to recolor your blade?", "Confirm Repaint", "Yes", "No") == "Yes")
var/energy_color_input = input(usr,"","Choose Energy Color",light_color) as color|null
if(energy_color_input)
light_color = sanitize_hexcolor(energy_color_input, desired_format=6, include_crunch=1)
diff --git a/code/game/objects/items/melee/misc.dm b/code/game/objects/items/melee/misc.dm
index dbfeb9d08f..29593cae06 100644
--- a/code/game/objects/items/melee/misc.dm
+++ b/code/game/objects/items/melee/misc.dm
@@ -557,7 +557,7 @@
..()
balanced = 0
-/obj/item/melee/supermatter_sword/ex_act(severity, target)
+/obj/item/melee/supermatter_sword/ex_act(severity, target, origin)
visible_message("The blast wave smacks into [src] and rapidly flashes to ash.",\
"You hear a loud crack as you are washed with a wave of heat.")
consume_everything()
diff --git a/code/game/objects/items/miscellaneous.dm b/code/game/objects/items/miscellaneous.dm
index 151f5f1c7d..80466832a6 100644
--- a/code/game/objects/items/miscellaneous.dm
+++ b/code/game/objects/items/miscellaneous.dm
@@ -26,7 +26,7 @@
stored_options = generate_display_names()
if(!stored_options.len)
return
- var/choice = tgui_input_list(M,"Which item would you like to order?","Select an Item", stored_options)
+ var/choice = input(M,"Which item would you like to order?","Select an Item") as null|anything in stored_options
if(!choice || !M.canUseTopic(src, BE_CLOSE, FALSE, NO_TK))
return
@@ -182,7 +182,7 @@
return carrier
/obj/item/choice_beacon/pet/spawn_option(atom/choice,mob/living/M)
- pet_name = tgui_input_text(M, "What would you like to name the pet? (leave blank for default name)", "Pet Name")
+ pet_name = input(M, "What would you like to name the pet? (leave blank for default name)", "Pet Name")
..()
//choice boxes (they just open in your hand instead of making a pod)
diff --git a/code/game/objects/items/paint.dm b/code/game/objects/items/paint.dm
index 5483d3dc38..cd65149f5d 100644
--- a/code/game/objects/items/paint.dm
+++ b/code/game/objects/items/paint.dm
@@ -56,7 +56,7 @@
icon_state = "paint_neutral"
/obj/item/paint/anycolor/attack_self(mob/user)
- var/t1 = tgui_input_list(user, "Please select a color:", "Locking Computer", list( "red", "pink", "blue", "cyan", "green", "lime", "yellow", "orange", "violet", "purple", "black", "gray", "white"))
+ var/t1 = input(user, "Please select a color:", "Locking Computer", null) in list( "red", "pink", "blue", "cyan", "green", "lime", "yellow", "orange", "violet", "purple", "black", "gray", "white")
if ((user.get_active_held_item() != src || user.stat || user.restrained()))
return
switch(t1)
diff --git a/code/game/objects/items/pinpointer.dm b/code/game/objects/items/pinpointer.dm
index d3dcbafb70..22ffc33516 100644
--- a/code/game/objects/items/pinpointer.dm
+++ b/code/game/objects/items/pinpointer.dm
@@ -154,7 +154,7 @@
user.visible_message("[user]'s pinpointer fails to detect a signal.", "Your pinpointer fails to detect a signal.")
return
- var/A = tgui_input_list(user, "Person to track", "Pinpoint", names)
+ var/A = input(user, "Person to track", "Pinpoint") in names
if(!A || QDELETED(src) || !user || !user.is_holding(src) || user.incapacitated())
return
diff --git a/code/game/objects/items/puzzle_pieces.dm b/code/game/objects/items/puzzle_pieces.dm
index 345f3185da..3f3e81604e 100644
--- a/code/game/objects/items/puzzle_pieces.dm
+++ b/code/game/objects/items/puzzle_pieces.dm
@@ -54,7 +54,7 @@
/obj/machinery/door/keycard/emp_act(severity)
return
-/obj/machinery/door/keycard/ex_act(severity, target)
+/obj/machinery/door/keycard/ex_act(severity, target, origin)
return
/obj/machinery/door/keycard/try_to_activate_door(mob/user)
diff --git a/code/game/objects/items/robot/robot_items.dm b/code/game/objects/items/robot/robot_items.dm
index fa72789221..cbfdc85f6d 100644
--- a/code/game/objects/items/robot/robot_items.dm
+++ b/code/game/objects/items/robot/robot_items.dm
@@ -997,7 +997,7 @@
to_chat(user, "[target] is firmly secured!")
/obj/item/cyborg_clamp/attack_self(mob/user)
- var/obj/chosen_cargo = tgui_input_list(user, "Drop what?", cargo)
+ var/obj/chosen_cargo = input(user, "Drop what?") as null|anything in cargo
if(!chosen_cargo)
return
chosen_cargo.forceMove(get_turf(chosen_cargo))
diff --git a/code/game/objects/items/scrolls.dm b/code/game/objects/items/scrolls.dm
index 095b435c6a..d58f670dc4 100644
--- a/code/game/objects/items/scrolls.dm
+++ b/code/game/objects/items/scrolls.dm
@@ -48,7 +48,7 @@
var/A
- A = tgui_input_list(user, "Area to jump to", "BOOYEA", GLOB.teleportlocs)
+ A = input(user, "Area to jump to", "BOOYEA", A) as null|anything in GLOB.teleportlocs
if(!src || QDELETED(src) || !user || !user.is_holding(src) || user.incapacitated() || !A || !uses)
return
var/area/thearea = GLOB.teleportlocs[A]
diff --git a/code/game/objects/items/shields.dm b/code/game/objects/items/shields.dm
index f1691e5eb9..8432a8b73e 100644
--- a/code/game/objects/items/shields.dm
+++ b/code/game/objects/items/shields.dm
@@ -174,11 +174,11 @@
/obj/item/shield/run_block(mob/living/owner, atom/object, damage, attack_text, attack_type, armour_penetration, mob/attacker, def_zone, final_block_chance, list/block_return)
if(ismovable(object))
var/atom/movable/AM = object
- if(CHECK_BITFIELD(shield_flags, SHIELD_TRANSPARENT) && (AM.pass_flags & PASSGLASS))
+ if((shield_flags & SHIELD_TRANSPARENT) && (AM.pass_flags & PASSGLASS))
return BLOCK_NONE
- if(CHECK_BITFIELD(shield_flags, SHIELD_NO_RANGED) && (attack_type & ATTACK_TYPE_PROJECTILE))
+ if((shield_flags & SHIELD_NO_RANGED) && (attack_type & ATTACK_TYPE_PROJECTILE))
return BLOCK_NONE
- if(CHECK_BITFIELD(shield_flags, SHIELD_NO_MELEE) && (attack_type & ATTACK_TYPE_MELEE))
+ if((shield_flags & SHIELD_NO_MELEE) && (attack_type & ATTACK_TYPE_MELEE))
return BLOCK_NONE
if(attack_type & ATTACK_TYPE_THROWN)
final_block_chance += 30
@@ -249,15 +249,15 @@
if(attack_type & ATTACK_TYPE_MELEE)
var/obj/hittingthing = object
if(hittingthing.damtype == BURN)
- if(CHECK_BITFIELD(shield_flags, SHIELD_ENERGY_WEAK))
+ if((shield_flags & SHIELD_ENERGY_WEAK))
final_damage *= 2
- else if(CHECK_BITFIELD(shield_flags, SHIELD_ENERGY_STRONG))
+ else if((shield_flags & SHIELD_ENERGY_STRONG))
final_damage *= 0.5
if(hittingthing.damtype == BRUTE)
- if(CHECK_BITFIELD(shield_flags, SHIELD_KINETIC_WEAK))
+ if((shield_flags & SHIELD_KINETIC_WEAK))
final_damage *= 2
- else if(CHECK_BITFIELD(shield_flags, SHIELD_KINETIC_STRONG))
+ else if((shield_flags & SHIELD_KINETIC_STRONG))
final_damage *= 0.5
if(hittingthing.damtype == STAMINA || hittingthing.damtype == TOX || hittingthing.damtype == CLONE || hittingthing.damtype == BRAIN || hittingthing.damtype == OXY)
@@ -266,19 +266,19 @@
if(attack_type & ATTACK_TYPE_PROJECTILE)
var/obj/item/projectile/shootingthing = object
if(is_energy_reflectable_projectile(shootingthing))
- if(CHECK_BITFIELD(shield_flags, SHIELD_ENERGY_WEAK))
+ if((shield_flags & SHIELD_ENERGY_WEAK))
final_damage *= 2
- else if(CHECK_BITFIELD(shield_flags, SHIELD_ENERGY_STRONG))
+ else if((shield_flags & SHIELD_ENERGY_STRONG))
final_damage *= 0.5
if(!is_energy_reflectable_projectile(object))
- if(CHECK_BITFIELD(shield_flags, SHIELD_KINETIC_WEAK))
+ if((shield_flags & SHIELD_KINETIC_WEAK))
final_damage *= 2
- else if(CHECK_BITFIELD(shield_flags, SHIELD_KINETIC_STRONG))
+ else if((shield_flags & SHIELD_KINETIC_STRONG))
final_damage *= 0.5
if(shootingthing.damage_type == STAMINA)
- if(CHECK_BITFIELD(shield_flags, SHIELD_DISABLER_DISRUPTED))
+ if((shield_flags & SHIELD_DISABLER_DISRUPTED))
final_damage *= 3 //disablers melt these kinds of shields. Really meant more for holoshields.
else
final_damage = 0
diff --git a/code/game/objects/items/stacks/stack.dm b/code/game/objects/items/stacks/stack.dm
index 12822aefd0..266d8b7b86 100644
--- a/code/game/objects/items/stacks/stack.dm
+++ b/code/game/objects/items/stacks/stack.dm
@@ -465,7 +465,7 @@
return
//get amount from user
var/max = get_amount()
- var/stackmaterial = round(tgui_input_num(user,"How many sheets do you wish to take out of this stack? (Maximum [max])"))
+ var/stackmaterial = round(input(user,"How many sheets do you wish to take out of this stack? (Maximum [max])") as null|num)
max = get_amount()
stackmaterial = min(max, stackmaterial)
if(stackmaterial == null || stackmaterial <= 0 || !user.canUseTopic(src, BE_CLOSE, TRUE, FALSE)) //, !iscyborg(user)
diff --git a/code/game/objects/items/storage/_storage.dm b/code/game/objects/items/storage/_storage.dm
index 2fc1b6484d..04362481b2 100644
--- a/code/game/objects/items/storage/_storage.dm
+++ b/code/game/objects/items/storage/_storage.dm
@@ -18,10 +18,10 @@
/obj/item/storage/AllowDrop()
return TRUE
-/obj/item/storage/contents_explosion(severity, target)
+/obj/item/storage/contents_explosion(severity, target, origin)
var/in_storage = istype(loc, /obj/item/storage)? (max(0, severity - 1)) : (severity)
for(var/atom/A in contents)
- A.ex_act(in_storage, target)
+ A.ex_act(in_storage, target, origin)
CHECK_TICK
//Cyberboss says: "USE THIS TO FILL IT, NOT INITIALIZE OR NEW"
diff --git a/code/game/objects/items/storage/boxes.dm b/code/game/objects/items/storage/boxes.dm
index 8b897cb6e5..df439e98f1 100644
--- a/code/game/objects/items/storage/boxes.dm
+++ b/code/game/objects/items/storage/boxes.dm
@@ -1290,9 +1290,9 @@
var/toxic_risk = min(round(spess_current_year - expiration_date * 0.01), 1)
for(var/obj/item/reagent_containers/food/snacks/S in contents)
if(prob(gross_risk))
- ENABLE_BITFIELD(S.foodtype, GROSS)
+ S.foodtype |= GROSS
if(prob(toxic_risk))
- ENABLE_BITFIELD(S.foodtype, TOXIC)
+ S.foodtype |= TOXIC
/obj/item/storage/box/mre/menu1
name = "\improper Nanotrasen MRE Ration Kit Menu 1"
diff --git a/code/game/objects/items/storage/dakis.dm b/code/game/objects/items/storage/dakis.dm
index b9b175bb04..29f12df4c4 100644
--- a/code/game/objects/items/storage/dakis.dm
+++ b/code/game/objects/items/storage/dakis.dm
@@ -24,7 +24,7 @@
var/custom_name
if(icon_state == "daki_base")
- body_choice = tgui_input_list(user, "Pick a body.", "", dakimakura_options)
+ body_choice = input("Pick a body.") in dakimakura_options
icon_state = "daki_[body_choice]"
custom_name = stripped_input(user, "What's her name?")
if(length(custom_name) > MAX_NAME_LEN)
diff --git a/code/game/objects/items/storage/toolbox.dm b/code/game/objects/items/storage/toolbox.dm
index 56cf50993b..869711e5b2 100644
--- a/code/game/objects/items/storage/toolbox.dm
+++ b/code/game/objects/items/storage/toolbox.dm
@@ -370,7 +370,7 @@ GLOBAL_LIST_EMPTY(rubber_toolbox_icons)
desc = replacetext(desc, "Danger", "Bouncy")
desc = replacetext(desc, "robust", "safe")
desc = replacetext(desc, "heavier", "bouncier")
- DISABLE_BITFIELD(flags_1, CONDUCT_1)
+ flags_1 &= ~(CONDUCT_1)
custom_materials = null
damtype = STAMINA
force += 3 //to compensate the higher stamina K.O. threshold compared to actual health.
diff --git a/code/game/objects/items/tanks/tanks.dm b/code/game/objects/items/tanks/tanks.dm
index 01da046809..b77e4a8ba0 100644
--- a/code/game/objects/items/tanks/tanks.dm
+++ b/code/game/objects/items/tanks/tanks.dm
@@ -48,7 +48,7 @@
var/obj/item/clothing/mask/M = check
if(M.mask_adjusted)
M.adjustmask(H)
- if(CHECK_BITFIELD(check.clothing_flags, ALLOWINTERNALS))
+ if((check.clothing_flags & ALLOWINTERNALS))
internals = TRUE
if(!internals)
diff --git a/code/game/objects/items/teleportation.dm b/code/game/objects/items/teleportation.dm
index a8e94ba001..bc6a40f8c0 100644
--- a/code/game/objects/items/teleportation.dm
+++ b/code/game/objects/items/teleportation.dm
@@ -164,7 +164,7 @@
turfs += T
if(turfs.len)
L["None (Dangerous)"] = pick(turfs)
- var/t1 = tgui_input_list(user, "Please select a teleporter to lock in on.", "Hand Teleporter", L)
+ var/t1 = input(user, "Please select a teleporter to lock in on.", "Hand Teleporter") as null|anything in L
if (!t1 || user.get_active_held_item() != src || user.incapacitated())
return
if(active_portal_pairs.len >= max_portal_pairs)
diff --git a/code/game/objects/items/tools/weldingtool.dm b/code/game/objects/items/tools/weldingtool.dm
index 13c3c100b5..7688d2d342 100644
--- a/code/game/objects/items/tools/weldingtool.dm
+++ b/code/game/objects/items/tools/weldingtool.dm
@@ -291,10 +291,10 @@
status = !status
if(status)
to_chat(user, "You resecure [src] and close the fuel tank.")
- DISABLE_BITFIELD(reagents.reagents_holder_flags, OPENCONTAINER)
+ reagents.reagents_holder_flags &= ~(OPENCONTAINER)
else
to_chat(user, "[src] can now be attached, modified, and refuelled.")
- ENABLE_BITFIELD(reagents.reagents_holder_flags, OPENCONTAINER)
+ reagents.reagents_holder_flags |= OPENCONTAINER
add_fingerprint(user)
/obj/item/weldingtool/proc/flamethrower_rods(obj/item/I, mob/user)
diff --git a/code/game/objects/items/toys.dm b/code/game/objects/items/toys.dm
index c2693510cd..547217366b 100644
--- a/code/game/objects/items/toys.dm
+++ b/code/game/objects/items/toys.dm
@@ -340,7 +340,7 @@
to_chat(user, "You can't do that right now!")
return TRUE
- if(tgui_alert(user, "Are you sure you want to recolor your blade?", "Confirm Repaint", list("Yes", "No")) == "Yes")
+ if(alert("Are you sure you want to recolor your blade?", "Confirm Repaint", "Yes", "No") == "Yes")
var/energy_color_input = input(usr,"","Choose Energy Color",light_color) as color|null
if(energy_color_input)
light_color = sanitize_hexcolor(energy_color_input, desired_format=6, include_crunch=1)
diff --git a/code/game/objects/obj_defense.dm b/code/game/objects/obj_defense.dm
index 15fd102878..95a651b50e 100644
--- a/code/game/objects/obj_defense.dm
+++ b/code/game/objects/obj_defense.dm
@@ -56,7 +56,7 @@
throwdamage = 0
take_damage(throwdamage, BRUTE, "melee", 1, get_dir(src, AM))
-/obj/ex_act(severity, target)
+/obj/ex_act(severity, target, origin)
if(resistance_flags & INDESTRUCTIBLE)
return
..() //contents explosion
diff --git a/code/game/objects/objs.dm b/code/game/objects/objs.dm
index e802e084f8..58c571d9e6 100644
--- a/code/game/objects/objs.dm
+++ b/code/game/objects/objs.dm
@@ -282,14 +282,14 @@
message_admins("[key_name_admin(usr)] modified the armor on [src] ([type]) to melee: [armor.melee], bullet: [armor.bullet], laser: [armor.laser], energy: [armor.energy], bomb: [armor.bomb], bio: [armor.bio], rad: [armor.rad], fire: [armor.fire], acid: [armor.acid]")
if(href_list[VV_HK_MASS_DEL_TYPE])
if(check_rights(R_DEBUG|R_SERVER))
- var/action_type = tgui_alert(usr, "Strict type ([type]) or type and all subtypes?",,list("Strict type","Type and subtypes","Cancel"))
+ var/action_type = alert("Strict type ([type]) or type and all subtypes?",,"Strict type","Type and subtypes","Cancel")
if(action_type == "Cancel" || !action_type)
return
- if(tgui_alert(usr, "Are you really sure you want to delete all objects of type [type]?",,list("Yes","No")) != "Yes")
+ if(alert("Are you really sure you want to delete all objects of type [type]?",,"Yes","No") != "Yes")
return
- if(tgui_alert(usr, "Second confirmation required. Delete?",,list("Yes","No")) != "Yes")
+ if(alert("Second confirmation required. Delete?",,"Yes","No") != "Yes")
return
var/O_type = type
diff --git a/code/game/objects/structures/barsigns.dm b/code/game/objects/structures/barsigns.dm
index 1f0121db76..a96d39316e 100644
--- a/code/game/objects/structures/barsigns.dm
+++ b/code/game/objects/structures/barsigns.dm
@@ -120,7 +120,7 @@
/obj/structure/sign/barsign/proc/pick_sign(mob/user)
- var/picked_name = tgui_input_list(user, "Available Signage", "Bar Sign", barsigns)
+ var/picked_name = input(user, "Available Signage", "Bar Sign", name) as null|anything in barsigns
if(!picked_name)
return
set_sign(picked_name)
diff --git a/code/game/objects/structures/crates_lockers/closets.dm b/code/game/objects/structures/crates_lockers/closets.dm
index fe1fb03426..7f98284ea4 100644
--- a/code/game/objects/structures/crates_lockers/closets.dm
+++ b/code/game/objects/structures/crates_lockers/closets.dm
@@ -554,9 +554,9 @@
if(!QDELETED(lockerelectronics))
lockerelectronics.accesses = req_access
-/obj/structure/closet/contents_explosion(severity, target)
+/obj/structure/closet/contents_explosion(severity, target, origin)
for(var/atom/A in contents)
- A.ex_act(severity, target)
+ A.ex_act(severity, target, origin)
CHECK_TICK
/obj/structure/closet/singularity_act()
diff --git a/code/game/objects/structures/crates_lockers/closets/genpop.dm b/code/game/objects/structures/crates_lockers/closets/genpop.dm
index 99665400e0..7be12a4819 100644
--- a/code/game/objects/structures/crates_lockers/closets/genpop.dm
+++ b/code/game/objects/structures/crates_lockers/closets/genpop.dm
@@ -40,13 +40,13 @@
return TRUE
/obj/structure/closet/secure_closet/genpop/proc/handle_edit_sentence(mob/user)
- var/prisoner_name = tgui_input_text(user, "Please input the name of the prisoner.", "Prisoner Name", registered_id.registered_name)
+ var/prisoner_name = input(user, "Please input the name of the prisoner.", "Prisoner Name", registered_id.registered_name) as text|null
if(prisoner_name == null | !user.Adjacent(src))
return FALSE
- var/sentence_length = tgui_input_num(user, "Please input the length of their sentence in minutes (0 for perma).", "Sentence Length", registered_id.sentence)
+ var/sentence_length = input(user, "Please input the length of their sentence in minutes (0 for perma).", "Sentence Length", registered_id.sentence) as num|null
if(sentence_length == null | !user.Adjacent(src))
return FALSE
- var/crimes = tgui_input_text(user, "Please input their crimes.", "Crimes", registered_id.crime)
+ var/crimes = input(user, "Please input their crimes.", "Crimes", registered_id.crime) as text|null
if(crimes == null | !user.Adjacent(src))
return FALSE
@@ -71,7 +71,7 @@
if(!broken && locked && registered_id != null)
var/name = registered_id.registered_name
- var/result = tgui_alert(user, "This locker currently contains [name]'s personal belongings ","Locker In Use",list("Reset","Amend ID", "Open"))
+ var/result = alert(user, "This locker currently contains [name]'s personal belongings ","Locker In Use","Reset","Amend ID", "Open")
if(!user.Adjacent(src))
return
if(result == "Reset")
diff --git a/code/game/objects/structures/crates_lockers/closets/secure/freezer.dm b/code/game/objects/structures/crates_lockers/closets/secure/freezer.dm
index ff3f4d8793..bfb86b087b 100644
--- a/code/game/objects/structures/crates_lockers/closets/secure/freezer.dm
+++ b/code/game/objects/structures/crates_lockers/closets/secure/freezer.dm
@@ -21,7 +21,7 @@
if(.) //if we actually closed the locker
recursive_organ_check(src)
-/obj/structure/closet/secure_closet/freezer/ex_act()
+/obj/structure/closet/secure_closet/freezer/ex_act(severity, target, origin)
if(!jones)
jones = TRUE
else
diff --git a/code/game/objects/structures/displaycase.dm b/code/game/objects/structures/displaycase.dm
index 321bb35cf8..c32bf81ecf 100644
--- a/code/game/objects/structures/displaycase.dm
+++ b/code/game/objects/structures/displaycase.dm
@@ -470,7 +470,7 @@
playsound(src, 'sound/machines/buzz-sigh.ogg', 50, TRUE)
return
- var/new_price_input = tgui_input_num(usr,"Set the sale price for this vend-a-tray.","new price",sale_price)
+ var/new_price_input = input(usr,"Set the sale price for this vend-a-tray.","new price",0) as num|null
if(isnull(new_price_input) || (payments_acc != potential_acc.registered_account))
to_chat(usr, "[src] rejects your new price.")
return
diff --git a/code/game/objects/structures/dresser.dm b/code/game/objects/structures/dresser.dm
index 48a6c2f530..9790a0e661 100644
--- a/code/game/objects/structures/dresser.dm
+++ b/code/game/objects/structures/dresser.dm
@@ -37,7 +37,7 @@
if(!(GLOB.socks_list[H.socks]?.has_color))
undergarment_choices -= "Socks Color"
- var/choice = tgui_input_list(H, "Underwear, Undershirt, or Socks?", "Changing", undergarment_choices)
+ var/choice = input(H, "Underwear, Undershirt, or Socks?", "Changing") as null|anything in undergarment_choices
if(!H.canUseTopic(src, BE_CLOSE, FALSE, NO_TK))
return
var/dye_undie = FALSE
@@ -45,21 +45,21 @@
var/dye_socks = FALSE
switch(choice)
if("Underwear")
- var/new_undies = tgui_input_list(H, "Select your underwear", "Changing", GLOB.underwear_list)
+ var/new_undies = input(H, "Select your underwear", "Changing") as null|anything in GLOB.underwear_list
if(new_undies)
H.underwear = new_undies
H.saved_underwear = new_undies
var/datum/sprite_accessory/underwear/bottom/B = GLOB.underwear_list[new_undies]
dye_undie = B?.has_color
if("Undershirt")
- var/new_undershirt = tgui_input_list(H, "Select your undershirt", "Changing", GLOB.undershirt_list)
+ var/new_undershirt = input(H, "Select your undershirt", "Changing") as null|anything in GLOB.undershirt_list
if(new_undershirt)
H.undershirt = new_undershirt
H.saved_undershirt = new_undershirt
var/datum/sprite_accessory/underwear/top/T = GLOB.undershirt_list[new_undershirt]
dye_shirt = T?.has_color
if("Socks")
- var/new_socks = tgui_input_list(H, "Select your socks", "Changing", GLOB.socks_list)
+ var/new_socks = input(H, "Select your socks", "Changing") as null|anything in GLOB.socks_list
if(new_socks)
H.socks = new_socks
H.saved_socks = new_socks
diff --git a/code/game/objects/structures/extinguisher.dm b/code/game/objects/structures/extinguisher.dm
index 467dd47c50..7542ec6768 100644
--- a/code/game/objects/structures/extinguisher.dm
+++ b/code/game/objects/structures/extinguisher.dm
@@ -32,9 +32,9 @@
stored_extinguisher = null
return ..()
-/obj/structure/extinguisher_cabinet/contents_explosion(severity, target)
+/obj/structure/extinguisher_cabinet/contents_explosion(severity, target, origin)
if(stored_extinguisher)
- stored_extinguisher.ex_act(severity, target)
+ stored_extinguisher.ex_act(severity, target, origin)
/obj/structure/extinguisher_cabinet/handle_atom_del(atom/A)
if(A == stored_extinguisher)
diff --git a/code/game/objects/structures/fireplace.dm b/code/game/objects/structures/fireplace.dm
index ca66dbd8de..ec7db22cf0 100644
--- a/code/game/objects/structures/fireplace.dm
+++ b/code/game/objects/structures/fireplace.dm
@@ -1,4 +1,4 @@
-#define LOG_BURN_TIMER 150
+#define LOG_BURN_TIMER 400
#define PAPER_BURN_TIMER 5
#define MAXIMUM_BURN_TIMER 3000
@@ -12,6 +12,7 @@
pixel_x = -16
resistance_flags = FIRE_PROOF
var/lit = FALSE
+ light_color = "#E38C2D"
var/fuel_added = 0
var/flame_expiry_timer
@@ -64,6 +65,12 @@
")
adjust_fuel_timer(PAPER_BURN_TIMER)
qdel(T)
+ else if(istype(T,/obj/item/grown/log))
+ user.visible_message("[user] tosses some \
+ wood into [src].", "You add \
+ some fuel to [src].")
+ adjust_fuel_timer(LOG_BURN_TIMER)
+ qdel(T)
else if(try_light(T,user))
return
else
diff --git a/code/game/objects/structures/flora.dm b/code/game/objects/structures/flora.dm
index b587e57c3a..288bcc2075 100644
--- a/code/game/objects/structures/flora.dm
+++ b/code/game/objects/structures/flora.dm
@@ -40,6 +40,16 @@
density = FALSE
pixel_x = -16
+/obj/structure/flora/stump/attackby(obj/item/W, mob/user, params)
+ if((W.tool_behaviour == TOOL_SHOVEL) && params)
+ playsound(src, 'sound/effects/shovel_dig.ogg', 50, 1)
+ if(do_after(user, 20))
+ new /obj/item/grown/log/tree(get_turf(src))
+ user.visible_message("[user] digs up [src].", "You dig up [src].")
+ qdel(src)
+ else
+ return ..()
+
/obj/structure/flora/tree/pine
name = "pine tree"
desc = "A coniferous pine tree."
@@ -58,6 +68,7 @@
desc = "A wondrous decorated Christmas tree."
icon_state = "pine_c"
icon_states = null
+ resistance_flags = INDESTRUCTIBLE //Sorry grinch, not this time
/obj/structure/flora/tree/pine/xmas/presents
icon_state = "pinepresents"
diff --git a/code/game/objects/structures/ghost_role_spawners.dm b/code/game/objects/structures/ghost_role_spawners.dm
index e3825b1ee6..be92782c74 100644
--- a/code/game/objects/structures/ghost_role_spawners.dm
+++ b/code/game/objects/structures/ghost_role_spawners.dm
@@ -184,7 +184,7 @@
/obj/effect/mob_spawn/human/golem/on_attack_hand(mob/user, act_intent = user.a_intent, unarmed_attack_flags)
if(isgolem(user) && can_transfer)
- var/transfer_choice = tgui_alert(user, "Transfer your soul to [src]? (Warning, your old body will die!)",,list("Yes","No"))
+ var/transfer_choice = alert("Transfer your soul to [src]? (Warning, your old body will die!)",,"Yes","No")
if(transfer_choice != "Yes" || QDELETED(src) || uses <= 0 || !user.canUseTopic(src, BE_CLOSE, NO_DEXTERY, NO_TK))
return
log_game("[key_name(user)] golem-swapped into [src]")
@@ -742,7 +742,7 @@
/datum/action/disguise/Trigger()
var/mob/living/carbon/human/H = owner
if(!currently_disguised)
- var/user_object_type = tgui_input_list(H, "Disguising as OBJECT or MOB?", "", list("OBJECT", "MOB"))
+ var/user_object_type = input(H, "Disguising as OBJECT or MOB?") as null|anything in list("OBJECT", "MOB")
if(user_object_type)
var/search_term = stripped_input(H, "Enter the search term")
if(search_term)
@@ -758,7 +758,7 @@
if(!length(filtered_results))
to_chat(H, "Nothing matched your search query!")
else
- var/disguise_selection = tgui_input_list(H, "Select item to disguise as", "", filtered_results)
+ var/disguise_selection = input("Select item to disguise as") as null|anything in filtered_results
if(disguise_selection)
var/atom/disguise_item = disguise_selection
var/image/I = image(icon = initial(disguise_item.icon), icon_state = initial(disguise_item.icon_state), loc = H)
diff --git a/code/game/objects/structures/guncase.dm b/code/game/objects/structures/guncase.dm
index e7ff9d4abf..78f0da2db2 100644
--- a/code/game/objects/structures/guncase.dm
+++ b/code/game/objects/structures/guncase.dm
@@ -91,9 +91,9 @@
/obj/structure/guncase/handle_atom_del(atom/A)
update_icon()
-/obj/structure/guncase/contents_explosion(severity, target)
+/obj/structure/guncase/contents_explosion(severity, target, origin)
for(var/atom/A in contents)
- A.ex_act(severity++, target)
+ A.ex_act(severity++, target, origin)
CHECK_TICK
/obj/structure/guncase/shotgun
diff --git a/code/game/objects/structures/loot_pile.dm b/code/game/objects/structures/loot_pile.dm
index b6249ec1e4..dc3971fdd2 100644
--- a/code/game/objects/structures/loot_pile.dm
+++ b/code/game/objects/structures/loot_pile.dm
@@ -9,6 +9,7 @@
icon_state = "randompile"
density = FALSE
anchored = TRUE
+ max_integrity = 100
var/loot_amount = 5
var/delete_on_depletion = FALSE
var/can_use_hands = TRUE
diff --git a/code/game/objects/structures/mirror.dm b/code/game/objects/structures/mirror.dm
index d518401ccb..a70d9d4678 100644
--- a/code/game/objects/structures/mirror.dm
+++ b/code/game/objects/structures/mirror.dm
@@ -26,7 +26,7 @@
//handle facial hair (if necessary)
if(H.gender != FEMALE)
- var/new_style = tgui_input_list(user, "Select a facial hair style", "Grooming", GLOB.facial_hair_styles_list)
+ var/new_style = input(user, "Select a facial hair style", "Grooming") as null|anything in GLOB.facial_hair_styles_list
if(!user.canUseTopic(src, BE_CLOSE, FALSE, NO_TK))
return //no tele-grooming
if(new_style)
@@ -35,7 +35,7 @@
H.facial_hair_style = "Shaved"
//handle normal hair
- var/new_style = tgui_input_list(user, "Select a hair style", "Grooming", GLOB.hair_styles_list)
+ var/new_style = input(user, "Select a hair style", "Grooming") as null|anything in GLOB.hair_styles_list
if(!user.canUseTopic(src, BE_CLOSE, FALSE, NO_TK))
return //no tele-grooming
if(new_style)
@@ -141,7 +141,7 @@
var/mob/living/carbon/human/H = user
- var/choice = tgui_input_list(user, "Something to change?", "Magical Grooming", list("name", "race", "gender", "hair", "eyes"))
+ var/choice = input(user, "Something to change?", "Magical Grooming") as null|anything in list("name", "race", "gender", "hair", "eyes")
if(!user.canUseTopic(src, BE_CLOSE, FALSE, NO_TK))
return
@@ -163,7 +163,7 @@
if("race")
var/newrace
- var/racechoice = tgui_input_list(H, "What are we again?", "Race change", choosable_races)
+ var/racechoice = input(H, "What are we again?", "Race change") as null|anything in choosable_races
newrace = GLOB.species_list[racechoice]
if(!newrace)
@@ -176,7 +176,7 @@
var/list/choices = GLOB.skin_tones
if(CONFIG_GET(flag/allow_custom_skintones))
choices += "custom"
- var/new_s_tone = tgui_input_list(H, "Choose your skin tone:", "Race change", choices)
+ var/new_s_tone = input(H, "Choose your skin tone:", "Race change") as null|anything in choices
if(new_s_tone)
if(new_s_tone == "custom")
var/default = H.dna.skin_tone_override || null
@@ -214,14 +214,14 @@
if(!user.canUseTopic(src, BE_CLOSE, FALSE, NO_TK))
return
if(H.gender == "male")
- if(tgui_alert(H, "Become a Witch?", "Confirmation", list("Yes", "No")) == "Yes")
+ if(alert(H, "Become a Witch?", "Confirmation", "Yes", "No") == "Yes")
H.gender = "female"
to_chat(H, "Man, you feel like a woman!")
else
return
else
- if(tgui_alert(H, "Become a Warlock?", "Confirmation", list("Yes", "No")) == "Yes")
+ if(alert(H, "Become a Warlock?", "Confirmation", "Yes", "No") == "Yes")
H.gender = "male"
to_chat(H, "Whoa man, you feel like a man!")
else
@@ -231,7 +231,7 @@
H.update_mutations_overlay() //(hulk male/female)
if("hair")
- var/hairchoice = tgui_alert(H, "Hair style or hair color?", "Change Hair", list("Style", "Color"))
+ var/hairchoice = alert(H, "Hair style or hair color?", "Change Hair", "Style", "Color")
if(!user.canUseTopic(src, BE_CLOSE, FALSE, NO_TK))
return
if(hairchoice == "Style") //So you just want to use a mirror then?
@@ -249,7 +249,7 @@
H.update_hair()
if(BODY_ZONE_PRECISE_EYES)
- var/eye_type = tgui_input_list(H, "Choose the eye you want to color", "Eye Color", list("Both Eyes", "Left Eye", "Right Eye"))
+ var/eye_type = input(H, "Choose the eye you want to color", "Eye Color") as null|anything in list("Both Eyes", "Left Eye", "Right Eye")
if(eye_type)
var/input_color = H.left_eye_color
if(eye_type == "Right Eye")
diff --git a/code/game/objects/structures/reflector.dm b/code/game/objects/structures/reflector.dm
index 47f9bd3e5d..944e1dac9c 100644
--- a/code/game/objects/structures/reflector.dm
+++ b/code/game/objects/structures/reflector.dm
@@ -159,7 +159,7 @@
if (!can_rotate || admin)
to_chat(user, "The rotation is locked!")
return FALSE
- var/new_angle = tgui_input_num(user, "Input a new angle for primary reflection face.", "Reflector Angle", rotation_angle)
+ var/new_angle = input(user, "Input a new angle for primary reflection face.", "Reflector Angle", rotation_angle) as null|num
if(!user.canUseTopic(src, BE_CLOSE, ismonkey(user)))
return
if(!isnull(new_angle))
@@ -249,7 +249,7 @@
P.setAngle(rotation_angle)
return ..()
-/obj/structure/reflector/ex_act()
+/obj/structure/reflector/ex_act(severity, target, origin)
if(admin)
return
else
diff --git a/code/game/objects/structures/safe.dm b/code/game/objects/structures/safe.dm
index 55eb100b21..beacee827c 100644
--- a/code/game/objects/structures/safe.dm
+++ b/code/game/objects/structures/safe.dm
@@ -84,7 +84,7 @@ FLOOR SAFES
/obj/structure/safe/blob_act(obj/structure/blob/B)
return
-/obj/structure/safe/ex_act(severity, target)
+/obj/structure/safe/ex_act(severity, target, origin)
if(((severity == 2 && target == src) || severity == 1) && explosion_count < BROKEN_THRESHOLD)
explosion_count++
switch(explosion_count)
diff --git a/code/game/objects/structures/signs/_signs.dm b/code/game/objects/structures/signs/_signs.dm
index b4ee0a3e55..8b82cdba5e 100644
--- a/code/game/objects/structures/signs/_signs.dm
+++ b/code/game/objects/structures/signs/_signs.dm
@@ -45,7 +45,7 @@
var/list/sign_types = list("Secure Area", "Biohazard", "High Voltage", "Radiation", "Hard Vacuum Ahead", "Disposal: Leads To Space", "Danger: Fire", "No Smoking", "Medbay", "Science", "Chemistry", \
"Hydroponics", "Xenobiology")
var/obj/structure/sign/sign_type
- switch(tgui_input_list(user, "Select a sign type.", "Sign Customization", sign_types))
+ switch(input(user, "Select a sign type.", "Sign Customization") as null|anything in sign_types)
if("Blank")
sign_type = /obj/structure/sign/basic
if("Secure Area")
diff --git a/code/game/objects/structures/spirit_board.dm b/code/game/objects/structures/spirit_board.dm
index 7781414583..1b3093e4e7 100644
--- a/code/game/objects/structures/spirit_board.dm
+++ b/code/game/objects/structures/spirit_board.dm
@@ -31,7 +31,7 @@
virgin = 0
notify_ghosts("Someone has begun playing with a [src.name] in [get_area(src)]!", source = src)
- planchette = tgui_input_list(M, "Choose the letter.", "Seance!", list("A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"))
+ planchette = input("Choose the letter.", "Seance!") as null|anything in list("A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z")
if(!planchette || !Adjacent(M) || next_use > world.time)
return
M.log_message("picked a letter on [src], which was \"[planchette]\".")
diff --git a/code/game/objects/structures/transit_tubes/transit_tube_pod.dm b/code/game/objects/structures/transit_tubes/transit_tube_pod.dm
index 82e946a2f4..9f3a829633 100644
--- a/code/game/objects/structures/transit_tubes/transit_tube_pod.dm
+++ b/code/game/objects/structures/transit_tubes/transit_tube_pod.dm
@@ -50,14 +50,14 @@
empty_pod(location)
qdel(src)
-/obj/structure/transit_tube_pod/ex_act(severity, target)
+/obj/structure/transit_tube_pod/ex_act(severity, target, origin)
..()
if(!QDELETED(src))
empty_pod()
-/obj/structure/transit_tube_pod/contents_explosion(severity, target)
+/obj/structure/transit_tube_pod/contents_explosion(severity, target, origin)
for(var/atom/movable/AM in contents)
- AM.ex_act(severity, target)
+ AM.ex_act(severity, target, origin)
/obj/structure/transit_tube_pod/singularity_pull(S, current_size)
..()
diff --git a/code/game/turfs/closed.dm b/code/game/turfs/closed.dm
index a3ec6c6276..ccfb5dc238 100644
--- a/code/game/turfs/closed.dm
+++ b/code/game/turfs/closed.dm
@@ -70,6 +70,7 @@
icon_state = "wood"
baseturfs = /turf/closed/indestructible/wood
smooth = SMOOTH_TRUE
+ canSmoothWith = list(/obj/structure/falsewall/wood, /turf/closed/wall/mineral/wood, /turf/closed/indestructible/wood)
/turf/closed/indestructible/oldshuttle/corner
icon_state = "corner"
diff --git a/code/game/turfs/simulated/floor.dm b/code/game/turfs/simulated/floor.dm
index 4b03b2b8e6..9b6767b874 100644
--- a/code/game/turfs/simulated/floor.dm
+++ b/code/game/turfs/simulated/floor.dm
@@ -72,7 +72,7 @@
if(mapload && prob(66)) // 2/3 instead of 1/3 (default)
MakeDirty()
-/turf/open/floor/ex_act(severity, target)
+/turf/open/floor/ex_act(severity, target, origin)
var/shielded = is_shielded()
..()
if(severity != 1 && shielded && target != src)
diff --git a/code/game/turfs/simulated/floor/plating.dm b/code/game/turfs/simulated/floor/plating.dm
index 199e7767f1..c831faca61 100644
--- a/code/game/turfs/simulated/floor/plating.dm
+++ b/code/game/turfs/simulated/floor/plating.dm
@@ -195,7 +195,7 @@
return TRUE
return FALSE
-/turf/open/floor/plating/foam/ex_act()
+/turf/open/floor/plating/foam/ex_act(severity, target, origin)
..()
ScrapeAway(flags = CHANGETURF_INHERIT_AIR)
diff --git a/code/game/turfs/simulated/floor/plating/asteroid.dm b/code/game/turfs/simulated/floor/plating/asteroid.dm
index ab2effa1ab..2770d12454 100644
--- a/code/game/turfs/simulated/floor/plating/asteroid.dm
+++ b/code/game/turfs/simulated/floor/plating/asteroid.dm
@@ -89,7 +89,7 @@
for(var/obj/item/stack/ore/O in src)
SEND_SIGNAL(W, COMSIG_PARENT_ATTACKBY, O)
-/turf/open/floor/plating/asteroid/ex_act(severity, target)
+/turf/open/floor/plating/asteroid/ex_act(severity, target, origin)
. = SEND_SIGNAL(src, COMSIG_ATOM_EX_ACT, severity, target)
contents_explosion(severity, target)
diff --git a/code/game/turfs/simulated/floor/plating/misc_plating.dm b/code/game/turfs/simulated/floor/plating/misc_plating.dm
index d834272bea..e49b6b78d3 100644
--- a/code/game/turfs/simulated/floor/plating/misc_plating.dm
+++ b/code/game/turfs/simulated/floor/plating/misc_plating.dm
@@ -120,7 +120,7 @@
/turf/open/floor/plating/beach/try_replace_tile(obj/item/stack/tile/T, mob/user, params)
return
-/turf/open/floor/plating/beach/ex_act(severity, target)
+/turf/open/floor/plating/beach/ex_act(severity, target, origin)
contents_explosion(severity, target)
/turf/open/floor/plating/beach/sand
diff --git a/code/game/turfs/simulated/floor/reinf_floor.dm b/code/game/turfs/simulated/floor/reinf_floor.dm
index 2d03624354..32eda3bdb7 100644
--- a/code/game/turfs/simulated/floor/reinf_floor.dm
+++ b/code/game/turfs/simulated/floor/reinf_floor.dm
@@ -53,7 +53,7 @@
acidpwr = min(acidpwr, 50) //we reduce the power so reinf floor never get melted.
. = ..()
-/turf/open/floor/engine/ex_act(severity,target)
+/turf/open/floor/engine/ex_act(severity,target, origin)
var/shielded = is_shielded()
contents_explosion(severity, target)
if(severity != 1 && shielded && target != src)
diff --git a/code/game/turfs/simulated/lava.dm b/code/game/turfs/simulated/lava.dm
index e7471478fb..8d7da15761 100644
--- a/code/game/turfs/simulated/lava.dm
+++ b/code/game/turfs/simulated/lava.dm
@@ -18,8 +18,8 @@
clawfootstep = FOOTSTEP_LAVA
heavyfootstep = FOOTSTEP_LAVA
-/turf/open/lava/ex_act(severity, target)
- contents_explosion(severity, target)
+/turf/open/lava/ex_act(severity, target, origin)
+ contents_explosion(severity, target, origin)
/turf/open/lava/MakeSlippery(wet_setting, min_wet_time, wet_time_to_add, max_wet_time, permanent)
return
diff --git a/code/game/turfs/simulated/minerals.dm b/code/game/turfs/simulated/minerals.dm
index 4a5b9f43de..48e7fa8f8a 100644
--- a/code/game/turfs/simulated/minerals.dm
+++ b/code/game/turfs/simulated/minerals.dm
@@ -171,7 +171,7 @@
/turf/closed/mineral/acid_melt()
ScrapeAway()
-/turf/closed/mineral/ex_act(severity, target)
+/turf/closed/mineral/ex_act(severity, target, origin)
..()
switch(severity)
if(3)
@@ -661,7 +661,7 @@
/turf/closed/mineral/strong/acid_melt()
return
-/turf/closed/mineral/strong/ex_act(severity, target)
+/turf/closed/mineral/strong/ex_act(severity, target, origin)
return
#undef MINING_MESSAGE_COOLDOWN
diff --git a/code/game/turfs/simulated/wall/mineral_walls.dm b/code/game/turfs/simulated/wall/mineral_walls.dm
index ed48c24462..f59b90a62a 100644
--- a/code/game/turfs/simulated/wall/mineral_walls.dm
+++ b/code/game/turfs/simulated/wall/mineral_walls.dm
@@ -272,12 +272,10 @@
icon_state = "map-overspace"
fixed_underlay = list("space"=1)
-/turf/closed/wall/mineral/plastitanium/explosive/ex_act(severity)
+/turf/closed/wall/mineral/plastitanium/explosive/ex_act(severity, target, origin)
var/datum/explosion/acted_explosion = null
- for(var/datum/explosion/E in GLOB.explosions)
- if(E.explosion_id == explosion_id)
- acted_explosion = E
- break
+ if(istype(origin, /datum/explosion))
+ acted_explosion = origin
if(acted_explosion && istype(acted_explosion.explosion_source, /obj/item/bombcore))
var/obj/item/bombcore/large/bombcore = new(get_turf(src))
bombcore.detonate()
diff --git a/code/game/turfs/simulated/walls.dm b/code/game/turfs/simulated/walls.dm
index 76dc6533b6..6303b33afa 100644
--- a/code/game/turfs/simulated/walls.dm
+++ b/code/game/turfs/simulated/walls.dm
@@ -80,7 +80,7 @@
if(girder_type)
new /obj/item/stack/sheet/metal(src)
-/turf/closed/wall/ex_act(severity, target)
+/turf/closed/wall/ex_act(severity, target, origin)
if(target == src)
dismantle_wall(1,1)
return
@@ -88,7 +88,7 @@
if(1)
//SN src = null
var/turf/NT = ScrapeAway()
- NT.contents_explosion(severity, target)
+ NT.contents_explosion(severity, target, origin)
return
if(2)
if (prob(50))
diff --git a/code/game/turfs/turf.dm b/code/game/turfs/turf.dm
index d949158850..85de964463 100755
--- a/code/game/turfs/turf.dm
+++ b/code/game/turfs/turf.dm
@@ -451,7 +451,7 @@ GLOBAL_LIST_EMPTY(station_turfs)
/turf/proc/is_shielded()
-/turf/contents_explosion(severity, target)
+/turf/contents_explosion(severity, target, origin)
var/affecting_level
if(severity == 1)
affecting_level = 1
@@ -469,7 +469,7 @@ GLOBAL_LIST_EMPTY(station_turfs)
var/atom/movable/AM = A
if(!AM.ex_check(explosion_id))
continue
- A.ex_act(severity, target)
+ A.ex_act(severity, target, origin)
CHECK_TICK
/turf/wave_ex_act(power, datum/wave_explosion/explosion, dir)
@@ -512,7 +512,7 @@ GLOBAL_LIST_EMPTY(station_turfs)
/turf/shove_act(mob/living/target, mob/living/user, pre_act = FALSE)
var/list/possibilities
for(var/obj/O in contents)
- if(CHECK_BITFIELD(O.obj_flags, SHOVABLE_ONTO))
+ if((O.obj_flags & SHOVABLE_ONTO))
LAZYADD(possibilities, O)
else if(!O.CanPass(target, src))
return FALSE
diff --git a/code/modules/admin/DB_ban/functions.dm b/code/modules/admin/DB_ban/functions.dm
index 82fc35466e..b8d2452874 100644
--- a/code/modules/admin/DB_ban/functions.dm
+++ b/code/modules/admin/DB_ban/functions.dm
@@ -92,7 +92,7 @@
qdel(query_add_ban_get_ckey)
if(!seen_before)
if(!had_banned_mob || (had_banned_mob && !banned_mob_guest_key))
- if(tgui_alert(usr, "[bankey] has not been seen before, are you sure you want to create a ban for them?", "Unknown ckey", list("Yes", "No", "Cancel")) != "Yes")
+ if(alert(usr, "[bankey] has not been seen before, are you sure you want to create a ban for them?", "Unknown ckey", "Yes", "No", "Cancel") != "Yes")
return
var/a_key
@@ -289,7 +289,7 @@
switch(param)
if("reason")
if(!value)
- value = tgui_input_text(usr, "Insert the new reason for [p_key]'s ban", "New Reason", "[reason]", null)
+ value = input("Insert the new reason for [p_key]'s ban", "New Reason", "[reason]", null) as null|text
if(!value)
to_chat(usr, "Cancelled")
return
@@ -302,7 +302,7 @@
message_admins("[key_name_admin(usr)] has edited a ban for [p_key]'s reason from [reason] to [value]")
if("duration")
if(!value)
- value = tgui_input_num(usr, "Insert the new duration (in minutes) for [p_key]'s ban", "New Duration", "[duration]", null)
+ value = input("Insert the new duration (in minutes) for [p_key]'s ban", "New Duration", "[duration]", null) as null|num
if(!isnum(value) || !value)
to_chat(usr, "Cancelled")
return
@@ -314,7 +314,7 @@
qdel(query_edit_ban_duration)
message_admins("[key_name_admin(usr)] has edited a ban for [p_key]'s duration from [duration] to [value]")
if("unban")
- if(tgui_alert(usr, "Unban [p_key]?", "Unban?", list("Yes", "No")) == "Yes")
+ if(alert("Unban [p_key]?", "Unban?", "Yes", "No") == "Yes")
DB_ban_unban_by_id(banid)
return
else
diff --git a/code/modules/admin/admin.dm b/code/modules/admin/admin.dm
index 2cd7e88565..d56e78c9fb 100644
--- a/code/modules/admin/admin.dm
+++ b/code/modules/admin/admin.dm
@@ -470,25 +470,25 @@
options += "Server Restart (Kill and restart DD)";
if(SSticker.admin_delay_notice)
- if(tgui_alert(usr, "Are you sure? An admin has already delayed the round end for the following reason: [SSticker.admin_delay_notice]", "Confirmation", list("Yes", "No")) != "Yes")
+ if(alert(usr, "Are you sure? An admin has already delayed the round end for the following reason: [SSticker.admin_delay_notice]", "Confirmation", "Yes", "No") != "Yes")
return FALSE
- var/result = tgui_input_list(usr, "Select reboot method", "World Reboot", options)
+ var/result = input(usr, "Select reboot method", "World Reboot", options[1]) as null|anything in options
if(result)
SSblackbox.record_feedback("tally", "admin_verb", 1, "Reboot World") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
var/init_by = "Initiated by [usr.client.holder.fakekey ? "Admin" : usr.key]."
switch(result)
if("Regular Restart")
if(!(isnull(usr.client.address) || (usr.client.address in localhost_addresses)))
- if(tgui_alert(usr, "Are you sure you want to restart the server?","This server is live",list("Restart","Cancel")) != "Restart")
+ if(alert("Are you sure you want to restart the server?","This server is live","Restart","Cancel") != "Restart")
return FALSE
SSticker.Reboot(init_by, "admin reboot - by [usr.key] [usr.client.holder.fakekey ? "(stealth)" : ""]", 10)
if("Regular Restart (with delay)")
- var/delay = tgui_input_num(usr, "What delay should the restart have (in seconds)?", "Restart Delay", 5)
+ var/delay = input("What delay should the restart have (in seconds)?", "Restart Delay", 5) as num|null
if(!delay)
return FALSE
if(!(isnull(usr.client.address) || (usr.client.address in localhost_addresses)))
- if(tgui_alert(usr, "Are you sure you want to restart the server?","This server is live",list("Restart","Cancel")) != "Restart")
+ if(alert("Are you sure you want to restart the server?","This server is live","Restart","Cancel") != "Restart")
return FALSE
SSticker.Reboot(init_by, "admin reboot - by [usr.key] [usr.client.holder.fakekey ? "(stealth)" : ""]", delay * 10)
if("Hard Restart (No Delay, No Feeback Reason)")
@@ -508,7 +508,7 @@
if (!usr.client.holder)
return
- var/confirm = tgui_alert(usr, "End the round and restart the game world?", "End Round", list("Yes", "Cancel"))
+ var/confirm = alert("End the round and restart the game world?", "End Round", "Yes", "Cancel")
if(confirm == "Cancel")
return
if(confirm == "Yes")
@@ -523,7 +523,7 @@
if(!check_rights(0))
return
- var/message = tgui_input_message(usr, "Global message to send:", "Admin Announce", null, null)
+ var/message = input("Global message to send:", "Admin Announce", null, null) as message
if(message)
if(!check_rights(R_SERVER,0))
message = adminscrub(message,500)
@@ -538,7 +538,7 @@
if(!check_rights(0))
return
- var/new_admin_notice = tgui_input_message(src,"Set a public notice for this round. Everyone who joins the server will see it.\n(Leaving it blank will delete the current notice):","Set Notice",GLOB.admin_notice)
+ var/new_admin_notice = input(src,"Set a public notice for this round. Everyone who joins the server will see it.\n(Leaving it blank will delete the current notice):","Set Notice",GLOB.admin_notice) as message|null
if(new_admin_notice == null)
return
if(new_admin_notice == GLOB.admin_notice)
@@ -599,7 +599,7 @@
if(!SSticker.start_immediately)
var/localhost_addresses = list("127.0.0.1", "::1")
if(!(isnull(usr.client.address) || (usr.client.address in localhost_addresses)))
- if(tgui_alert(usr, "Are you sure you want to start the round?","Start Now",list("Start Now","Cancel")) != "Start Now")
+ if(alert("Are you sure you want to start the round?","Start Now","Start Now","Cancel") != "Start Now")
return FALSE
SSticker.start_immediately = TRUE
log_admin("[usr.key] has started the game.")
@@ -684,9 +684,9 @@
set desc="Delay the game start"
set name="Delay Pre-Game"
- var/newtime = tgui_input_num(usr, "Set a new time in seconds. Set -1 for indefinite delay.","Set Delay",round(SSticker.GetTimeLeft()/10))
+ var/newtime = input("Set a new time in seconds. Set -1 for indefinite delay.","Set Delay",round(SSticker.GetTimeLeft()/10)) as num|null
if(SSticker.current_state > GAME_STATE_PREGAME)
- return tgui_alert(usr, "Too late... The game has already started!")
+ return alert("Too late... The game has already started!")
if(newtime)
newtime = newtime*10
SSticker.SetTimeLeft(newtime)
@@ -708,7 +708,7 @@
message_admins("[key_name_admin(usr)] has unprisoned [key_name_admin(M)]")
log_admin("[key_name(usr)] has unprisoned [key_name(M)]")
else
- tgui_alert(usr, "[M.name] is not prisoned.")
+ alert("[M.name] is not prisoned.")
SSblackbox.record_feedback("tally", "admin_verb", 1, "Unprison") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
////////////////////////////////////////////////////////////////////////////////////////////////ADMIN HELPER PROCS
@@ -873,7 +873,7 @@
var/count = 0
if(!SSjob.initialized)
- tgui_alert(usr, "You cannot manage jobs before the job subsystem is initialized!")
+ alert(usr, "You cannot manage jobs before the job subsystem is initialized!")
return
dat += "
"
@@ -972,7 +972,7 @@
question = "This mob already has a user ([tomob.key]) in control of it! "
question += "Are you sure you want to place [frommob.name]([frommob.key]) in control of [tomob.name]?"
- var/ask = tgui_alert(usr, question, "Place ghost in control of mob?", list("Yes", "No"))
+ var/ask = alert(question, "Place ghost in control of mob?", "Yes", "No")
if (ask != "Yes")
return TRUE
diff --git a/code/modules/admin/admin_investigate.dm b/code/modules/admin/admin_investigate.dm
index 23cf7eae87..52be445120 100644
--- a/code/modules/admin/admin_investigate.dm
+++ b/code/modules/admin/admin_investigate.dm
@@ -24,7 +24,7 @@
var/list/combined = sortList(logs_present) + sortList(logs_missing)
- var/selected = tgui_input_list(src, "Investigate what?", "Investigate", combined)
+ var/selected = input("Investigate what?", "Investigate") as null|anything in combined
if(!(selected in combined) || selected == "---")
return
diff --git a/code/modules/admin/admin_verbs.dm b/code/modules/admin/admin_verbs.dm
index 2c85e0ca42..8d3e1c79ec 100644
--- a/code/modules/admin/admin_verbs.dm
+++ b/code/modules/admin/admin_verbs.dm
@@ -518,7 +518,7 @@ GLOBAL_PROTECT(admin_verbs_hideable)
set desc = "Cause an explosion of varying strength at your location."
var/list/choices = list("Small Bomb (1, 2, 3, 3)", "Medium Bomb (2, 3, 4, 4)", "Big Bomb (3, 5, 7, 5)", "Maxcap", "Custom Bomb")
- var/choice = tgui_input_list(src, "What size explosion would you like to produce? NOTE: You can do all this rapidly and in an IC manner (using cruise missiles!) with the Config/Launch Supplypod verb. WARNING: These ignore the maxcap", choices)
+ var/choice = input("What size explosion would you like to produce? NOTE: You can do all this rapidly and in an IC manner (using cruise missiles!) with the Config/Launch Supplypod verb. WARNING: These ignore the maxcap") as null|anything in choices
var/turf/epicenter = mob.loc
switch(choice)
@@ -533,20 +533,20 @@ GLOBAL_PROTECT(admin_verbs_hideable)
if("Maxcap")
explosion(epicenter, GLOB.MAX_EX_DEVESTATION_RANGE, GLOB.MAX_EX_HEAVY_RANGE, GLOB.MAX_EX_LIGHT_RANGE, GLOB.MAX_EX_FLASH_RANGE)
if("Custom Bomb")
- var/devastation_range = tgui_input_num(src, "Devastation range (in tiles):")
+ var/devastation_range = input("Devastation range (in tiles):") as null|num
if(devastation_range == null)
return
- var/heavy_impact_range = tgui_input_num(src, "Heavy impact range (in tiles):")
+ var/heavy_impact_range = input("Heavy impact range (in tiles):") as null|num
if(heavy_impact_range == null)
return
- var/light_impact_range = tgui_input_num(src, "Light impact range (in tiles):")
+ var/light_impact_range = input("Light impact range (in tiles):") as null|num
if(light_impact_range == null)
return
- var/flash_range = tgui_input_num(src, "Flash range (in tiles):")
+ var/flash_range = input("Flash range (in tiles):") as null|num
if(flash_range == null)
return
if(devastation_range > GLOB.MAX_EX_DEVESTATION_RANGE || heavy_impact_range > GLOB.MAX_EX_HEAVY_RANGE || light_impact_range > GLOB.MAX_EX_LIGHT_RANGE || flash_range > GLOB.MAX_EX_FLASH_RANGE)
- if(tgui_alert(src, "Bomb is bigger than the maxcap. Continue?",,list("Yes","No")) != "Yes")
+ if(alert("Bomb is bigger than the maxcap. Continue?",,"Yes","No") != "Yes")
return
epicenter = mob.loc //We need to reupdate as they may have moved again
explosion(epicenter, devastation_range, heavy_impact_range, light_impact_range, flash_range, TRUE, TRUE)
@@ -559,34 +559,34 @@ GLOBAL_PROTECT(admin_verbs_hideable)
set name = "Drop Wave Explosion"
set desc = "Cause an explosive shockwave at your location."
- var/power = tgui_input_num(src, "Wave initial power", "Power", 50)
+ var/power = input(src, "Wave initial power", "Power", 50) as num|null
if(isnull(power))
return
- var/falloff = tgui_input_num(src, "Wave innate falloff factor", "Falloff", EXPLOSION_DEFAULT_FALLOFF_MULTIPLY)
+ var/falloff = input(src, "Wave innate falloff factor", "Falloff", EXPLOSION_DEFAULT_FALLOFF_MULTIPLY) as num|null
if(isnull(falloff))
return
falloff = max(0, falloff)
if(falloff > 1)
to_chat(src, "Aborting: Falloff cannot be higher tahn 1.")
return
- var/constant = tgui_input_num(src, "Wave innate falloff constant", "Constant", EXPLOSION_DEFAULT_FALLOFF_SUBTRACT)
+ var/constant = input(src, "Wave innate falloff constant", "Constant", EXPLOSION_DEFAULT_FALLOFF_SUBTRACT) as num|null
if(isnull(constant))
return
if(constant < 0)
to_chat(src, "Aborting: Falloff constant cannot be less than 0.")
return
- var/fire = tgui_input_num(src, "Probability per tile of fire?", "Fire Probability", 0)
+ var/fire = input(src, "Probability per tile of fire?", "Fire Probability", 0) as num|null
if(isnull(fire))
return
- var/speed = tgui_input_num(src, "Speed in ticks to wait between cycles? 0 for fast as possible", "Wait", 0)
+ var/speed = input(src, "Speed in ticks to wait between cycles? 0 for fast as possible", "Wait", 0) as num|null
if(isnull(speed))
return
- var/block_resistance = tgui_input_num(src, "DANGEROUS: Block resistance? USE 1 IF YOU DO NOT KNOW WHAT YOU ARE DOING.", "Block Negation", 1)
+ var/block_resistance = input(src, "DANGEROUS: Block resistance? USE 1 IF YOU DO NOT KNOW WHAT YOU ARE DOING.", "Block Negation", 1) as num|null
if(isnull(block_resistance))
return
block_resistance = max(0, block_resistance)
if(power > 500)
- var/sure = tgui_alert(src, "Explosion power is extremely high. Are you absolutely sure?", "Uhh...", list("No", "Yes"))
+ var/sure = alert(src, "Explosion power is extremely high. Are you absolutely sure?", "Uhh...", "No", "Yes")
if(sure != "Yes")
return
// point of no return
@@ -604,7 +604,7 @@ GLOBAL_PROTECT(admin_verbs_hideable)
set name = "Drop DynEx Bomb"
set desc = "Cause an explosion of varying strength at your location."
- var/ex_power = tgui_input_num(src, "Explosive Power:")
+ var/ex_power = input("Explosive Power:") as null|num
var/turf/epicenter = mob.loc
if(ex_power && epicenter)
dyn_explosion(epicenter, ex_power)
@@ -617,7 +617,7 @@ GLOBAL_PROTECT(admin_verbs_hideable)
set name = "Get DynEx Range"
set desc = "Get the estimated range of a bomb, using explosive power."
- var/ex_power = tgui_input_num(src, "Explosive Power:")
+ var/ex_power = input("Explosive Power:") as null|num
if (isnull(ex_power))
return
var/range = round((2 * ex_power)**GLOB.DYN_EX_SCALE)
@@ -628,7 +628,7 @@ GLOBAL_PROTECT(admin_verbs_hideable)
set name = "Get DynEx Power"
set desc = "Get the estimated required power of a bomb, to reach a specific range."
- var/ex_range = tgui_input_num(src, "Light Explosion Range:")
+ var/ex_range = input("Light Explosion Range:") as null|num
if (isnull(ex_range))
return
var/power = (0.5 * ex_range)**(1/GLOB.DYN_EX_SCALE)
@@ -639,7 +639,7 @@ GLOBAL_PROTECT(admin_verbs_hideable)
set name = "Set DynEx Scale"
set desc = "Set the scale multiplier of dynex explosions. The default is 0.5."
- var/ex_scale = tgui_input_num(src, "New DynEx Scale:")
+ var/ex_scale = input("New DynEx Scale:") as null|num
if(!ex_scale)
return
GLOB.DYN_EX_SCALE = ex_scale
@@ -684,10 +684,10 @@ GLOBAL_PROTECT(admin_verbs_hideable)
// if(!SStrading_card_game.loaded)
// message_admins("The card subsystem is not currently loaded")
// return
-// var/pack = tgui_input_list(src, "Which pack should we test?", "You fucked it didn't you", sortList(SStrading_card_game.card_packs))
-// var/batchCount = tgui_input_num(src, "How many times should we open it?", "Don't worry, I understand")
-// var/batchSize = tgui_input_num(src, "How many cards per batch?", "I hope you remember to check the validation")
-// var/guar = tgui_input_num(src, "Should we use the pack's guaranteed rarity? If so, how many?", "We've all been there. Man you should have seen the old system")
+// var/pack = input("Which pack should we test?", "You fucked it didn't you") as null|anything in sortList(SStrading_card_game.card_packs)
+// var/batchCount = input("How many times should we open it?", "Don't worry, I understand") as null|num
+// var/batchSize = input("How many cards per batch?", "I hope you remember to check the validation") as null|num
+// var/guar = input("Should we use the pack's guaranteed rarity? If so, how many?", "We've all been there. Man you should have seen the old system") as null|num
// checkCardDistribution(pack, batchSize, batchCount, guar)
// /client/proc/print_cards()
@@ -704,7 +704,7 @@ GLOBAL_PROTECT(admin_verbs_hideable)
var/type_length = length_char("/obj/effect/proc_holder/spell") + 2
for(var/A in GLOB.spells)
spell_list[copytext_char("[A]", type_length)] = A
- var/obj/effect/proc_holder/spell/S = tgui_input_list(src, "Choose the spell to give to that guy", "ABRAKADABRA", sortList(spell_list))
+ var/obj/effect/proc_holder/spell/S = input("Choose the spell to give to that guy", "ABRAKADABRA") as null|anything in sortList(spell_list)
if(!S)
return
@@ -725,7 +725,7 @@ GLOBAL_PROTECT(admin_verbs_hideable)
set desc = "Remove a spell from the selected mob."
if(T?.mind)
- var/obj/effect/proc_holder/spell/S = tgui_input_list(src, "Choose the spell to remove", "NO ABRAKADABRA", sortList(T.mind.spell_list))
+ var/obj/effect/proc_holder/spell/S = input("Choose the spell to remove", "NO ABRAKADABRA") as null|anything in sortList(T.mind.spell_list)
if(S)
T.mind.RemoveSpell(S)
log_admin("[key_name(usr)] removed the spell [S] from [key_name(T)].")
@@ -739,7 +739,7 @@ GLOBAL_PROTECT(admin_verbs_hideable)
if(!istype(T))
to_chat(src, "You can only give a disease to a mob of type /mob/living.", confidential = TRUE)
return
- var/datum/disease/D = tgui_input_list(src, "Choose the disease to give to that guy", "ACHOO", sortList(SSdisease.diseases, /proc/cmp_typepaths_asc))
+ var/datum/disease/D = input("Choose the disease to give to that guy", "ACHOO") as null|anything in sortList(SSdisease.diseases, /proc/cmp_typepaths_asc)
if(!D)
return
T.ForceContractDisease(new D, FALSE, TRUE)
@@ -751,7 +751,7 @@ GLOBAL_PROTECT(admin_verbs_hideable)
set category = "Admin.Events"
set name = "OSay"
set desc = "Makes an object say something."
- var/message = tgui_input_text(usr, "What do you want the message to be?", "Make Sound")
+ var/message = input(usr, "What do you want the message to be?", "Make Sound") as text | null
if(!message)
return
O.say(message)
diff --git a/code/modules/admin/antag_panel.dm b/code/modules/admin/antag_panel.dm
index 80ec32d997..180735d746 100644
--- a/code/modules/admin/antag_panel.dm
+++ b/code/modules/admin/antag_panel.dm
@@ -91,10 +91,10 @@ GLOBAL_VAR(antag_prototypes)
/datum/mind/proc/traitor_panel()
if(!SSticker.HasRoundStarted())
- tgui_alert(usr, "Not before round-start!", "Alert")
+ alert("Not before round-start!", "Alert")
return
if(QDELETED(src))
- tgui_alert(usr, "This mind doesn't have a mob, or is deleted! For some reason!", "Edit Memory")
+ alert("This mind doesn't have a mob, or is deleted! For some reason!", "Edit Memory")
return
var/out = "[name][(current && (current.real_name!=name))?" (as [current.real_name])":""] "
diff --git a/code/modules/admin/callproc/callproc.dm b/code/modules/admin/callproc/callproc.dm
index 83d51e3049..21bf732493 100644
--- a/code/modules/admin/callproc/callproc.dm
+++ b/code/modules/admin/callproc/callproc.dm
@@ -12,7 +12,7 @@
var/targetselected = FALSE
var/returnval
- switch(tgui_alert(usr, "Proc owned by something?",,list("Yes","No")))
+ switch(alert("Proc owned by something?",,"Yes","No"))
if("Yes")
targetselected = TRUE
var/list/value = vv_get_value(default_class = VV_ATOM_REFERENCE, classes = list(VV_ATOM_REFERENCE, VV_DATUM_REFERENCE, VV_MOB_REFERENCE, VV_CLIENT, VV_MARKED_DATUM, VV_TEXT_LOCATE, VV_PROCCALL_RETVAL))
@@ -26,7 +26,7 @@
target = null
targetselected = FALSE
- var/procpath = tgui_input_text(src, "Proc path, eg: /proc/fake_blood","Path:", null)
+ var/procpath = input("Proc path, eg: /proc/fake_blood","Path:", null) as text|null
if(!procpath)
return
@@ -136,7 +136,7 @@ GLOBAL_PROTECT(LastAdminCalledProc)
if(!check_rights(R_DEBUG))
return
- var/procname = tgui_input_text(src, "Proc name, eg: fake_blood","Proc:", null)
+ var/procname = input("Proc name, eg: fake_blood","Proc:", null) as text|null
if(!procname)
return
if(!hascall(A,procname))
@@ -161,14 +161,14 @@ GLOBAL_PROTECT(LastAdminCalledProc)
to_chat(usr, ., confidential = TRUE)
/client/proc/get_callproc_args()
- var/argnum = tgui_input_num(src, "Number of arguments","Number:",0)
+ var/argnum = input("Number of arguments","Number:",0) as num|null
if(isnull(argnum))
return
. = list()
var/list/named_args = list()
while(argnum--)
- var/named_arg = tgui_input_text(src, "Leave blank for positional argument. Positional arguments will be considered as if they were added first.", "Named argument")
+ var/named_arg = input("Leave blank for positional argument. Positional arguments will be considered as if they were added first.", "Named argument") as text|null
var/value = vv_get_value(restricted_classes = list(VV_RESTORE_DEFAULT))
if (!value["class"])
return
diff --git a/code/modules/admin/check_antagonists.dm b/code/modules/admin/check_antagonists.dm
index 8ae036703a..532a11a532 100644
--- a/code/modules/admin/check_antagonists.dm
+++ b/code/modules/admin/check_antagonists.dm
@@ -134,7 +134,7 @@
/datum/admins/proc/check_antagonists()
if(!SSticker.HasRoundStarted())
- tgui_alert(usr, "The game hasn't started yet!")
+ alert("The game hasn't started yet!")
return
var/list/dat = list("Round Status
Round Status
")
if(SSticker.mode.replacementmode)
diff --git a/code/modules/admin/create_object.dm b/code/modules/admin/create_object.dm
index 18d9cb658f..a0d7e41485 100644
--- a/code/modules/admin/create_object.dm
+++ b/code/modules/admin/create_object.dm
@@ -19,7 +19,7 @@
/obj/item, /obj/item/clothing, /obj/item/stack, /obj/item,
/obj/item/reagent_containers, /obj/item/gun)
- var/path = tgui_input_list(user, "Select the path of the object you wish to create.", "Path", create_object_forms)
+ var/path = input("Select the path of the object you wish to create.", "Path", /obj) in create_object_forms
var/html_form = create_object_forms[path]
if (!html_form)
diff --git a/code/modules/admin/create_poll.dm b/code/modules/admin/create_poll.dm
index b43d084005..e5391f0f43 100644
--- a/code/modules/admin/create_poll.dm
+++ b/code/modules/admin/create_poll.dm
@@ -6,7 +6,7 @@
if(!SSdbcore.Connect())
to_chat(src, "Failed to establish database connection.")
return
- var/polltype = tgui_input_list(src, "Choose poll type.","Poll Type", list("Single Option","Text Reply","Rating","Multiple Choice", "Instant Runoff Voting"))
+ var/polltype = input("Choose poll type.","Poll Type") as null|anything in list("Single Option","Text Reply","Rating","Multiple Choice", "Instant Runoff Voting")
var/choice_amount = 0
switch(polltype)
if("Single Option")
@@ -17,7 +17,7 @@
polltype = POLLTYPE_RATING
if("Multiple Choice")
polltype = POLLTYPE_MULTI
- choice_amount = tgui_input_num(src, "How many choices should be allowed?","Select choice amount")
+ choice_amount = input("How many choices should be allowed?","Select choice amount") as num|null
switch(choice_amount)
if(0)
to_chat(src, "Multiple choice poll must have at least one choice allowed.")
@@ -31,7 +31,7 @@
else
return 0
var/starttime = SQLtime()
- var/endtime = tgui_input_text(src, "Set end time for poll as format YYYY-MM-DD HH:MM:SS. All times in server time. HH:MM:SS is optional and 24-hour. Must be later than starting time for obvious reasons.", "Set end time", SQLtime())
+ var/endtime = input("Set end time for poll as format YYYY-MM-DD HH:MM:SS. All times in server time. HH:MM:SS is optional and 24-hour. Must be later than starting time for obvious reasons.", "Set end time", SQLtime()) as text
if(!endtime)
return
var/datum/db_query/query_validate_time = SSdbcore.NewQuery({"
@@ -49,7 +49,7 @@
endtime = query_validate_time.item[1]
qdel(query_validate_time)
var/adminonly
- switch(tgui_alert(usr, "Admin only poll?",,list("Yes","No","Cancel")))
+ switch(alert("Admin only poll?",,"Yes","No","Cancel"))
if("Yes")
adminonly = 1
if("No")
@@ -57,26 +57,26 @@
else
return
var/dontshow
- switch(tgui_alert(usr, "Hide poll results from tracking until completed?",,list("Yes","No","Cancel")))
+ switch(alert("Hide poll results from tracking until completed?",,"Yes","No","Cancel"))
if("Yes")
dontshow = 1
if("No")
dontshow = 0
else
return
- var/question = tgui_input_message(src, "Write your question","Question")
+ var/question = input("Write your question","Question") as message|null
if(!question)
return
var/list/sql_option_list = list()
if(polltype != POLLTYPE_TEXT)
var/add_option = 1
while(add_option)
- var/option = tgui_input_message(src, "Write your option","Option")
+ var/option = input("Write your option","Option") as message|null
if(!option)
return
var/default_percentage_calc = 0
if(polltype != POLLTYPE_IRV)
- switch(tgui_alert(usr, "Should this option be included by default when poll result percentages are generated?",,list("Yes","No","Cancel")))
+ switch(alert("Should this option be included by default when poll result percentages are generated?",,"Yes","No","Cancel"))
if("Yes")
default_percentage_calc = 1
if("No")
@@ -89,29 +89,29 @@
var/descmid = ""
var/descmax = ""
if(polltype == POLLTYPE_RATING)
- minval = tgui_input_num(src, "Set minimum rating value.","Minimum rating")
+ minval = input("Set minimum rating value.","Minimum rating") as num|null
if(minval == null)
return
- maxval = tgui_input_num(src, "Set maximum rating value.","Maximum rating")
+ maxval = input("Set maximum rating value.","Maximum rating") as num|null
if(minval >= maxval)
to_chat(src, "Maximum rating value can't be less than or equal to minimum rating value")
continue
if(maxval == null)
return
- descmin = tgui_input_message(src, "Optional: Set description for minimum rating","Minimum rating description")
+ descmin = input("Optional: Set description for minimum rating","Minimum rating description") as message|null
if(descmin == null)
return
- descmid = tgui_input_message(src, "Optional: Set description for median rating","Median rating description")
+ descmid = input("Optional: Set description for median rating","Median rating description") as message|null
if(descmid == null)
return
- descmax = tgui_input_message(src, "Optional: Set description for maximum rating","Maximum rating description")
+ descmax = input("Optional: Set description for maximum rating","Maximum rating description") as message|null
if(descmax == null)
return
sql_option_list += list(list(
"text" = option, "minval" = minval, "maxval" = maxval,
"descmin" = descmin, "descmid" = descmid, "descmax" = descmax,
"default_percentage_calc" = default_percentage_calc))
- switch(tgui_alert(usr, " ",,list("Add option","Finish", "Cancel")))
+ switch(alert(" ",,"Add option","Finish", "Cancel"))
if("Add option")
add_option = 1
if("Finish")
diff --git a/code/modules/admin/fun_balloon.dm b/code/modules/admin/fun_balloon.dm
index f11b193680..417663fcb7 100644
--- a/code/modules/admin/fun_balloon.dm
+++ b/code/modules/admin/fun_balloon.dm
@@ -35,7 +35,7 @@
/obj/effect/fun_balloon/attack_ghost(mob/user)
if(!user.client || !user.client.holder || popped)
return
- var/confirmation = tgui_alert(user, "Pop [src]?","Fun Balloon",list("Yes","No"))
+ var/confirmation = alert("Pop [src]?","Fun Balloon","Yes","No")
if(confirmation == "Yes" && !popped)
popped = TRUE
effect()
diff --git a/code/modules/admin/outfit_editor.dm b/code/modules/admin/outfit_editor.dm
index e50f1bec4c..9a99d8b20e 100644
--- a/code/modules/admin/outfit_editor.dm
+++ b/code/modules/admin/outfit_editor.dm
@@ -117,11 +117,11 @@
if(!choice)
return
if(!ispath(choice))
- tgui_alert(owner, "Invalid item", OUTFIT_EDITOR_NAME, "oh no")
+ alert(owner, "Invalid item", OUTFIT_EDITOR_NAME, "oh no")
return
if(initial(choice.icon_state) == null) //hacky check copied from experimentor code
var/msg = "Warning: This item's icon_state is null, indicating it is very probably not actually a usable item."
- if(tgui_alert(owner, msg, OUTFIT_EDITOR_NAME, list("Use it anyway", "Cancel")) != "Use it anyway")
+ if(alert(owner, msg, OUTFIT_EDITOR_NAME, "Use it anyway", "Cancel") != "Use it anyway")
return
if(drip.vars.Find(slot))
diff --git a/code/modules/admin/permissionedit.dm b/code/modules/admin/permissionedit.dm
index 4676d50df4..9f5dc00a48 100644
--- a/code/modules/admin/permissionedit.dm
+++ b/code/modules/admin/permissionedit.dm
@@ -165,7 +165,7 @@
to_chat(usr, "Unable to connect to database, changes are temporary only.", confidential = TRUE)
use_db = FALSE
else
- use_db = tgui_alert(usr, "Permanent changes are saved to the database for future rounds, temporary changes will affect only the current round", "Permanent or Temporary?", list("Permanent", "Temporary", "Cancel"))
+ use_db = alert("Permanent changes are saved to the database for future rounds, temporary changes will affect only the current round", "Permanent or Temporary?", "Permanent", "Temporary", "Cancel")
if(use_db == "Cancel")
return
if(use_db == "Permanent")
@@ -208,7 +208,7 @@
if(admin_ckey)
. = admin_ckey
else
- admin_key = tgui_input_text(usr, "New admin's key","Admin key")
+ admin_key = input("New admin's key","Admin key") as text|null
. = ckey(admin_key)
if(!.)
return FALSE
@@ -247,7 +247,7 @@
qdel(query_add_admin_log)
/datum/admins/proc/remove_admin(admin_ckey, admin_key, use_db, datum/admins/D)
- if(tgui_alert(usr, "Are you sure you want to remove [admin_ckey]?","Confirm Removal",list("Do it","Cancel")) == "Do it")
+ if(alert("Are you sure you want to remove [admin_ckey]?","Confirm Removal","Do it","Cancel") == "Do it")
GLOB.admin_datums -= admin_ckey
GLOB.deadmins -= admin_ckey
if(D)
@@ -305,9 +305,9 @@
for(R in GLOB.admin_ranks)
if((R.rights & usr.client.holder.rank.can_edit_rights) == R.rights)
rank_names[R.name] = R
- var/new_rank = tgui_input_list(usr, "Please select a rank", "New rank", rank_names)
+ var/new_rank = input("Please select a rank", "New rank") as null|anything in rank_names
if(new_rank == "*New Rank*")
- new_rank = tgui_input_text(usr, "Please input a new rank", "New custom rank")
+ new_rank = input("Please input a new rank", "New custom rank") as text|null
if(!new_rank)
return
R = rank_names[new_rank]
@@ -492,7 +492,7 @@
to_chat(usr, "Error: Rank deletion attempted while rank still used; Tell a coder, this shouldn't happen.", confidential = TRUE)
return
qdel(query_admins_with_rank)
- if(tgui_alert(usr, "Are you sure you want to remove [admin_rank]?","Confirm Removal",list("Do it","Cancel")) == "Do it")
+ if(alert("Are you sure you want to remove [admin_rank]?","Confirm Removal","Do it","Cancel") == "Do it")
var/m1 = "[key_name_admin(usr)] removed rank [admin_rank] permanently"
var/m2 = "[key_name(usr)] removed rank [admin_rank] permanently"
var/datum/db_query/query_add_rank = SSdbcore.NewQuery(
diff --git a/code/modules/admin/sound_emitter.dm b/code/modules/admin/sound_emitter.dm
index b8ea8d0c0e..ad9c995aa1 100644
--- a/code/modules/admin/sound_emitter.dm
+++ b/code/modules/admin/sound_emitter.dm
@@ -90,7 +90,7 @@
sound_file = new_file
to_chat(user, "New sound file set to [sound_file].", confidential = TRUE)
if(href_list["edit_volume"])
- var/new_volume = tgui_input_num(user, "Choose a volume.", "Sound Emitter", sound_volume)
+ var/new_volume = input(user, "Choose a volume.", "Sound Emitter", sound_volume) as null|num
if(isnull(new_volume))
return
new_volume = clamp(new_volume, 0, 100)
@@ -99,7 +99,7 @@
if(href_list["edit_mode"])
var/new_mode
var/mode_list = list("Local (normal sound)" = SOUND_EMITTER_LOCAL, "Direct (not affected by environment/location)" = SOUND_EMITTER_DIRECT)
- new_mode = tgui_input_list(user, "Choose a new mode.", "Sound Emitter", mode_list)
+ new_mode = input(user, "Choose a new mode.", "Sound Emitter") as null|anything in mode_list
if(!new_mode)
return
motus_operandi = mode_list[new_mode]
@@ -107,13 +107,13 @@
if(href_list["edit_range"])
var/new_range
var/range_list = list("Radius (all mobs within a radius)" = SOUND_EMITTER_RADIUS, "Z-Level (all mobs on the same z)" = SOUND_EMITTER_ZLEVEL, "Global (all players)" = SOUND_EMITTER_GLOBAL)
- new_range = tgui_input_list(user, "Choose a new range.", "Sound Emitter", range_list)
+ new_range = input(user, "Choose a new range.", "Sound Emitter") as null|anything in range_list
if(!new_range)
return
emitter_range = range_list[new_range]
to_chat(user, "Range set to [emitter_range].", confidential = TRUE)
if(href_list["edit_radius"])
- var/new_radius = tgui_input_num(user, "Choose a radius.", "Sound Emitter", sound_volume)
+ var/new_radius = input(user, "Choose a radius.", "Sound Emitter", sound_volume) as null|num
if(isnull(new_radius))
return
new_radius = clamp(new_radius, 0, 127)
diff --git a/code/modules/admin/sql_message_system.dm b/code/modules/admin/sql_message_system.dm
index a02df755c9..3ba309bc24 100644
--- a/code/modules/admin/sql_message_system.dm
+++ b/code/modules/admin/sql_message_system.dm
@@ -6,7 +6,7 @@
return
var/target_ckey = ckey(target_key)
if(!target_key && (type == "note" || type == "message" || type == "watchlist entry"))
- var/new_key = tgui_input_text(usr,"Who would you like to create a [type] for?","Enter a key or ckey",null)
+ var/new_key = input(usr,"Who would you like to create a [type] for?","Enter a key or ckey",null) as null|text
if(!new_key)
return
var/new_ckey = ckey(new_key)
@@ -18,7 +18,7 @@
qdel(query_find_ckey)
return
if(!query_find_ckey.NextRow())
- if(tgui_alert(usr, "[new_key]/([new_ckey]) has not been seen before, are you sure you want to create a [type] for them?", "Unknown ckey", list("Yes", "No", "Cancel")) != "Yes")
+ if(alert(usr, "[new_key]/([new_ckey]) has not been seen before, are you sure you want to create a [type] for them?", "Unknown ckey", "Yes", "No", "Cancel") != "Yes")
qdel(query_find_ckey)
return
qdel(query_find_ckey)
@@ -35,7 +35,7 @@
if(!target_ckey)
target_ckey = admin_ckey
if(!text)
- text = tgui_input_message(usr,"Write your [type]","Create [type]")
+ text = input(usr,"Write your [type]","Create [type]") as null|message
if(!text)
return
if(!timestamp)
@@ -45,7 +45,7 @@
if (ssqlname)
server = ssqlname
if(isnull(secret))
- switch(tgui_alert(usr, "Hide note from being viewed by players?", "Secret note?",list("Yes","No","Cancel")))
+ switch(alert("Hide note from being viewed by players?", "Secret note?","Yes","No","Cancel"))
if("Yes")
secret = 1
if("No")
@@ -53,8 +53,8 @@
else
return
if(isnull(expiry))
- if(tgui_alert(usr, "Set an expiry time? Expired messages are hidden like deleted ones.", "Expiry time?", list("Yes", "No", "Cancel")) == "Yes")
- var/expire_time = tgui_input_text(usr, "Set expiry time for [type] as format YYYY-MM-DD HH:MM:SS. All times in server time. HH:MM:SS is optional and 24-hour. Must be later than current time for obvious reasons.", "Set expiry time", SQLtime())
+ if(alert(usr, "Set an expiry time? Expired messages are hidden like deleted ones.", "Expiry time?", "Yes", "No", "Cancel") == "Yes")
+ var/expire_time = input("Set expiry time for [type] as format YYYY-MM-DD HH:MM:SS. All times in server time. HH:MM:SS is optional and 24-hour. Must be later than current time for obvious reasons.", "Set expiry time", SQLtime()) as null|text
if(!expire_time)
return
var/datum/db_query/query_validate_expire_time = SSdbcore.NewQuery(
@@ -73,7 +73,7 @@
expiry = query_validate_expire_time.item[1]
qdel(query_validate_expire_time)
if(type == "note" && isnull(note_severity))
- note_severity = tgui_input_list(usr, "Set the severity of the note.", "Severity", list("High", "Medium", "Minor", "None"))
+ note_severity = input("Set the severity of the note.", "Severity", null, null) as null|anything in list("High", "Medium", "Minor", "None")
if(!note_severity)
return
var/datum/db_query/query_create_message = SSdbcore.NewQuery({"
@@ -180,7 +180,7 @@
var/target_key = query_find_edit_message.item[2]
var/admin_key = query_find_edit_message.item[3]
var/old_text = query_find_edit_message.item[4]
- var/new_text = tgui_input_message(usr, "Input new [type]", "New [type]", "[old_text]")
+ var/new_text = input("Input new [type]", "New [type]", "[old_text]") as null|message
if(!new_text)
qdel(query_find_edit_message)
return
@@ -231,7 +231,7 @@
var/admin_key = query_find_edit_expiry_message.item[3]
var/old_expiry = query_find_edit_expiry_message.item[4]
var/new_expiry
- var/expire_time = tgui_input_text(usr, "Set expiry time for [type] as format YYYY-MM-DD HH:MM:SS. All times in server time. HH:MM:SS is optional and 24-hour. Must be later than current time for obvious reasons. Enter -1 to remove expiry time.", "Set expiry time", old_expiry)
+ var/expire_time = input("Set expiry time for [type] as format YYYY-MM-DD HH:MM:SS. All times in server time. HH:MM:SS is optional and 24-hour. Must be later than current time for obvious reasons. Enter -1 to remove expiry time.", "Set expiry time", old_expiry) as null|text
if(!expire_time)
qdel(query_find_edit_expiry_message)
return
@@ -303,7 +303,7 @@
old_severity = "NA"
var/editor_key = usr.key
var/editor_ckey = usr.ckey
- var/new_severity = tgui_input_list(usr, "Set the severity of the note.", "Severity", list("high", "medium", "minor", "none")) //lowercase for edit log consistency
+ var/new_severity = input("Set the severity of the note.", "Severity", null, null) as null|anything in list("high", "medium", "minor", "none") //lowercase for edit log consistency
if(!new_severity)
qdel(query_find_edit_note_severity)
return
diff --git a/code/modules/admin/stickyban.dm b/code/modules/admin/stickyban.dm
index 4906f9a97a..57487f3144 100644
--- a/code/modules/admin/stickyban.dm
+++ b/code/modules/admin/stickyban.dm
@@ -14,7 +14,7 @@
if (data["ckey"])
ckey = ckey(data["ckey"])
else
- ckey = tgui_input_text(usr,"Ckey","Ckey","")
+ ckey = input(usr,"Ckey","Ckey","") as text|null
if (!ckey)
return
ckey = ckey(ckey)
@@ -27,7 +27,7 @@
if (data["reason"])
ban["message"] = data["reason"]
else
- var/reason = tgui_input_text(usr,"Reason","Reason","Ban Evasion")
+ var/reason = input(usr,"Reason","Reason","Ban Evasion") as text|null
if (!reason)
return
ban["message"] = "[reason]"
@@ -61,7 +61,7 @@
if (!ban)
to_chat(usr, "Error: No sticky ban for [ckey] found!", confidential = TRUE)
return
- if (tgui_alert(usr, "Are you sure you want to remove the sticky ban on [ckey]?","Are you sure",list("Yes","No")) == "No")
+ if (alert("Are you sure you want to remove the sticky ban on [ckey]?","Are you sure","Yes","No") == "No")
return
if (!get_stickyban_from_ckey(ckey))
to_chat(usr, "Error: The ban disappeared.", confidential = TRUE)
@@ -98,7 +98,7 @@
to_chat(usr, "Error: [alt] is not linked to [ckey]'s sticky ban!", confidential = TRUE)
return
- if (tgui_alert(usr, "Are you sure you want to disassociate [alt] from [ckey]'s sticky ban? \nNote: Nothing stops byond from re-linking them, Use \[E] to exempt them","Are you sure",list("Yes","No")) == "No")
+ if (alert("Are you sure you want to disassociate [alt] from [ckey]'s sticky ban? \nNote: Nothing stops byond from re-linking them, Use \[E] to exempt them","Are you sure","Yes","No") == "No")
return
//we have to do this again incase something changes
@@ -138,7 +138,7 @@
to_chat(usr, "Error: No sticky ban for [ckey] found!", confidential = TRUE)
return
var/oldreason = ban["message"]
- var/reason = tgui_input_text(usr,"Reason","Reason","[ban["message"]]")
+ var/reason = input(usr,"Reason","Reason","[ban["message"]]") as text|null
if (!reason || reason == oldreason)
return
//we have to do this again incase something changed while we waited for input
@@ -180,7 +180,7 @@
to_chat(usr, "Error: [alt] is not linked to [ckey]'s sticky ban!", confidential = TRUE)
return
- if (tgui_alert(usr, "Are you sure you want to exempt [alt] from [ckey]'s sticky ban?","Are you sure",list("Yes","No")) == "No")
+ if (alert("Are you sure you want to exempt [alt] from [ckey]'s sticky ban?","Are you sure","Yes","No") == "No")
return
//we have to do this again incase something changes
@@ -230,7 +230,7 @@
to_chat(usr, "Error: [alt] is not exempt from [ckey]'s sticky ban!", confidential = TRUE)
return
- if (tgui_alert(usr, "Are you sure you want to unexempt [alt] from [ckey]'s sticky ban?","Are you sure",list("Yes","No")) == "No")
+ if (alert("Are you sure you want to unexempt [alt] from [ckey]'s sticky ban?","Are you sure","Yes","No") == "No")
return
//we have to do this again incase something changes
@@ -272,7 +272,7 @@
var/ckey = data["ckey"]
- if (tgui_alert(usr, "Are you sure you want to put [ckey]'s stickyban on timeout until next round (or removed)?","Are you sure",list("Yes","No")) == "No")
+ if (alert("Are you sure you want to put [ckey]'s stickyban on timeout until next round (or removed)?","Are you sure","Yes","No") == "No")
return
var/ban = get_stickyban_from_ckey(ckey)
if (!ban)
@@ -298,7 +298,7 @@
return
var/ckey = data["ckey"]
- if (tgui_alert(usr, "Are you sure you want to lift the timeout on [ckey]'s stickyban?","Are you sure",list("Yes","No")) == "No")
+ if (alert("Are you sure you want to lift the timeout on [ckey]'s stickyban?","Are you sure","Yes","No") == "No")
return
var/ban = get_stickyban_from_ckey(ckey)
@@ -323,7 +323,7 @@
if (!data["ckey"])
return
var/ckey = data["ckey"]
- if (tgui_alert(usr, "Are you sure you want to revert the sticky ban on [ckey] to its state at round start (or last edit)?","Are you sure",list("Yes","No")) == "No")
+ if (alert("Are you sure you want to revert the sticky ban on [ckey] to its state at round start (or last edit)?","Are you sure","Yes","No") == "No")
return
var/ban = get_stickyban_from_ckey(ckey)
if (!ban)
diff --git a/code/modules/admin/topic.dm b/code/modules/admin/topic.dm
index 6dc345d7e8..a8a7e51611 100644
--- a/code/modules/admin/topic.dm
+++ b/code/modules/admin/topic.dm
@@ -130,7 +130,7 @@
message_admins("[key_name_admin(usr)] tried to create a death squad. Unfortunately, there were not enough candidates available.")
log_admin("[key_name(usr)] failed to create a death squad.")
if("blob")
- var/strength = tgui_input_num(usr, "Set Blob Resource Gain Rate","Set Resource Rate",1)
+ var/strength = input("Set Blob Resource Gain Rate","Set Resource Rate",1) as num|null
if(!strength)
return
message_admins("[key_name(usr)] spawned a blob with base resource gain [strength].")
@@ -176,7 +176,7 @@
var/datum/round_event/event = E.runEvent()
if(event.announceWhen>0)
event.processing = FALSE
- var/prompt = tgui_alert(usr, "Would you like to alert the crew?", "Alert", list("Yes", "No", "Cancel"))
+ var/prompt = alert(usr, "Would you like to alert the crew?", "Alert", "Yes", "No", "Cancel")
switch(prompt)
if("Cancel")
event.kill()
@@ -331,7 +331,7 @@
if(!check_rights(R_SERVER))
return
- var/timer = tgui_input_num(usr, "Enter new shuttle duration (seconds):","Edit Shuttle Timeleft", SSshuttle.emergency.timeLeft())
+ var/timer = input("Enter new shuttle duration (seconds):","Edit Shuttle Timeleft", SSshuttle.emergency.timeLeft() ) as num|null
if(!timer)
return
SSshuttle.emergency.setTimer(timer*10)
@@ -374,7 +374,7 @@
if(!check_rights(R_ADMIN))
return
- var/timer = tgui_input_num(usr, "Enter new maximum time",, CONFIG_GET(number/midround_antag_time_check))
+ var/timer = input("Enter new maximum time",, CONFIG_GET(number/midround_antag_time_check)) as num|null
if(!timer)
return
CONFIG_SET(number/midround_antag_time_check, timer)
@@ -385,7 +385,7 @@
if(!check_rights(R_ADMIN))
return
- var/ratio = tgui_input_num(usr, "Enter new life ratio",, CONFIG_GET(number/midround_antag_life_check) * 100)
+ var/ratio = input("Enter new life ratio",, CONFIG_GET(number/midround_antag_life_check) * 100) as num
if(!ratio)
return
CONFIG_SET(number/midround_antag_life_check, ratio / 100)
@@ -409,7 +409,7 @@
if(!check_rights(R_SERVER))
return
if(!SSticker.delay_end)
- SSticker.admin_delay_notice = tgui_input_text(usr, "Enter a reason for delaying the round end", "Round Delay Reason")
+ SSticker.admin_delay_notice = input(usr, "Enter a reason for delaying the round end", "Round Delay Reason") as null|text
if(isnull(SSticker.admin_delay_notice))
return
else
@@ -428,8 +428,8 @@
return
message_admins("[key_name_admin(usr)] is considering ending the round.")
- if(tgui_alert(usr, "This will end the round, are you SURE you want to do this?", "Confirmation", list("Yes", "No")) == "Yes")
- if(tgui_alert(usr, "Final Confirmation: End the round NOW?", "Confirmation", list("Yes", "No")) == "Yes")
+ if(alert(usr, "This will end the round, are you SURE you want to do this?", "Confirmation", "Yes", "No") == "Yes")
+ if(alert(usr, "Final Confirmation: End the round NOW?", "Confirmation", "Yes", "No") == "Yes")
message_admins("[key_name_admin(usr)] has ended the round.")
SSticker.force_ending = 1 //Yeah there we go APC destroyed mission accomplished
return
@@ -448,7 +448,7 @@
return
var/delmob = 0
- switch(tgui_alert(usr, "Delete old mob?","Message",list("Yes","No","Cancel")))
+ switch(alert("Delete old mob?","Message","Yes","No","Cancel"))
if("Cancel")
return
if("Yes")
@@ -518,11 +518,11 @@
var/banfolder = href_list["unbanf"]
GLOB.Banlist.cd = "/base/[banfolder]"
var/key = GLOB.Banlist["key"]
- if(tgui_alert(usr, "Are you sure you want to unban [key]?", "Confirmation", list("Yes", "No")) == "Yes")
+ if(alert(usr, "Are you sure you want to unban [key]?", "Confirmation", "Yes", "No") == "Yes")
if(RemoveBan(banfolder))
unbanpanel()
else
- tgui_alert(usr, "This ban has already been lifted / does not exist.", "Error", list("Ok"))
+ alert(usr, "This ban has already been lifted / does not exist.", "Error", "Ok")
unbanpanel()
else if(href_list["unbane"])
@@ -544,25 +544,25 @@
var/duration
- switch(tgui_alert(usr, "Temporary Ban for [banned_key]?",,list("Yes","No")))
+ switch(alert("Temporary Ban for [banned_key]?",,"Yes","No"))
if("Yes")
temp = 1
var/mins = 0
if(minutes > GLOB.CMinutes)
mins = minutes - GLOB.CMinutes
- mins = tgui_input_num(usr,"How long (in minutes)? (Default: 1440)","Ban time",mins ? mins : 1440)
+ mins = input(usr,"How long (in minutes)? (Default: 1440)","Ban time",mins ? mins : 1440) as num|null
if(mins <= 0)
to_chat(usr, "[mins] is not a valid duration.")
return
minutes = GLOB.CMinutes + mins
duration = GetExp(minutes)
- reason = tgui_input_message(usr,"Please State Reason For Banning [banned_key].","Reason",reason2)
+ reason = input(usr,"Please State Reason For Banning [banned_key].","Reason",reason2) as message|null
if(!reason)
return
if("No")
temp = 0
duration = "Perma"
- reason = tgui_input_message(usr,"Please State Reason For Banning [banned_key].","Reason",reason2)
+ reason = input(usr,"Please State Reason For Banning [banned_key].","Reason",reason2) as message|null
if(!reason)
return
@@ -592,7 +592,7 @@
if(jobban_isbanned(M, "appearance"))
- switch(tgui_alert(usr, "Remove appearance ban?","Please Confirm",list("Yes","No")))
+ switch(alert("Remove appearance ban?","Please Confirm","Yes","No"))
if("Yes")
ban_unban_log_save("[key_name(usr)] removed [key_name(M)]'s appearance ban.")
log_admin_private("[key_name(usr)] removed [key_name(M)]'s appearance ban.")
@@ -602,12 +602,12 @@
message_admins("[key_name_admin(usr)] removed [key_name_admin(M)]'s appearance ban.")
to_chat(M, "[usr.client.key] has removed your appearance ban.")
- else switch(tgui_alert(usr, "Appearance ban [M.key]?",,list("Yes","No", "Cancel")))
+ else switch(alert("Appearance ban [M.key]?",,"Yes","No", "Cancel"))
if("Yes")
- var/reason = tgui_input_message(usr,"Please State Reason.","Reason")
+ var/reason = input(usr,"Please State Reason.","Reason") as message|null
if(!reason)
return
- var/severity = tgui_input_list(usr, "Set the severity of the note/ban.", "Severity", list("High", "Medium", "Minor", "None"))
+ var/severity = input("Set the severity of the note/ban.", "Severity", null, null) as null|anything in list("High", "Medium", "Minor", "None")
if(!severity)
return
if(!DB_ban_record(BANTYPE_JOB_PERMA, M, -1, reason, "appearance"))
@@ -1025,16 +1025,16 @@
//Banning comes first
if(notbannedlist.len) //at least 1 unbanned job exists in joblist so we have stuff to ban.
var/severity = null
- switch(tgui_alert(usr, "Temporary Ban for [M.key]?",,list("Yes","No", "Cancel")))
+ switch(alert("Temporary Ban for [M.key]?",,"Yes","No", "Cancel"))
if("Yes")
- var/mins = tgui_input_num(usr,"How long (in minutes)?","Ban time",1440)
+ var/mins = input(usr,"How long (in minutes)?","Ban time",1440) as num|null
if(mins <= 0)
to_chat(usr, "[mins] is not a valid duration.")
return
- var/reason = tgui_input_message(usr,"Please State Reason For Banning [M.key].","Reason")
+ var/reason = input(usr,"Please State Reason For Banning [M.key].","Reason") as message|null
if(!reason)
return
- severity = tgui_input_list(usr, "Set the severity of the note/ban.", "Severity", list("High", "Medium", "Minor", "None"))
+ severity = input("Set the severity of the note/ban.", "Severity", null, null) as null|anything in list("High", "Medium", "Minor", "None")
if(!severity)
return
var/msg
@@ -1058,8 +1058,8 @@
href_list["jobban2"] = 1 // lets it fall through and refresh
return 1
if("No")
- var/reason = tgui_input_message(usr,"Please State Reason For Banning [M.key].","Reason")
- severity = tgui_input_list(usr, "Set the severity of the note/ban.", "Severity", list("High", "Medium", "Minor", "None"))
+ var/reason = input(usr,"Please State Reason For Banning [M.key].","Reason") as message|null
+ severity = input("Set the severity of the note/ban.", "Severity", null, null) as null|anything in list("High", "Medium", "Minor", "None")
if(!severity)
return
if(reason)
@@ -1094,7 +1094,7 @@
var/reason = jobban_isbanned(M, job)
if(!reason)
continue //skip if it isn't jobbanned anyway
- switch(tgui_alert(usr, "Job: '[job]' Reason: '[reason]' Un-jobban?","Please Confirm",list("Yes","No")))
+ switch(alert("Job: '[job]' Reason: '[reason]' Un-jobban?","Please Confirm","Yes","No"))
if("Yes")
ban_unban_log_save("[key_name(usr)] unjobbanned [key_name(M)] from [job]")
log_admin_private("[key_name(usr)] unbanned [key_name(M)] from [job]")
@@ -1122,7 +1122,7 @@
if(!check_if_greater_rights_than(M.client))
to_chat(usr, "Error: They have more rights than you do.")
return
- if(tgui_alert(usr, "Kick [key_name(M)]?", "Confirm", list("Yes", "No")) != "Yes")
+ if(alert(usr, "Kick [key_name(M)]?", "Confirm", "Yes", "No") != "Yes")
return
if(!M)
to_chat(usr, "Error: [M] no longer exists!")
@@ -1176,7 +1176,7 @@
else if(href_list["deletemessage"])
if(!check_rights(R_ADMIN))
return
- var/safety = tgui_alert(usr, "Delete message/note?",,list("Yes","No"));
+ var/safety = alert("Delete message/note?",,"Yes","No");
if (safety == "Yes")
var/message_id = href_list["deletemessage"]
delete_message(message_id)
@@ -1184,7 +1184,7 @@
else if(href_list["deletemessageempty"])
if(!check_rights(R_ADMIN))
return
- var/safety = tgui_alert(usr, "Delete message/note?",,list("Yes","No"));
+ var/safety = alert("Delete message/note?",,"Yes","No");
if (safety == "Yes")
var/message_id = href_list["deletemessageempty"]
delete_message(message_id, browse = TRUE)
@@ -1301,13 +1301,13 @@
if(M.client && M.client.holder)
return //admins cannot be banned. Even if they could, the ban doesn't affect them anyway
- switch(tgui_alert(usr, "Temporary Ban for [M.key]?",,list("Yes","No", "Cancel")))
+ switch(alert("Temporary Ban for [M.key]?",,"Yes","No", "Cancel"))
if("Yes")
- var/mins = tgui_input_num(usr,"How long (in minutes)?","Ban time",1440)
+ var/mins = input(usr,"How long (in minutes)?","Ban time",1440) as num|null
if(mins <= 0)
to_chat(usr, "[mins] is not a valid duration.")
return
- var/reason = tgui_input_message(usr,"Please State Reason For Banning [M.key].","Reason")
+ var/reason = input(usr,"Please State Reason For Banning [M.key].","Reason") as message|null
if(!reason)
return
if(!DB_ban_record(BANTYPE_TEMP, M, mins, reason))
@@ -1330,10 +1330,10 @@
AH.Resolve()
qdel(M.client)
if("No")
- var/reason = tgui_input_message(usr,"Please State Reason For Banning [M.key].","Reason")
+ var/reason = input(usr,"Please State Reason For Banning [M.key].","Reason") as message|null
if(!reason)
return
- switch(tgui_alert(usr,"IP ban?",,list("Yes","No","Cancel")))
+ switch(alert(usr,"IP ban?",,"Yes","No","Cancel"))
if("Cancel")
return
if("Yes")
@@ -1381,7 +1381,7 @@
for (var/rule in subtypesof(/datum/dynamic_ruleset/roundstart))
var/datum/dynamic_ruleset/roundstart/newrule = new rule()
roundstart_rules[newrule.name] = newrule
- var/added_rule = tgui_input_list(usr,"What ruleset do you want to force? This will bypass threat level and population restrictions.", "Rigging Roundstart", sortList(roundstart_rules))
+ var/added_rule = input(usr,"What ruleset do you want to force? This will bypass threat level and population restrictions.", "Rigging Roundstart", null) as null|anything in sortList(roundstart_rules)
if (added_rule)
GLOB.dynamic_forced_roundstart_ruleset += roundstart_rules[added_rule]
log_admin("[key_name(usr)] set [added_rule] to be a forced roundstart ruleset.")
@@ -1434,7 +1434,7 @@
if(!check_rights(R_ADMIN))
return
- GLOB.dynamic_stacking_limit = tgui_input_num(usr,"Change the threat limit at which round-endings rulesets will start to stack.", "Change stacking limit", null)
+ GLOB.dynamic_stacking_limit = input(usr,"Change the threat limit at which round-endings rulesets will start to stack.", "Change stacking limit", null) as num
log_admin("[key_name(usr)] set 'stacking_limit' to [GLOB.dynamic_stacking_limit].")
message_admins("[key_name(usr)] set 'stacking_limit' to [GLOB.dynamic_stacking_limit].")
dynamic_mode_options(usr)
@@ -1446,7 +1446,7 @@
if(SSticker?.mode)
return tgui_alert(usr, "The game has already started.")
- var/new_value = tgui_input_num(usr, "Enter the forced threat level for dynamic mode.", "Forced threat level")
+ var/new_value = input(usr, "Enter the forced threat level for dynamic mode.", "Forced threat level") as num
if (new_value > 100)
return tgui_alert(usr, "The value must be be under 100.")
GLOB.dynamic_forced_threat_level = new_value
@@ -1460,7 +1460,7 @@
return
if (SSticker.HasRoundStarted())
- return tgui_alert(usr, "The game has already started.", null, null, null, null)
+ return alert(usr, "The game has already started.", null, null, null, null)
GLOB.master_mode = href_list["c_mode2"]
log_admin("[key_name(usr)] set the mode as [GLOB.master_mode].")
message_admins("[key_name_admin(usr)] set the mode as [GLOB.master_mode].")
@@ -1474,9 +1474,9 @@
return
if(SSticker.HasRoundStarted())
- return tgui_alert(usr, "The game has already started.", null, null, null, null)
+ return alert(usr, "The game has already started.", null, null, null, null)
if(GLOB.master_mode != "secret")
- return tgui_alert(usr, "The game mode has to be secret!", null, null, null, null)
+ return alert(usr, "The game mode has to be secret!", null, null, null, null)
GLOB.secret_force_mode = href_list["f_secret2"]
log_admin("[key_name(usr)] set the forced secret mode as [GLOB.secret_force_mode].")
message_admins("[key_name_admin(usr)] set the forced secret mode as [GLOB.secret_force_mode].")
@@ -1531,7 +1531,7 @@
if(!ismob(M))
to_chat(usr, "this can only be used on instances of type /mob.")
- var/speech = tgui_input_text(usr, "What will [key_name(M)] say?", "Force speech", "")// Don't need to sanitize, since it does that in say(), we also trust our admins.
+ var/speech = input("What will [key_name(M)] say?", "Force speech", "")// Don't need to sanitize, since it does that in say(), we also trust our admins.
if(!speech)
return
M.say(speech, forced = "admin speech")
@@ -1560,7 +1560,7 @@
to_chat(usr, "This cannot be used on instances of type /mob/living/silicon/ai.")
return
- if(tgui_alert(usr, "Send [key_name(M)] to Prison?", "Message", list("Yes", "No")) != "Yes")
+ if(alert(usr, "Send [key_name(M)] to Prison?", "Message", "Yes", "No") != "Yes")
return
M.forceMove(pick(GLOB.prisonwarp))
@@ -1583,7 +1583,7 @@
to_chat(usr, "[M] doesn't seem to have an active client.")
return
- if(tgui_alert(usr, "Send [key_name(M)] back to Lobby?", "Message", list("Yes", "No")) != "Yes")
+ if(alert(usr, "Send [key_name(M)] back to Lobby?", "Message", "Yes", "No") != "Yes")
return
log_admin("[key_name(usr)] has sent [key_name(M)] back to the Lobby, removing their respawn restrictions if they existed.")
@@ -1600,7 +1600,7 @@
if(!check_rights(R_FUN))
return
- if(tgui_alert(usr, "Confirm?", "Message", list("Yes", "No")) != "Yes")
+ if(alert(usr, "Confirm?", "Message", "Yes", "No") != "Yes")
return
var/mob/M = locate(href_list["tdome1"])
@@ -1627,7 +1627,7 @@
if(!check_rights(R_FUN))
return
- if(tgui_alert(usr, "Confirm?", "Message", list("Yes", "No")) != "Yes")
+ if(alert(usr, "Confirm?", "Message", "Yes", "No") != "Yes")
return
var/mob/M = locate(href_list["tdome2"])
@@ -1654,7 +1654,7 @@
if(!check_rights(R_FUN))
return
- if(tgui_alert(usr, "Confirm?", "Message", list("Yes", "No")) != "Yes")
+ if(alert(usr, "Confirm?", "Message", "Yes", "No") != "Yes")
return
var/mob/M = locate(href_list["tdomeadmin"])
@@ -1678,7 +1678,7 @@
if(!check_rights(R_FUN))
return
- if(tgui_alert(usr, "Confirm?", "Message", list("Yes", "No")) != "Yes")
+ if(alert(usr, "Confirm?", "Message", "Yes", "No") != "Yes")
return
var/mob/M = locate(href_list["tdomeobserve"])
@@ -1917,7 +1917,7 @@
for(var/datum/job/job in SSjob.occupations)
if(job.title == Add)
var/newtime = null
- newtime = tgui_input_num(usr, "How many jebs do you want?", "Add wanted posters", "[newtime]")
+ newtime = input(usr, "How many jebs do you want?", "Add wanted posters", "[newtime]") as num|null
if(!newtime)
to_chat(src.owner, "Setting to amount of positions filled for the job")
job.total_positions = job.current_positions
@@ -2049,7 +2049,7 @@
if(!check_rights(R_ADMIN))
return
- if(tgui_alert(usr, "Confirm?", "Message", list("Yes", "No")) != "Yes")
+ if(alert(usr, "Confirm?", "Message", "Yes", "No") != "Yes")
return
var/mob/M = locate(href_list["getmob"])
usr.client.Getmob(M)
@@ -2101,7 +2101,7 @@
return
if(!SSticker.HasRoundStarted())
- tgui_alert(usr, "The game hasn't started yet!")
+ alert("The game hasn't started yet!")
return
var/mob/M = locate(href_list["traitor"])
@@ -2182,10 +2182,10 @@
paths += path
if(!paths)
- tgui_alert(usr, "The path list you sent is empty.")
+ alert("The path list you sent is empty.")
return
if(length(paths) > 5)
- tgui_alert(usr, "Select fewer object types, (max 5).")
+ alert("Select fewer object types, (max 5).")
return
var/list/offset = splittext(href_list["offset"],",")
@@ -2310,7 +2310,7 @@
if(src.admincaster_feed_channel.channel_name == "" || src.admincaster_feed_channel.channel_name == "\[REDACTED\]" || check )
src.admincaster_screen=7
else
- var/choice = tgui_alert(usr, "Please confirm Feed channel creation.","Network Channel Handler",list("Confirm","Cancel"))
+ var/choice = alert("Please confirm Feed channel creation.","Network Channel Handler","Confirm","Cancel")
if(choice=="Confirm")
GLOB.news_network.CreateFeedChannel(src.admincaster_feed_channel.channel_name, src.admin_signature, src.admincaster_feed_channel.locked, 1)
SSblackbox.record_feedback("tally", "newscaster_channels", 1, src.admincaster_feed_channel.channel_name)
@@ -2324,7 +2324,7 @@
var/list/available_channels = list()
for(var/datum/news/feed_channel/F in GLOB.news_network.network_channels)
available_channels += F.channel_name
- src.admincaster_feed_channel.channel_name = adminscrub(tgui_input_list(usr, "Choose receiving Feed Channel.", "Network Channel Handler", available_channels))
+ src.admincaster_feed_channel.channel_name = adminscrub(input(usr, "Choose receiving Feed Channel.", "Network Channel Handler") in available_channels )
src.access_news_network()
else if(href_list["ac_set_new_message"])
@@ -2405,7 +2405,7 @@
if(src.admincaster_wanted_message.criminal == "" || src.admincaster_wanted_message.body == "")
src.admincaster_screen = 16
else
- var/choice = tgui_alert(usr, "Please confirm Wanted Issue [(input_param==1) ? ("creation.") : ("edit.")]","Network Security Handler",list("Confirm","Cancel"))
+ var/choice = alert("Please confirm Wanted Issue [(input_param==1) ? ("creation.") : ("edit.")]","Network Security Handler","Confirm","Cancel")
if(choice=="Confirm")
if(input_param==1) //If input_param == 1 we're submitting a new wanted issue. At 2 we're just editing an existing one. See the else below
GLOB.news_network.submitWanted(admincaster_wanted_message.criminal, admincaster_wanted_message.body, admin_signature, null, 1, 1)
@@ -2419,7 +2419,7 @@
else if(href_list["ac_cancel_wanted"])
if(!check_rights(R_ADMIN))
return
- var/choice = tgui_alert(usr, "Please confirm Wanted Issue removal.","Network Security Handler",list("Confirm","Cancel"))
+ var/choice = alert("Please confirm Wanted Issue removal.","Network Security Handler","Confirm","Cancel")
if(choice=="Confirm")
GLOB.news_network.deleteWanted()
src.admincaster_screen=17
@@ -2504,7 +2504,7 @@
else if(href_list["ac_set_signature"])
if(!check_rights(R_ADMIN))
return
- src.admin_signature = adminscrub(tgui_input_text(usr, "Provide your desired signature.", "Network Identity Handler", ""))
+ src.admin_signature = adminscrub(input(usr, "Provide your desired signature.", "Network Identity Handler", ""))
src.access_news_network()
else if(href_list["ac_del_comment"])
@@ -2533,7 +2533,7 @@
return
if(SSticker.IsRoundInProgress())
var/afkonly = text2num(href_list["afkonly"])
- if(tgui_alert(usr, "Are you sure you want to kick all [afkonly ? "AFK" : ""] clients from the lobby??","Message",list("Yes","Cancel")) != "Yes")
+ if(alert("Are you sure you want to kick all [afkonly ? "AFK" : ""] clients from the lobby??","Message","Yes","Cancel") != "Yes")
to_chat(usr, "Kick clients from lobby aborted")
return
var/list/listkicked = kick_clients_in_lobby("You were kicked from the lobby by [usr.client.holder.fakekey ? "an Administrator" : "[usr.client.key]"].", afkonly)
@@ -2586,16 +2586,16 @@
if(!check_rights(R_ADMIN))
return
var/list/type_choices = typesof(/datum/station_goal)
- var/picked = tgui_input_list(usr, "Choose goal type", type_choices)
+ var/picked = input("Choose goal type") in type_choices|null
if(!picked)
return
var/datum/station_goal/G = new picked()
if(picked == /datum/station_goal)
- var/newname = tgui_input_text(usr, "Enter goal name:")
+ var/newname = input("Enter goal name:") as text|null
if(!newname)
return
G.name = newname
- var/description = tgui_input_message(usr, "Enter CentCom message contents:")
+ var/description = input("Enter CentCom message contents:") as message|null
if(!description)
return
G.report_message = description
@@ -2711,8 +2711,8 @@
var/answer = href_list["slowquery"]
if(answer == "yes")
log_query_debug("[usr.key] | Reported a server hang")
- if(tgui_alert(usr, "Had you just press any admin buttons?", "Query server hang report", list("Yes", "No")) == "Yes")
- var/response = tgui_input_text(usr,"What were you just doing?","Query server hang report")
+ if(alert(usr, "Had you just press any admin buttons?", "Query server hang report", "Yes", "No") == "Yes")
+ var/response = input(usr,"What were you just doing?","Query server hang report") as null|text
if(response)
log_query_debug("[usr.key] | [response]")
else if(answer == "no")
@@ -2723,7 +2723,7 @@
return
if(SSticker.HasRoundStarted())
- return tgui_alert(usr, "The game has already started.", null, null, null, null)
+ return alert(usr, "The game has already started.", null, null, null, null)
var/dat = {"What mode do you wish to play?"}
for(var/mode in config.modes)
dat += {"[config.mode_names[mode]] "}
@@ -2737,9 +2737,9 @@
return
if(SSticker.HasRoundStarted())
- return tgui_alert(usr, "The game has already started.", null, null, null, null)
+ return alert(usr, "The game has already started.", null, null, null, null)
if(GLOB.master_mode != "secret")
- return tgui_alert(usr, "The game mode has to be secret!", null, null, null, null)
+ return alert(usr, "The game mode has to be secret!", null, null, null, null)
var/dat = {"What game mode do you want to force secret to be? Use this if you want to change the game mode, but want the players to believe it's secret. This will only work if the current game mode is secret."}
for(var/mode in config.modes)
dat += {"[config.mode_names[mode]] "}
diff --git a/code/modules/admin/verbs/SDQL2/SDQL_2.dm b/code/modules/admin/verbs/SDQL2/SDQL_2.dm
index f2c10ecc1c..498355f7c3 100644
--- a/code/modules/admin/verbs/SDQL2/SDQL_2.dm
+++ b/code/modules/admin/verbs/SDQL2/SDQL_2.dm
@@ -262,7 +262,7 @@
selectors_used |= query.where_switched
combined_refs |= query.select_refs
running -= query
- if(!CHECK_BITFIELD(query.options, SDQL2_OPTION_DO_NOT_AUTOGC))
+ if(!(query.options & SDQL2_OPTION_DO_NOT_AUTOGC))
QDEL_IN(query, 50)
else
if(usr)
@@ -442,19 +442,19 @@ GLOBAL_DATUM_INIT(sdql2_vv_statobj, /obj/effect/statclick/SDQL2_VV_all, new(null
if("select")
switch(value)
if("force_nulls")
- DISABLE_BITFIELD(options, SDQL2_OPTION_SELECT_OUTPUT_SKIP_NULLS)
+ options &= ~(SDQL2_OPTION_SELECT_OUTPUT_SKIP_NULLS)
if("proccall")
switch(value)
if("blocking")
- ENABLE_BITFIELD(options, SDQL2_OPTION_BLOCKING_CALLS)
+ options |= SDQL2_OPTION_BLOCKING_CALLS
if("priority")
switch(value)
if("high")
- ENABLE_BITFIELD(options, SDQL2_OPTION_HIGH_PRIORITY)
+ options |= SDQL2_OPTION_HIGH_PRIORITY
if("autogc")
switch(value)
if("keep_alive")
- ENABLE_BITFIELD(options, SDQL2_OPTION_DO_NOT_AUTOGC)
+ options |= SDQL2_OPTION_DO_NOT_AUTOGC
/datum/SDQL2_query/proc/ARun()
INVOKE_ASYNC(src, .proc/Run)
diff --git a/code/modules/admin/verbs/adminhelp.dm b/code/modules/admin/verbs/adminhelp.dm
index 6baea9463f..f721bcc5fc 100644
--- a/code/modules/admin/verbs/adminhelp.dm
+++ b/code/modules/admin/verbs/adminhelp.dm
@@ -444,7 +444,7 @@ GLOBAL_DATUM_INIT(ahelp_tickets, /datum/admin_help_tickets, new)
usr << browse(dat.Join(), "window=ahelp[id];size=620x480")
/datum/admin_help/proc/Retitle()
- var/new_title = tgui_input_text(usr, "Enter a title for the ticket", "Rename Ticket", name)
+ var/new_title = input(usr, "Enter a title for the ticket", "Rename Ticket", name) as text|null
if(new_title)
name = new_title
//not saying the original name cause it could be a long ass message
@@ -508,7 +508,7 @@ GLOBAL_DATUM_INIT(ahelp_tickets, /datum/admin_help_tickets, new)
// Used for methods where input via arg doesn't work
/client/proc/get_adminhelp()
- var/msg = tgui_input_text(src, "Please describe your problem concisely and an admin will help as soon as they're able.", "Adminhelp contents")
+ var/msg = input(src, "Please describe your problem concisely and an admin will help as soon as they're able.", "Adminhelp contents") as text
adminhelp(msg)
/client/verb/adminhelp(msg as text)
@@ -533,7 +533,7 @@ GLOBAL_DATUM_INIT(ahelp_tickets, /datum/admin_help_tickets, new)
SSblackbox.record_feedback("tally", "admin_verb", 1, "Adminhelp") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
if(current_ticket)
- if(tgui_alert(usr, "You already have a ticket open. Is this for the same issue?",,list("Yes","No")) != "No")
+ if(alert(usr, "You already have a ticket open. Is this for the same issue?",,"Yes","No") != "No")
if(current_ticket)
current_ticket.MessageNoRecipient(msg)
current_ticket.TimeoutVerb()
diff --git a/code/modules/admin/verbs/adminjump.dm b/code/modules/admin/verbs/adminjump.dm
index 72680eaadc..2f89dc82eb 100644
--- a/code/modules/admin/verbs/adminjump.dm
+++ b/code/modules/admin/verbs/adminjump.dm
@@ -84,7 +84,7 @@
var/list/keys = list()
for(var/mob/M in GLOB.player_list)
keys += M.client
- var/client/selection = tgui_input_list(src, "Please, select a player!", "Admin Jumping", sortKey(keys))
+ var/client/selection = input("Please, select a player!", "Admin Jumping", null, null) as null|anything in sortKey(keys)
if(!selection)
to_chat(src, "No keys found.", confidential = TRUE)
return
@@ -124,7 +124,7 @@
var/list/keys = list()
for(var/mob/M in GLOB.player_list)
keys += M.client
- var/client/selection = tgui_input_list(src, "Please, select a player!", "Admin Jumping", sortKey(keys))
+ var/client/selection = input("Please, select a player!", "Admin Jumping", null, null) as null|anything in sortKey(keys)
if(!selection)
return
var/mob/M = selection.mob
@@ -146,7 +146,7 @@
if(!src.holder)
to_chat(src, "Only administrators may use this command.", confidential = TRUE)
return
- var/area/A = tgui_input_list(usr, "Pick an area.", "Pick an area", GLOB.sortedAreas)
+ var/area/A = input(usr, "Pick an area.", "Pick an area") in GLOB.sortedAreas|null
if(A && istype(A))
var/list/turfs = get_area_turfs(A)
if(length(turfs) && M.forceMove(pick(turfs)))
diff --git a/code/modules/admin/verbs/adminpm.dm b/code/modules/admin/verbs/adminpm.dm
index d3c8a770df..3a708ef182 100644
--- a/code/modules/admin/verbs/adminpm.dm
+++ b/code/modules/admin/verbs/adminpm.dm
@@ -30,7 +30,7 @@
targets["[T.mob.real_name](as [T.mob.name]) - [T]"] = T
else
targets["(No Mob) - [T]"] = T
- var/target = tgui_input_list(src,"To whom shall we send a message?","Admin PM", sortList(targets))
+ var/target = input(src,"To whom shall we send a message?","Admin PM",null) as null|anything in sortList(targets)
cmd_admin_pm(targets[target],null)
SSblackbox.record_feedback("tally", "admin_verb", 1, "Admin PM") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
@@ -54,7 +54,7 @@
if(AH)
message_admins("[key_name_admin(src)] has started replying to [key_name_admin(C, 0, 0)]'s admin help.")
- var/msg = tgui_input_message(src,"Message:", "Private message to [C.holder?.fakekey ? "an Administrator" : key_name(C, 0, 0)].")
+ var/msg = input(src,"Message:", "Private message to [C.holder?.fakekey ? "an Administrator" : key_name(C, 0, 0)].") as message|null
if (!msg)
message_admins("[key_name_admin(src)] has cancelled their reply to [key_name_admin(C, 0, 0)]'s admin help.")
return
@@ -105,7 +105,7 @@
if(!ircreplyamount) //to prevent people from spamming irc/discord
return
if(!msg)
- msg = tgui_input_message(src,"Message:", "Private message to Administrator")
+ msg = input(src,"Message:", "Private message to Administrator") as message|null
if(!msg)
return
@@ -116,7 +116,7 @@
else
//get message text, limit it's length.and clean/escape html
if(!msg)
- msg = tgui_input_message(src,"Message:", "Private message to [recipient.holder?.fakekey ? "an Administrator" : key_name(recipient, 0, 0)].")
+ msg = input(src,"Message:", "Private message to [recipient.holder?.fakekey ? "an Administrator" : key_name(recipient, 0, 0)].") as message|null
msg = trim(msg)
if(!msg)
return
@@ -238,7 +238,7 @@
/client/proc/popup_admin_pm(client/recipient, msg)
var/sender = src
var/sendername = key
- var/reply = tgui_input_message(recipient, msg,"Admin PM from-[sendername]", "") //show message and await a reply
+ var/reply = input(recipient, msg,"Admin PM from-[sendername]", "") as message|null //show message and await a reply
if(recipient && reply)
if(sender)
recipient.cmd_admin_pm(sender,reply) //sender is still about, let's reply to them
diff --git a/code/modules/admin/verbs/adminsay.dm b/code/modules/admin/verbs/adminsay.dm
index 5afbda4e19..fdd1e8dcad 100644
--- a/code/modules/admin/verbs/adminsay.dm
+++ b/code/modules/admin/verbs/adminsay.dm
@@ -31,5 +31,5 @@
SSblackbox.record_feedback("tally", "admin_verb", 1, "Asay") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/proc/get_admin_say()
- var/msg = tgui_input_text(src, null, "asay \"text\"")
+ var/msg = input(src, null, "asay \"text\"") as text
cmd_admin_say(msg)
diff --git a/code/modules/admin/verbs/ak47s.dm b/code/modules/admin/verbs/ak47s.dm
index b2081b84d2..561037060f 100644
--- a/code/modules/admin/verbs/ak47s.dm
+++ b/code/modules/admin/verbs/ak47s.dm
@@ -1,7 +1,7 @@
GLOBAL_VAR_INIT(terrorism, FALSE)
/client/proc/ak47s() // For when you just can't summon guns worthy of a firefight
if(!SSticker.HasRoundStarted())
- tgui_alert(usr, "The game hasn't started yet!")
+ alert("The game hasn't started yet!")
return
GLOB.terrorism = TRUE
diff --git a/code/modules/admin/verbs/borgpanel.dm b/code/modules/admin/verbs/borgpanel.dm
index ff6b3938cf..4b60ecc0ff 100644
--- a/code/modules/admin/verbs/borgpanel.dm
+++ b/code/modules/admin/verbs/borgpanel.dm
@@ -7,7 +7,7 @@
return
if (!istype(borgo, /mob/living/silicon/robot))
- borgo = tgui_input_list(usr, "Select a borg", "Select a borg", sortNames(GLOB.silicon_mobs))
+ borgo = input("Select a borg", "Select a borg", null, null) as null|anything in sortNames(GLOB.silicon_mobs)
if (!istype(borgo, /mob/living/silicon/robot))
to_chat(usr, "Borg is required for borgpanel", confidential = TRUE)
@@ -83,7 +83,7 @@
return
switch (action)
if ("set_charge")
- var/newcharge = tgui_input_num(usr, "New charge (0-[borg.cell.maxcharge]):", borg.name, borg.cell.charge)
+ var/newcharge = input("New charge (0-[borg.cell.maxcharge]):", borg.name, borg.cell.charge) as num|null
if (newcharge)
borg.cell.charge = clamp(newcharge, 0, borg.cell.maxcharge)
message_admins("[key_name_admin(user)] set the charge of [ADMIN_LOOKUPFLW(borg)] to [borg.cell.charge].")
diff --git a/code/modules/admin/verbs/cinematic.dm b/code/modules/admin/verbs/cinematic.dm
index 85a4a5773d..b23cd0af0b 100644
--- a/code/modules/admin/verbs/cinematic.dm
+++ b/code/modules/admin/verbs/cinematic.dm
@@ -6,6 +6,6 @@
if(!SSticker)
return
- var/datum/cinematic/choice = tgui_input_list(src,"Cinematic","Choose", subtypesof(/datum/cinematic))
+ var/datum/cinematic/choice = input(src,"Cinematic","Choose",null) as anything in subtypesof(/datum/cinematic)
if(choice)
Cinematic(initial(choice.id),world,null)
diff --git a/code/modules/admin/verbs/deadsay.dm b/code/modules/admin/verbs/deadsay.dm
index 42c588056b..1cddbe9509 100644
--- a/code/modules/admin/verbs/deadsay.dm
+++ b/code/modules/admin/verbs/deadsay.dm
@@ -32,7 +32,7 @@
SSblackbox.record_feedback("tally", "admin_verb", 1, "Dsay") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/proc/get_dead_say()
- var/msg = tgui_input_text(src, null, "dsay \"text\"")
+ var/msg = input(src, null, "dsay \"text\"") as text|null
if (isnull(msg))
return
diff --git a/code/modules/admin/verbs/debug.dm b/code/modules/admin/verbs/debug.dm
index c4e882cef2..138913b3a4 100644
--- a/code/modules/admin/verbs/debug.dm
+++ b/code/modules/admin/verbs/debug.dm
@@ -31,7 +31,7 @@
set name = "Make Robot"
if(!SSticker.HasRoundStarted())
- tgui_alert(usr, "Wait until the game starts")
+ alert("Wait until the game starts")
return
if(ishuman(M))
log_admin("[key_name(src)] has robotized [M.key].")
@@ -40,21 +40,21 @@
H.Robotize()
else
- tgui_alert(usr, "Invalid mob")
+ alert("Invalid mob")
/client/proc/cmd_admin_blobize(mob/M in GLOB.mob_list)
set category = "Admin.Fun"
set name = "Make Blob"
if(!SSticker.HasRoundStarted())
- tgui_alert(usr, "Wait until the game starts")
+ alert("Wait until the game starts")
return
if(ishuman(M))
log_admin("[key_name(src)] has blobized [M.key].")
var/mob/living/carbon/human/H = M
H.become_overmind()
else
- tgui_alert(usr, "Invalid mob")
+ alert("Invalid mob")
/client/proc/cmd_admin_animalize(mob/M in GLOB.mob_list)
@@ -62,15 +62,15 @@
set name = "Make Simple Animal"
if(!SSticker.HasRoundStarted())
- tgui_alert(usr, "Wait until the game starts")
+ alert("Wait until the game starts")
return
if(!M)
- tgui_alert(usr, "That mob doesn't seem to exist, close the panel and try again.")
+ alert("That mob doesn't seem to exist, close the panel and try again.")
return
if(isnewplayer(M))
- tgui_alert(usr, "The mob must not be a new_player.")
+ alert("The mob must not be a new_player.")
return
log_admin("[key_name(src)] has animalized [M.key].")
@@ -87,16 +87,16 @@
for(var/mob/C in GLOB.mob_list)
if(C.key)
available.Add(C)
- var/mob/choice = tgui_input_list(src, "Choose a player to play the pAI", "Spawn pAI", available)
+ var/mob/choice = input("Choose a player to play the pAI", "Spawn pAI") in available
if(!choice)
return 0
if(!isobserver(choice))
- var/confirm = tgui_input_list(src, "[choice.key] isn't ghosting right now. Are you sure you want to yank him out of them out of their body and place them in this pAI?", "Spawn pAI Confirmation", list("Yes", "No"))
+ var/confirm = input("[choice.key] isn't ghosting right now. Are you sure you want to yank him out of them out of their body and place them in this pAI?", "Spawn pAI Confirmation", "No") in list("Yes", "No")
if(confirm != "Yes")
return 0
var/obj/item/paicard/card = new(T)
var/mob/living/silicon/pai/pai = new(card)
- pai.name = tgui_input_text(choice, "Enter your pAI name:", "pAI Name", "Personal AI")
+ pai.name = input(choice, "Enter your pAI name:", "pAI Name", "Personal AI") as text
pai.real_name = pai.name
choice.transfer_ckey(pai)
card.setPersonality(pai)
@@ -110,7 +110,7 @@
set name = "Make Alien"
if(!SSticker.HasRoundStarted())
- tgui_alert(usr, "Wait until the game starts")
+ alert("Wait until the game starts")
return
if(ishuman(M))
INVOKE_ASYNC(M, /mob/living/carbon/human/proc/Alienize)
@@ -118,14 +118,14 @@
log_admin("[key_name(usr)] made [key_name(M)] into an alien at [AREACOORD(M)].")
message_admins("[key_name_admin(usr)] made [ADMIN_LOOKUPFLW(M)] into an alien.")
else
- tgui_alert(usr, "Invalid mob")
+ alert("Invalid mob")
/client/proc/cmd_admin_slimeize(mob/M in GLOB.mob_list)
set category = "Admin.Fun"
set name = "Make slime"
if(!SSticker.HasRoundStarted())
- tgui_alert(usr, "Wait until the game starts")
+ alert("Wait until the game starts")
return
if(ishuman(M))
INVOKE_ASYNC(M, /mob/living/carbon/human/proc/slimeize)
@@ -133,7 +133,7 @@
log_admin("[key_name(usr)] made [key_name(M)] into a slime at [AREACOORD(M)].")
message_admins("[key_name_admin(usr)] made [ADMIN_LOOKUPFLW(M)] into a slime.")
else
- tgui_alert(usr, "Invalid mob")
+ alert("Invalid mob")
//TODO: merge the vievars version into this or something maybe mayhaps
/client/proc/cmd_debug_del_all(object as text)
@@ -146,7 +146,7 @@
if(matches.len==0)
return
- var/hsbitem = tgui_input_list(usr, "Choose an object to delete.", "Delete:", matches)
+ var/hsbitem = input(usr, "Choose an object to delete.", "Delete:") as null|anything in matches
if(hsbitem)
hsbitem = matches[hsbitem]
var/counter = 0
@@ -173,7 +173,7 @@
set name = "Grant Full Access"
if(!SSticker.HasRoundStarted())
- tgui_alert(usr, "Wait until the game starts")
+ alert("Wait until the game starts")
return
if(ishuman(M))
var/mob/living/carbon/human/H = M
@@ -205,7 +205,7 @@
H.equip_to_slot(id,SLOT_WEAR_ID)
else
- tgui_alert(usr, "Invalid mob")
+ alert("Invalid mob")
SSblackbox.record_feedback("tally", "admin_verb", 1, "Grant Full Access") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
log_admin("[key_name(src)] has granted [M.key] full access.")
message_admins("[key_name_admin(usr)] has granted [M.key] full access.")
@@ -216,7 +216,7 @@
set desc = "Direct intervention"
if(M.ckey)
- if(tgui_alert(src, "This mob is being controlled by [M.key]. Are you sure you wish to assume control of it? [M.key] will be made a ghost.",,list("Yes","No")) != "Yes")
+ if(alert("This mob is being controlled by [M.key]. Are you sure you wish to assume control of it? [M.key] will be made a ghost.",,"Yes","No") != "Yes")
return
else
var/mob/dead/observer/ghost = new/mob/dead/observer(get_turf(M), M)
@@ -236,12 +236,12 @@
if(!M)
return
if(M.ckey)
- if(tgui_alert(usr, "This mob is being controlled by [M.key]. Are you sure you wish to give someone else control of it? [M.key] will be made a ghost.",,list("Yes","No")) != "Yes")
+ if(alert("This mob is being controlled by [M.key]. Are you sure you wish to give someone else control of it? [M.key] will be made a ghost.",,"Yes","No") != "Yes")
return
- var/client/newkey = tgui_input_list(src, "Pick the player to put in control.", "New player", sortList(GLOB.clients))
+ var/client/newkey = input(src, "Pick the player to put in control.", "New player") as null|anything in sortList(GLOB.clients)
var/mob/oldmob = newkey.mob
var/delmob = FALSE
- if((isobserver(oldmob) || tgui_alert(usr, "Do you want to delete [newkey]'s old mob?","Delete?",list("Yes","No")) != "No"))
+ if((isobserver(oldmob) || alert("Do you want to delete [newkey]'s old mob?","Delete?","Yes","No") != "No"))
delmob = TRUE
if(!M || QDELETED(M))
to_chat(usr, "The target mob no longer exists, aborting.")
@@ -494,7 +494,7 @@
var/datum/outfit/O = path //not much to initalize here but whatever
outfits[initial(O.name)] = path
- var/dresscode = tgui_input_list(src, "Select outfit", "Robust quick dress shop", baseoutfits + sortList(outfits))
+ var/dresscode = input("Select outfit", "Robust quick dress shop") as null|anything in baseoutfits + sortList(outfits)
if (isnull(dresscode))
return
@@ -508,7 +508,7 @@
var/datum/outfit/O = path
job_outfits[initial(O.name)] = path
- dresscode = tgui_input_list(src, "Select job equipment", "Robust quick dress shop", sortList(job_outfits))
+ dresscode = input("Select job equipment", "Robust quick dress shop") as null|anything in sortList(job_outfits)
dresscode = job_outfits[dresscode]
if(isnull(dresscode))
return
@@ -520,7 +520,7 @@
var/datum/outfit/O = path
plasmaman_outfits[initial(O.name)] = path
- dresscode = tgui_input_list(src, "Select plasmeme equipment", "Robust quick dress shop", sortList(plasmaman_outfits))
+ dresscode = input("Select plasmeme equipment", "Robust quick dress shop") as null|anything in sortList(plasmaman_outfits)
dresscode = plasmaman_outfits[dresscode]
if(isnull(dresscode))
return
@@ -529,7 +529,7 @@
var/list/custom_names = list()
for(var/datum/outfit/D in GLOB.custom_outfits)
custom_names[D.name] = D
- var/selected_name = tgui_input_list(src, "Select outfit", "Robust quick dress shop", sortList(custom_names))
+ var/selected_name = input("Select outfit", "Robust quick dress shop") as null|anything in sortList(custom_names)
dresscode = custom_names[selected_name]
if(isnull(dresscode))
return
@@ -542,7 +542,7 @@
set name = "Start Singularity"
set desc = "Sets up the singularity and all machines to get power flowing through the station"
- if(tgui_alert(usr, "Are you sure? This will start up the engine. Should only be used during debug!",,list("Yes","No")) != "Yes")
+ if(alert("Are you sure? This will start up the engine. Should only be used during debug!",,"Yes","No") != "Yes")
return
for(var/obj/machinery/power/emitter/E in GLOB.machines)
@@ -598,7 +598,7 @@
set name = "Debug Mob Lists"
set desc = "For when you just gotta know"
- switch(tgui_input_list(src, "Which list?", "", list("Players","Admins","Mobs","Living Mobs","Dead Mobs","Clients","Joined Clients")))
+ switch(input("Which list?") in list("Players","Admins","Mobs","Living Mobs","Dead Mobs","Clients","Joined Clients"))
if("Players")
to_chat(usr, jointext(GLOB.player_list,","))
if("Admins")
@@ -687,7 +687,7 @@
names[name] = ruin_landmark
- var/ruinname = tgui_input_list(src, "Select ruin", "Jump to Ruin", names)
+ var/ruinname = input("Select ruin", "Jump to Ruin") as null|anything in names
var/obj/effect/landmark/ruin/landmark = names[ruinname]
@@ -725,13 +725,13 @@
for(var/name in SSmapping.ice_ruins_underground_templates)
names[name] = list(SSmapping.ice_ruins_underground_templates[name], ZTRAIT_ICE_RUINS_UNDERGROUND, list(/area/icemoon/underground/unexplored))
- var/ruinname = tgui_input_list(src, "Select ruin", "Spawn Ruin", names)
+ var/ruinname = input("Select ruin", "Spawn Ruin") as null|anything in names
var/data = names[ruinname]
if (!data)
return
var/datum/map_template/ruin/template = data[1]
if (exists[template])
- var/response = tgui_alert(usr, "There is already a [template] in existence.", "Spawn Ruin", list("Jump", "Place Another", "Cancel"))
+ var/response = alert("There is already a [template] in existence.", "Spawn Ruin", "Jump", "Place Another", "Cancel")
if (response == "Jump")
usr.forceMove(get_turf(exists[template]))
return
@@ -755,7 +755,7 @@
set desc = "Deallocates all reserved space, restoring it to round start conditions."
if(!holder)
return
- var/answer = tgui_alert(usr, "WARNING: THIS WILL WIPE ALL RESERVED SPACE TO A CLEAN SLATE! ANY MOVING SHUTTLES, ELEVATORS, OR IN-PROGRESS PHOTOGRAPHY WILL BE DELETED!", "Really wipe dynamic turfs?", list("YES", "NO"))
+ var/answer = alert("WARNING: THIS WILL WIPE ALL RESERVED SPACE TO A CLEAN SLATE! ANY MOVING SHUTTLES, ELEVATORS, OR IN-PROGRESS PHOTOGRAPHY WILL BE DELETED!", "Really wipe dynamic turfs?", "YES", "NO")
if(answer != "YES")
return
message_admins("[key_name_admin(src)] cleared dynamic transit space.")
@@ -833,7 +833,7 @@
"Total Time" = /proc/cmp_profile_time_dsc,
"Call Count" = /proc/cmp_profile_count_dsc
)
- var/sort = tgui_input_list(src, "Sort type?", "Sort Type", sortlist)
+ var/sort = input(src, "Sort type?", "Sort Type", "Avg time") as null|anything in sortlist
if (!sort)
return
sort = sortlist[sort]
@@ -845,5 +845,5 @@
set desc = "Force config reload to world default"
if(!check_rights(R_DEBUG))
return
- if(tgui_alert(usr, "Are you absolutely sure you want to reload the configuration from the default path on the disk, wiping any in-round modificatoins?", "Really reset?", list("No", "Yes")) == "Yes")
+ if(alert(usr, "Are you absolutely sure you want to reload the configuration from the default path on the disk, wiping any in-round modificatoins?", "Really reset?", "No", "Yes") == "Yes")
config.admin_reload()
diff --git a/code/modules/admin/verbs/diagnostics.dm b/code/modules/admin/verbs/diagnostics.dm
index ff476ee716..8defd78a06 100644
--- a/code/modules/admin/verbs/diagnostics.dm
+++ b/code/modules/admin/verbs/diagnostics.dm
@@ -56,7 +56,7 @@
if(!src.holder)
return
- var/confirm = tgui_alert(src, "Are you sure you want to reload all admins?", "Confirm", list("Yes", "No"))
+ var/confirm = alert(src, "Are you sure you want to reload all admins?", "Confirm", "Yes", "No")
if(confirm !="Yes")
return
@@ -68,7 +68,7 @@
set name = "Toggle CDN"
set category = "Server"
var/static/admin_disabled_cdn_transport = null
- if (tgui_alert(usr, "Are you sure you want to toggle the CDN asset transport?", "Confirm", list("Yes", "No")) != "Yes")
+ if (alert(usr, "Are you sure you want to toggle the CDN asset transport?", "Confirm", "Yes", "No") != "Yes")
return
var/current_transport = CONFIG_GET(string/asset_transport)
if (!current_transport || current_transport == "simple")
@@ -80,7 +80,7 @@
log_admin("[key_name(usr)] re-enabled the CDN asset transport")
else
to_chat(usr, "The CDN is not enabled!")
- if (tgui_alert(usr, "The CDN asset transport is not enabled! If you having issues with assets you can also try disabling filename mutations.", "The CDN asset transport is not enabled!", list("Try disabling filename mutations", "Nevermind")) == "Try disabling filename mutations")
+ if (alert(usr, "The CDN asset transport is not enabled! If you having issues with assets you can also try disabling filename mutations.", "The CDN asset transport is not enabled!", "Try disabling filename mutations", "Nevermind") == "Try disabling filename mutations")
SSassets.transport.dont_mutate_filenames = !SSassets.transport.dont_mutate_filenames
message_admins("[key_name_admin(usr)] [(SSassets.transport.dont_mutate_filenames ? "disabled" : "re-enabled")] asset filename transforms")
log_admin("[key_name(usr)] [(SSassets.transport.dont_mutate_filenames ? "disabled" : "re-enabled")] asset filename transforms")
diff --git a/code/modules/admin/verbs/dice.dm b/code/modules/admin/verbs/dice.dm
index 25f067c392..f033351f96 100644
--- a/code/modules/admin/verbs/dice.dm
+++ b/code/modules/admin/verbs/dice.dm
@@ -4,8 +4,8 @@
if(!check_rights(R_FUN))
return
- var/sum = tgui_input_num(src, "How many times should we throw?")
- var/side = tgui_input_num(src, "Select the number of sides.")
+ var/sum = input("How many times should we throw?") as num
+ var/side = input("Select the number of sides.") as num
if(!side)
side = 6
if(!sum)
@@ -13,12 +13,12 @@
var/dice = num2text(sum) + "d" + num2text(side)
- if(tgui_alert(src, "Do you want to inform the world about your game?",,list("Yes", "No")) == "Yes")
+ if(alert("Do you want to inform the world about your game?",,"Yes", "No") == "Yes")
to_chat(world, "
The dice have been rolled by Gods!
")
var/result = roll(dice)
- if(tgui_alert(src, "Do you want to inform the world about the result?",,list("Yes", "No")) == "Yes")
+ if(alert("Do you want to inform the world about the result?",,"Yes", "No") == "Yes")
to_chat(world, "
Gods rolled [dice], result is [result]
")
message_admins("[key_name_admin(src)] rolled dice [dice], result is [result]")
diff --git a/code/modules/admin/verbs/fps.dm b/code/modules/admin/verbs/fps.dm
index 4364840220..2b65d2a44c 100644
--- a/code/modules/admin/verbs/fps.dm
+++ b/code/modules/admin/verbs/fps.dm
@@ -8,13 +8,13 @@
return
var/cfg_fps = CONFIG_GET(number/fps)
- var/new_fps = round(tgui_input_num(src, "Sets game frames-per-second. Can potentially break the game (default: [cfg_fps])","FPS", world.fps))
+ var/new_fps = round(input("Sets game frames-per-second. Can potentially break the game (default: [cfg_fps])","FPS", world.fps) as num|null)
if(new_fps <= 0)
to_chat(src, "Error: set_server_fps(): Invalid world.fps value. No changes made.")
return
if(new_fps > cfg_fps * 1.5)
- if(tgui_alert(src, "You are setting fps to a high value:\n\t[new_fps] frames-per-second\n\tconfig.fps = [cfg_fps]","Warning!",list("Confirm","ABORT-ABORT-ABORT")) != "Confirm")
+ if(alert(src, "You are setting fps to a high value:\n\t[new_fps] frames-per-second\n\tconfig.fps = [cfg_fps]","Warning!","Confirm","ABORT-ABORT-ABORT") != "Confirm")
return
var/msg = "[key_name(src)] has modified world.fps to [new_fps]"
diff --git a/code/modules/admin/verbs/getlogs.dm b/code/modules/admin/verbs/getlogs.dm
index 46f9092bdb..446dbcc69a 100644
--- a/code/modules/admin/verbs/getlogs.dm
+++ b/code/modules/admin/verbs/getlogs.dm
@@ -24,7 +24,7 @@
return
message_admins("[key_name_admin(src)] accessed file: [path]")
- switch(tgui_alert(src, "View (in game), Open (in your system's text editor), or Download?", path, list("View", "Open", "Download")))
+ switch(alert("View (in game), Open (in your system's text editor), or Download?", path, "View", "Open", "Download"))
if ("View")
src << browse("
[html_encode(file2text(file(path)))]
", list2params(list("window" = "viewfile.[path]")))
if ("Open")
diff --git a/code/modules/admin/verbs/machine_upgrade.dm b/code/modules/admin/verbs/machine_upgrade.dm
index f5652da846..58deff2a24 100644
--- a/code/modules/admin/verbs/machine_upgrade.dm
+++ b/code/modules/admin/verbs/machine_upgrade.dm
@@ -4,7 +4,7 @@
if (!istype(M))
return
- var/new_rating = tgui_input_num(usr, "Enter new rating:","Num")
+ var/new_rating = input("Enter new rating:","Num") as num
if(new_rating && M.component_parts)
for(var/obj/item/stock_parts/P in M.component_parts)
P.rating = new_rating
diff --git a/code/modules/admin/verbs/manipulate_organs.dm b/code/modules/admin/verbs/manipulate_organs.dm
index 6461778eed..b2648735ec 100644
--- a/code/modules/admin/verbs/manipulate_organs.dm
+++ b/code/modules/admin/verbs/manipulate_organs.dm
@@ -1,7 +1,7 @@
/client/proc/manipulate_organs(mob/living/carbon/C in world)
set name = "Manipulate Organs"
set category = "Debug"
- var/operation = tgui_input_list(src, "Select organ operation.", "Organ Manipulation", list("add organ", "add implant", "drop organ/implant", "remove organ/implant", "cancel"))
+ var/operation = input("Select organ operation.", "Organ Manipulation", "cancel") as null|anything in list("add organ", "add implant", "drop organ/implant", "remove organ/implant", "cancel")
if (!operation)
return
@@ -12,7 +12,7 @@
var/dat = replacetext("[path]", "/obj/item/organ/", ":")
organs[dat] = path
- var/obj/item/organ/organ = tgui_input_list(src, "Select organ type:", "Organ Manipulation", organs)
+ var/obj/item/organ/organ = input("Select organ type:", "Organ Manipulation", null) as null|anything in organs
if(!organ)
return
organ = organs[organ]
@@ -26,7 +26,7 @@
var/dat = replacetext("[path]", "/obj/item/implant/", ":")
organs[dat] = path
- var/obj/item/implant/organ = tgui_input_list(src, "Select implant type:", "Organ Manipulation", organs)
+ var/obj/item/implant/organ = input("Select implant type:", "Organ Manipulation", null) as null|anything in organs
if(!organ)
return
organ = organs[organ]
@@ -44,7 +44,7 @@
var/obj/item/implant/I = X
organs["[I.name] ([I.type])"] = I
- var/obj/item/organ = tgui_input_list(src, "Select organ/implant:", "Organ Manipulation", organs)
+ var/obj/item/organ = input("Select organ/implant:", "Organ Manipulation", null) as null|anything in organs
if(!organ)
return
organ = organs[organ]
diff --git a/code/modules/admin/verbs/map_template_loadverb.dm b/code/modules/admin/verbs/map_template_loadverb.dm
index 620667046e..e89c3ad5a6 100644
--- a/code/modules/admin/verbs/map_template_loadverb.dm
+++ b/code/modules/admin/verbs/map_template_loadverb.dm
@@ -4,7 +4,7 @@
var/datum/map_template/template
- var/map = tgui_input_list(src, "Choose a Map Template to place at your CURRENT LOCATION","Place Map Template", SSmapping.map_templates)
+ var/map = input(src, "Choose a Map Template to place at your CURRENT LOCATION","Place Map Template") as null|anything in SSmapping.map_templates
if(!map)
return
template = SSmapping.map_templates[map]
@@ -19,10 +19,10 @@
item.plane = ABOVE_LIGHTING_PLANE
preview += item
var/list/orientations = list("South" = SOUTH, "North" = NORTH, "East" = EAST, "West" = WEST)
- var/choice = tgui_input_list(src, "Which orientation? Maps are normally facing SOUTH.", "Template Orientation", orientations)
+ var/choice = input(src, "Which orientation? Maps are normally facing SOUTH.", "Template Orientation", "South") as null|anything in orientations
var/orientation = orientations[choice]
images += preview
- if(tgui_alert(src, "Confirm location.","Template Confirm",list("Yes","No")) == "Yes")
+ if(alert(src,"Confirm location.","Template Confirm","Yes","No") == "Yes")
if(template.load(T, centered = TRUE, orientation = orientation))
message_admins("[key_name_admin(src)] has placed a map template ([template.name]) at [ADMIN_COORDJMP(T)]")
else
@@ -40,7 +40,7 @@
to_chat(src, "Filename must end in '.dmm': [map]")
return
var/datum/map_template/M
- switch(tgui_alert(src, "What kind of map is this?", "Map type", list("Normal", "Shuttle", "Cancel")))
+ switch(alert(src, "What kind of map is this?", "Map type", "Normal", "Shuttle", "Cancel"))
if("Normal")
M = new /datum/map_template(map, "[map]", TRUE)
if("Shuttle")
@@ -58,11 +58,11 @@
report_link = " - validation report"
to_chat(src, "Map template '[map]' failed validation.")
if(report.loadable)
- var/response = tgui_alert(src, "The map failed validation, would you like to load it anyways?", "Map Errors", list("Cancel", "Upload Anyways"))
+ var/response = alert(src, "The map failed validation, would you like to load it anyways?", "Map Errors", "Cancel", "Upload Anyways")
if(response != "Upload Anyways")
return
else
- tgui_alert(src, "The map failed validation and cannot be loaded.", "Map Errors", list("Oh Darn"))
+ alert(src, "The map failed validation and cannot be loaded.", "Map Errors", "Oh Darn")
return
SSmapping.map_templates[M.name] = M
diff --git a/code/modules/admin/verbs/mapping.dm b/code/modules/admin/verbs/mapping.dm
index 8b01981ace..0dfee4c38c 100644
--- a/code/modules/admin/verbs/mapping.dm
+++ b/code/modules/admin/verbs/mapping.dm
@@ -110,7 +110,7 @@ GLOBAL_LIST_EMPTY(dirty_vars)
set name = "Camera Report"
if(!Master)
- tgui_alert(usr, "Master_controller not found.","Sec Camera Report")
+ alert(usr,"Master_controller not found.","Sec Camera Report")
return 0
var/list/obj/machinery/camera/CL = list()
@@ -219,7 +219,7 @@ GLOBAL_LIST_EMPTY(dirty_vars)
/client/proc/count_objects_on_z_level()
set category = "Mapping"
set name = "Count Objects On Level"
- var/level = tgui_input_text(src, "Which z-level?","Level?")
+ var/level = input("Which z-level?","Level?") as text
if(!level)
return
var/num_level = text2num(level)
@@ -228,7 +228,7 @@ GLOBAL_LIST_EMPTY(dirty_vars)
if(!isnum(num_level))
return
- var/type_text = tgui_input_text(src, "Which type path?","Path?")
+ var/type_text = input("Which type path?","Path?") as text
if(!type_text)
return
var/type_path = text2path(type_text)
@@ -259,7 +259,7 @@ GLOBAL_LIST_EMPTY(dirty_vars)
set category = "Mapping"
set name = "Count Objects All"
- var/type_text = tgui_input_text(src, "Which type path?","")
+ var/type_text = input("Which type path?","") as text
if(!type_text)
return
var/type_path = text2path(type_text)
diff --git a/code/modules/admin/verbs/maprotation.dm b/code/modules/admin/verbs/maprotation.dm
index 08b4dfff5b..af8bd6e9fb 100644
--- a/code/modules/admin/verbs/maprotation.dm
+++ b/code/modules/admin/verbs/maprotation.dm
@@ -1,7 +1,7 @@
/client/proc/forcerandomrotate()
set category = "Server"
set name = "Trigger Random Map Rotation"
- var/rotate = tgui_alert(usr, "Force a random map rotation to trigger?", "Rotate map?", list("Yes", "Cancel"))
+ var/rotate = alert("Force a random map rotation to trigger?", "Rotate map?", "Yes", "Cancel")
if (rotate != "Yes")
return
message_admins("[key_name_admin(usr)] is forcing a random map rotation.")
@@ -33,7 +33,7 @@
mapname += "\]"
maprotatechoices[mapname] = VM
- var/chosenmap = tgui_input_list(src, "Choose a map to change to", "Change Map", maprotatechoices)
+ var/chosenmap = input("Choose a map to change to", "Change Map") as null|anything in maprotatechoices
if (!chosenmap)
return
SSticker.maprotatechecked = 1
diff --git a/code/modules/admin/verbs/onlyone.dm b/code/modules/admin/verbs/onlyone.dm
index a2b8ce3418..3860706538 100644
--- a/code/modules/admin/verbs/onlyone.dm
+++ b/code/modules/admin/verbs/onlyone.dm
@@ -1,7 +1,7 @@
GLOBAL_VAR_INIT(highlander, FALSE)
/client/proc/only_one() //Gives everyone kilts, berets, claymores, and pinpointers, with the objective to hijack the emergency shuttle.
if(!SSticker.HasRoundStarted())
- tgui_alert(usr, "The game hasn't started yet!")
+ alert("The game hasn't started yet!")
return
GLOB.highlander = TRUE
diff --git a/code/modules/admin/verbs/playsound.dm b/code/modules/admin/verbs/playsound.dm
index 87eb782aee..c9a5cafd9b 100644
--- a/code/modules/admin/verbs/playsound.dm
+++ b/code/modules/admin/verbs/playsound.dm
@@ -5,7 +5,7 @@
return
var/freq = 1
- var/vol = tgui_input_num(usr, "What volume would you like the sound to play at?",, 100)
+ var/vol = input(usr, "What volume would you like the sound to play at?",, 100) as null|num
if(!vol)
return
vol = clamp(vol, 1, 100)
@@ -20,7 +20,7 @@
admin_sound.status = SOUND_STREAM
admin_sound.volume = vol
- var/res = tgui_alert(usr, "Show the title of this song to the players?",, list("Yes","No", "Cancel"))
+ var/res = alert(usr, "Show the title of this song to the players?",, "Yes","No", "Cancel")
switch(res)
if("Yes")
to_chat(world, "An admin played: [S]", confidential = TRUE)
@@ -61,7 +61,7 @@
to_chat(src, "Youtube-dl was not configured, action unavailable") //Check config.txt for the INVOKE_YOUTUBEDL value
return
- var/web_sound_input = tgui_input_text(src, "Enter content URL (supported sites only, leave blank to stop playing)", "Play Internet Sound via youtube-dl")
+ var/web_sound_input = input("Enter content URL (supported sites only, leave blank to stop playing)", "Play Internet Sound via youtube-dl") as text|null
if(istext(web_sound_input))
var/web_sound_url = ""
var/stop_web_sounds = FALSE
@@ -98,7 +98,7 @@
music_extra_data["link"] = data["webpage_url"]
music_extra_data["title"] = data["title"]
- var/res = tgui_alert(usr, "Show the title of and link to this song to the players?\n[title]",, list("No", "Yes", "Cancel"))
+ var/res = alert(usr, "Show the title of and link to this song to the players?\n[title]",, "No", "Yes", "Cancel")
switch(res)
if("Yes")
to_chat(world, "An admin played: [webpage_url]")
@@ -139,7 +139,7 @@
if(!check_rights(R_SOUNDS))
return
- var/web_sound_input = tgui_input_text(src, "Enter content stream URL (must be a direct link)", "Play Internet Sound via direct URL")
+ var/web_sound_input = input("Enter content stream URL (must be a direct link)", "Play Internet Sound via direct URL") as text|null
if(istext(web_sound_input))
if(!length(web_sound_input))
log_admin("[key_name(src)] stopped web sound")
diff --git a/code/modules/admin/verbs/randomverbs.dm b/code/modules/admin/verbs/randomverbs.dm
index 02d2591d85..a0a1da9584 100644
--- a/code/modules/admin/verbs/randomverbs.dm
+++ b/code/modules/admin/verbs/randomverbs.dm
@@ -4,7 +4,7 @@
if(!check_rights(R_ADMIN))
return
- var/confirm = tgui_alert(src, "Make [M] drop everything?", "Message", list("Yes", "No"))
+ var/confirm = alert(src, "Make [M] drop everything?", "Message", "Yes", "No")
if(confirm != "Yes")
return
@@ -29,7 +29,7 @@
return
message_admins("[key_name_admin(src)] has started answering [ADMIN_LOOKUPFLW(M)]'s prayer.")
- var/msg = tgui_input_text(src, "Message:", text("Subtle PM to [M.key]"))
+ var/msg = input("Message:", text("Subtle PM to [M.key]")) as text|null
if (!msg)
message_admins("[key_name_admin(src)] decided not to answer [ADMIN_LOOKUPFLW(M)]'s prayer")
@@ -65,12 +65,12 @@
return
if (!sender)
- sender = tgui_input_list(src, "Who is the message from?", "Sender", list(RADIO_CHANNEL_CENTCOM,RADIO_CHANNEL_SYNDICATE))
+ sender = input("Who is the message from?", "Sender") as null|anything in list(RADIO_CHANNEL_CENTCOM,RADIO_CHANNEL_SYNDICATE)
if(!sender)
return
message_admins("[key_name_admin(src)] has started answering [key_name_admin(H)]'s [sender] request.")
- var/input = tgui_input_text(src, "Please enter a message to reply to [key_name(H)] via their headset.","Outgoing message from [sender]", "")
+ var/input = input("Please enter a message to reply to [key_name(H)] via their headset.","Outgoing message from [sender]", "") as text|null
if(!input)
message_admins("[key_name_admin(src)] decided not to answer [key_name_admin(H)]'s [sender] request.")
return
@@ -100,7 +100,7 @@
if(operation == "set")
prompt = "Please enter the new reputation value:"
- msg = tgui_input_num(src, "Message:", prompt)
+ msg = input("Message:", prompt) as num|null
if (!msg)
return
@@ -134,7 +134,7 @@
if(!check_rights(R_ADMIN))
return
- var/msg = tgui_input_text(src, "Message:", text("Enter the text you wish to appear to everyone:"))
+ var/msg = input("Message:", text("Enter the text you wish to appear to everyone:")) as text|null
if (!msg)
return
@@ -151,12 +151,12 @@
return
if(!M)
- M = tgui_input_list(src, "Direct narrate to whom?", "Active Players", GLOB.player_list)
+ M = input("Direct narrate to whom?", "Active Players") as null|anything in GLOB.player_list
if(!M)
return
- var/msg = tgui_input_text(src, "Message:", text("Enter the text you wish to appear to your target:"))
+ var/msg = input("Message:", text("Enter the text you wish to appear to your target:")) as text|null
if( !msg )
return
@@ -176,10 +176,10 @@
return
if(!A)
return
- var/range = tgui_input_num(src, "Range:", "Narrate to mobs within how many tiles:", 7)
+ var/range = input("Range:", "Narrate to mobs within how many tiles:", 7) as num|null
if(!range)
return
- var/msg = tgui_input_text(src, "Message:", text("Enter the text you wish to appear to everyone within view:"))
+ var/msg = input("Message:", text("Enter the text you wish to appear to everyone within view:")) as text|null
if (!msg)
return
for(var/mob/M in view(range,A))
@@ -296,13 +296,13 @@
continue //we have a live body we are tied to
candidates += M.ckey
if(candidates.len)
- ckey = tgui_input_list(usr, "Pick the player you want to respawn as a xeno.", "Suitable Candidates", candidates)
+ ckey = input("Pick the player you want to respawn as a xeno.", "Suitable Candidates") as null|anything in candidates
else
to_chat(usr, "Error: create_xeno(): no suitable candidates.")
if(!istext(ckey))
return 0
- var/alien_caste = tgui_input_list(usr, "Please choose which caste to spawn.","Pick a caste", list("Queen","Praetorian","Hunter","Sentinel","Drone","Larva"))
+ var/alien_caste = input(usr, "Please choose which caste to spawn.","Pick a caste",null) as null|anything in list("Queen","Praetorian","Hunter","Sentinel","Drone","Larva")
var/obj/effect/landmark/spawn_here = GLOB.xeno_spawn.len ? pick(GLOB.xeno_spawn) : null
var/mob/living/carbon/alien/new_xeno
switch(alien_caste)
@@ -341,7 +341,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
if(!check_rights(R_ADMIN))
return
- var/input = ckey(tgui_input_text(src, "Please specify which key will be respawned.", "Key", ""))
+ var/input = ckey(input(src, "Please specify which key will be respawned.", "Key", ""))
if(!input)
return
@@ -358,7 +358,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
if(G_found.mind && !G_found.mind.active) //mind isn't currently in use by someone/something
//Check if they were an alien
if(G_found.mind.assigned_role == ROLE_ALIEN)
- if(tgui_alert(usr, "This character appears to have been an alien. Would you like to respawn them as such?",,list("Yes","No"))=="Yes")
+ if(alert("This character appears to have been an alien. Would you like to respawn them as such?",,"Yes","No")=="Yes")
var/turf/T
if(GLOB.xeno_spawn.len)
T = pick(GLOB.xeno_spawn)
@@ -393,7 +393,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
//check if they were a monkey
else if(findtext(G_found.real_name,"monkey"))
- if(tgui_alert(usr, "This character appears to have been a monkey. Would you like to respawn them as such?",,list("Yes","No"))=="Yes")
+ if(alert("This character appears to have been a monkey. Would you like to respawn them as such?",,"Yes","No")=="Yes")
var/mob/living/carbon/monkey/new_monkey = new
SSjob.SendToLateJoin(new_monkey)
G_found.mind.transfer_to(new_monkey) //be careful when doing stuff like this! I've already checked the mind isn't in use
@@ -487,10 +487,10 @@ Traitors and the like can also be revived with the previous role mostly intact.
if(!issilicon(new_character))//If they are not a cyborg/AI.
if(!record_found&&new_character.mind.assigned_role!=new_character.mind.special_role)//If there are no records for them. If they have a record, this info is already in there. MODE people are not announced anyway.
//Power to the user!
- if(tgui_alert(new_character,"Warning: No data core entry detected. Would you like to announce the arrival of this character by adding them to various databases, such as medical records?",,list("No","Yes"))=="Yes")
+ if(alert(new_character,"Warning: No data core entry detected. Would you like to announce the arrival of this character by adding them to various databases, such as medical records?",,"No","Yes")=="Yes")
GLOB.data_core.manifest_inject(new_character)
- if(tgui_alert(new_character,"Would you like an active AI to announce this character?",,list("No","Yes"))=="Yes")
+ if(alert(new_character,"Would you like an active AI to announce this character?",,"No","Yes")=="Yes")
AnnounceArrival(new_character, new_character.mind.assigned_role)
var/msg = "[admin] has respawned [player_key] as [new_character.real_name]."
@@ -509,14 +509,14 @@ Traitors and the like can also be revived with the previous role mostly intact.
if(!check_rights(R_ADMIN))
return
- var/input = tgui_input_text(usr, "Please enter anything you want the AI to do. Anything. Serious.", "What?", "")
+ var/input = input(usr, "Please enter anything you want the AI to do. Anything. Serious.", "What?", "") as text|null
if(!input)
return
log_admin("Admin [key_name(usr)] has added a new AI law - [input]")
message_admins("Admin [key_name_admin(usr)] has added a new AI law - [input]")
- var/show_log = tgui_alert(src, "Show ion message?", "Message", list("Yes", "No"))
+ var/show_log = alert(src, "Show ion message?", "Message", "Yes", "No")
var/announce_ion_laws = (show_log == "Yes" ? 1 : -1)
var/datum/round_event/ion_storm/add_law_only/ion = new()
@@ -535,7 +535,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
if(!mob)
return
if(!istype(M))
- tgui_alert(src, "Cannot revive a ghost")
+ alert("Cannot revive a ghost")
return
M.revive(full_heal = 1, admin_revive = 1)
@@ -552,11 +552,11 @@ Traitors and the like can also be revived with the previous role mostly intact.
if(!check_rights(R_ADMIN))
return
- var/input = tgui_input_message(usr, "Enter a Command Report. Ensure it makes sense IC.", "What?", "")
+ var/input = input(usr, "Enter a Command Report. Ensure it makes sense IC.", "What?", "") as message|null
if(!input)
return
- var/confirm = tgui_alert(src, "Do you want to announce the contents of the report to the crew?", "Announce", list("Yes", "No", "Cancel"))
+ var/confirm = alert(src, "Do you want to announce the contents of the report to the crew?", "Announce", "Yes", "No", "Cancel")
var/announce_command_report = TRUE
switch(confirm)
if("Yes")
@@ -578,13 +578,13 @@ Traitors and the like can also be revived with the previous role mostly intact.
if(!check_rights(R_ADMIN))
return
- var/input = tgui_input_message(src, "Enter a priority announcement. Ensure it makes sense IC.", "What?", "")
+ var/input = input(usr, "Enter a priority announcement. Ensure it makes sense IC.", "What?", "") as message|null
if(!input)
return
- var/title = tgui_input_text(src, "What should the title be?", "What?","")
+ var/title = input(src, "What should the title be?", "What?","") as text|null
- var/special_name = tgui_input_text(src, "Who is making the announcement?", "Who?", "")
+ var/special_name = input(src, "Who is making the announcement?", "Who?", "") as text|null
priority_announce(input, title, sender_override = special_name)
log_admin("[key_name(src)] has sent a priority announcement: [input]")
@@ -598,7 +598,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
if(!check_rights(R_ADMIN))
return
- var/input = tgui_input_text(usr, "Please input a new name for Central Command.", "What?", "")
+ var/input = input(usr, "Please input a new name for Central Command.", "What?", "") as text|null
if(!input)
return
change_command_name(input)
@@ -630,25 +630,25 @@ Traitors and the like can also be revived with the previous role mostly intact.
if(!check_rights(R_ADMIN))
return
- var/devastation = tgui_input_num(src, "Range of total devastation. -1 to none", text("Input"))
+ var/devastation = input("Range of total devastation. -1 to none", text("Input")) as num|null
if(devastation == null)
return
- var/heavy = tgui_input_num(src, "Range of heavy impact. -1 to none", text("Input"))
+ var/heavy = input("Range of heavy impact. -1 to none", text("Input")) as num|null
if(heavy == null)
return
- var/light = tgui_input_num(src, "Range of light impact. -1 to none", text("Input"))
+ var/light = input("Range of light impact. -1 to none", text("Input")) as num|null
if(light == null)
return
- var/flash = tgui_input_num(src, "Range of flash. -1 to none", text("Input"))
+ var/flash = input("Range of flash. -1 to none", text("Input")) as num|null
if(flash == null)
return
- var/flames = tgui_input_num(src, "Range of flames. -1 to none", text("Input"))
+ var/flames = input("Range of flames. -1 to none", text("Input")) as num|null
if(flames == null)
return
if ((devastation != -1) || (heavy != -1) || (light != -1) || (flash != -1) || (flames != -1))
if ((devastation > 20) || (heavy > 20) || (light > 20) || (flames > 20))
- if (tgui_alert(src, "Are you sure you want to do this? It will laaag.", "Confirmation", list("Yes", "No")) == "No")
+ if (alert(src, "Are you sure you want to do this? It will laaag.", "Confirmation", "Yes", "No") == "No")
return
explosion(O, devastation, heavy, light, flash, null, null,flames)
@@ -666,7 +666,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
if(!check_rights(R_ADMIN))
return
- var/range = tgui_input_num(src, "Range.", text("Input"))
+ var/range = input("Range.", text("Input")) as num|null
if(!range)
return
log_admin("[key_name(usr)] created an EM Pulse - log below") //because we'll just log the empulse itself
@@ -682,7 +682,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
if(!check_rights(R_ADMIN))
return
- var/confirm = tgui_alert(src, "Drop a brain?", "Confirm", list("Yes", "No","Cancel"))
+ var/confirm = alert(src, "Drop a brain?", "Confirm", "Yes", "No","Cancel")
if(confirm == "Cancel")
return
//Due to the delay here its easy for something to have happened to the mob
@@ -705,7 +705,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
set name = "Gibself"
set category = "Admin.Fun"
- var/confirm = tgui_alert(src, "You sure?", "Confirm", list("Yes", "No"))
+ var/confirm = alert(src, "You sure?", "Confirm", "Yes", "No")
if(confirm == "Yes")
log_admin("[key_name(usr)] used gibself.")
message_admins("[key_name_admin(usr)] used gibself.")
@@ -727,7 +727,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
set desc = "switches between 1x and custom views"
if(view_size.getView() == view_size.default)
- view_size.setTo(tgui_input_list(src, "Select view range:", "FUCK YE", list(1,2,3,4,5,6,7,8,9,10,11,12,13,14,128) - 7))
+ view_size.setTo(input("Select view range:", "FUCK YE", 7) in list(1,2,3,4,5,6,7,8,9,10,11,12,13,14,128) - 7)
else
view_size.resetToDefault(getScreenSize(prefs.widescreenpref))
@@ -746,7 +746,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
if(!check_rights(R_ADMIN))
return
- var/confirm = tgui_alert(src, "You sure?", "Confirm", list("Yes", "No"))
+ var/confirm = alert(src, "You sure?", "Confirm", "Yes", "No")
if(confirm != "Yes")
return
@@ -761,7 +761,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
set name = "Cancel Shuttle"
if(!check_rights(0))
return
- if(tgui_alert(src, "You sure?", "Confirm", list("Yes", "No")) != "Yes")
+ if(alert(src, "You sure?", "Confirm", "Yes", "No") != "Yes")
return
if(EMERGENCY_AT_LEAST_DOCKED)
@@ -783,7 +783,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
if(SSshuttle.emergency.mode == SHUTTLE_DISABLED)
to_chat(usr, "Error, shuttle is already disabled.")
return
- if(tgui_alert(src, "You sure?", "Confirm", list("Yes", "No")) != "Yes")
+ if(alert(src, "You sure?", "Confirm", "Yes", "No") != "Yes")
return
message_admins("[key_name_admin(usr)] disabled the shuttle.")
SSshuttle.lastMode = SSshuttle.emergency.mode
@@ -803,7 +803,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
if(SSshuttle.emergency.mode != SHUTTLE_DISABLED)
to_chat(usr, "Error, shuttle not disabled.")
return
- if(tgui_alert(src, "You sure?", "Confirm", list("Yes", "No")) != "Yes")
+ if(alert(src, "You sure?", "Confirm", "Yes", "No") != "Yes")
return
message_admins("[key_name_admin(usr)] enabled the emergency shuttle.")
SSshuttle.adminEmergencyNoRecall = FALSE
@@ -833,7 +833,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
return
- var/notifyplayers = tgui_alert(src, "Do you want to notify the players?", "Options", list("Yes", "No", "Cancel"))
+ var/notifyplayers = alert(src, "Do you want to notify the players?", "Options", "Yes", "No", "Cancel")
if(notifyplayers == "Cancel")
return
@@ -872,7 +872,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
if(!check_rights(R_ADMIN))
return
- var/level = tgui_input_list(src, "Select security level to change to","Set Security Level", list("green","blue","amber","red","delta"))
+ var/level = input("Select security level to change to","Set Security Level") as null|anything in list("green","blue","amber","red","delta")
if(level)
set_security_level(level)
@@ -888,7 +888,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
return
if(!N.timing)
- var/newtime = tgui_input_num(usr, "Set activation timer.", "Activate Nuke", "[N.timer_set]")
+ var/newtime = input(usr, "Set activation timer.", "Activate Nuke", "[N.timer_set]") as num|null
if(!newtime)
return
N.timer_set = newtime
@@ -1117,11 +1117,11 @@ Traitors and the like can also be revived with the previous role mostly intact.
if(!holder)
return
- var/weather_type = tgui_input_list(src, "Choose a weather", "Weather", subtypesof(/datum/weather))
+ var/weather_type = input("Choose a weather", "Weather") as null|anything in subtypesof(/datum/weather)
if(!weather_type)
return
- var/z_level = tgui_input_num(src, "Z-Level to target? Leave blank to target current Z-Level.", "Z-Level")
+ var/z_level = input("Z-Level to target? Leave blank to target current Z-Level.", "Z-Level") as num|null
if(!isnum(z_level))
if(!src.mob)
return
@@ -1142,7 +1142,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
if(!check_rights(R_ADMIN))
return
- var/confirm = tgui_alert(src, "Please confirm you want to add latent zombie organs in all humans?", "Confirm Zombies", list("Yes", "No"))
+ var/confirm = alert(src, "Please confirm you want to add latent zombie organs in all humans?", "Confirm Zombies", "Yes", "No")
if(confirm != "Yes")
return
@@ -1160,7 +1160,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
if(!check_rights(R_ADMIN))
return
- var/confirm = tgui_alert(src, "Please confirm you want to cure all zombies?", "Confirm Zombie Cure", list("Yes", "No"))
+ var/confirm = alert(src, "Please confirm you want to cure all zombies?", "Confirm Zombie Cure", "Yes", "No")
if(confirm != "Yes")
return
@@ -1179,7 +1179,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
if(!check_rights(R_ADMIN))
return
- var/confirm = tgui_alert(src, "Please confirm you want polymorph all mobs?", "Confirm Polymorph", list("Yes", "No"))
+ var/confirm = alert(src, "Please confirm you want polymorph all mobs?", "Confirm Polymorph", "Yes", "No")
if(confirm != "Yes")
return
@@ -1213,7 +1213,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
if(!check_rights(R_ADMIN))
return
- var/input = tgui_input_message(usr, "Please specify your tip that you want to send to the players.", "Tip", "")
+ var/input = input(usr, "Please specify your tip that you want to send to the players.", "Tip", "") as message|null
if(!input)
return
@@ -1338,7 +1338,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
ADMIN_PUNISHMENT_SCARIFY,
ADMIN_PUNISHMENT_CLUWNE)
- var/punishment = tgui_input_list(usr, "Choose a punishment", "DIVINE SMITING", punishment_list)
+ var/punishment = input("Choose a punishment", "DIVINE SMITING") as null|anything in punishment_list
if(QDELETED(target) || !punishment)
return
@@ -1365,7 +1365,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
var/turf/endT = spaceDebrisFinishLoc(startside, T.z)
new /obj/effect/immovablerod(startT, endT,target)
if(ADMIN_PUNISHMENT_SUPPLYPOD_QUICK)
- var/target_path = tgui_input_text(usr,"Enter typepath of an atom you'd like to send with the pod (type \"empty\" to send an empty pod):" ,"Typepath","/obj/item/reagent_containers/food/snacks/grown/harebell")
+ var/target_path = input(usr,"Enter typepath of an atom you'd like to send with the pod (type \"empty\" to send an empty pod):" ,"Typepath","/obj/item/reagent_containers/food/snacks/grown/harebell") as null|text
var/area/pod_storage_area = locate(/area/centcom/supplypod/podStorage) in GLOB.sortedAreas
var/obj/structure/closet/supplypod/centcompod/pod = new(pick(get_area_turfs(pod_storage_area))) //Lets not runtime
pod.damage = 40
@@ -1378,7 +1378,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
if(!ispath(delivery))
delivery = pick_closest_path(target_path)
if(!delivery)
- tgui_alert(src, "ERROR: Incorrect / improper path given.")
+ alert("ERROR: Incorrect / improper path given.")
new delivery(pod)
new /obj/effect/pod_landingzone(get_turf(target), pod)
if(ADMIN_PUNISHMENT_SUPPLYPOD)
@@ -1404,13 +1404,13 @@ Traitors and the like can also be revived with the previous role mostly intact.
if(ADMIN_PUNISHMENT_CUSTOM_PIE)
var/obj/item/reagent_containers/food/snacks/pie/cream/nostun/A = new()
if(!A.reagents)
- var/amount = tgui_input_num(usr, "Specify the reagent size of [A]", "Set Reagent Size", 50)
+ var/amount = input(usr, "Specify the reagent size of [A]", "Set Reagent Size", 50) as num|null
if(amount)
A.create_reagents(amount)
if(A.reagents)
var/chosen_id = choose_reagent_id(usr)
if(chosen_id)
- var/amount = tgui_input_num(usr, "Choose the amount to add.", "Choose the amount.", A.reagents.maximum_volume)
+ var/amount = input(usr, "Choose the amount to add.", "Choose the amount.", A.reagents.maximum_volume) as num|null
if(amount)
A.reagents.add_reagent(chosen_id, amount)
A.splat(target)
@@ -1449,7 +1449,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
return
var/list/how_fucked_is_this_dude = list("A little", "A lot", "So fucking much", "FUCK THIS DUDE")
- var/hatred = tgui_input_list(usr, "How much do you hate this guy?", "", how_fucked_is_this_dude)
+ var/hatred = input("How much do you hate this guy?") in how_fucked_is_this_dude
var/repetitions
var/shots_per_limb_per_rep = 2
var/damage
@@ -1545,7 +1545,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
if(!check_rights(R_ADMIN))
return
var/message = pick(GLOB.admiral_messages)
- message = tgui_input_text(src, "Enter message from the on-call admiral to be put in the recall report.", "Admiral Message", message)
+ message = input("Enter message from the on-call admiral to be put in the recall report.", "Admiral Message", message) as text|null
if(!message)
return
@@ -1592,7 +1592,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
light_range = 2
duration = 9
-/obj/effect/temp_visual/target/ex_act()
+/obj/effect/temp_visual/target/ex_act(severity, target, origin)
return
/obj/effect/temp_visual/target/Initialize(mapload, list/flame_hit)
@@ -1659,7 +1659,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
if(!D)
return
- var/add_or_remove = tgui_input_list(usr, "Remove/Add?", "Trait Remove/Add", list("Add","Remove"))
+ var/add_or_remove = input("Remove/Add?", "Trait Remove/Add") as null|anything in list("Add","Remove")
if(!add_or_remove)
return
var/list/availible_traits = list()
@@ -1676,7 +1676,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
var/name = GLOB.trait_name_map[trait] || trait
availible_traits[name] = trait
- var/chosen_trait = tgui_input_list(src, "Select trait to modify", "Trait", sortList(availible_traits))
+ var/chosen_trait = input("Select trait to modify", "Trait") as null|anything in sortList(availible_traits)
if(!chosen_trait)
return
chosen_trait = availible_traits[chosen_trait]
@@ -1686,14 +1686,14 @@ Traitors and the like can also be revived with the previous role mostly intact.
if("Add") //Not doing source choosing here intentionally to make this bit faster to use, you can always vv it.
ADD_TRAIT(D,chosen_trait,source)
if("Remove")
- var/specific = tgui_input_list(src, "All or specific source ?", "Trait Remove/Add", list("All","Specific"))
+ var/specific = input("All or specific source ?", "Trait Remove/Add") as null|anything in list("All","Specific")
if(!specific)
return
switch(specific)
if("All")
source = null
if("Specific")
- source = tgui_input_list(src, "Source to be removed","Trait Remove/Add", sortList(D.status_traits[chosen_trait]))
+ source = input("Source to be removed","Trait Remove/Add") as null|anything in sortList(D.status_traits[chosen_trait])
if(!source)
return
REMOVE_TRAIT(D,chosen_trait,source)
@@ -1708,7 +1708,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
return
var/turf/T = get_turf(usr)
- target = tgui_input_list(src, "Any specific target in mind? Please note only live, non cluwned, human targets are valid.", "Target", GLOB.player_list)
+ target = input("Any specific target in mind? Please note only live, non cluwned, human targets are valid.", "Target", target) as null|anything in GLOB.player_list
if(target && ishuman(target))
var/mob/living/carbon/human/H = target
var/mob/living/simple_animal/hostile/floor_cluwne/FC = new /mob/living/simple_animal/hostile/floor_cluwne(T)
diff --git a/code/modules/admin/verbs/reestablish_db_connection.dm b/code/modules/admin/verbs/reestablish_db_connection.dm
index 503379c551..2090902ebc 100644
--- a/code/modules/admin/verbs/reestablish_db_connection.dm
+++ b/code/modules/admin/verbs/reestablish_db_connection.dm
@@ -7,10 +7,10 @@
if (SSdbcore.IsConnected())
if (!check_rights(R_DEBUG,0))
- tgui_alert(src, "The database is already connected! (Only those with +debug can force a reconnection)", "The database is already connected!")
+ alert("The database is already connected! (Only those with +debug can force a reconnection)", "The database is already connected!")
return
- var/reconnect = tgui_alert(src, "The database is already connected! If you *KNOW* that this is incorrect, you can force a reconnection", "The database is already connected!", list("Force Reconnect", "Cancel"))
+ var/reconnect = alert("The database is already connected! If you *KNOW* that this is incorrect, you can force a reconnection", "The database is already connected!", "Force Reconnect", "Cancel")
if (reconnect != "Force Reconnect")
return
diff --git a/code/modules/admin/verbs/secrets.dm b/code/modules/admin/verbs/secrets.dm
index de5d641bde..80344d076c 100644
--- a/code/modules/admin/verbs/secrets.dm
+++ b/code/modules/admin/verbs/secrets.dm
@@ -104,7 +104,7 @@
message_admins("[key_name_admin(holder)] has removed the cap on security officers.")
//Buttons for helpful stuff. This is where people land in the tgui
if("clear_virus")
- var/choice = tgui_input_list(holder, "Are you sure you want to cure all disease?", "", list("Yes", "Cancel"))
+ var/choice = input("Are you sure you want to cure all disease?") in list("Yes", "Cancel")
if(choice == "Yes")
message_admins("[key_name_admin(holder)] has cured all diseases.")
for(var/thing in SSdisease.active_diseases)
@@ -130,11 +130,11 @@
holder.holder.output_ai_laws()//huh, inconvenient var naming, huh?
if("showgm")
if(!SSticker.HasRoundStarted())
- tgui_alert(holder, "The game hasn't started yet!")
+ alert("The game hasn't started yet!")
else if (SSticker.mode)
- tgui_alert(holder, "The game mode is [SSticker.mode.name]")
+ alert("The game mode is [SSticker.mode.name]")
else
- tgui_alert(holder, "For some reason there's a SSticker, but not a game mode")
+ alert("For some reason there's a SSticker, but not a game mode")
if("manifest")
var/dat = "Showing Crew Manifest."
dat += "
Name
Position
"
@@ -163,7 +163,7 @@
if("ctfbutton")
toggle_all_ctf(holder)
if("tdomereset")
- var/delete_mobs = tgui_alert(holder, "Clear all mobs?","Confirm",list("Yes","No","Cancel"))
+ var/delete_mobs = alert("Clear all mobs?","Confirm","Yes","No","Cancel")
if(delete_mobs == "Cancel")
return
@@ -181,7 +181,7 @@
var/area/template = GLOB.areas_by_type[/area/tdome/arena_source]
template.copy_contents_to(thunderdome)
if("set_name")
- var/new_name = tgui_input_text(holder, "Please input a new name for the station.", "What?", "")
+ var/new_name = input(holder, "Please input a new name for the station.", "What?", "") as text|null
if(!new_name)
return
set_station_name(new_name)
@@ -195,7 +195,7 @@
message_admins("[key_name_admin(holder)] reset the station name.")
priority_announce("[command_name()] has renamed the station to \"[new_name]\".")
if("night_shift_set")
- var/val = tgui_alert(holder, "What do you want to set night shift to? This will override the automatic system until set to automatic again.", "Night Shift", list("On", "Off", "Automatic"))
+ var/val = alert(holder, "What do you want to set night shift to? This will override the automatic system until set to automatic again.", "Night Shift", "On", "Off", "Automatic")
switch(val)
if("Automatic")
if(CONFIG_GET(flag/enable_night_shifts))
@@ -239,14 +239,14 @@
if(!is_funmin)
return
SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("Virus Outbreak"))
- switch(tgui_alert(holder, "Do you want this to be a random disease or do you have something in mind?",,list("Make Your Own","Random","Choose")))
+ switch(alert("Do you want this to be a random disease or do you have something in mind?",,"Make Your Own","Random","Choose"))
if("Make Your Own")
AdminCreateVirus(holder)
if("Random")
var/datum/round_event_control/disease_outbreak/DC = locate(/datum/round_event_control/disease_outbreak) in SSevents.control
E = DC.runEvent()
if("Choose")
- var/virus = tgui_input_list(holder, "Choose the virus to spread", "BIOHAZARD", sortList(typesof(/datum/disease), /proc/cmp_typepaths_asc))
+ var/virus = input("Choose the virus to spread", "BIOHAZARD") as null|anything in sortList(typesof(/datum/disease), /proc/cmp_typepaths_asc)
var/datum/round_event_control/disease_outbreak/DC = locate(/datum/round_event_control/disease_outbreak) in SSevents.control
var/datum/round_event/disease_outbreak/DO = DC.runEvent()
DO.virus_type = virus
@@ -254,7 +254,7 @@
if("allspecies")
if(!is_funmin)
return
- var/result = tgui_input_list(holder, "Please choose a new species","Species", GLOB.species_list)
+ var/result = input(holder, "Please choose a new species","Species") as null|anything in GLOB.species_list
if(result)
SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("Mass Species Change", "[result]"))
log_admin("[key_name(holder)] turned all humans into [result]", 1)
@@ -297,7 +297,7 @@
if("onlyone")
if(!is_funmin)
return
- var/response = tgui_alert(holder, "Delay by 40 seconds?", "There can, in fact, only be one", list("Instant!", "40 seconds (crush the hope of a normal shift)"))
+ var/response = alert("Delay by 40 seconds?", "There can, in fact, only be one", "Instant!", "40 seconds (crush the hope of a normal shift)")
if(response == "Instant!")
holder.only_one()
else
@@ -308,7 +308,7 @@
return
SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("Summon Guns"))
var/survivor_probability = 0
- switch(tgui_alert(holder, "Do you want this to create survivors antagonists?",,list("No Antags","Some Antags","All Antags!")))
+ switch(alert("Do you want this to create survivors antagonists?",,"No Antags","Some Antags","All Antags!"))
if("Some Antags")
survivor_probability = 25
if("All Antags!")
@@ -320,7 +320,7 @@
return
SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("Summon Magic"))
var/survivor_probability = 0
- switch(tgui_alert(holder, "Do you want this to create magician antagonists?",,list("No Antags","Some Antags","All Antags!")))
+ switch(alert("Do you want this to create magician antagonists?",,"No Antags","Some Antags","All Antags!"))
if("Some Antags")
survivor_probability = 25
if("All Antags!")
@@ -331,12 +331,12 @@
if(!is_funmin)
return
if(!SSevents.wizardmode)
- if(tgui_alert(holder, "Do you want to toggle summon events on?",,list("Yes","No")) == "Yes")
+ if(alert("Do you want to toggle summon events on?",,"Yes","No") == "Yes")
summonevents()
SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("Summon Events", "Activate"))
else
- switch(tgui_alert(holder, "What would you like to do?","Intensify Summon Events",list("Turn Off Summon Events","Nothing")))
+ switch(alert("What would you like to do?",,"Intensify Summon Events","Turn Off Summon Events","Nothing"))
if("Intensify Summon Events")
summonevents()
SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("Summon Events", "Intensify"))
@@ -452,7 +452,7 @@
return
SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("Bomb Cap"))
- var/newBombCap = tgui_input_num(holder,"What would you like the new bomb cap to be. (entered as the light damage range (the 3rd number in common (1,2,3) notation)) Must be above 4)", "New Bomb Cap", GLOB.MAX_EX_LIGHT_RANGE)
+ var/newBombCap = input(holder,"What would you like the new bomb cap to be. (entered as the light damage range (the 3rd number in common (1,2,3) notation)) Must be above 4)", "New Bomb Cap", GLOB.MAX_EX_LIGHT_RANGE) as num|null
if (!CONFIG_SET(number/bombcap, newBombCap))
return
@@ -471,7 +471,7 @@
if(!is_funmin)
return
if(!SSticker.HasRoundStarted())
- tgui_alert(holder, "The game hasn't started yet!")
+ alert("The game hasn't started yet!")
return
var/objective = stripped_input(holder, "Enter an objective")
if(!objective)
@@ -497,7 +497,7 @@
if(!is_funmin)
return
if(!SSticker.HasRoundStarted())
- tgui_alert(holder, "The game hasn't started yet!")
+ alert("The game hasn't started yet!")
return
message_admins("[key_name_admin(holder)] activated AK-47s for Everyone!")
holder.ak47s()
@@ -516,11 +516,11 @@
if("anime")
if(!is_funmin)
return
- var/animetype = tgui_alert(holder, "Would you like to have the clothes be changed?",,list("Yes","No","Cancel"))
+ var/animetype = alert("Would you like to have the clothes be changed?",,"Yes","No","Cancel")
var/droptype
if(animetype =="Yes")
- droptype = tgui_alert(holder, "Make the uniforms Nodrop?",,list("Yes","No","Cancel"))
+ droptype = alert("Make the uniforms Nodrop?",,"Yes","No","Cancel")
if(animetype == "Cancel" || droptype == "Cancel")
return
@@ -584,7 +584,7 @@
if(E)
E.processing = FALSE
if(E.announceWhen>0)
- switch(tgui_alert(holder, "Would you like to alert the crew?", "Alert", list("Yes", "No", "Cancel")))
+ switch(alert(holder, "Would you like to alert the crew?", "Alert", "Yes", "No", "Cancel"))
if("Cancel")
E.kill()
return
diff --git a/code/modules/admin/verbs/selectequipment.dm b/code/modules/admin/verbs/selectequipment.dm
index 12b2c42d9f..eb75df9ac1 100644
--- a/code/modules/admin/verbs/selectequipment.dm
+++ b/code/modules/admin/verbs/selectequipment.dm
@@ -37,7 +37,7 @@
user = CLIENT_FROM_VAR(_user)
if(!ishuman(target) && !isobserver(target))
- tgui_alert(usr, "Invalid mob")
+ alert("Invalid mob")
return
target_mob = target
@@ -197,7 +197,7 @@
/client/proc/admin_apply_outfit(mob/target, dresscode)
if(!ishuman(target) && !isobserver(target))
- tgui_alert(usr, "Invalid mob")
+ alert("Invalid mob")
return
if(!dresscode)
@@ -210,7 +210,7 @@
else
human_target = target
if(human_target.l_store || human_target.r_store || human_target.s_store) //saves a lot of time for admins and coders alike
- if(tgui_alert(src, "Drop Items in Pockets? No will delete them.", "Robust quick dress shop", list("Yes", "No")) == "No")
+ if(alert("Drop Items in Pockets? No will delete them.", "Robust quick dress shop", "Yes", "No") == "No")
delete_pocket = TRUE
SSblackbox.record_feedback("tally", "admin_verb", 1, "Select Equipment") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
diff --git a/code/modules/admin/verbs/shuttlepanel.dm b/code/modules/admin/verbs/shuttlepanel.dm
index e69c9aa050..7552936136 100644
--- a/code/modules/admin/verbs/shuttlepanel.dm
+++ b/code/modules/admin/verbs/shuttlepanel.dm
@@ -24,7 +24,7 @@
options += "Delete Shuttle"
options += "Into The Sunset (delete & greentext 'escape')"
- var/selection = tgui_input_list(user, "Select where to fly [name || id]:", "Fly Shuttle", options)
+ var/selection = input(user, "Select where to fly [name || id]:", "Fly Shuttle") as null|anything in options
if(!selection)
return
@@ -35,12 +35,12 @@
setTimer(ignitionTime)
if("Delete Shuttle")
- if(tgui_alert(user, "Really delete [name || id]?", "Delete Shuttle", list("Cancel", "Really!")) != "Really!")
+ if(alert(user, "Really delete [name || id]?", "Delete Shuttle", "Cancel", "Really!") != "Really!")
return
jumpToNullSpace()
if("Into The Sunset (delete & greentext 'escape')")
- if(tgui_alert(user, "Really delete [name || id] and greentext escape objectives?", "Delete Shuttle", list("Cancel", "Really!")) != "Really!")
+ if(alert(user, "Really delete [name || id] and greentext escape objectives?", "Delete Shuttle", "Cancel", "Really!") != "Really!")
return
intoTheSunset()
@@ -52,7 +52,7 @@
return // use the existing verbs for this
/obj/docking_port/mobile/arrivals/admin_fly_shuttle(mob/user)
- switch(tgui_alert(user, "Would you like to fly the arrivals shuttle once or change its destination?", "Fly Shuttle", list("Fly", "Retarget", "Cancel")))
+ switch(alert(user, "Would you like to fly the arrivals shuttle once or change its destination?", "Fly Shuttle", "Fly", "Retarget", "Cancel"))
if("Cancel")
return
if("Fly")
@@ -67,7 +67,7 @@
if (canDock(S) == SHUTTLE_CAN_DOCK)
options[S.name || S.id] = S
- var/selection = tgui_input_list(user, "Select the new arrivals destination:", "Fly Shuttle", options)
+ var/selection = input(user, "Select the new arrivals destination:", "Fly Shuttle") as null|anything in options
if(!selection)
return
target_dock = options[selection]
diff --git a/code/modules/admin/view_variables/admin_delete.dm b/code/modules/admin/view_variables/admin_delete.dm
index 592b2680be..947ad5db2c 100644
--- a/code/modules/admin/view_variables/admin_delete.dm
+++ b/code/modules/admin/view_variables/admin_delete.dm
@@ -10,7 +10,7 @@
else
jmp_coords = coords = "in nullspace"
- if (tgui_alert(src, "Are you sure you want to delete:\n[D]\n[coords]?", "Confirmation", list("Yes", "No")) == "Yes")
+ if (alert(src, "Are you sure you want to delete:\n[D]\n[coords]?", "Confirmation", "Yes", "No") == "Yes")
log_admin("[key_name(usr)] deleted [D] [coords]")
message_admins("[key_name_admin(usr)] deleted [D] [jmp_coords]")
SSblackbox.record_feedback("tally", "admin_verb", 1, "Delete") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
diff --git a/code/modules/admin/view_variables/get_variables.dm b/code/modules/admin/view_variables/get_variables.dm
index ee53a06ce1..3f90002edc 100644
--- a/code/modules/admin/view_variables/get_variables.dm
+++ b/code/modules/admin/view_variables/get_variables.dm
@@ -83,25 +83,25 @@
if(extra_classes)
classes += extra_classes
- .["class"] = tgui_input_list(src, "What kind of data?", "Variable Type", classes)
+ .["class"] = input(src, "What kind of data?", "Variable Type", default_class) as null|anything in classes
if(holder && holder.marked_datum && .["class"] == markstring)
.["class"] = VV_MARKED_DATUM
switch(.["class"])
if(VV_TEXT)
- .["value"] = tgui_input_text(src, "Enter new text:", "Text", current_value)
+ .["value"] = input("Enter new text:", "Text", current_value) as null|text
if(.["value"] == null)
.["class"] = null
return
if(VV_MESSAGE)
- .["value"] = tgui_input_message(src, "Enter new text:", "Text", current_value)
+ .["value"] = input("Enter new text:", "Text", current_value) as null|message
if(.["value"] == null)
.["class"] = null
return
if(VV_NUM)
- .["value"] = tgui_input_num(src, "Enter new number:", "Num", current_value)
+ .["value"] = input("Enter new number:", "Num", current_value) as null|num
if(.["value"] == null)
.["class"] = null
return
@@ -128,7 +128,7 @@
var/type = current_value
var/error = ""
do
- type = tgui_input_text(src, "Enter type:[error]", "Type", type)
+ type = input("Enter type:[error]", "Type", type) as null|text
if(!type)
break
type = text2path(type)
@@ -146,7 +146,7 @@
.["class"] = null
return
var/list/things = vv_reference_list(type, subtypes)
- var/value = tgui_input_list(src, "Select reference:", "Reference", things)
+ var/value = input("Select reference:", "Reference", current_value) as null|anything in things
if(!value)
.["class"] = null
return
@@ -159,7 +159,7 @@
.["class"] = null
return
var/list/things = vv_reference_list(type, subtypes)
- var/value = tgui_input_list(src, "Select reference:", "Reference", things)
+ var/value = input("Select reference:", "Reference", current_value) as null|anything in things
if(!value)
.["class"] = null
return
@@ -172,14 +172,14 @@
.["class"] = null
return
var/list/things = vv_reference_list(type, subtypes)
- var/value = tgui_input_list(src, "Select reference:", "Reference", things)
+ var/value = input("Select reference:", "Reference", current_value) as null|anything in things
if(!value)
.["class"] = null
return
.["value"] = things[value]
if(VV_CLIENT)
- .["value"] = tgui_input_list(src, "Select reference:", "Reference", GLOB.clients)
+ .["value"] = input("Select reference:", "Reference", current_value) as null|anything in GLOB.clients
if(.["value"] == null)
.["class"] = null
return
@@ -234,7 +234,7 @@
var/type = current_value
var/error = ""
do
- type = tgui_input_text(src, "Enter type:[error]", "Type", type)
+ type = input("Enter type:[error]", "Type", type) as null|text
if(!type)
break
type = text2path(type)
@@ -256,15 +256,15 @@
if(VV_TEXT_LOCATE)
var/datum/D
do
- var/ref = tgui_input_text(src, "Enter reference:", "Reference")
+ var/ref = input("Enter reference:", "Reference") as null|text
if(!ref)
break
D = locate(ref)
if(!D)
- tgui_alert(usr, "Invalid ref!")
+ alert("Invalid ref!")
continue
if(!D.can_vv_mark())
- tgui_alert(usr, "Datum can not be marked!")
+ alert("Datum can not be marked!")
continue
while(!D)
.["type"] = D.type
diff --git a/code/modules/admin/view_variables/mass_edit_variables.dm b/code/modules/admin/view_variables/mass_edit_variables.dm
index b2171e5df1..5b120b6cef 100644
--- a/code/modules/admin/view_variables/mass_edit_variables.dm
+++ b/code/modules/admin/view_variables/mass_edit_variables.dm
@@ -31,7 +31,7 @@
names = sortList(names)
- variable = tgui_input_list(src, "Which var?", "Var", names)
+ variable = input("Which var?", "Var") as null|anything in names
else
variable = var_name
@@ -52,7 +52,7 @@
if(variable in GLOB.VVpixelmovement)
if(!check_rights(R_DEBUG))
return
- var/prompt = tgui_alert(src, "Editing this var may irreparably break tile gliding for the rest of the round. THIS CAN'T BE UNDONE", "DANGER", list("ABORT ", "Continue", " ABORT"))
+ var/prompt = alert(src, "Editing this var may irreparably break tile gliding for the rest of the round. THIS CAN'T BE UNDONE", "DANGER", "ABORT ", "Continue", " ABORT")
if (prompt != "Continue")
return
@@ -118,7 +118,7 @@
var/pre_processing = new_value
var/unique
if (varsvars?.len)
- unique = tgui_alert(usr, "Process vars unique to each instance, or same for all?", "Variable Association", list("Unique", "Same"))
+ unique = alert(usr, "Process vars unique to each instance, or same for all?", "Variable Association", "Unique", "Same")
if(unique == "Unique")
unique = TRUE
else
@@ -145,7 +145,7 @@
CHECK_TICK
if (VV_NEW_TYPE)
- var/many = tgui_alert(src, "Create only one [value["type"]] and assign each or a new one for each thing", "How Many", list("One", "Many", "Cancel"))
+ var/many = alert(src, "Create only one [value["type"]] and assign each or a new one for each thing", "How Many", "One", "Many", "Cancel")
if (many == "Cancel")
return
if (many == "Many")
diff --git a/code/modules/admin/view_variables/modify_variables.dm b/code/modules/admin/view_variables/modify_variables.dm
index 3287c04cb8..b9de3e09bc 100644
--- a/code/modules/admin/view_variables/modify_variables.dm
+++ b/code/modules/admin/view_variables/modify_variables.dm
@@ -9,7 +9,7 @@ GLOBAL_PROTECT(VVpixelmovement)
/client/proc/vv_parse_text(O, new_var)
if(O && findtext(new_var,"\["))
- var/process_vars = tgui_alert(usr, "\[] detected in string, process as variables?","Process Variables?",list("Yes","No"))
+ var/process_vars = alert(usr,"\[] detected in string, process as variables?","Process Variables?","Yes","No")
if(process_vars == "Yes")
. = string2listofvars(new_var, O)
@@ -24,7 +24,7 @@ GLOBAL_PROTECT(VVpixelmovement)
if (!subtypes || !subtypes.len)
return FALSE
if (subtypes?.len)
- switch(tgui_alert(src, "Strict object type detection?", "Type detection", list("Strictly this type","This type and subtypes", "Cancel")))
+ switch(alert("Strict object type detection?", "Type detection", "Strictly this type","This type and subtypes", "Cancel"))
if("Strictly this type")
return FALSE
if("This type and subtypes")
@@ -97,7 +97,7 @@ GLOBAL_PROTECT(VVpixelmovement)
L += var_value
- switch(tgui_alert(src, "Would you like to associate a value with the list entry?",,list("Yes","No")))
+ switch(alert("Would you like to associate a value with the list entry?",,"Yes","No"))
if("Yes")
L[var_value] = mod_list_add_ass(O) //hehe
if (O)
@@ -116,7 +116,7 @@ GLOBAL_PROTECT(VVpixelmovement)
return
if(L.len > 1000)
- var/confirm = tgui_alert(src, "The list you're trying to edit is very long, continuing may crash the server.", "Warning", list("Continue", "Abort"))
+ var/confirm = alert(src, "The list you're trying to edit is very long, continuing may crash the server.", "Warning", "Continue", "Abort")
if(confirm != "Continue")
return
@@ -131,7 +131,7 @@ GLOBAL_PROTECT(VVpixelmovement)
value = "null"
names["#[i] [key] = [value]"] = i
if (!index)
- var/variable = tgui_input_list(src, "Which var?","Var",names + "(ADD VAR)" + "(CLEAR NULLS)" + "(CLEAR DUPES)" + "(SHUFFLE)")
+ var/variable = input("Which var?","Var") as null|anything in names + "(ADD VAR)" + "(CLEAR NULLS)" + "(CLEAR DUPES)" + "(SHUFFLE)"
if(variable == null)
return
@@ -178,7 +178,7 @@ GLOBAL_PROTECT(VVpixelmovement)
if (index == null)
return
var/assoc = 0
- var/prompt = tgui_alert(src, "Do you want to edit the key or its assigned value?", "Associated List", list("Key", "Assigned Value", "Cancel"))
+ var/prompt = alert(src, "Do you want to edit the key or its assigned value?", "Associated List", "Key", "Assigned Value", "Cancel")
if (prompt == "Cancel")
return
if (prompt == "Assigned Value")
@@ -308,7 +308,7 @@ GLOBAL_PROTECT(VVpixelmovement)
names = sortList(names)
- variable = tgui_input_list(src, "Which var?","Var",names)
+ variable = input("Which var?","Var") as null|anything in names
if(!variable)
return
diff --git a/code/modules/admin/view_variables/topic.dm b/code/modules/admin/view_variables/topic.dm
index e4f289ec21..c32b7a9ad7 100644
--- a/code/modules/admin/view_variables/topic.dm
+++ b/code/modules/admin/view_variables/topic.dm
@@ -32,7 +32,7 @@
// If the new name is something that would be restricted by IC chat filters,
// give the admin a warning but allow them to do it anyway if they want.
- // if(CHAT_FILTER_CHECK(new_name) && tgui_alert(usr, "Your selected name contains words restricted by IC chat filters. Confirm this new name?", "IC Chat Filter Conflict", list("Confirm", "Cancel")) == "Cancel")
+ // if(CHAT_FILTER_CHECK(new_name) && alert(usr, "Your selected name contains words restricted by IC chat filters. Confirm this new name?", "IC Chat Filter Conflict", "Confirm", "Cancel") == "Cancel")
// return
if( !new_name || !M )
@@ -69,7 +69,7 @@
to_chat(usr, "This can only be done to instances of type /mob/living/carbon/monkey", confidential = TRUE)
return
- if(tgui_alert(usr, "Confirm mob type change?",,list("Transform","Cancel")) != "Transform")
+ if(alert("Confirm mob type change?",,"Transform","Cancel") != "Transform")
return
if(!Mo)
to_chat(usr, "Mob doesn't exist anymore", confidential = TRUE)
@@ -86,7 +86,7 @@
var/Text = href_list["adjustDamage"]
- var/amount = tgui_input_num(usr, "Deal how much damage to mob? (Negative values here heal)","Adjust [Text]loss",0)
+ var/amount = input("Deal how much damage to mob? (Negative values here heal)","Adjust [Text]loss",0) as num|null
if (isnull(amount))
return
diff --git a/code/modules/admin/view_variables/topic_basic.dm b/code/modules/admin/view_variables/topic_basic.dm
index f8c1b6174e..043c50173d 100644
--- a/code/modules/admin/view_variables/topic_basic.dm
+++ b/code/modules/admin/view_variables/topic_basic.dm
@@ -68,7 +68,7 @@
names += componentsubtypes
names += "---Elements---"
names += sortList(subtypesof(/datum/element), /proc/cmp_typepaths_asc)
- var/result = tgui_input_list(usr, "Choose a component/element to add","better know what ur fuckin doin pal",names)
+ var/result = input(usr, "Choose a component/element to add","better know what ur fuckin doin pal") as null|anything in names
if(!usr || !result || result == "---Components---" || result == "---Elements---")
return
if(QDELETED(src))
diff --git a/code/modules/admin/view_variables/topic_list.dm b/code/modules/admin/view_variables/topic_list.dm
index 9351f58152..349d9da698 100644
--- a/code/modules/admin/view_variables/topic_list.dm
+++ b/code/modules/admin/view_variables/topic_list.dm
@@ -9,7 +9,7 @@
mod_list(target, null, "list", "contents", target_index, autodetect_class = FALSE)
if(href_list[VV_HK_LIST_REMOVE])
var/variable = target[target_index]
- var/prompt = tgui_alert(src, "Do you want to remove item number [target_index] from list?", "Confirm", list("Yes", "No"))
+ var/prompt = alert("Do you want to remove item number [target_index] from list?", "Confirm", "Yes", "No")
if (prompt != "Yes")
return
target.Cut(target_index, target_index+1)
diff --git a/code/modules/antagonists/abductor/abductor.dm b/code/modules/antagonists/abductor/abductor.dm
index 4285e383c3..7eb7ec2af2 100644
--- a/code/modules/antagonists/abductor/abductor.dm
+++ b/code/modules/antagonists/abductor/abductor.dm
@@ -99,7 +99,7 @@
var/list/current_teams = list()
for(var/datum/team/abductor_team/T in get_all_teams(/datum/team/abductor_team))
current_teams[T.name] = T
- var/choice = tgui_input_list(admin,"Add to which team ?", "", current_teams + "new team")
+ var/choice = input(admin,"Add to which team ?") as null|anything in (current_teams + "new team")
if (choice == "new team")
team = new
else if(choice in current_teams)
@@ -119,7 +119,7 @@
to_chat(admin, "This only works on humans!")
return
var/mob/living/carbon/human/H = owner.current
- var/gear = tgui_alert(admin, "Agent or Scientist Gear","Gear",list("Agent","Scientist"))
+ var/gear = alert(admin,"Agent or Scientist Gear","Gear","Agent","Scientist")
if(gear)
if(gear=="Agent")
H.equipOutfit(/datum/outfit/abductor/agent)
diff --git a/code/modules/antagonists/blob/blob/blobs/core.dm b/code/modules/antagonists/blob/blob/blobs/core.dm
index 38484c70b0..ef7c01a781 100644
--- a/code/modules/antagonists/blob/blob/blobs/core.dm
+++ b/code/modules/antagonists/blob/blob/blobs/core.dm
@@ -45,7 +45,7 @@
GLOB.poi_list -= src
return ..()
-/obj/structure/blob/core/ex_act(severity, target)
+/obj/structure/blob/core/ex_act(severity, target, origin)
var/damage = 50 - 10 * severity //remember, the core takes half brute damage, so this is 20/15/10 damage based on severity
take_damage(damage, BRUTE, "bomb", 0)
diff --git a/code/modules/antagonists/blob/blob/powers.dm b/code/modules/antagonists/blob/blob/powers.dm
index f26a0e0002..9256d0d16b 100644
--- a/code/modules/antagonists/blob/blob/powers.dm
+++ b/code/modules/antagonists/blob/blob/powers.dm
@@ -72,7 +72,7 @@
for(var/i in 1 to GLOB.blob_nodes.len)
var/obj/structure/blob/node/B = GLOB.blob_nodes[i]
nodes["Blob Node #[i] ([get_area_name(B)])"] = B
- var/node_name = tgui_input_list(src, "Choose a node to jump to.", "Node Jump", nodes)
+ var/node_name = input(src, "Choose a node to jump to.", "Node Jump") in nodes
var/obj/structure/blob/node/chosen_node = nodes[node_name]
if(chosen_node)
forceMove(chosen_node.loc)
@@ -352,7 +352,7 @@
var/datum/blobstrain/bs = pick((GLOB.valid_blobstrains))
choices[initial(bs.name)] = bs
- var/choice = tgui_input_list(usr, "Please choose a new strain","Strain", choices)
+ var/choice = input(usr, "Please choose a new strain","Strain") as anything in choices
if (choice && choices[choice] && !QDELETED(src))
var/datum/blobstrain/bs = choices[choice]
set_strain(bs)
diff --git a/code/modules/antagonists/bloodsucker/datum_bloodsucker.dm b/code/modules/antagonists/bloodsucker/datum_bloodsucker.dm
index 27f33ce546..07c92bfd97 100644
--- a/code/modules/antagonists/bloodsucker/datum_bloodsucker.dm
+++ b/code/modules/antagonists/bloodsucker/datum_bloodsucker.dm
@@ -289,7 +289,7 @@
options["\[ Not Now \]"] = null
// Abort?
if(options.len > 1)
- var/choice = tgui_input_list(owner.current, "You have the opportunity to grow more ancient at the cost of [level_bloodcost] units of blood. Select a power to advance your Rank.", "Your Blood Thickens...", options)
+ var/choice = input(owner.current, "You have the opportunity to grow more ancient at the cost of [level_bloodcost] units of blood. Select a power to advance your Rank.", "Your Blood Thickens...") in options
// Cheat-Safety: Can't keep opening/closing coffin to spam levels
if(bloodsucker_level_unspent <= 0) // Already spent all your points, and tried opening/closing your coffin, pal.
return
diff --git a/code/modules/antagonists/bloodsucker/objects/bloodsucker_coffin.dm b/code/modules/antagonists/bloodsucker/objects/bloodsucker_coffin.dm
index d93ae9ed2b..881da8f282 100644
--- a/code/modules/antagonists/bloodsucker/objects/bloodsucker_coffin.dm
+++ b/code/modules/antagonists/bloodsucker/objects/bloodsucker_coffin.dm
@@ -143,7 +143,7 @@
A = get_area(src)
// Claim?
if(!bloodsuckerdatum.coffin && !resident && (is_station_level(Turf.z) || !A.map_name == "Space"))
- switch(tgui_alert(user, "Do you wish to claim this as your coffin? [get_area(src)] will be your lair.","Claim Lair",list("Yes", "No")))
+ switch(alert(user,"Do you wish to claim this as your coffin? [get_area(src)] will be your lair.","Claim Lair","Yes", "No"))
if("Yes")
ClaimCoffin(user)
if (user.AmStaked()) // Stake? No Heal!
diff --git a/code/modules/antagonists/bloodsucker/objects/bloodsucker_crypt.dm b/code/modules/antagonists/bloodsucker/objects/bloodsucker_crypt.dm
index c0c500e619..e8fb82a5d1 100644
--- a/code/modules/antagonists/bloodsucker/objects/bloodsucker_crypt.dm
+++ b/code/modules/antagonists/bloodsucker/objects/bloodsucker_crypt.dm
@@ -232,7 +232,7 @@
if(B.lair != get_area(src))
to_chat(user, "You may only activate this structure in your lair: [B.lair].")
return
- switch(tgui_alert(user, "Do you wish to afix this structure here? Be aware you wont be able to unsecure it anymore", "Secure [src]", list("Yes", "No")))
+ switch(alert(user,"Do you wish to afix this structure here? Be aware you wont be able to unsecure it anymore", "Secure [src]", "Yes", "No"))
if("Yes")
owner = user
density = FALSE
@@ -398,7 +398,7 @@
alert_text += "\n\nYou will no longer be loyal to the station!"
if(SSticker.mode.AmValidAntag(target.mind)) */
alert_text += "\n\nYou will not lose your current objectives, but they come second to the will of your new master!"
- switch(tgui_alert(target, alert_text,"THE HORRIBLE PAIN! WHEN WILL IT END?!",list("Yes, Master!", "NEVER!")))
+ switch(alert(target, alert_text,"THE HORRIBLE PAIN! WHEN WILL IT END?!","Yes, Master!", "NEVER!"))
if("Yes, Master!")
disloyalty_accept(target)
else
diff --git a/code/modules/antagonists/brainwashing/brainwashing.dm b/code/modules/antagonists/brainwashing/brainwashing.dm
index 0bcdd980bf..491ee9d2e5 100644
--- a/code/modules/antagonists/brainwashing/brainwashing.dm
+++ b/code/modules/antagonists/brainwashing/brainwashing.dm
@@ -54,9 +54,9 @@
var/objective = stripped_input(admin, "Add an objective, or leave empty to finish.", "Brainwashing", null, MAX_MESSAGE_LEN)
if(objective)
objectives += objective
- while(tgui_alert(admin, "Add another objective?","More Brainwashing",list("Yes","No")) == "Yes")
+ while(alert(admin,"Add another objective?","More Brainwashing","Yes","No") == "Yes")
- if(tgui_alert(admin, "Confirm Brainwashing?","Are you sure?",list("Yes","No")) == "No")
+ if(alert(admin,"Confirm Brainwashing?","Are you sure?","Yes","No") == "No")
return
if(!LAZYLEN(objectives))
diff --git a/code/modules/antagonists/brother/brother.dm b/code/modules/antagonists/brother/brother.dm
index 8a5f23ae58..30e6a80e85 100644
--- a/code/modules/antagonists/brother/brother.dm
+++ b/code/modules/antagonists/brother/brother.dm
@@ -63,7 +63,7 @@
continue
candidates[L.mind.name] = L.mind
- var/choice = tgui_input_list(admin,"Choose the blood brother.", "Brother", candidates)
+ var/choice = input(admin,"Choose the blood brother.", "Brother") as null|anything in candidates
if(!choice)
return
var/datum/mind/bro = candidates[choice]
diff --git a/code/modules/antagonists/changeling/powers/fakedeath.dm b/code/modules/antagonists/changeling/powers/fakedeath.dm
index 0bbbeefbd3..08dc85efbf 100644
--- a/code/modules/antagonists/changeling/powers/fakedeath.dm
+++ b/code/modules/antagonists/changeling/powers/fakedeath.dm
@@ -36,7 +36,7 @@
to_chat(user, "We are already reviving.")
return
if(!user.stat) //Confirmation for living changelings if they want to fake their death
- switch(tgui_alert(user, "Are we sure we wish to fake our own death?",,list("Yes", "No")))
+ switch(alert("Are we sure we wish to fake our own death?",,"Yes", "No"))
if("No")
return
return ..()
diff --git a/code/modules/antagonists/changeling/powers/headcrab.dm b/code/modules/antagonists/changeling/powers/headcrab.dm
index c88790b800..867f160081 100644
--- a/code/modules/antagonists/changeling/powers/headcrab.dm
+++ b/code/modules/antagonists/changeling/powers/headcrab.dm
@@ -12,7 +12,7 @@
/obj/effect/proc_holder/changeling/headcrab/sting_action(mob/user)
set waitfor = FALSE
- if(tgui_alert(user, "Are we sure we wish to kill ourself and create a headslug?",,list("Yes", "No")) == "No")
+ if(alert("Are we sure we wish to kill ourself and create a headslug?",,"Yes", "No") == "No")
return
var/datum/mind/M = user.mind
var/list/organs = user.getorganszone(BODY_ZONE_HEAD, 1)
diff --git a/code/modules/antagonists/changeling/powers/hivemind.dm b/code/modules/antagonists/changeling/powers/hivemind.dm
index a342ae7b32..f7718d7708 100644
--- a/code/modules/antagonists/changeling/powers/hivemind.dm
+++ b/code/modules/antagonists/changeling/powers/hivemind.dm
@@ -60,7 +60,7 @@ GLOBAL_LIST_EMPTY(hivemind_bank)
to_chat(user, "The airwaves already have all of our DNA.")
return
- var/chosen_name = tgui_input_list(user, "Select a DNA to channel: ", "Channel DNA", names)
+ var/chosen_name = input("Select a DNA to channel: ", "Channel DNA", null) as null|anything in names
if(!chosen_name)
return
@@ -107,7 +107,7 @@ GLOBAL_LIST_EMPTY(hivemind_bank)
to_chat(user, "There's no new DNA to absorb from the air.")
return
- var/S = tgui_input_list(user, "Select a DNA absorb from the air: ", "Absorb DNA", names)
+ var/S = input("Select a DNA absorb from the air: ", "Absorb DNA", null) as null|anything in names
if(!S)
return
var/datum/changelingprofile/chosen_prof = names[S]
diff --git a/code/modules/antagonists/clockcult/clock_effects/clock_overlay.dm b/code/modules/antagonists/clockcult/clock_effects/clock_overlay.dm
index 97d2935a86..7e2fd1e11c 100644
--- a/code/modules/antagonists/clockcult/clock_effects/clock_overlay.dm
+++ b/code/modules/antagonists/clockcult/clock_effects/clock_overlay.dm
@@ -8,7 +8,7 @@
linked.examine(user)
return ..()
-/obj/effect/clockwork/overlay/ex_act()
+/obj/effect/clockwork/overlay/ex_act(severity, target, origin)
return FALSE
/obj/effect/clockwork/overlay/singularity_act()
diff --git a/code/modules/antagonists/clockcult/clock_effects/clock_sigils.dm b/code/modules/antagonists/clockcult/clock_effects/clock_sigils.dm
index a4cbdaa08f..d7facb7f2d 100644
--- a/code/modules/antagonists/clockcult/clock_effects/clock_sigils.dm
+++ b/code/modules/antagonists/clockcult/clock_effects/clock_sigils.dm
@@ -36,7 +36,7 @@
return TRUE
. = ..()
-/obj/effect/clockwork/sigil/ex_act(severity)
+/obj/effect/clockwork/sigil/ex_act(severity, target, origin)
visible_message("[src] scatters into thousands of particles.")
qdel(src)
@@ -204,7 +204,7 @@
. = ..()
update_icon()
-/obj/effect/clockwork/sigil/transmission/ex_act(severity)
+/obj/effect/clockwork/sigil/transmission/ex_act(severity, target, origin)
if(severity == 3)
adjust_clockwork_power(500) //Light explosions charge the network!
visible_message("[src] flares a brilliant orange!")
@@ -459,13 +459,13 @@
for(var/datum/clockwork_rite/R in GLOB.all_clockwork_rites)
if(is_servant_of_ratvar(user, require_full_power = TRUE) || !R.requires_full_power)
possible_rites[R] = R
- var/input_key = tgui_input_list(user, "Choose a rite", "Choosing a rite", possible_rites)
+ var/input_key = input(user, "Choose a rite", "Choosing a rite") as null|anything in possible_rites
if(!input_key)
return
var/datum/clockwork_rite/CR = possible_rites[input_key]
if(!CR)
return
- var/choice = tgui_alert(user, "What to do with this rite?", "What to do?", list("Cast", "Show Info", "Cancel"))
+ var/choice = alert(user, "What to do with this rite?", "What to do?", "Cast", "Show Info", "Cancel")
switch(choice)
if("Cast")
CR.try_cast(src, user)
diff --git a/code/modules/antagonists/clockcult/clock_effects/servant_blocker.dm b/code/modules/antagonists/clockcult/clock_effects/servant_blocker.dm
index ce6e315cd8..6fc2bde9d8 100644
--- a/code/modules/antagonists/clockcult/clock_effects/servant_blocker.dm
+++ b/code/modules/antagonists/clockcult/clock_effects/servant_blocker.dm
@@ -38,7 +38,7 @@
/obj/effect/clockwork/servant_blocker/singularity_pull()
return
-/obj/effect/clockwork/servant_blocker/ex_act(severity, target)
+/obj/effect/clockwork/servant_blocker/ex_act(severity, target, origin)
return
/obj/effect/clockwork/servant_blocker/safe_throw_at()
diff --git a/code/modules/antagonists/clockcult/clock_effects/spatial_gateway.dm b/code/modules/antagonists/clockcult/clock_effects/spatial_gateway.dm
index e4fe9e8c9d..f2aa443f82 100644
--- a/code/modules/antagonists/clockcult/clock_effects/spatial_gateway.dm
+++ b/code/modules/antagonists/clockcult/clock_effects/spatial_gateway.dm
@@ -102,7 +102,7 @@
return TRUE
return ..()
-/obj/effect/clockwork/spatial_gateway/ex_act(severity)
+/obj/effect/clockwork/spatial_gateway/ex_act(severity, target, origin)
if(severity == 1 && uses)
uses = 0
visible_message("[src] is disrupted!")
@@ -187,7 +187,7 @@
if(!possible_targets.len)
to_chat(invoker, "There are no other eligible targets for a Spatial Gateway!")
return FALSE
- var/input_target_key = tgui_input_list(invoker, "Choose a target to form a rift to.", "Spatial Gateway", possible_targets)
+ var/input_target_key = input(invoker, "Choose a target to form a rift to.", "Spatial Gateway") as null|anything in possible_targets
var/atom/movable/target = possible_targets[input_target_key]
if(!src || !input_target_key || !invoker || !invoker.canUseTopic(src, !issilicon(invoker)) || !is_servant_of_ratvar(invoker) || (isitem(src) && invoker.get_active_held_item() != src) || !invoker.can_speak_vocal())
return FALSE //if any of the involved things no longer exist, the invoker is stunned, too far away to use the object, or does not serve ratvar, or if the object is an item and not in the mob's active hand, fail
@@ -251,7 +251,7 @@
name = "stable gateway"
is_stable = TRUE
-/obj/effect/clockwork/spatial_gateway/stable/ex_act(severity)
+/obj/effect/clockwork/spatial_gateway/stable/ex_act(severity, target, origin)
if(severity == 1)
start_shutdown() //Yes, you can chain devastation-level explosions to delay a gateway shutdown, if you somehow manage to do it without breaking the obelisk. Is it worth it? Probably not.
return TRUE
diff --git a/code/modules/antagonists/clockcult/clock_items/clockwork_slab.dm b/code/modules/antagonists/clockcult/clock_items/clockwork_slab.dm
index 77b81ee536..8060b7b0cd 100644
--- a/code/modules/antagonists/clockcult/clock_items/clockwork_slab.dm
+++ b/code/modules/antagonists/clockcult/clock_items/clockwork_slab.dm
@@ -371,7 +371,7 @@
update_quickbind()
else
// todo: async this due to ((input)) but its fine for now
- var/target_index = tgui_input_num(usr, "Position of [initial(path.name)], 1 to [maximum_quickbound]?", "Input")
+ var/target_index = input("Position of [initial(path.name)], 1 to [maximum_quickbound]?", "Input") as num|null
if(isnum(target_index) && target_index > 0 && target_index <= maximum_quickbound && !..())
var/datum/clockwork_scripture/S
if(LAZYLEN(quickbound) >= target_index)
diff --git a/code/modules/antagonists/clockcult/clock_items/construct_chassis.dm b/code/modules/antagonists/clockcult/clock_items/construct_chassis.dm
index eba7c4be72..daee9f5c2c 100644
--- a/code/modules/antagonists/clockcult/clock_items/construct_chassis.dm
+++ b/code/modules/antagonists/clockcult/clock_items/construct_chassis.dm
@@ -48,7 +48,7 @@
to_chat(user, "You were too late! Better luck next time.")
return
user.forceMove(get_turf(src)) //If we attack through the alert, jump to the chassis so we know what we're getting into
- if(tgui_alert(user, "Become a [construct_name]? You can no longer be cloned!", construct_name, list("Yes", "Cancel")) == "Cancel")
+ if(alert(user, "Become a [construct_name]? You can no longer be cloned!", construct_name, "Yes", "Cancel") == "Cancel")
return
if(QDELETED(src))
to_chat(user, "You were too late! Better luck next time.")
diff --git a/code/modules/antagonists/clockcult/clock_items/judicial_visor.dm b/code/modules/antagonists/clockcult/clock_items/judicial_visor.dm
index 6a53097922..e748da8765 100644
--- a/code/modules/antagonists/clockcult/clock_items/judicial_visor.dm
+++ b/code/modules/antagonists/clockcult/clock_items/judicial_visor.dm
@@ -214,5 +214,5 @@
sleep(3) //so the animation completes properly
qdel(src)
-/obj/effect/clockwork/judicial_marker/ex_act(severity)
+/obj/effect/clockwork/judicial_marker/ex_act(severity, target, origin)
return
diff --git a/code/modules/antagonists/clockcult/clock_mobs/_eminence.dm b/code/modules/antagonists/clockcult/clock_mobs/_eminence.dm
index faea34b53e..e7aeb7e796 100644
--- a/code/modules/antagonists/clockcult/clock_mobs/_eminence.dm
+++ b/code/modules/antagonists/clockcult/clock_mobs/_eminence.dm
@@ -131,7 +131,7 @@
if(!G.recalls_remaining)
to_chat(src, "The Ark can no longer recall!")
return
- if(tgui_alert(src, "Initiate mass recall?", "Mass Recall", list("Yes", "No")) != "Yes" || QDELETED(src) || QDELETED(G) || !G.obj_integrity)
+ if(alert(src, "Initiate mass recall?", "Mass Recall", "Yes", "No") != "Yes" || QDELETED(src) || QDELETED(G) || !G.obj_integrity)
return
G.initiate_mass_recall() //wHOOPS LOOKS LIKE A HULK GOT THROUGH
@@ -156,7 +156,7 @@
commands += "Power This Structure"
if(P.obj_integrity < P.max_integrity)
commands += "Repair This Structure"
- var/roma_invicta = tgui_input_list(src, "Choose a command to issue to your cult!", "Issue Commands", commands)
+ var/roma_invicta = input(src, "Choose a command to issue to your cult!", "Issue Commands") as null|anything in commands
if(!roma_invicta)
return
var/command_text = ""
@@ -290,7 +290,7 @@
to_chat(owner, "There are no Obelisks to warp to!")
return
- var/target_key = tgui_input_list(owner, "Choose an Obelisk to warp to.", "Obelisk Warp", possible_targets)
+ var/target_key = input(owner, "Choose an Obelisk to warp to.", "Obelisk Warp") as null|anything in possible_targets
var/obj/structure/destructible/clockwork/powered/clockwork_obelisk/target = possible_targets[target_key]
if(!target_key || !owner)
@@ -334,6 +334,6 @@
/datum/action/innate/eminence/mass_recall/Activate()
var/obj/structure/destructible/clockwork/massive/celestial_gateway/G = GLOB.ark_of_the_clockwork_justiciar
if(G && !G.recalling && G.recalls_remaining)
- if(tgui_alert(owner, "Initiate mass recall?", "Mass Recall", list("Yes", "No")) != "Yes" || QDELETED(owner) || QDELETED(G) || !G.obj_integrity)
+ if(alert(owner, "Initiate mass recall?", "Mass Recall", "Yes", "No") != "Yes" || QDELETED(owner) || QDELETED(G) || !G.obj_integrity)
return
G.initiate_mass_recall()
diff --git a/code/modules/antagonists/clockcult/clock_scripture.dm b/code/modules/antagonists/clockcult/clock_scripture.dm
index 17d03c020f..6922c7cd81 100644
--- a/code/modules/antagonists/clockcult/clock_scripture.dm
+++ b/code/modules/antagonists/clockcult/clock_scripture.dm
@@ -276,7 +276,7 @@ Judgement 80k power or nine converts
return
var/obj/structure/destructible/clockwork/massive/celestial_gateway/G = GLOB.ark_of_the_clockwork_justiciar
if(G && !G.active && combat_construct && is_reebe(invoker.z) && !confirmed) //Putting marauders on the base during the prep phase is a bad idea mmkay
- if(tgui_alert(invoker, "This is a combat construct, and you cannot easily get it to the station. Are you sure you want to make one here?", "Construct Alert", list("Yes", "Cancel")) == "Cancel")
+ if(alert(invoker, "This is a combat construct, and you cannot easily get it to the station. Are you sure you want to make one here?", "Construct Alert", "Yes", "Cancel") == "Cancel")
return
if(!is_servant_of_ratvar(invoker) || !invoker.canUseTopic(slab))
return
diff --git a/code/modules/antagonists/clockcult/clock_scriptures/scripture_applications.dm b/code/modules/antagonists/clockcult/clock_scriptures/scripture_applications.dm
index 85450dc152..e251fb41e9 100644
--- a/code/modules/antagonists/clockcult/clock_scriptures/scripture_applications.dm
+++ b/code/modules/antagonists/clockcult/clock_scriptures/scripture_applications.dm
@@ -231,3 +231,31 @@
to_chat(invoker, "\"Only one of my weapons may exist in this temporal stream!\"")
return FALSE
return ..()
+
+/datum/clockwork_scripture/create_object/construct/cogscarab
+ descname = "Building Construct"
+ name = "Cogscarab"
+ desc = "Creates a shell for a cogscarab, a drone that helps build your base!"
+ invocations = list("Arise, drone!", "Create defenses for the true light!")
+ channel_time = 80
+ power_cost = 8000
+ creator_message = "Your slab disgorges several chunks of replicant alloy that form into a spiderlike shell."
+ usage_tip = "These machines will help you get a base built up while you go out to look for more followers."
+ tier = SCRIPTURE_APPLICATION
+ one_per_tile = TRUE
+ primary_component = BELLIGERENT_EYE
+ sort_priority = 9
+ quickbind = TRUE
+ quickbind_desc = "Creates a cogscarab, good for the backline."
+ object_path = /obj/item/clockwork/construct_chassis/cogscarab/
+ construct_type = /mob/living/simple_animal/drone/cogscarab
+ combat_construct = FALSE
+
+/datum/clockwork_scripture/create_object/construct/cogscarab/update_construct_limit()
+ var/human_servants = 0
+ for(var/V in SSticker.mode.servants_of_ratvar)
+ var/datum/mind/M = V
+ var/mob/living/L = M.current
+ if(ishuman(L) && L.stat != DEAD)
+ human_servants++
+ construct_limit = round(clamp((human_servants / 4), 1, 3)) //1 per 4 human servants, maximum of 3
diff --git a/code/modules/antagonists/clockcult/clock_structures/ark_of_the_clockwork_justicar.dm b/code/modules/antagonists/clockcult/clock_structures/ark_of_the_clockwork_justicar.dm
index 9d0adfdba8..2391658613 100644
--- a/code/modules/antagonists/clockcult/clock_structures/ark_of_the_clockwork_justicar.dm
+++ b/code/modules/antagonists/clockcult/clock_structures/ark_of_the_clockwork_justicar.dm
@@ -42,7 +42,7 @@
/obj/structure/destructible/clockwork/massive/celestial_gateway/on_attack_hand(mob/user, act_intent, unarmed_attack_flags)
if(!active && is_servant_of_ratvar(user) && user.canUseTopic(src, !issilicon(user), NO_DEXTERY))
- if(tgui_alert(user, "Are you sure you want to activate the ark? Once enabled, there will be no turning back.", "Enabling the ark", list("Activate!", "Cancel")) == "Activate!")
+ if(alert(user, "Are you sure you want to activate the ark? Once enabled, there will be no turning back.", "Enabling the ark", "Activate!", "Cancel") == "Activate!")
if(active)
return
log_game("[key_name(user)] has activated an Ark of the Clockwork Justicar at [COORD(src)].")
@@ -197,7 +197,7 @@
glow = new /obj/effect/clockwork/overlay/gateway_glow(get_turf(src))
glow.linked = src
-/obj/structure/destructible/clockwork/massive/celestial_gateway/ex_act(severity)
+/obj/structure/destructible/clockwork/massive/celestial_gateway/ex_act(severity, target, origin)
var/damage = max((obj_integrity * 0.7) / severity, 100) //requires multiple bombs to take down
take_damage(damage, BRUTE, "bomb", 0)
@@ -356,9 +356,9 @@
if(GLOB.servants_active)
to_chat(user, "The Ark is already counting down.")
return ..()
- if(tgui_alert(user, "Activate the Ark's countdown?", name, list("Yes", "No")) == "Yes")
- if(tgui_alert(user, "REALLY activate the Ark's countdown?", name, list("Yes", "No")) == "Yes")
- if(tgui_alert(user, "You're REALLY SURE? This cannot be undone.", name, list("Yes - Activate the Ark", "No")) == "Yes - Activate the Ark")
+ if(alert(user, "Activate the Ark's countdown?", name, "Yes", "No") == "Yes")
+ if(alert(user, "REALLY activate the Ark's countdown?", name, "Yes", "No") == "Yes")
+ if(alert(user, "You're REALLY SURE? This cannot be undone.", name, "Yes - Activate the Ark", "No") == "Yes - Activate the Ark")
message_admins("Admin [key_name_admin(user)] started the Ark's countdown!")
log_admin("Admin [key_name(user)] started the Ark's countdown on a non-clockcult mode!")
to_chat(user, "The gamemode is now being treated as clockwork cult, and the Ark is counting down from 5 \
diff --git a/code/modules/antagonists/clockcult/clock_structures/clockwork_obelisk.dm b/code/modules/antagonists/clockcult/clock_structures/clockwork_obelisk.dm
index cef6e70ec3..2b4b797b4d 100644
--- a/code/modules/antagonists/clockcult/clock_structures/clockwork_obelisk.dm
+++ b/code/modules/antagonists/clockcult/clock_structures/clockwork_obelisk.dm
@@ -53,7 +53,7 @@
if(!is_servant_of_ratvar(user) || !can_access_clockwork_power(src, hierophant_cost) || !anchored)
to_chat(user, "You place your hand on [src], but it doesn't react.")
return
- var/choice = tgui_alert(user, "You place your hand on [src]...",,list("Hierophant Broadcast","Spatial Gateway","Cancel")) //Will create a stable gateway instead if between two obelisks one of which is onstation and the other on reebe
+ var/choice = alert(user,"You place your hand on [src]...",,"Hierophant Broadcast","Spatial Gateway","Cancel") //Will create a stable gateway instead if between two obelisks one of which is onstation and the other on reebe
switch(choice)
if("Hierophant Broadcast")
if(active)
diff --git a/code/modules/antagonists/clockcult/clock_structures/eminence_spire.dm b/code/modules/antagonists/clockcult/clock_structures/eminence_spire.dm
index de7dfabbd0..5302153b9c 100644
--- a/code/modules/antagonists/clockcult/clock_structures/eminence_spire.dm
+++ b/code/modules/antagonists/clockcult/clock_structures/eminence_spire.dm
@@ -56,7 +56,7 @@
if(!GLOB.servants_active)
to_chat(user, "The Ark must be active first!")
return
- if(tgui_alert(user, "Become the Eminence using admin?", "Become Eminence", list("Yes", "No")) != "Yes")
+ if(alert(user, "Become the Eminence using admin?", "Become Eminence", "Yes", "No") != "Yes")
return
message_admins("Admin [key_name_admin(user)] directly became the Eminence of the cult!")
log_admin("Admin [key_name(user)] made themselves the Eminence.")
@@ -67,7 +67,7 @@
M.playsound_local(M, 'sound/machines/clockcult/eminence_selected.ogg', 50, FALSE)
/obj/structure/destructible/clockwork/eminence_spire/proc/nomination(mob/living/nominee) //A user is nominating themselves or ghosts to become Eminence
- var/nomination_choice = tgui_alert(nominee, "Who would you like to nominate?", "Eminence Nomination", list("Nominate Yourself", "Nominate Ghosts", "Cancel"))
+ var/nomination_choice = alert(nominee, "Who would you like to nominate?", "Eminence Nomination", "Nominate Yourself", "Nominate Ghosts", "Cancel")
if(!is_servant_of_ratvar(nominee) || !nominee.canUseTopic(src) || eminence_nominee)
return
switch(nomination_choice)
@@ -84,7 +84,7 @@
selection_timer = addtimer(CALLBACK(src, .proc/kingmaker), 300, TIMER_STOPPABLE)
/obj/structure/destructible/clockwork/eminence_spire/proc/objection(mob/living/wright)
- if(tgui_alert(wright, "Object to the selection of [eminence_nominee] as Eminence?", "Objection!", list("Object", "Cancel")) == "Cancel" || !is_servant_of_ratvar(wright) || !wright.canUseTopic(src) || !eminence_nominee)
+ if(alert(wright, "Object to the selection of [eminence_nominee] as Eminence?", "Objection!", "Object", "Cancel") == "Cancel" || !is_servant_of_ratvar(wright) || !wright.canUseTopic(src) || !eminence_nominee)
return
hierophant_message("[wright] objects to the nomination of [eminence_nominee]! The eminence spire has been reset.")
for(var/mob/M in servants_and_ghosts())
@@ -93,7 +93,7 @@
deltimer(selection_timer)
/obj/structure/destructible/clockwork/eminence_spire/proc/cancelation(mob/living/cold_feet)
- if(tgui_alert(cold_feet, "Cancel your nomination?", "Cancel Nomination", list("Withdraw Nomination", "Cancel")) == "Cancel" || !is_servant_of_ratvar(cold_feet) || !cold_feet.canUseTopic(src) || !eminence_nominee)
+ if(alert(cold_feet, "Cancel your nomination?", "Cancel Nomination", "Withdraw Nomination", "Cancel") == "Cancel" || !is_servant_of_ratvar(cold_feet) || !cold_feet.canUseTopic(src) || !eminence_nominee)
return
hierophant_message("[eminence_nominee] has withdrawn their nomination! The eminence spire has been reset.")
for(var/mob/M in servants_and_ghosts())
diff --git a/code/modules/antagonists/clockcult/clock_structures/heralds_beacon.dm b/code/modules/antagonists/clockcult/clock_structures/heralds_beacon.dm
index 76220702c0..f8a3afbf91 100644
--- a/code/modules/antagonists/clockcult/clock_structures/heralds_beacon.dm
+++ b/code/modules/antagonists/clockcult/clock_structures/heralds_beacon.dm
@@ -71,7 +71,7 @@
to_chat(user, "You can no longer vote with [src].")
return
var/voting = !(user.key in voters)
- if(tgui_alert(user, "[voting ? "Cast a" : "Undo your"] vote to activate the beacon?", "Herald's Beacon", list("Change Vote", "Cancel")) == "Cancel")
+ if(alert(user, "[voting ? "Cast a" : "Undo your"] vote to activate the beacon?", "Herald's Beacon", "Change Vote", "Cancel") == "Cancel")
return
if(!user.canUseTopic(src) || !is_servant_of_ratvar(user) || !available)
return
diff --git a/code/modules/antagonists/clockcult/clock_structures/ratvar_the_clockwork_justicar.dm b/code/modules/antagonists/clockcult/clock_structures/ratvar_the_clockwork_justicar.dm
index b08b90bbfa..51f8dc7101 100644
--- a/code/modules/antagonists/clockcult/clock_structures/ratvar_the_clockwork_justicar.dm
+++ b/code/modules/antagonists/clockcult/clock_structures/ratvar_the_clockwork_justicar.dm
@@ -42,7 +42,7 @@
//ATTACK GHOST IGNORING PARENT RETURN VALUE
/obj/structure/destructible/clockwork/massive/ratvar/attack_ghost(mob/dead/observer/O)
- var/alertresult = tgui_alert(O, "Embrace the Justiciar's light? You can no longer be cloned!",,list("Yes", "No"))
+ var/alertresult = alert(O, "Embrace the Justiciar's light? You can no longer be cloned!",,"Yes", "No")
if(alertresult == "No" || QDELETED(O) || !istype(O) || !O.key)
return FALSE
var/mob/living/simple_animal/drone/cogscarab/ratvar/R = new/mob/living/simple_animal/drone/cogscarab/ratvar(get_turf(src))
diff --git a/code/modules/antagonists/clockcult/clockcult.dm b/code/modules/antagonists/clockcult/clockcult.dm
index 8bf26d6397..0db3f9e6df 100644
--- a/code/modules/antagonists/clockcult/clockcult.dm
+++ b/code/modules/antagonists/clockcult/clockcult.dm
@@ -240,3 +240,18 @@
parts += printplayerlist(members - eminence)
return "
[parts.Join(" ")]
"
+
+//I have no idea where to put this so I'm leaving it here. Loads reebe. Only one reebe can exist, so it's checked via a global var.
+/proc/load_reebe()
+ if(GLOB.reebe_loaded)
+ return TRUE
+ var/list/errorList = list()
+ var/list/reebes = SSmapping.LoadGroup(errorList, "Reebe", "map_files/generic", "City_of_Cogs.dmm", default_traits = ZTRAITS_REEBE, silent = TRUE)
+ if(errorList.len) // reebe failed to load
+ message_admins("Reebe failed to load!")
+ log_game("Reebe failed to load!")
+ return FALSE
+ for(var/datum/parsed_map/PM in reebes)
+ PM.initTemplateBounds()
+ GLOB.reebe_loaded = TRUE
+ return TRUE
diff --git a/code/modules/antagonists/cult/blood_magic.dm b/code/modules/antagonists/cult/blood_magic.dm
index a8fe894eda..9bd1030685 100644
--- a/code/modules/antagonists/cult/blood_magic.dm
+++ b/code/modules/antagonists/cult/blood_magic.dm
@@ -49,7 +49,7 @@
to_chat(owner, "Your body has reached its limit, you cannot store more than [MAX_BLOODCHARGE] spells at once. Pick a spell to nullify.")
else
to_chat(owner, "Your body has reached its limit, you cannot have more than [RUNELESS_MAX_BLOODCHARGE] spells at once without an empowering rune! Pick a spell to nullify.")
- var/nullify_spell = tgui_input_list(owner, "Choose a spell to remove.", "Current Spells", spells)
+ var/nullify_spell = input(owner, "Choose a spell to remove.", "Current Spells") as null|anything in spells
if(nullify_spell)
qdel(nullify_spell)
return
@@ -61,9 +61,9 @@
var/cult_name = initial(J.name)
possible_spells[cult_name] = J
possible_spells += "(REMOVE SPELL)"
- entered_spell_name = tgui_input_list(owner, "Pick a blood spell to prepare...", "Spell Choices", possible_spells)
+ entered_spell_name = input(owner, "Pick a blood spell to prepare...", "Spell Choices") as null|anything in possible_spells
if(entered_spell_name == "(REMOVE SPELL)")
- var/nullify_spell = tgui_input_list(owner, "Choose a spell to remove.", "Current Spells", spells)
+ var/nullify_spell = input(owner, "Choose a spell to remove.", "Current Spells") as null|anything in spells
if(nullify_spell)
qdel(nullify_spell)
return
@@ -192,7 +192,7 @@
magic_path = "/obj/item/melee/blood_magic/armor"
/datum/action/innate/cult/blood_spell/equipment/Activate()
- var/choice = tgui_alert(owner, "Choose your equipment type",,"Combat Equipment",list("Ritual Dagger","Cancel"))
+ var/choice = alert(owner,"Choose your equipment type",,"Combat Equipment","Ritual Dagger","Cancel")
if(choice == "Ritual Dagger")
var/turf/T = get_turf(owner)
owner.visible_message("[owner]'s hand glows red for a moment.", \
@@ -497,7 +497,7 @@
log_game("Teleport spell failed - user in away mission")
return
- var/input_rune_key = tgui_input_list(user, "Choose a rune to teleport to.", "Rune to Teleport to", potential_runes) //we know what key they picked
+ var/input_rune_key = input(user, "Choose a rune to teleport to.", "Rune to Teleport to") as null|anything in potential_runes //we know what key they picked
var/obj/effect/rune/teleport/actual_selected_rune = potential_runes[input_rune_key] //what rune does that key correspond to?
if(QDELETED(src) || !user || !user.is_holding(src) || user.incapacitated() || !actual_selected_rune || !proximity)
return
@@ -610,7 +610,7 @@
candidate.color = "black"
if(do_after(user, 90, target = candidate))
candidate.emp_act(80)
- var/construct_class = tgui_alert(user, "Please choose which type of construct you wish to create.",,list("Juggernaut","Wraith","Artificer"))
+ var/construct_class = alert(user, "Please choose which type of construct you wish to create.",,"Juggernaut","Wraith","Artificer")
user.visible_message("The dark cloud receedes from what was formerly [candidate], revealing a\n [construct_class]!")
switch(construct_class)
if("Juggernaut")
@@ -787,7 +787,7 @@
/obj/item/melee/blood_magic/manipulator/attack_self(mob/living/user)
if(iscultist(user))
var/list/options = list("Blood Spear (150)", "Blood Bolt Barrage (300)", "Blood Beam (500)")
- var/choice = tgui_input_list(user, "Choose a greater blood rite...", "Greater Blood Rites", options)
+ var/choice = input(user, "Choose a greater blood rite...", "Greater Blood Rites") as null|anything in options
if(!choice)
to_chat(user, "You decide against conducting a greater blood rite.")
return
diff --git a/code/modules/antagonists/cult/cult_comms.dm b/code/modules/antagonists/cult/cult_comms.dm
index dcc6379c1f..bbdf41ff48 100644
--- a/code/modules/antagonists/cult/cult_comms.dm
+++ b/code/modules/antagonists/cult/cult_comms.dm
@@ -79,7 +79,7 @@
return ..()
/datum/action/innate/cult/mastervote/Activate()
- var/choice = tgui_alert(owner, "The mantle of leadership is heavy. Success in this role requires an expert level of communication and experience. Are you sure?",, list("Yes", "No"))
+ var/choice = alert(owner, "The mantle of leadership is heavy. Success in this role requires an expert level of communication and experience. Are you sure?",, "Yes", "No")
if(choice == "Yes" && IsAvailable())
var/datum/antagonist/cult/C = owner.mind.has_antag_datum(/datum/antagonist/cult,TRUE)
if(!C.cult_team)
diff --git a/code/modules/antagonists/cult/cult_items.dm b/code/modules/antagonists/cult/cult_items.dm
index e55d6bcb02..35151953a0 100644
--- a/code/modules/antagonists/cult/cult_items.dm
+++ b/code/modules/antagonists/cult/cult_items.dm
@@ -665,7 +665,7 @@
for(var/datum/mind/M in SSticker.mode.cult)
if(M.current && M.current.stat != DEAD)
cultists |= M.current
- var/mob/living/cultist_to_receive = tgui_input_list(user, "Who do you wish to call to [src]?", "Followers of the Geometer", cultists - user)
+ var/mob/living/cultist_to_receive = input(user, "Who do you wish to call to [src]?", "Followers of the Geometer") as null|anything in (cultists - user)
if(!Adjacent(user) || !src || QDELETED(src) || user.incapacitated())
return
if(!cultist_to_receive)
diff --git a/code/modules/antagonists/cult/ritual.dm b/code/modules/antagonists/cult/ritual.dm
index 0a93dc3675..98889169c6 100644
--- a/code/modules/antagonists/cult/ritual.dm
+++ b/code/modules/antagonists/cult/ritual.dm
@@ -53,7 +53,7 @@ This file contains the cult dagger and rune list code
if(!check_rune_turf(Turf, user))
return
- entered_rune_name = tgui_input_list(user, "Choose a rite to scribe.", "Sigils of Power", GLOB.rune_types)
+ entered_rune_name = input(user, "Choose a rite to scribe.", "Sigils of Power") as null|anything in GLOB.rune_types
if(!src || QDELETED(src) || !Adjacent(user) || user.incapacitated() || !check_rune_turf(Turf, user))
return
rune_to_scribe = GLOB.rune_types[entered_rune_name]
@@ -101,7 +101,7 @@ This file contains the cult dagger and rune list code
if(!(A in summon_objective.summon_spots))
to_chat(user, "The Geometer can only be summoned where the veil is weak - in [english_list(summon_objective.summon_spots)]!")
return
- var/confirm_final = tgui_alert(user, "This is the FINAL step to summon Nar'Sie; it is a long, painful ritual and the crew will be alerted to your presence", "Are you prepared for the final battle?", list("My life for Nar'Sie!", "No"))
+ var/confirm_final = alert(user, "This is the FINAL step to summon Nar'Sie; it is a long, painful ritual and the crew will be alerted to your presence", "Are you prepared for the final battle?", "My life for Nar'Sie!", "No")
if(confirm_final == "No")
to_chat(user, "You decide to prepare further before scribing the rune.")
return
diff --git a/code/modules/antagonists/cult/runes.dm b/code/modules/antagonists/cult/runes.dm
index 46ffba70b4..7981a10701 100644
--- a/code/modules/antagonists/cult/runes.dm
+++ b/code/modules/antagonists/cult/runes.dm
@@ -385,7 +385,7 @@ structure_check() searches for nearby cultist structures required for the invoca
fail_invoke()
return
- var/input_rune_key = tgui_input_list(user, "Choose a rune to teleport to.", "Rune to Teleport to", potential_runes) //we know what key they picked
+ var/input_rune_key = input(user, "Choose a rune to teleport to.", "Rune to Teleport to") as null|anything in potential_runes //we know what key they picked
var/obj/effect/rune/teleport/actual_selected_rune = potential_runes[input_rune_key] //what rune does that key correspond to?
if(!Adjacent(user) || !src || QDELETED(src) || user.incapacitated() || !actual_selected_rune)
fail_invoke()
@@ -562,7 +562,7 @@ structure_check() searches for nearby cultist structures required for the invoca
fail_invoke()
return
if(potential_revive_mobs.len > 1)
- mob_to_revive = tgui_input_list(user, "Choose a cultist to revive.", "Cultist to Revive", potential_revive_mobs)
+ mob_to_revive = input(user, "Choose a cultist to revive.", "Cultist to Revive") as null|anything in potential_revive_mobs
else
mob_to_revive = potential_revive_mobs[1]
if(QDELETED(src) || !validness_checks(mob_to_revive, user))
@@ -719,7 +719,7 @@ structure_check() searches for nearby cultist structures required for the invoca
for(var/datum/mind/M in SSticker.mode.cult)
if(!(M.current in invokers) && M.current && M.current.stat != DEAD)
cultists |= M.current
- var/mob/living/cultist_to_summon = tgui_input_list(user, "Who do you wish to call to [src]?", "Followers of the Geometer", cultists)
+ var/mob/living/cultist_to_summon = input(user, "Who do you wish to call to [src]?", "Followers of the Geometer") as null|anything in cultists
if(!Adjacent(user) || !src || QDELETED(src) || user.incapacitated())
return
if(!cultist_to_summon)
@@ -853,7 +853,7 @@ structure_check() searches for nearby cultist structures required for the invoca
. = ..()
var/mob/living/user = invokers[1]
var/turf/T = get_turf(src)
- var/choice = tgui_alert(user, "You tear open a connection to the spirit realm...",,list("Summon a Cult Ghost","Ascend as a Dark Spirit","Cancel"))
+ var/choice = alert(user,"You tear open a connection to the spirit realm...",,"Summon a Cult Ghost","Ascend as a Dark Spirit","Cancel")
if(choice == "Summon a Cult Ghost")
var/area/A = get_area(T)
if(A.map_name == "Space" || is_mining_level(T.z))
diff --git a/code/modules/antagonists/devil/devil.dm b/code/modules/antagonists/devil/devil.dm
index 9db621db40..65ce89d33f 100644
--- a/code/modules/antagonists/devil/devil.dm
+++ b/code/modules/antagonists/devil/devil.dm
@@ -131,7 +131,7 @@ GLOBAL_LIST_INIT(devil_suffix, list(" the Red", " the Soulless", " the Master",
log_admin("[key_name_admin(admin)] set [owner.current] devil ascendable to [ascendable])")
/datum/antagonist/devil/admin_add(datum/mind/new_owner,mob/admin)
- switch(tgui_alert(admin, "Should the devil be able to ascend",,list("Yes","No","Cancel")))
+ switch(alert(admin,"Should the devil be able to ascend",,"Yes","No","Cancel"))
if("Yes")
ascendable = TRUE
if("No")
diff --git a/code/modules/antagonists/devil/sintouched/sintouched.dm b/code/modules/antagonists/devil/sintouched/sintouched.dm
index 67fed36bb3..c9bf474567 100644
--- a/code/modules/antagonists/devil/sintouched/sintouched.dm
+++ b/code/modules/antagonists/devil/sintouched/sintouched.dm
@@ -56,7 +56,7 @@
/datum/antagonist/sintouched/admin_add(datum/mind/new_owner,mob/admin)
var/choices = sins + "Random"
- var/chosen_sin = tgui_input_list(admin,"What kind ?","Sin kind", choices)
+ var/chosen_sin = input(admin,"What kind ?","Sin kind") as null|anything in choices
if(!chosen_sin)
return
if(chosen_sin in sins)
diff --git a/code/modules/antagonists/devil/true_devil/_true_devil.dm b/code/modules/antagonists/devil/true_devil/_true_devil.dm
index ac1e5630da..fd7e6fb98d 100644
--- a/code/modules/antagonists/devil/true_devil/_true_devil.dm
+++ b/code/modules/antagonists/devil/true_devil/_true_devil.dm
@@ -179,7 +179,7 @@
/mob/living/carbon/true_devil/is_literate()
return 1
-/mob/living/carbon/true_devil/ex_act(severity, ex_target)
+/mob/living/carbon/true_devil/ex_act(severity, target, origin)
if(!ascended)
var/b_loss
switch (severity)
diff --git a/code/modules/antagonists/disease/disease_mob.dm b/code/modules/antagonists/disease/disease_mob.dm
index 654986d355..f6c8c3dbe1 100644
--- a/code/modules/antagonists/disease/disease_mob.dm
+++ b/code/modules/antagonists/disease/disease_mob.dm
@@ -296,7 +296,7 @@ the new instance inside the host to be updated to the template's stats.
/mob/camera/disease/proc/confirm_initial_infection(mob/living/carbon/human/H)
set waitfor = FALSE
- if(tgui_alert(src, "Select [H.name] as your initial host?", "Select Host", list("Yes", "No")) != "Yes")
+ if(alert(src, "Select [H.name] as your initial host?", "Select Host", "Yes", "No") != "Yes")
return
if(!freemove)
return
diff --git a/code/modules/antagonists/eldritch_cult/eldritch_items.dm b/code/modules/antagonists/eldritch_cult/eldritch_items.dm
index 0f297ccb28..28228aedd6 100644
--- a/code/modules/antagonists/eldritch_cult/eldritch_items.dm
+++ b/code/modules/antagonists/eldritch_cult/eldritch_items.dm
@@ -350,7 +350,7 @@
drawing = TRUE
- var/type = pick_list[tgui_input_list(user,"Choose the rune","Rune", pick_list)]
+ var/type = pick_list[input(user,"Choose the rune","Rune") as null|anything in pick_list ]
if(!type)
drawing = FALSE
return
diff --git a/code/modules/antagonists/eldritch_cult/eldritch_knowledge.dm b/code/modules/antagonists/eldritch_cult/eldritch_knowledge.dm
index 71a2d0580e..33a17c3278 100644
--- a/code/modules/antagonists/eldritch_cult/eldritch_knowledge.dm
+++ b/code/modules/antagonists/eldritch_cult/eldritch_knowledge.dm
@@ -170,7 +170,7 @@
to_chat(user, "These items don't possess the required fingerprints or DNA.")
return FALSE
- var/chosen_mob = tgui_input_list(user, "Select the person you wish to curse","Your target", sortList(compiled_list, /proc/cmp_mob_realname_dsc))
+ var/chosen_mob = input("Select the person you wish to curse","Your target") as null|anything in sortList(compiled_list, /proc/cmp_mob_realname_dsc)
if(!chosen_mob)
return FALSE
curse(compiled_list[chosen_mob])
@@ -296,7 +296,7 @@
if(!targeted)
break
targets["[targeted.current.real_name] the [targeted.assigned_role]"] = targeted.current
- LH.target = targets[tgui_input_list(user,"Choose your next target","Target", targets)]
+ LH.target = targets[input(user,"Choose your next target","Target") in targets]
if(!LH.target && targets.len)
LH.target = pick(targets) //Tsk tsk, you can and will get another target if you want it or not.
diff --git a/code/modules/antagonists/eldritch_cult/eldritch_magic.dm b/code/modules/antagonists/eldritch_cult/eldritch_magic.dm
index 1d4bcd3910..158acc0071 100644
--- a/code/modules/antagonists/eldritch_cult/eldritch_magic.dm
+++ b/code/modules/antagonists/eldritch_cult/eldritch_magic.dm
@@ -621,7 +621,7 @@
if(!originator?.linked_mobs[living_owner])
CRASH("Uh oh the mansus link got somehow activated without it being linked to a raw prophet or the mob not being in a list of mobs that should be able to do it.")
- var/message = sanitize(tgui_input_text(usr, "Message:", "Telepathy from the Manse"))
+ var/message = sanitize(input("Message:", "Telepathy from the Manse") as text|null)
if(QDELETED(living_owner))
return
diff --git a/code/modules/antagonists/eldritch_cult/eldritch_structures.dm b/code/modules/antagonists/eldritch_cult/eldritch_structures.dm
index b920a1040a..01fd945cba 100644
--- a/code/modules/antagonists/eldritch_cult/eldritch_structures.dm
+++ b/code/modules/antagonists/eldritch_cult/eldritch_structures.dm
@@ -80,7 +80,7 @@
for(var/X in subtypesof(/obj/item/eldritch_potion))
var/obj/item/eldritch_potion/potion = X
lst[initial(potion.name)] = potion
- var/type = lst[tgui_input_list(user,"Choose your brew","Brew", lst)]
+ var/type = lst[input(user,"Choose your brew","Brew") in lst]
playsound(src, 'sound/misc/desceration-02.ogg', 75, TRUE)
new type(drop_location())
current_mass = 0
diff --git a/code/modules/antagonists/monkey/monkey.dm b/code/modules/antagonists/monkey/monkey.dm
index 6c03e3c686..971532958f 100644
--- a/code/modules/antagonists/monkey/monkey.dm
+++ b/code/modules/antagonists/monkey/monkey.dm
@@ -69,7 +69,7 @@
/datum/antagonist/monkey/admin_remove(mob/admin)
var/mob/living/carbon/monkey/M = owner.current
if(istype(M))
- switch(tgui_alert(admin, "Humanize?", "Humanize", list("Yes", "No")))
+ switch(alert(admin, "Humanize?", "Humanize", "Yes", "No"))
if("Yes")
if(admin == M)
admin = M.humanize(TR_KEEPITEMS | TR_KEEPIMPLANTS | TR_KEEPORGANS | TR_KEEPDAMAGE | TR_KEEPVIRUS | TR_DEFAULTMSG)
@@ -89,7 +89,7 @@
/datum/antagonist/monkey/leader/admin_add(datum/mind/new_owner,mob/admin)
var/mob/living/carbon/human/H = new_owner.current
if(istype(H))
- switch(tgui_alert(admin, "Monkeyize?", "Monkeyize", list("Yes", "No")))
+ switch(alert(admin, "Monkeyize?", "Monkeyize", "Yes", "No"))
if("Yes")
if(admin == H)
admin = H.monkeyize()
diff --git a/code/modules/antagonists/nukeop/equipment/borgchameleon.dm b/code/modules/antagonists/nukeop/equipment/borgchameleon.dm
index c01460b386..b3c31152a5 100644
--- a/code/modules/antagonists/nukeop/equipment/borgchameleon.dm
+++ b/code/modules/antagonists/nukeop/equipment/borgchameleon.dm
@@ -66,7 +66,7 @@
if(animation_playing)
to_chat(user, "\the [src] is recharging.")
return
- var/borg_icon = tgui_input_list(user, "Select an icon!", "Robot Icon", engymodels)
+ var/borg_icon = input(user, "Select an icon!", "Robot Icon", null) as null|anything in engymodels
if(!borg_icon)
return FALSE
switch(borg_icon)
diff --git a/code/modules/antagonists/nukeop/equipment/nuclear_challenge.dm b/code/modules/antagonists/nukeop/equipment/nuclear_challenge.dm
index 8f2e942bad..78e4d38b3c 100644
--- a/code/modules/antagonists/nukeop/equipment/nuclear_challenge.dm
+++ b/code/modules/antagonists/nukeop/equipment/nuclear_challenge.dm
@@ -26,7 +26,7 @@ GLOBAL_VAR_INIT(war_declared, FALSE)
return
declaring_war = TRUE
- var/are_you_sure = tgui_alert(user, "Consult your team carefully before you declare war on [station_name()]]. Are you sure you want to alert the enemy crew? You have [DisplayTimeText(world.time-SSticker.round_start_time - CHALLENGE_TIME_LIMIT)] to decide", "Declare war?", list("Yes", "No"))
+ var/are_you_sure = alert(user, "Consult your team carefully before you declare war on [station_name()]]. Are you sure you want to alert the enemy crew? You have [DisplayTimeText(world.time-SSticker.round_start_time - CHALLENGE_TIME_LIMIT)] to decide", "Declare war?", "Yes", "No")
declaring_war = FALSE
if(!check_allowed(user))
@@ -39,7 +39,7 @@ GLOBAL_VAR_INIT(war_declared, FALSE)
var/war_declaration = "[user.real_name] has declared [user.p_their()] intent to utterly destroy [station_name()] with a nuclear device, and dares the crew to try and stop [user.p_them()]."
declaring_war = TRUE
- var/custom_threat = tgui_alert(user, "Do you want to customize your declaration?", "Customize?", list("Yes", "No"))
+ var/custom_threat = alert(user, "Do you want to customize your declaration?", "Customize?", "Yes", "No")
declaring_war = FALSE
if(!check_allowed(user))
diff --git a/code/modules/antagonists/revenant/revenant.dm b/code/modules/antagonists/revenant/revenant.dm
index 537c714966..f05321487f 100644
--- a/code/modules/antagonists/revenant/revenant.dm
+++ b/code/modules/antagonists/revenant/revenant.dm
@@ -174,7 +174,7 @@
//Immunities
-/mob/living/simple_animal/revenant/ex_act(severity, target)
+/mob/living/simple_animal/revenant/ex_act(severity, target, origin)
return 1 //Immune to the effects of explosions.
/mob/living/simple_animal/revenant/wave_ex_act(power, datum/wave_explosion/explosion, dir)
diff --git a/code/modules/antagonists/slaughter/slaughter.dm b/code/modules/antagonists/slaughter/slaughter.dm
index 09e97fba06..c468862c8b 100644
--- a/code/modules/antagonists/slaughter/slaughter.dm
+++ b/code/modules/antagonists/slaughter/slaughter.dm
@@ -249,7 +249,7 @@
released and fully healed, because in the end it's just a jape, \
sibling!"
-/mob/living/simple_animal/slaughter/laughter/ex_act(severity)
+/mob/living/simple_animal/slaughter/laughter/ex_act(severity, target, origin)
switch(severity)
if(1)
death()
diff --git a/code/modules/antagonists/traitor/classes/subterfuge.dm b/code/modules/antagonists/traitor/classes/subterfuge.dm
index 54f07eb23c..6c4bd26afb 100644
--- a/code/modules/antagonists/traitor/classes/subterfuge.dm
+++ b/code/modules/antagonists/traitor/classes/subterfuge.dm
@@ -9,7 +9,7 @@
var/datum/game_mode/dynamic/mode
if(istype(SSticker.mode,/datum/game_mode/dynamic))
mode = SSticker.mode
- assassin_prob = max(0,mode.threat_level-40)
+ assassin_prob = max(0,mode.threat_level-20)
if(prob(assassin_prob))
var/datum/objective/assassinate/once/kill_objective = new
kill_objective.owner = T.owner
diff --git a/code/modules/antagonists/traitor/equipment/Malf_Modules.dm b/code/modules/antagonists/traitor/equipment/Malf_Modules.dm
index f734e3289c..fcc8bcade8 100644
--- a/code/modules/antagonists/traitor/equipment/Malf_Modules.dm
+++ b/code/modules/antagonists/traitor/equipment/Malf_Modules.dm
@@ -255,7 +255,7 @@ GLOBAL_LIST_INIT(blacklisted_malf_machines, typecacheof(list(
if(!istype(T) || !is_station_level(T.z))
to_chat(owner, "You cannot activate the doomsday device while off-station!")
return
- if(tgui_alert(owner, "Send arming signal? (true = arm, false = cancel)", "purge_all_life()", list("confirm = TRUE;", "confirm = FALSE;")) != "confirm = TRUE;")
+ if(alert(owner, "Send arming signal? (true = arm, false = cancel)", "purge_all_life()", "confirm = TRUE;", "confirm = FALSE;") != "confirm = TRUE;")
return
if (active)
return //prevent the AI from activating an already active doomsday
@@ -695,7 +695,7 @@ GLOBAL_LIST_INIT(blacklisted_malf_machines, typecacheof(list(
if(!owner_AI.can_place_transformer(src))
return
active = TRUE
- if(tgui_alert(owner, "Are you sure you want to place the machine here?", "Are you sure?", list("Yes", "No")) == "No")
+ if(alert(owner, "Are you sure you want to place the machine here?", "Are you sure?", "Yes", "No") == "No")
active = FALSE
return
if(!owner_AI.can_place_transformer(src))
diff --git a/code/modules/antagonists/wizard/equipment/artefact.dm b/code/modules/antagonists/wizard/equipment/artefact.dm
index 9bd4a922bc..44f267358a 100644
--- a/code/modules/antagonists/wizard/equipment/artefact.dm
+++ b/code/modules/antagonists/wizard/equipment/artefact.dm
@@ -285,7 +285,7 @@
/obj/item/voodoo/attack_self(mob/user)
if(!target && length(possible))
- target = tgui_input_list(user, "Select your victim!", "Voodoo", possible)
+ target = input(user, "Select your victim!", "Voodoo") as null|anything in possible
return
if(user.zone_selected == BODY_ZONE_CHEST)
@@ -300,7 +300,7 @@
if(target && cooldown < world.time)
switch(user.zone_selected)
if(BODY_ZONE_PRECISE_MOUTH)
- var/wgw = sanitize(tgui_input_text(user, "What would you like the victim to say", "Voodoo", null))
+ var/wgw = sanitize(input(user, "What would you like the victim to say", "Voodoo", null) as text)
target.say(wgw, forced = "voodoo doll")
log_game("[key_name(user)] made [key_name(target)] say [wgw] with a voodoo doll.")
if(BODY_ZONE_PRECISE_EYES)
diff --git a/code/modules/antagonists/wizard/equipment/soulstone.dm b/code/modules/antagonists/wizard/equipment/soulstone.dm
index 5a876ea9db..fe9770e64a 100644
--- a/code/modules/antagonists/wizard/equipment/soulstone.dm
+++ b/code/modules/antagonists/wizard/equipment/soulstone.dm
@@ -222,7 +222,7 @@
var/obj/structure/constructshell/T = target
var/mob/living/simple_animal/hostile/construct/shade/A = locate() in src
if(A)
- var/construct_class = tgui_alert(user, "Please choose which type of construct you wish to create.",,list("Juggernaut","Wraith","Artificer"))
+ var/construct_class = alert(user, "Please choose which type of construct you wish to create.",,"Juggernaut","Wraith","Artificer")
if(!T || !T.loc)
return
switch(construct_class)
diff --git a/code/modules/arousal/arousal.dm b/code/modules/arousal/arousal.dm
index 7f80cae837..a3adf0d25b 100644
--- a/code/modules/arousal/arousal.dm
+++ b/code/modules/arousal/arousal.dm
@@ -16,7 +16,7 @@
set name = "Toggle undergarments"
set category = "IC"
- var/confirm = tgui_input_list(src, "Select what part of your form to alter", "Undergarment Toggling", list("Top", "Bottom", "Socks", "All"))
+ var/confirm = input(src, "Select what part of your form to alter", "Undergarment Toggling") as null|anything in list("Top", "Bottom", "Socks", "All")
if(!confirm)
return
if(confirm == "Top")
@@ -55,7 +55,7 @@
return genit_list
/obj/item/organ/genital/proc/climaxable(mob/living/carbon/human/H, silent = FALSE) //returns the fluid source (ergo reagents holder) if found.
- if(CHECK_BITFIELD(genital_flags, GENITAL_FUID_PRODUCTION))
+ if((genital_flags & GENITAL_FUID_PRODUCTION))
. = reagents
else
if(linked_organ)
@@ -124,10 +124,10 @@
var/list/worn_stuff = get_equipped_items()
for(var/obj/item/organ/genital/G in internal_organs)
- if(CHECK_BITFIELD(G.genital_flags, CAN_CLIMAX_WITH) && G.is_exposed(worn_stuff)) //filter out what you can't masturbate with
+ if((G.genital_flags & CAN_CLIMAX_WITH) && G.is_exposed(worn_stuff)) //filter out what you can't masturbate with
LAZYADD(genitals_list, G)
if(LAZYLEN(genitals_list))
- var/obj/item/organ/genital/ret_organ = tgui_input_list(src, "with what?", "Climax", genitals_list)
+ var/obj/item/organ/genital/ret_organ = input(src, "with what?", "Climax", null) as null|obj in genitals_list
return ret_organ
else if(!silent)
to_chat(src, "You cannot climax without available genitals.")
@@ -151,10 +151,10 @@
if(!silent)
to_chat(src, "You cannot do this alone.")
return //No one left.
- var/mob/living/target = tgui_input_list(src, "With whom?", "Sexual partner", partners) //pick one, default to null
+ var/mob/living/target = input(src, "With whom?", "Sexual partner", null) as null|anything in partners //pick one, default to null
if(target && in_range(src, target))
to_chat(src,"Waiting for consent...")
- var/consenting = tgui_input_list(target, "Do you want [src] to climax with you?","Climax mechanics", list("Yes","No"))
+ var/consenting = input(target, "Do you want [src] to climax with you?","Climax mechanics","No") in list("Yes","No")
if(consenting == "Yes")
return target
else
@@ -172,7 +172,7 @@
containers_list += C
if(containers_list.len)
- var/obj/item/reagent_containers/SC = tgui_input_list(src, "Into or onto what?(Cancel for nowhere)", "", containers_list)
+ var/obj/item/reagent_containers/SC = input(src, "Into or onto what?(Cancel for nowhere)", null) as null|obj in containers_list
if(SC && CanReach(SC))
return SC
else if(!silent)
@@ -212,7 +212,7 @@
if(forced_climax) //Something forced us to cum, this is not a masturbation thing and does not progress to the other checks
log_message("was forced to climax by [cause]",LOG_EMOTE)
for(var/obj/item/organ/genital/G in internal_organs)
- if(!CHECK_BITFIELD(G.genital_flags, CAN_CLIMAX_WITH)) //Skip things like wombs and testicles
+ if(!(G.genital_flags & CAN_CLIMAX_WITH)) //Skip things like wombs and testicles
continue
mob_climax_outside(G, mb_time = 0) //removed climax timer for sudden, forced orgasms
//Now all genitals that could climax, have.
@@ -226,7 +226,7 @@
return
//Ok, now we check what they want to do.
- var/choice = tgui_input_list(src, "Select sexual activity", "Sexual activity:", list("Climax alone","Climax with partner", "Fill container"))
+ var/choice = input(src, "Select sexual activity", "Sexual activity:") as null|anything in list("Climax alone","Climax with partner", "Fill container")
if(!choice)
return
@@ -243,7 +243,7 @@
if(picked_organ)
var/mob/living/partner = pick_partner() //Get someone
if(partner)
- var/spillage = tgui_input_list(src, "Would your fluids spill outside?", "Choose overflowing option", list("Yes", "No"))
+ var/spillage = input(src, "Would your fluids spill outside?", "Choose overflowing option", "Yes") as null|anything in list("Yes", "No")
if(spillage && in_range(src, partner))
mob_climax_partner(picked_organ, partner, spillage == "Yes" ? TRUE : FALSE)
if("Fill container")
diff --git a/code/modules/arousal/genitals.dm b/code/modules/arousal/genitals.dm
index 99b43488f1..b7e90e5b84 100644
--- a/code/modules/arousal/genitals.dm
+++ b/code/modules/arousal/genitals.dm
@@ -112,15 +112,15 @@
var/list/genital_list = list()
for(var/obj/item/organ/genital/G in internal_organs)
- if(!CHECK_BITFIELD(G.genital_flags, GENITAL_INTERNAL))
+ if(!(G.genital_flags & GENITAL_INTERNAL))
genital_list += G
if(!genital_list.len) //There is nothing to expose
return
//Full list of exposable genitals created
var/obj/item/organ/genital/picked_organ
- picked_organ = tgui_input_list(src, "Choose which genitalia to expose/hide", "Expose/Hide genitals", genital_list)
+ picked_organ = input(src, "Choose which genitalia to expose/hide", "Expose/Hide genitals") as null|anything in genital_list
if(picked_organ && (picked_organ in internal_organs))
- var/picked_visibility = tgui_input_list(src, "Choose visibility setting", "Expose/Hide genitals", GLOB.genitals_visibility_toggles)
+ var/picked_visibility = input(src, "Choose visibility setting", "Expose/Hide genitals") as null|anything in GLOB.genitals_visibility_toggles
if(picked_visibility && picked_organ && (picked_organ in internal_organs))
picked_organ.toggle_visibility(picked_visibility)
return
@@ -136,7 +136,7 @@
if(!genital_list.len) //There's nothing that can show arousal
return
var/obj/item/organ/genital/picked_organ
- picked_organ = tgui_input_list(src, "Choose which genitalia to toggle arousal on", "Set genital arousal", genital_list)
+ picked_organ = input(src, "Choose which genitalia to toggle arousal on", "Set genital arousal", null) in genital_list
if(picked_organ)
var/original_state = picked_organ.aroused_state
picked_organ.set_aroused_state(!picked_organ.aroused_state)
diff --git a/code/modules/arousal/organs/breasts.dm b/code/modules/arousal/organs/breasts.dm
index e37224e401..b9129e28a1 100644
--- a/code/modules/arousal/organs/breasts.dm
+++ b/code/modules/arousal/organs/breasts.dm
@@ -48,7 +48,7 @@
else
desc += " You estimate that they're [uppertext(size)]-cups."
- if(CHECK_BITFIELD(genital_flags, GENITAL_FUID_PRODUCTION) && aroused_state)
+ if((genital_flags & GENITAL_FUID_PRODUCTION) && aroused_state)
var/datum/reagent/R = GLOB.chemical_reagents_list[fluid_id]
if(R)
desc += " They're leaking [lowertext(R.name)]."
@@ -115,7 +115,7 @@
size = D.features["breasts_size"]
shape = D.features["breasts_shape"]
if(!D.features["breasts_producing"])
- DISABLE_BITFIELD(genital_flags, GENITAL_FUID_PRODUCTION|CAN_CLIMAX_WITH|CAN_MASTURBATE_WITH)
+ genital_flags &= ~ (GENITAL_FUID_PRODUCTION|CAN_CLIMAX_WITH|CAN_MASTURBATE_WITH)
if(!isnum(size))
cached_size = breast_values[size]
else
diff --git a/code/modules/arousal/toys/dildos.dm b/code/modules/arousal/toys/dildos.dm
index a4d014c1c0..4de6877915 100644
--- a/code/modules/arousal/toys/dildos.dm
+++ b/code/modules/arousal/toys/dildos.dm
@@ -46,25 +46,25 @@
if(!can_customize)
return FALSE
if(src && !user.incapacitated() && in_range(user,src))
- var/color_choice = tgui_input_list(user,"Choose a color for your dildo.","Dildo Color", GLOB.dildo_colors)
+ var/color_choice = input(user,"Choose a color for your dildo.","Dildo Color") as null|anything in GLOB.dildo_colors
if(src && color_choice && !user.incapacitated() && in_range(user,src))
sanitize_inlist(color_choice, GLOB.dildo_colors, "Red")
color = GLOB.dildo_colors[color_choice]
update_appearance()
if(src && !user.incapacitated() && in_range(user,src))
- var/shape_choice = tgui_input_list(user,"Choose a shape for your dildo.","Dildo Shape", GLOB.dildo_shapes)
+ var/shape_choice = input(user,"Choose a shape for your dildo.","Dildo Shape") as null|anything in GLOB.dildo_shapes
if(src && shape_choice && !user.incapacitated() && in_range(user,src))
sanitize_inlist(shape_choice, GLOB.dildo_colors, "Knotted")
dildo_shape = GLOB.dildo_shapes[shape_choice]
update_appearance()
if(src && !user.incapacitated() && in_range(user,src))
- var/size_choice = tgui_input_list(user,"Choose the size for your dildo.","Dildo Size", GLOB.dildo_sizes)
+ var/size_choice = input(user,"Choose the size for your dildo.","Dildo Size") as null|anything in GLOB.dildo_sizes
if(src && size_choice && !user.incapacitated() && in_range(user,src))
sanitize_inlist(size_choice, GLOB.dildo_colors, "Medium")
dildo_size = GLOB.dildo_sizes[size_choice]
update_appearance()
if(src && !user.incapacitated() && in_range(user,src))
- var/transparency_choice = tgui_input_num(user,"Choose the transparency of your dildo. Lower is more transparent!(192-255)","Dildo Transparency", alpha)
+ var/transparency_choice = input(user,"Choose the transparency of your dildo. Lower is more transparent!(192-255)","Dildo Transparency") as null|num
if(src && transparency_choice && !user.incapacitated() && in_range(user,src))
sanitize_integer(transparency_choice, 192, 255, 192)
alpha = transparency_choice
diff --git a/code/modules/assembly/doorcontrol.dm b/code/modules/assembly/doorcontrol.dm
index c2994e7998..32e262ce65 100644
--- a/code/modules/assembly/doorcontrol.dm
+++ b/code/modules/assembly/doorcontrol.dm
@@ -29,7 +29,7 @@
if(!can_change_id)
return
var/new_id
- new_id = tgui_input_text(user, "Set ID", "Set ID", show_id? id : null)
+ new_id = input(user, "Set ID", "Set ID", show_id? id : null) as text|null
if(!isnull(new_id)) //0/"" is considered !, so check null instead of just !.
id = new_id
diff --git a/code/modules/assembly/holder.dm b/code/modules/assembly/holder.dm
index 9decf4ab88..84e70bbbb3 100644
--- a/code/modules/assembly/holder.dm
+++ b/code/modules/assembly/holder.dm
@@ -116,7 +116,7 @@
to_chat(user, "Assembly part missing!")
return
if(istype(a_left,a_right.type))//If they are the same type it causes issues due to window code
- switch(tgui_alert(user, "Which side would you like to use?",,list("Left","Right")))
+ switch(alert("Which side would you like to use?",,"Left","Right"))
if("Left")
a_left.attack_self(user)
if("Right")
diff --git a/code/modules/atmospherics/gasmixtures/gas_mixture.dm b/code/modules/atmospherics/gasmixtures/gas_mixture.dm
index 5cc6fa33d6..b670baaae7 100644
--- a/code/modules/atmospherics/gasmixtures/gas_mixture.dm
+++ b/code/modules/atmospherics/gasmixtures/gas_mixture.dm
@@ -63,7 +63,7 @@ GLOBAL_LIST_INIT(auxtools_atmos_initialized,FALSE)
if(!.)
return
if(href_list[VV_HK_PARSE_GASSTRING])
- var/gasstring = tgui_input_text(usr, "Input Gas String (WARNING: Advanced. Don't use this unless you know how these work.)", "Gas String Parse")
+ var/gasstring = input(usr, "Input Gas String (WARNING: Advanced. Don't use this unless you know how these work.", "Gas String Parse") as text|null
if(!istext(gasstring))
return
log_admin("[key_name(usr)] modified gas mixture [REF(src)]: Set to gas string [gasstring].")
@@ -77,10 +77,10 @@ GLOBAL_LIST_INIT(auxtools_atmos_initialized,FALSE)
var/list/gases = get_gases()
for(var/gas in gases)
gases[gas] = get_moles(gas)
- var/gasid = tgui_input_list(usr, "What kind of gas?", "Set Gas", GLOB.gas_data.ids)
+ var/gasid = input(usr, "What kind of gas?", "Set Gas") as null|anything in GLOB.gas_data.ids
if(!gasid)
return
- var/amount = tgui_input_num(usr, "Input amount", "Set Gas", gases[gasid] || 0)
+ var/amount = input(usr, "Input amount", "Set Gas", gases[gasid] || 0) as num|null
if(!isnum(amount))
return
amount = max(0, amount)
@@ -88,7 +88,7 @@ GLOBAL_LIST_INIT(auxtools_atmos_initialized,FALSE)
message_admins("[key_name(usr)] modified gas mixture [REF(src)]: Set gas [gasid] to [amount] moles.")
set_moles(gasid, amount)
if(href_list[VV_HK_SET_TEMPERATURE])
- var/temp = tgui_input_num(usr, "Set the temperature of this mixture to?", "Set Temperature", return_temperature())
+ var/temp = input(usr, "Set the temperature of this mixture to?", "Set Temperature", return_temperature()) as num|null
if(!isnum(temp))
return
temp = max(2.7, temp)
@@ -96,7 +96,7 @@ GLOBAL_LIST_INIT(auxtools_atmos_initialized,FALSE)
message_admins("[key_name(usr)] modified gas mixture [REF(src)]: Changed temperature to [temp].")
set_temperature(temp)
if(href_list[VV_HK_SET_VOLUME])
- var/volume = tgui_input_num(usr, "Set the volume of this mixture to?", "Set Volume", return_volume())
+ var/volume = input(usr, "Set the volume of this mixture to?", "Set Volume", return_volume()) as num|null
if(!isnum(volume))
return
volume = max(0, volume)
diff --git a/code/modules/atmospherics/machinery/airalarm.dm b/code/modules/atmospherics/machinery/airalarm.dm
index 03158b22d1..2313d9c71d 100644
--- a/code/modules/atmospherics/machinery/airalarm.dm
+++ b/code/modules/atmospherics/machinery/airalarm.dm
@@ -428,7 +428,7 @@
var/datum/tlv/tlv = TLV[env]
if(isnull(tlv))
return
- var/value = tgui_input_num(usr, "New [name] for [env]:", name, tlv.vars[name])
+ var/value = input("New [name] for [env]:", name, tlv.vars[name]) as num|null
if(!isnull(value) && !..())
if(value < 0)
tlv.vars[name] = -1
diff --git a/code/modules/atmospherics/machinery/components/binary_devices/passive_gate.dm b/code/modules/atmospherics/machinery/components/binary_devices/passive_gate.dm
index d7bfb46af5..56a7d78288 100644
--- a/code/modules/atmospherics/machinery/components/binary_devices/passive_gate.dm
+++ b/code/modules/atmospherics/machinery/components/binary_devices/passive_gate.dm
@@ -107,7 +107,7 @@ Passive gate is similar to the regular pump except:
pressure = MAX_OUTPUT_PRESSURE
. = TRUE
else if(pressure == "input")
- pressure = tgui_input_num(usr, "New output pressure (0-[MAX_OUTPUT_PRESSURE] kPa):", name, target_pressure)
+ pressure = input("New output pressure (0-[MAX_OUTPUT_PRESSURE] kPa):", name, target_pressure) as num|null
if(!isnull(pressure) || !..())
. = TRUE
else if(text2num(pressure) != null)
diff --git a/code/modules/atmospherics/machinery/components/binary_devices/pump.dm b/code/modules/atmospherics/machinery/components/binary_devices/pump.dm
index 133c280728..dc5a6eccd4 100644
--- a/code/modules/atmospherics/machinery/components/binary_devices/pump.dm
+++ b/code/modules/atmospherics/machinery/components/binary_devices/pump.dm
@@ -135,7 +135,7 @@
pressure = MAX_OUTPUT_PRESSURE
. = TRUE
else if(pressure == "input")
- pressure = tgui_input_num(usr, "New output pressure (0-[MAX_OUTPUT_PRESSURE] kPa):", name, target_pressure)
+ pressure = input("New output pressure (0-[MAX_OUTPUT_PRESSURE] kPa):", name, target_pressure) as num|null
if(!isnull(pressure) && !..())
. = TRUE
else if(text2num(pressure) != null)
diff --git a/code/modules/atmospherics/machinery/components/binary_devices/relief_valve.dm b/code/modules/atmospherics/machinery/components/binary_devices/relief_valve.dm
index 6ff796f4c1..d0b663e4ad 100644
--- a/code/modules/atmospherics/machinery/components/binary_devices/relief_valve.dm
+++ b/code/modules/atmospherics/machinery/components/binary_devices/relief_valve.dm
@@ -83,7 +83,7 @@
pressure = 50*ONE_ATMOSPHERE
. = TRUE
else if(pressure == "input") // The manual expirience.
- pressure = tgui_input_num(usr, "New output pressure ([close_pressure]-[50*ONE_ATMOSPHERE] kPa):", name, open_pressure)
+ pressure = input("New output pressure ([close_pressure]-[50*ONE_ATMOSPHERE] kPa):", name, open_pressure) as num|null
if(!isnull(pressure) && !..())
. = TRUE
else if(text2num(pressure) != null)
@@ -98,7 +98,7 @@
pressure = open_pressure
. = TRUE
else if(pressure == "input")
- pressure = tgui_input_num(usr, "New output pressure (0-[open_pressure] kPa):", name, close_pressure)
+ pressure = input("New output pressure (0-[open_pressure] kPa):", name, close_pressure) as num|null
if(!isnull(pressure) && !..())
. = TRUE
else if(text2num(pressure) != null)
diff --git a/code/modules/atmospherics/machinery/components/binary_devices/volume_pump.dm b/code/modules/atmospherics/machinery/components/binary_devices/volume_pump.dm
index 258ee21d9b..46d584339b 100644
--- a/code/modules/atmospherics/machinery/components/binary_devices/volume_pump.dm
+++ b/code/modules/atmospherics/machinery/components/binary_devices/volume_pump.dm
@@ -125,7 +125,7 @@
rate = MAX_TRANSFER_RATE
. = TRUE
else if(rate == "input")
- rate = tgui_input_num(usr, "New transfer rate (0-[MAX_TRANSFER_RATE] L/s):", name, transfer_rate)
+ rate = input("New transfer rate (0-[MAX_TRANSFER_RATE] L/s):", name, transfer_rate) as num|null
if(!isnull(rate) && !..())
. = TRUE
else if(text2num(rate) != null)
diff --git a/code/modules/atmospherics/machinery/components/components_base.dm b/code/modules/atmospherics/machinery/components/components_base.dm
index 7ade864a92..f8866877fe 100644
--- a/code/modules/atmospherics/machinery/components/components_base.dm
+++ b/code/modules/atmospherics/machinery/components/components_base.dm
@@ -126,7 +126,7 @@
air_update_turf(1)
/obj/machinery/atmospherics/components/proc/safe_input(var/title, var/text, var/default_set)
- var/new_value = tgui_input_num(usr,text,title,default_set)
+ var/new_value = input(usr,text,title,default_set) as num
if(usr.canUseTopic(src))
return new_value
return default_set
diff --git a/code/modules/atmospherics/machinery/components/trinary_devices/filter.dm b/code/modules/atmospherics/machinery/components/trinary_devices/filter.dm
index dbad55e9ef..4182f5ceca 100644
--- a/code/modules/atmospherics/machinery/components/trinary_devices/filter.dm
+++ b/code/modules/atmospherics/machinery/components/trinary_devices/filter.dm
@@ -143,7 +143,7 @@
rate = MAX_TRANSFER_RATE
. = TRUE
else if(rate == "input")
- rate = tgui_input_num(usr, "New transfer rate (0-[MAX_TRANSFER_RATE] L/s):", name, transfer_rate)
+ rate = input("New transfer rate (0-[MAX_TRANSFER_RATE] L/s):", name, transfer_rate) as num|null
if(!isnull(rate) && !..())
. = TRUE
else if(text2num(rate) != null)
diff --git a/code/modules/atmospherics/machinery/components/trinary_devices/mixer.dm b/code/modules/atmospherics/machinery/components/trinary_devices/mixer.dm
index 1257cb9bb2..3296981e5e 100644
--- a/code/modules/atmospherics/machinery/components/trinary_devices/mixer.dm
+++ b/code/modules/atmospherics/machinery/components/trinary_devices/mixer.dm
@@ -151,7 +151,7 @@
pressure = MAX_OUTPUT_PRESSURE
. = TRUE
else if(pressure == "input")
- pressure = tgui_input_num(usr, "New output pressure (0-[MAX_OUTPUT_PRESSURE] kPa):", name, target_pressure)
+ pressure = input("New output pressure (0-[MAX_OUTPUT_PRESSURE] kPa):", name, target_pressure) as num|null
if(!isnull(pressure) && !..())
. = TRUE
else if(text2num(pressure) != null)
diff --git a/code/modules/atmospherics/machinery/components/unary_devices/cryo.dm b/code/modules/atmospherics/machinery/components/unary_devices/cryo.dm
index efafc1c9a8..6c9ce28bc7 100644
--- a/code/modules/atmospherics/machinery/components/unary_devices/cryo.dm
+++ b/code/modules/atmospherics/machinery/components/unary_devices/cryo.dm
@@ -72,10 +72,10 @@
QDEL_NULL(beaker)
return ..()
-/obj/machinery/atmospherics/components/unary/cryo_cell/contents_explosion(severity, target)
+/obj/machinery/atmospherics/components/unary/cryo_cell/contents_explosion(severity, target, origin)
..()
if(beaker)
- beaker.ex_act(severity, target)
+ beaker.ex_act(severity, target, origin)
/obj/machinery/atmospherics/components/unary/cryo_cell/handle_atom_del(atom/A)
..()
diff --git a/code/modules/atmospherics/machinery/components/unary_devices/outlet_injector.dm b/code/modules/atmospherics/machinery/components/unary_devices/outlet_injector.dm
index 0a64d458d2..b2fa26edba 100644
--- a/code/modules/atmospherics/machinery/components/unary_devices/outlet_injector.dm
+++ b/code/modules/atmospherics/machinery/components/unary_devices/outlet_injector.dm
@@ -166,7 +166,7 @@
rate = MAX_TRANSFER_RATE
. = TRUE
else if(rate == "input")
- rate = tgui_input_num(usr, "New transfer rate (0-[MAX_TRANSFER_RATE] L/s):", name, volume_rate)
+ rate = input("New transfer rate (0-[MAX_TRANSFER_RATE] L/s):", name, volume_rate) as num|null
if(!isnull(rate) && !..())
. = TRUE
else if(text2num(rate) != null)
diff --git a/code/modules/atmospherics/machinery/components/unary_devices/relief_valve.dm b/code/modules/atmospherics/machinery/components/unary_devices/relief_valve.dm
index ecc9bc624f..ee4223b157 100644
--- a/code/modules/atmospherics/machinery/components/unary_devices/relief_valve.dm
+++ b/code/modules/atmospherics/machinery/components/unary_devices/relief_valve.dm
@@ -82,7 +82,7 @@
pressure = 50*ONE_ATMOSPHERE
. = TRUE
else if(pressure == "input")
- pressure = tgui_input_num(usr, "New output pressure ([close_pressure]-[50*ONE_ATMOSPHERE] kPa):", name, open_pressure)
+ pressure = input("New output pressure ([close_pressure]-[50*ONE_ATMOSPHERE] kPa):", name, open_pressure) as num|null
if(!isnull(pressure) && !..())
. = TRUE
else if(text2num(pressure) != null)
@@ -97,7 +97,7 @@
pressure = open_pressure
. = TRUE
else if(pressure == "input")
- pressure = tgui_input_num(usr, "New output pressure (0-[open_pressure] kPa):", name, close_pressure)
+ pressure = input("New output pressure (0-[open_pressure] kPa):", name, close_pressure) as num|null
if(!isnull(pressure) && !..())
. = TRUE
else if(text2num(pressure) != null)
diff --git a/code/modules/atmospherics/machinery/components/unary_devices/thermomachine.dm b/code/modules/atmospherics/machinery/components/unary_devices/thermomachine.dm
index c8ed757b29..cff08d0d02 100644
--- a/code/modules/atmospherics/machinery/components/unary_devices/thermomachine.dm
+++ b/code/modules/atmospherics/machinery/components/unary_devices/thermomachine.dm
@@ -59,10 +59,10 @@
/obj/machinery/atmospherics/components/unary/thermomachine/examine(mob/user)
. = ..()
- . += "The thermostat is set to [target_temperature]K ([(T0C-target_temperature)*-1]C)."
+ . += "The thermostat is set to [target_temperature]K ([target_temperature-T0C]C)."
if(in_range(user, src) || isobserver(user))
- . += "The status display reads: Efficiency [(heat_capacity/5000)*100]%."
- . += "Temperature range [min_temperature]K - [max_temperature]K ([(T0C-min_temperature)*-1]C - [(T0C-max_temperature)*-1]C)."
+ . += "The status display reads: Effective heat capacity [heat_capacity] J/K."
+ . += "Temperature range [min_temperature]K - [max_temperature]K ([min_temperature-T0C]C - [max_temperature-T0C]C)."
/obj/machinery/atmospherics/components/unary/thermomachine/process_atmos()
..()
@@ -158,7 +158,7 @@
var/target = params["target"]
var/adjust = text2num(params["adjust"])
if(target == "input")
- target = tgui_input_num(usr, "Set new target ([min_temperature]-[max_temperature] K):", name, target_temperature)
+ target = input("Set new target ([min_temperature]-[max_temperature] K):", name, target_temperature) as num|null
if(!isnull(target))
. = TRUE
else if(adjust)
diff --git a/code/modules/atmospherics/machinery/portable/canister.dm b/code/modules/atmospherics/machinery/portable/canister.dm
index e99ac55357..868c5dafa3 100644
--- a/code/modules/atmospherics/machinery/portable/canister.dm
+++ b/code/modules/atmospherics/machinery/portable/canister.dm
@@ -388,7 +388,7 @@
return
switch(action)
if("relabel")
- var/label = tgui_input_list(usr, "New canister label:", name, sortList(label2types))
+ var/label = input("New canister label:", name) as null|anything in sortList(label2types)
if(label && !..())
var/newtype = label2types[label]
if(newtype)
@@ -416,7 +416,7 @@
pressure = can_max_release_pressure
. = TRUE
else if(pressure == "input")
- pressure = tgui_input_num(usr, "New release pressure ([can_min_release_pressure]-[can_max_release_pressure] kPa):", name, release_pressure)
+ pressure = input("New release pressure ([can_min_release_pressure]-[can_max_release_pressure] kPa):", name, release_pressure) as num|null
if(!isnull(pressure) && !..())
. = TRUE
else if(text2num(pressure) != null)
@@ -461,7 +461,7 @@
if("increase")
timer_set = min(maximum_timer_set, timer_set + 10)
if("input")
- var/user_input = tgui_input_num(usr, "Set time to valve toggle.", name, timer_set)
+ var/user_input = input(usr, "Set time to valve toggle.", name) as null|num
if(!user_input)
return
var/N = text2num(user_input)
diff --git a/code/modules/awaymissions/bluespaceartillery.dm b/code/modules/awaymissions/bluespaceartillery.dm
index 0dafac89d1..ee4090b680 100644
--- a/code/modules/awaymissions/bluespaceartillery.dm
+++ b/code/modules/awaymissions/bluespaceartillery.dm
@@ -38,7 +38,7 @@
if(..())
return
var/A
- A = tgui_input_list(usr, "Area to bombard", "Open Fire", GLOB.teleportlocs)
+ A = input("Area to bombard", "Open Fire", A) in GLOB.teleportlocs
var/area/thearea = GLOB.teleportlocs[A]
if(usr.stat || usr.restrained())
return
diff --git a/code/modules/awaymissions/capture_the_flag.dm b/code/modules/awaymissions/capture_the_flag.dm
index d76c85848c..d32905e007 100644
--- a/code/modules/awaymissions/capture_the_flag.dm
+++ b/code/modules/awaymissions/capture_the_flag.dm
@@ -210,7 +210,7 @@
/obj/machinery/capture_the_flag/attack_ghost(mob/user)
if(ctf_enabled == FALSE)
if(user.client && user.client.holder)
- var/response = tgui_alert(user, "Enable CTF?", "CTF", list("Yes", "No"))
+ var/response = alert("Enable CTF?", "CTF", "Yes", "No")
if(response == "Yes")
toggle_all_ctf(user)
return
diff --git a/code/modules/awaymissions/corpse.dm b/code/modules/awaymissions/corpse.dm
index 27138a9d40..cd5c2f76f3 100644
--- a/code/modules/awaymissions/corpse.dm
+++ b/code/modules/awaymissions/corpse.dm
@@ -49,7 +49,7 @@
var/mob/dead/observer/O = user
if(!O.can_reenter_round() && !skip_reentry_check)
return FALSE
- var/ghost_role = tgui_alert(user, latejoinercalling ? "Latejoin as [mob_name]? (This is a ghost role, and as such, it's very likely to be off-station.)" : "Become [mob_name]? (Warning, You can no longer be cloned!)",,list("Yes","No"))
+ var/ghost_role = alert(latejoinercalling ? "Latejoin as [mob_name]? (This is a ghost role, and as such, it's very likely to be off-station.)" : "Become [mob_name]? (Warning, You can no longer be cloned!)",,"Yes","No")
if(ghost_role == "No" || !loc)
return
if(QDELETED(src) || QDELETED(user))
@@ -595,7 +595,7 @@
job_description = "Space Bar Patron"
/obj/effect/mob_spawn/human/alive/space_bar_patron/on_attack_hand(mob/user, act_intent = user.a_intent, unarmed_attack_flags)
- var/despawn = tgui_alert(user, "Return to cryosleep? (Warning, Your mob will be deleted!)",,list("Yes","No"))
+ var/despawn = alert("Return to cryosleep? (Warning, Your mob will be deleted!)",,"Yes","No")
if(despawn == "No" || !loc || !Adjacent(user))
return
user.visible_message("[user.name] climbs back into cryosleep...")
diff --git a/code/modules/awaymissions/mission_code/stationCollision.dm b/code/modules/awaymissions/mission_code/stationCollision.dm
index 434dc673f7..962abc59fd 100644
--- a/code/modules/awaymissions/mission_code/stationCollision.dm
+++ b/code/modules/awaymissions/mission_code/stationCollision.dm
@@ -149,5 +149,5 @@ GLOBAL_VAR_INIT(sc_safecode5, "[rand(0,9)]")
if(prob(25))
mezzer()
-/obj/singularity/narsie/mini/ex_act()
+/obj/singularity/narsie/mini/ex_act(severity, target, origin)
return
diff --git a/code/modules/awaymissions/mission_code/wildwest.dm b/code/modules/awaymissions/mission_code/wildwest.dm
index a027995acc..bc7e2cbd08 100644
--- a/code/modules/awaymissions/mission_code/wildwest.dm
+++ b/code/modules/awaymissions/mission_code/wildwest.dm
@@ -88,7 +88,7 @@
else
chargesa--
insistinga = 0
- var/wish = tgui_input_list(usr, "You want...","Wish", list("Power","Wealth","Immortality","To Kill","Peace"))
+ var/wish = input("You want...","Wish") as null|anything in list("Power","Wealth","Immortality","To Kill","Peace")
switch(wish)
if("Power")
to_chat(user, "Your wish is granted, but at a terrible cost...")
diff --git a/code/modules/awaymissions/signpost.dm b/code/modules/awaymissions/signpost.dm
index 76f4e004bd..4d85d947c2 100644
--- a/code/modules/awaymissions/signpost.dm
+++ b/code/modules/awaymissions/signpost.dm
@@ -16,7 +16,7 @@
. = ..()
if(.)
return
- if(tgui_alert(user, question,name,list("Yes","No")) == "Yes" && Adjacent(user))
+ if(alert(question,name,"Yes","No") == "Yes" && Adjacent(user))
var/turf/T = find_safe_turf(zlevels=zlevels)
if(T)
diff --git a/code/modules/buildmode/submodes/advanced.dm b/code/modules/buildmode/submodes/advanced.dm
index 69cb6ec588..418f504777 100644
--- a/code/modules/buildmode/submodes/advanced.dm
+++ b/code/modules/buildmode/submodes/advanced.dm
@@ -17,16 +17,16 @@
to_chat(c, "***********************************************************")
/datum/buildmode_mode/advanced/change_settings(client/c)
- var/target_path = tgui_input_text(c, "Enter typepath:", "Typepath", "/obj/structure/closet")
+ var/target_path = input(c, "Enter typepath:", "Typepath", "/obj/structure/closet")
objholder = text2path(target_path)
if(!ispath(objholder))
objholder = pick_closest_path(target_path)
if(!objholder)
- tgui_alert(c, "No path was selected")
+ alert("No path was selected")
return
else if(ispath(objholder, /area))
objholder = null
- tgui_alert(c, "That path is not allowed.")
+ alert("That path is not allowed.")
return
/datum/buildmode_mode/advanced/handle_click(client/c, params, obj/object)
diff --git a/code/modules/buildmode/submodes/area_edit.dm b/code/modules/buildmode/submodes/area_edit.dm
index e5ee2babf3..19f536e073 100644
--- a/code/modules/buildmode/submodes/area_edit.dm
+++ b/code/modules/buildmode/submodes/area_edit.dm
@@ -28,10 +28,10 @@
to_chat(c, "***********************************************************")
/datum/buildmode_mode/area_edit/change_settings(client/c)
- var/target_path = tgui_input_text(c, "Enter typepath:", "Typepath", "/area")
+ var/target_path = input(c, "Enter typepath:", "Typepath", "/area")
var/areatype = text2path(target_path)
if(ispath(areatype,/area))
- var/areaname = tgui_input_text(c, "Enter area name:", "Area name", "Area")
+ var/areaname = input(c, "Enter area name:", "Area name", "Area")
if(!areaname || !length(areaname))
return
storedarea = new areatype
diff --git a/code/modules/buildmode/submodes/boom.dm b/code/modules/buildmode/submodes/boom.dm
index fc18154206..8340a21b0f 100644
--- a/code/modules/buildmode/submodes/boom.dm
+++ b/code/modules/buildmode/submodes/boom.dm
@@ -14,19 +14,19 @@
to_chat(c, "***********************************************************")
/datum/buildmode_mode/boom/change_settings(client/c)
- devastation = tgui_input_num(c, "Range of total devastation. -1 to none", text("Input"))
+ devastation = input(c, "Range of total devastation. -1 to none", text("Input")) as num|null
if(devastation == null)
devastation = -1
- heavy = tgui_input_num(c, "Range of heavy impact. -1 to none", text("Input"))
+ heavy = input(c, "Range of heavy impact. -1 to none", text("Input")) as num|null
if(heavy == null)
heavy = -1
- light = tgui_input_num(c, "Range of light impact. -1 to none", text("Input"))
+ light = input(c, "Range of light impact. -1 to none", text("Input")) as num|null
if(light == null)
light = -1
- flash = tgui_input_num(c, "Range of flash. -1 to none", text("Input"))
+ flash = input(c, "Range of flash. -1 to none", text("Input")) as num|null
if(flash == null)
flash = -1
- flames = tgui_input_num(c, "Range of flames. -1 to none", text("Input"))
+ flames = input(c, "Range of flames. -1 to none", text("Input")) as num|null
if(flames == null)
flames = -1
diff --git a/code/modules/buildmode/submodes/fill.dm b/code/modules/buildmode/submodes/fill.dm
index a37937b5f4..b7d87edef2 100644
--- a/code/modules/buildmode/submodes/fill.dm
+++ b/code/modules/buildmode/submodes/fill.dm
@@ -1,6 +1,6 @@
/datum/buildmode_mode/fill
key = "fill"
-
+
use_corner_selection = TRUE
var/objholder = null
@@ -12,16 +12,16 @@
to_chat(c, "***********************************************************")
/datum/buildmode_mode/fill/change_settings(client/c)
- var/target_path = tgui_input_text(c, "Enter typepath:" ,"Typepath","/obj/structure/closet")
+ var/target_path = input(c, "Enter typepath:" ,"Typepath","/obj/structure/closet")
objholder = text2path(target_path)
if(!ispath(objholder))
objholder = pick_closest_path(target_path)
if(!objholder)
- tgui_alert(c, "No path has been selected.")
+ alert("No path has been selected.")
return
else if(ispath(objholder, /area))
objholder = null
- tgui_alert(c, "Area paths are not supported for this mode, use the area edit mode instead.")
+ alert("Area paths are not supported for this mode, use the area edit mode instead.")
return
deselect_region()
diff --git a/code/modules/buildmode/submodes/mapgen.dm b/code/modules/buildmode/submodes/mapgen.dm
index 34bd0ddf6c..7ed99afd50 100644
--- a/code/modules/buildmode/submodes/mapgen.dm
+++ b/code/modules/buildmode/submodes/mapgen.dm
@@ -16,7 +16,7 @@
for(var/path in gen_paths)
var/datum/mapGenerator/MP = path
options[initial(MP.buildmode_name)] = path
- var/type = tgui_input_list(c,"Select Generator Type","Type", options)
+ var/type = input(c,"Select Generator Type","Type") as null|anything in options
if(!type)
return
@@ -42,7 +42,7 @@
return
G.defineRegion(cornerA, cornerB, 1)
highlight_region(G.map)
- var/confirm = tgui_alert(c, "Are you sure you want run the map generator?", "Run generator", list("Yes", "No"))
+ var/confirm = alert("Are you sure you want run the map generator?", "Run generator", "Yes", "No")
if(confirm == "Yes")
G.generate()
log_admin("Build Mode: [key_name(c)] ran the map generator '[G.buildmode_name]' in the region from [AREACOORD(cornerA)] to [AREACOORD(cornerB)]")
diff --git a/code/modules/buildmode/submodes/variable_edit.dm b/code/modules/buildmode/submodes/variable_edit.dm
index 9b09e41c68..ac4c1ef66a 100644
--- a/code/modules/buildmode/submodes/variable_edit.dm
+++ b/code/modules/buildmode/submodes/variable_edit.dm
@@ -22,8 +22,8 @@
valueholder = null
/datum/buildmode_mode/varedit/change_settings(client/c)
- varholder = tgui_input_text(c, "Enter variable name:" ,"Name", "name")
-
+ varholder = input(c, "Enter variable name:" ,"Name", "name")
+
if(!vv_varname_lockcheck(varholder))
return
diff --git a/code/modules/cargo/blackmarket/blackmarket_uplink.dm b/code/modules/cargo/blackmarket/blackmarket_uplink.dm
index 830b4a6b6a..7d5b333f13 100644
--- a/code/modules/cargo/blackmarket/blackmarket_uplink.dm
+++ b/code/modules/cargo/blackmarket/blackmarket_uplink.dm
@@ -1,6 +1,6 @@
/obj/item/blackmarket_uplink
name = "Black Market Uplink"
- desc = "A mishmash of a subspace amplifier, a radio, and an analyzer. Somehow able to access the black market, with a variable inventory in limited stock at inflated prices. No refunds, customer responsible for pick-ups."
+ desc = "A mishmash of a subspace amplifier, a radio, and an analyzer. Somehow able to access the black market, with a variable inventory in limited stock at inflated prices. No refunds, customer responsible for pick-ups."
icon = 'icons/obj/blackmarket.dmi'
icon_state = "uplink"
// UI variables.
@@ -35,7 +35,7 @@
/obj/item/blackmarket_uplink/AltClick(mob/user)
if(!isliving(user) || !user.canUseTopic(src, BE_CLOSE, FALSE, NO_TK))
return
- var/amount_to_remove = FLOOR(tgui_input_num(user, "How much do you want to withdraw? Current Amount: [money]", "Withdraw Funds", 5), 1)
+ var/amount_to_remove = FLOOR(input(user, "How much do you want to withdraw? Current Amount: [money]", "Withdraw Funds", 5) as num|null, 1)
if(!user.canUseTopic(src, BE_CLOSE, FALSE, NO_TK))
return
if(!amount_to_remove || amount_to_remove < 0)
diff --git a/code/modules/cargo/centcom_podlauncher.dm b/code/modules/cargo/centcom_podlauncher.dm
index f5490d5e85..e4060de1a2 100644
--- a/code/modules/cargo/centcom_podlauncher.dm
+++ b/code/modules/cargo/centcom_podlauncher.dm
@@ -284,11 +284,11 @@
var/list/expNames = list("Devastation", "Heavy Damage", "Light Damage", "Flame") //Explosions have a range of different types of damage
var/list/boomInput = list()
for (var/i=1 to expNames.len) //Gather input from the user for the value of each type of damage
- boomInput.Add(tgui_input_num(usr, "Enter the [expNames[i]] range of the explosion. WARNING: This ignores the bomb cap!", "[expNames[i]] Range", 0))
+ boomInput.Add(input("Enter the [expNames[i]] range of the explosion. WARNING: This ignores the bomb cap!", "[expNames[i]] Range", 0) as null|num)
if (isnull(boomInput[i]))
return
if (!isnum(boomInput[i])) //If the user doesn't input a number, set that specific explosion value to zero
- tgui_alert(usr, "That wasn't a number! Value set to default (zero) instead.")
+ alert(usr, "That wasn't a number! Value set to default (zero) instead.")
boomInput = 0
explosionChoice = 1
temp_pod.explosionSize = boomInput
@@ -306,11 +306,11 @@
damageChoice = 0
temp_pod.damage = 0
return
- var/damageInput = tgui_input_num(usr, "Enter the amount of brute damage dealt by getting hit","How much damage to deal", 0)
+ var/damageInput = input("Enter the amount of brute damage dealt by getting hit","How much damage to deal", 0) as null|num
if (isnull(damageInput))
return
if (!isnum(damageInput)) //Sanitize the input for damage to deal.s
- tgui_alert(usr, "That wasn't a number! Value set to default (zero) instead.")
+ alert(usr, "That wasn't a number! Value set to default (zero) instead.")
damageInput = 0
damageChoice = 1
temp_pod.damage = damageInput
@@ -330,10 +330,10 @@
temp_pod.adminNamed = FALSE
temp_pod.setStyle(temp_pod.style) //This resets the name of the pod based on it's current style (see supplypod/setStyle() proc)
return
- var/nameInput= tgui_input_text(usr, "Custom name", "Enter a custom name", GLOB.podstyles[temp_pod.style][POD_NAME])
+ var/nameInput= input("Custom name", "Enter a custom name", GLOB.podstyles[temp_pod.style][POD_NAME]) as null|text //Gather input for name and desc
if (isnull(nameInput))
return
- var/descInput = tgui_input_text(usr, "Custom description", "Enter a custom desc", GLOB.podstyles[temp_pod.style][POD_DESC]) //The GLOB.podstyles is used to get the name, desc, or icon state based on the pod's style
+ var/descInput = input("Custom description", "Enter a custom desc", GLOB.podstyles[temp_pod.style][POD_DESC]) as null|text //The GLOB.podstyles is used to get the name, desc, or icon state based on the pod's style
if (isnull(descInput))
return
temp_pod.name = nameInput
@@ -344,14 +344,14 @@
if (temp_pod.effectShrapnel == TRUE) //If already doing custom damage, set back to default (no shrapnel)
temp_pod.effectShrapnel = FALSE
return
- var/shrapnelInput = tgui_input_list(usr, "Please enter the type of pellet cloud you'd like to create on landing (Can be any projectile!)", "Projectile Typepath", sortList(subtypesof(/obj/item/projectile), /proc/cmp_typepaths_asc))
+ var/shrapnelInput = input("Please enter the type of pellet cloud you'd like to create on landing (Can be any projectile!)", "Projectile Typepath", 0) in sortList(subtypesof(/obj/item/projectile), /proc/cmp_typepaths_asc)
if (isnull(shrapnelInput))
return
- var/shrapnelMagnitude = tgui_input_num(usr, "Enter the magnitude of the pellet cloud. This is usually a value around 1-5. Please note that Ryll-Ryll has asked me to tell you that if you go too crazy with the projectiles you might crash the server. So uh, be gentle!", "Shrapnel Magnitude", 0)
+ var/shrapnelMagnitude = input("Enter the magnitude of the pellet cloud. This is usually a value around 1-5. Please note that Ryll-Ryll has asked me to tell you that if you go too crazy with the projectiles you might crash the server. So uh, be gentle!", "Shrapnel Magnitude", 0) as null|num
if (isnull(shrapnelMagnitude))
return
if (!isnum(shrapnelMagnitude))
- tgui_alert(usr, "That wasn't a number! Value set to 3 instead.")
+ alert(usr, "That wasn't a number! Value set to 3 instead.")
shrapnelMagnitude = 3
temp_pod.shrapnel_type = shrapnelInput
temp_pod.shrapnel_magnitude = shrapnelMagnitude
@@ -403,7 +403,7 @@
specificTarget = null
return
var/list/mobs = getpois()//code stolen from observer.dm
- var/inputTarget = tgui_input_list(usr, "Select a mob! (Smiting does this automatically)", "Target", mobs)
+ var/inputTarget = input("Select a mob! (Smiting does this automatically)", "Target", null, null) as null|anything in mobs
if (isnull(inputTarget))
return
var/mob/target = mobs[inputTarget]
@@ -448,11 +448,11 @@
if (found.file == tempSound.file)
soundLen = found.len
if (!soundLen)
- soundLen = tgui_input_num(holder, "Couldn't auto-determine sound file length. What is the exact length of the sound file, in seconds. This number will be used to line the sound up so that it finishes right as the pod lands!", "Pick a Sound File", 0.3)
+ soundLen = input(holder, "Couldn't auto-determine sound file length. What is the exact length of the sound file, in seconds. This number will be used to line the sound up so that it finishes right as the pod lands!", "Pick a Sound File", 0.3) as null|num
if (isnull(soundLen))
return
if (!isnum(soundLen))
- tgui_alert(usr, "That wasn't a number! Value set to default ([initial(temp_pod.fallingSoundLength)*0.1]) instead.")
+ alert(usr, "That wasn't a number! Value set to default ([initial(temp_pod.fallingSoundLength)*0.1]) instead.")
temp_pod.fallingSound = soundInput
temp_pod.fallingSoundLength = 10 * soundLen
. = TRUE
@@ -487,7 +487,7 @@
if (temp_pod.soundVolume != initial(temp_pod.soundVolume))
temp_pod.soundVolume = initial(temp_pod.soundVolume)
return
- var/soundInput = tgui_input_num(holder, "Please pick a volume. Default is between 1 and 100 with 50 being average, but pick whatever. I'm a notification, not a cop. If you still cant hear your sound, consider turning on the Quiet effect. It will silence all pod sounds except for the custom admin ones set by the previous three buttons.", "Pick Admin Sound Volume")
+ var/soundInput = input(holder, "Please pick a volume. Default is between 1 and 100 with 50 being average, but pick whatever. I'm a notification, not a cop. If you still cant hear your sound, consider turning on the Quiet effect. It will silence all pod sounds except for the custom admin ones set by the previous three buttons.", "Pick Admin Sound Volume") as null|num
if (isnull(soundInput))
return
temp_pod.soundVolume = soundInput
@@ -521,7 +521,7 @@
updateSelector()
. = TRUE
if("clearBay") //Delete all mobs and objs in the selected bay
- if(tgui_alert(usr, "This will delete all objs and mobs in [bay]. Are you sure?", "Confirmation", list("Delete that shit", "No")) == "Delete that shit")
+ if(alert(usr, "This will delete all objs and mobs in [bay]. Are you sure?", "Confirmation", "Delete that shit", "No") == "Delete that shit")
clearBay()
refreshBay()
. = TRUE
diff --git a/code/modules/cargo/supplypod.dm b/code/modules/cargo/supplypod.dm
index 3d2264a593..749e1ad247 100644
--- a/code/modules/cargo/supplypod.dm
+++ b/code/modules/cargo/supplypod.dm
@@ -187,10 +187,10 @@
else
..()
-/obj/structure/closet/supplypod/ex_act() //Explosions dont do SHIT TO US! This is because supplypods create explosions when they land.
+/obj/structure/closet/supplypod/ex_act(severity, target, origin) //Explosions dont do SHIT TO US! This is because supplypods create explosions when they land.
return
-/obj/structure/closet/supplypod/contents_explosion() //Supplypods also protect their contents from the harmful effects of fucking exploding.
+/obj/structure/closet/supplypod/contents_explosion(severity, target, origin) //Supplypods also protect their contents from the harmful effects of fucking exploding.
return
/obj/structure/closet/supplypod/toggle(mob/living/user)
diff --git a/code/modules/client/client_procs.dm b/code/modules/client/client_procs.dm
index b9589d02bc..6f4c357eef 100644
--- a/code/modules/client/client_procs.dm
+++ b/code/modules/client/client_procs.dm
@@ -82,6 +82,10 @@ GLOBAL_LIST_INIT(blacklisted_builds, list(
if(CONFIG_GET(flag/emergency_tgui_logging))
log_href("[src] (usr:[usr]\[[COORD(usr)]\]) : [hsrc ? "[hsrc] " : ""][href]")
return
+ if(href_list["reload_tguipanel"])
+ nuke_chat()
+ if(href_list["reload_statbrowser"])
+ src << browse(file('html/statbrowser.html'), "window=statbrowser")
last_activity = world.time
@@ -355,11 +359,11 @@ GLOBAL_LIST_INIT(blacklisted_builds, list(
// Initialize tgui panel
tgui_panel.initialize()
src << browse(file('html/statbrowser.html'), "window=statbrowser")
-
+ addtimer(CALLBACK(src, .proc/check_panel_loaded), 30 SECONDS)
if(alert_mob_dupe_login)
spawn()
- tgui_alert(mob, "You have logged in already with another key this round, please log out of this one NOW or risk being banned!")
+ alert(mob, "You have logged in already with another key this round, please log out of this one NOW or risk being banned!")
connection_time = world.time
connection_realtime = world.realtime
@@ -1091,6 +1095,11 @@ GLOBAL_LIST_INIT(blacklisted_builds, list(
verblist[++verblist.len] = list(verb_to_init.category, verb_to_init.name)
src << output("[url_encode(json_encode(verb_tabs))];[url_encode(json_encode(verblist))]", "statbrowser:init_verbs")
+/client/proc/check_panel_loaded()
+ if(statbrowser_ready)
+ return
+ to_chat(src, span_userdanger("Statpanel failed to load, click here to reload the panel "))
+
//increment progress for an unlockable loadout item
/client/proc/increment_progress(key, amount)
if(prefs)
diff --git a/code/modules/client/preferences.dm b/code/modules/client/preferences.dm
index 90fd95bdf0..cb262e57f3 100644
--- a/code/modules/client/preferences.dm
+++ b/code/modules/client/preferences.dm
@@ -1612,17 +1612,17 @@ GLOBAL_LIST_EMPTY(preferences_datums)
switch(href_list["preference"])
if("ghostform")
if(unlock_content)
- var/new_form = tgui_input_list(user, "Thanks for supporting BYOND - Choose your ghostly form:","Thanks for supporting BYOND", GLOB.ghost_forms)
+ var/new_form = input(user, "Thanks for supporting BYOND - Choose your ghostly form:","Thanks for supporting BYOND",null) as null|anything in GLOB.ghost_forms
if(new_form)
ghost_form = new_form
if("ghostorbit")
if(unlock_content)
- var/new_orbit = tgui_input_list(user, "Thanks for supporting BYOND - Choose your ghostly orbit:","Thanks for supporting BYOND", GLOB.ghost_orbits)
+ var/new_orbit = input(user, "Thanks for supporting BYOND - Choose your ghostly orbit:","Thanks for supporting BYOND", null) as null|anything in GLOB.ghost_orbits
if(new_orbit)
ghost_orbit = new_orbit
if("ghostaccs")
- var/new_ghost_accs = tgui_alert(user, "Do you want your ghost to show full accessories where possible, hide accessories but still use the directional sprites where possible, or also ignore the directions and stick to the default sprites?",,list(GHOST_ACCS_FULL_NAME, GHOST_ACCS_DIR_NAME, GHOST_ACCS_NONE_NAME))
+ var/new_ghost_accs = alert("Do you want your ghost to show full accessories where possible, hide accessories but still use the directional sprites where possible, or also ignore the directions and stick to the default sprites?",,GHOST_ACCS_FULL_NAME, GHOST_ACCS_DIR_NAME, GHOST_ACCS_NONE_NAME)
switch(new_ghost_accs)
if(GHOST_ACCS_FULL_NAME)
ghost_accs = GHOST_ACCS_FULL
@@ -1632,7 +1632,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
ghost_accs = GHOST_ACCS_NONE
if("ghostothers")
- var/new_ghost_others = tgui_alert(user, "Do you want the ghosts of others to show up as their own setting, as their default sprites or always as the default white ghost?",,list(GHOST_OTHERS_THEIR_SETTING_NAME, GHOST_OTHERS_DEFAULT_SPRITE_NAME, GHOST_OTHERS_SIMPLE_NAME))
+ var/new_ghost_others = alert("Do you want the ghosts of others to show up as their own setting, as their default sprites or always as the default white ghost?",,GHOST_OTHERS_THEIR_SETTING_NAME, GHOST_OTHERS_DEFAULT_SPRITE_NAME, GHOST_OTHERS_SIMPLE_NAME)
switch(new_ghost_others)
if(GHOST_OTHERS_THEIR_SETTING_NAME)
ghost_others = GHOST_OTHERS_THEIR_SETTING
@@ -1642,7 +1642,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
ghost_others = GHOST_OTHERS_SIMPLE
if("name")
- var/new_name = tgui_input_text(user, "Choose your character's name:", "Character Preference", real_name)
+ var/new_name = input(user, "Choose your character's name:", "Character Preference") as text|null
if(new_name)
new_name = reject_bad_name(new_name)
if(new_name)
@@ -1651,7 +1651,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
to_chat(user, "Invalid name. Your name should be at least 2 and at most [MAX_NAME_LEN] characters long. It may only contain the characters A-Z, a-z, -, ' and .")
if("age")
- var/new_age = tgui_input_num(user, "Choose your character's age:\n([AGE_MIN]-[AGE_MAX])", "Character Preference", age)
+ var/new_age = input(user, "Choose your character's age:\n([AGE_MIN]-[AGE_MAX])", "Character Preference") as num|null
if(new_age)
age = max(min( round(text2num(new_age)), AGE_MAX),AGE_MIN)
@@ -1692,7 +1692,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
if("hair_style")
var/new_hair_style
- new_hair_style = tgui_input_list(user, "Choose your character's hair style:", "Character Preference", GLOB.hair_styles_list)
+ new_hair_style = input(user, "Choose your character's hair style:", "Character Preference") as null|anything in GLOB.hair_styles_list
if(new_hair_style)
hair_style = new_hair_style
@@ -1709,7 +1709,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
if("facial_hair_style")
var/new_facial_hair_style
- new_facial_hair_style = tgui_input_list(user, "Choose your character's facial-hair style:", "Character Preference", GLOB.facial_hair_styles_list)
+ new_facial_hair_style = input(user, "Choose your character's facial-hair style:", "Character Preference") as null|anything in GLOB.facial_hair_styles_list
if(new_facial_hair_style)
facial_hair_style = new_facial_hair_style
@@ -1726,7 +1726,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
if("grad_style")
var/new_grad_style
- new_grad_style = tgui_input_list(user, "Choose your character's hair gradient style:", "Character Preference", GLOB.hair_gradients_list)
+ new_grad_style = input(user, "Choose your character's hair gradient style:", "Character Preference") as null|anything in GLOB.hair_gradients_list
if(new_grad_style)
grad_style = new_grad_style
@@ -1740,12 +1740,12 @@ GLOBAL_LIST_EMPTY(preferences_datums)
bgstate = next_list_item(bgstate, bgstate_options)
if("modify_limbs")
- var/limb_type = tgui_input_list(user, "Choose the limb to modify:", "Character Preference", LOADOUT_ALLOWED_LIMB_TARGETS)
+ var/limb_type = input(user, "Choose the limb to modify:", "Character Preference") as null|anything in LOADOUT_ALLOWED_LIMB_TARGETS
if(limb_type)
- var/modification_type = tgui_input_list(user, "Choose the modification to the limb:", "Character Preference", LOADOUT_LIMBS)
+ var/modification_type = input(user, "Choose the modification to the limb:", "Character Preference") as null|anything in LOADOUT_LIMBS
if(modification_type)
if(modification_type == LOADOUT_LIMB_PROSTHETIC)
- var/prosthetic_type = tgui_input_list(user, "Choose the type of prosthetic", "Character Preference", list("prosthetic") + GLOB.prosthetic_limb_types)
+ var/prosthetic_type = input(user, "Choose the type of prosthetic", "Character Preference") as null|anything in (list("prosthetic") + GLOB.prosthetic_limb_types)
if(prosthetic_type)
var/number_of_prosthetics = 0
for(var/modified_limb in modified_limbs)
@@ -1763,7 +1763,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
modified_limbs[limb_type] = list(modification_type)
if("underwear")
- var/new_underwear = tgui_input_list(user, "Choose your character's underwear:", "Character Preference", GLOB.underwear_list)
+ var/new_underwear = input(user, "Choose your character's underwear:", "Character Preference") as null|anything in GLOB.underwear_list
if(new_underwear)
underwear = new_underwear
@@ -1773,7 +1773,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
undie_color = sanitize_hexcolor(n_undie_color, 6)
if("undershirt")
- var/new_undershirt = tgui_input_list(user, "Choose your character's undershirt:", "Character Preference", GLOB.undershirt_list)
+ var/new_undershirt = input(user, "Choose your character's undershirt:", "Character Preference") as null|anything in GLOB.undershirt_list
if(new_undershirt)
undershirt = new_undershirt
@@ -1783,7 +1783,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
shirt_color = sanitize_hexcolor(n_shirt_color, 6)
if("socks")
- var/new_socks = tgui_input_list(user, "Choose your character's socks:", "Character Preference", GLOB.socks_list)
+ var/new_socks = input(user, "Choose your character's socks:", "Character Preference") as null|anything in GLOB.socks_list
if(new_socks)
socks = new_socks
@@ -1809,7 +1809,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
right_eye_color = sanitize_hexcolor(new_eyes, 6)
if("eye_type")
- var/new_eye_type = tgui_input_list(user, "Choose your character's eye type.", "Character Preference", GLOB.eye_types)
+ var/new_eye_type = input(user, "Choose your character's eye type.", "Character Preference") as null|anything in GLOB.eye_types
if(new_eye_type)
eye_type = new_eye_type
@@ -1818,7 +1818,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
right_eye_color = left_eye_color
if("species")
- var/result = tgui_input_list(user, "Select a species", "Species Selection", GLOB.roundstart_race_names)
+ var/result = input(user, "Select a species", "Species Selection") as null|anything in GLOB.roundstart_race_names
if(result)
var/newtype = GLOB.species_list[GLOB.roundstart_race_names[result]]
pref_species = new newtype()
@@ -1848,7 +1848,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
eye_type = pref_species.eye_type
if("custom_species")
- var/new_species = reject_bad_name(tgui_input_text(user, "Choose your species subtype, if unique. This will show up on examinations and health scans. Do not abuse this:", "Character Preference", custom_species))
+ var/new_species = reject_bad_name(input(user, "Choose your species subtype, if unique. This will show up on examinations and health scans. Do not abuse this:", "Character Preference", custom_species) as null|text)
if(new_species)
custom_species = new_species
else
@@ -1892,7 +1892,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
if("ipc_screen")
var/new_ipc_screen
- new_ipc_screen = tgui_input_list(user, "Choose your character's screen:", "Character Preference", GLOB.ipc_screens_list)
+ new_ipc_screen = input(user, "Choose your character's screen:", "Character Preference") as null|anything in GLOB.ipc_screens_list
if(new_ipc_screen)
features["ipc_screen"] = new_ipc_screen
@@ -1908,31 +1908,31 @@ GLOBAL_LIST_EMPTY(preferences_datums)
if((!S.ckeys_allowed) || (S.ckeys_allowed.Find(user.client.ckey)))
snowflake_antenna_list[S.name] = path
var/new_ipc_antenna
- new_ipc_antenna = tgui_input_list(user, "Choose your character's antenna:", "Character Preference", snowflake_antenna_list)
+ new_ipc_antenna = input(user, "Choose your character's antenna:", "Character Preference") as null|anything in snowflake_antenna_list
if(new_ipc_antenna)
features["ipc_antenna"] = new_ipc_antenna
if("arachnid_legs")
var/new_arachnid_legs
- new_arachnid_legs = tgui_input_list(user, "Choose your character's variant of arachnid legs:", "Character Preference", GLOB.arachnid_legs_list)
+ new_arachnid_legs = input(user, "Choose your character's variant of arachnid legs:", "Character Preference") as null|anything in GLOB.arachnid_legs_list
if(new_arachnid_legs)
features["arachnid_legs"] = new_arachnid_legs
if("arachnid_spinneret")
var/new_arachnid_spinneret
- new_arachnid_spinneret = tgui_input_list(user, "Choose your character's spinneret markings:", "Character Preference", GLOB.arachnid_spinneret_list)
+ new_arachnid_spinneret = input(user, "Choose your character's spinneret markings:", "Character Preference") as null|anything in GLOB.arachnid_spinneret_list
if(new_arachnid_spinneret)
features["arachnid_spinneret"] = new_arachnid_spinneret
if("arachnid_mandibles")
var/new_arachnid_mandibles
- new_arachnid_mandibles = tgui_input_list(user, "Choose your character's variant of mandibles:", "Character Preference", GLOB.arachnid_mandibles_list)
+ new_arachnid_mandibles = input(user, "Choose your character's variant of mandibles:", "Character Preference") as null|anything in GLOB.arachnid_mandibles_list
if (new_arachnid_mandibles)
features["arachnid_mandibles"] = new_arachnid_mandibles
if("tail_lizard")
var/new_tail
- new_tail = tgui_input_list(user, "Choose your character's tail:", "Character Preference", GLOB.tails_list_lizard)
+ new_tail = input(user, "Choose your character's tail:", "Character Preference") as null|anything in GLOB.tails_list_lizard
if(new_tail)
features["tail_lizard"] = new_tail
if(new_tail != "None")
@@ -1951,7 +1951,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
if((!S.ckeys_allowed) || (S.ckeys_allowed.Find(user.client.ckey)))
snowflake_tails_list[S.name] = path
var/new_tail
- new_tail = tgui_input_list(user, "Choose your character's tail:", "Character Preference", snowflake_tails_list)
+ new_tail = input(user, "Choose your character's tail:", "Character Preference") as null|anything in snowflake_tails_list
if(new_tail)
features["tail_human"] = new_tail
if(new_tail != "None")
@@ -1970,7 +1970,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
if((!S.ckeys_allowed) || (S.ckeys_allowed.Find(user.client.ckey)))
snowflake_tails_list[S.name] = path
var/new_tail
- new_tail = tgui_input_list(user, "Choose your character's tail:", "Character Preference", snowflake_tails_list)
+ new_tail = input(user, "Choose your character's tail:", "Character Preference") as null|anything in snowflake_tails_list
if(new_tail)
features["mam_tail"] = new_tail
if(new_tail != "None")
@@ -1980,7 +1980,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
if("meat_type")
var/new_meat
- new_meat = tgui_input_list(user, "Choose your character's meat type:", "Character Preference", GLOB.meat_types)
+ new_meat = input(user, "Choose your character's meat type:", "Character Preference") as null|anything in GLOB.meat_types
if(new_meat)
features["meat_type"] = new_meat
@@ -1995,7 +1995,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
if((!S.ckeys_allowed) || (S.ckeys_allowed.Find(user.client.ckey)))
snowflake_snouts_list[S.name] = path
var/new_snout
- new_snout = tgui_input_list(user, "Choose your character's snout:", "Character Preference", snowflake_snouts_list)
+ new_snout = input(user, "Choose your character's snout:", "Character Preference") as null|anything in snowflake_snouts_list
if(new_snout)
features["snout"] = new_snout
features["mam_snouts"] = "None"
@@ -2012,14 +2012,14 @@ GLOBAL_LIST_EMPTY(preferences_datums)
if((!S.ckeys_allowed) || (S.ckeys_allowed.Find(user.client.ckey)))
snowflake_mam_snouts_list[S.name] = path
var/new_mam_snouts
- new_mam_snouts = tgui_input_list(user, "Choose your character's snout:", "Character Preference", snowflake_mam_snouts_list)
+ new_mam_snouts = input(user, "Choose your character's snout:", "Character Preference") as null|anything in snowflake_mam_snouts_list
if(new_mam_snouts)
features["mam_snouts"] = new_mam_snouts
features["snout"] = "None"
if("horns")
var/new_horns
- new_horns = tgui_input_list(user, "Choose your character's horns:", "Character Preference", GLOB.horns_list)
+ new_horns = input(user, "Choose your character's horns:", "Character Preference") as null|anything in GLOB.horns_list
if(new_horns)
features["horns"] = new_horns
@@ -2033,7 +2033,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
if("wings")
var/new_wings
- new_wings = tgui_input_list(user, "Choose your character's wings:", "Character Preference", GLOB.r_wings_list)
+ new_wings = input(user, "Choose your character's wings:", "Character Preference") as null|anything in GLOB.r_wings_list
if(new_wings)
features["wings"] = new_wings
@@ -2047,61 +2047,61 @@ GLOBAL_LIST_EMPTY(preferences_datums)
if("frills")
var/new_frills
- new_frills = tgui_input_list(user, "Choose your character's frills:", "Character Preference", GLOB.frills_list)
+ new_frills = input(user, "Choose your character's frills:", "Character Preference") as null|anything in GLOB.frills_list
if(new_frills)
features["frills"] = new_frills
if("spines")
var/new_spines
- new_spines = tgui_input_list(user, "Choose your character's spines:", "Character Preference", GLOB.spines_list)
+ new_spines = input(user, "Choose your character's spines:", "Character Preference") as null|anything in GLOB.spines_list
if(new_spines)
features["spines"] = new_spines
if("legs")
var/new_legs
- new_legs = tgui_input_list(user, "Choose your character's legs:", "Character Preference", GLOB.legs_list)
+ new_legs = input(user, "Choose your character's legs:", "Character Preference") as null|anything in GLOB.legs_list
if(new_legs)
features["legs"] = new_legs
if("insect_wings")
var/new_insect_wings
- new_insect_wings = tgui_input_list(user, "Choose your character's wings:", "Character Preference", GLOB.insect_wings_list)
+ new_insect_wings = input(user, "Choose your character's wings:", "Character Preference") as null|anything in GLOB.insect_wings_list
if(new_insect_wings)
features["insect_wings"] = new_insect_wings
if("deco_wings")
var/new_deco_wings
- new_deco_wings = tgui_input_list(user, "Choose your character's wings:", "Character Preference", GLOB.deco_wings_list)
+ new_deco_wings = input(user, "Choose your character's wings:", "Character Preference") as null|anything in GLOB.deco_wings_list
if(new_deco_wings)
features["deco_wings"] = new_deco_wings
if("insect_fluff")
var/new_insect_fluff
- new_insect_fluff = tgui_input_list(user, "Choose your character's wings:", "Character Preference", GLOB.insect_fluffs_list)
+ new_insect_fluff = input(user, "Choose your character's wings:", "Character Preference") as null|anything in GLOB.insect_fluffs_list
if(new_insect_fluff)
features["insect_fluff"] = new_insect_fluff
if("insect_markings")
var/new_insect_markings
- new_insect_markings = tgui_input_list(user, "Choose your character's markings:", "Character Preference", GLOB.insect_markings_list)
+ new_insect_markings = input(user, "Choose your character's markings:", "Character Preference") as null|anything in GLOB.insect_markings_list
if(new_insect_markings)
features["insect_markings"] = new_insect_markings
if("arachnid_legs")
var/new_arachnid_legs
- new_arachnid_legs = tgui_input_list(user, "Choose your character's variant of arachnid legs:", "Character Preference", GLOB.arachnid_legs_list)
+ new_arachnid_legs = input(user, "Choose your character's variant of arachnid legs:", "Character Preference") as null|anything in GLOB.arachnid_legs_list
if(new_arachnid_legs)
features["arachnid_legs"] = new_arachnid_legs
if("arachnid_spinneret")
var/new_arachnid_spinneret
- new_arachnid_spinneret = tgui_input_list(user, "Choose your character's spinneret markings:", "Character Preference", GLOB.arachnid_spinneret_list)
+ new_arachnid_spinneret = input(user, "Choose your character's spinneret markings:", "Character Preference") as null|anything in GLOB.arachnid_spinneret_list
if(new_arachnid_spinneret)
features["arachnid_spinneret"] = new_arachnid_spinneret
if("arachnid_mandibles")
var/new_arachnid_mandibles
- new_arachnid_mandibles = tgui_input_list(user, "Choose your character's variant of mandibles:", "Character Preference", GLOB.arachnid_mandibles_list)
+ new_arachnid_mandibles = input(user, "Choose your character's variant of mandibles:", "Character Preference") as null|anything in GLOB.arachnid_mandibles_list
if (new_arachnid_mandibles)
features["arachnid_mandibles"] = new_arachnid_mandibles
@@ -2109,7 +2109,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
var/list/choices = GLOB.skin_tones - GLOB.nonstandard_skin_tones
if(CONFIG_GET(flag/allow_custom_skintones))
choices += "custom"
- var/new_s_tone = tgui_input_list(user, "Choose your character's skin tone:", "Character Preference", choices)
+ var/new_s_tone = input(user, "Choose your character's skin tone:", "Character Preference") as null|anything in choices
if(new_s_tone)
if(new_s_tone == "custom")
var/default = use_custom_skin_tone ? skin_tone : null
@@ -2136,7 +2136,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
if((!S.ckeys_allowed) || (S.ckeys_allowed.Find(user.client.ckey)))
snowflake_taur_list[S.name] = path
var/new_taur
- new_taur = tgui_input_list(user, "Choose your character's tauric body:", "Character Preference", snowflake_taur_list)
+ new_taur = input(user, "Choose your character's tauric body:", "Character Preference") as null|anything in snowflake_taur_list
if(new_taur)
features["taur"] = new_taur
if(new_taur != "None")
@@ -2157,7 +2157,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
if((!S.ckeys_allowed) || (S.ckeys_allowed.Find(user.client.ckey)))
snowflake_ears_list[S.name] = path
var/new_ears
- new_ears = tgui_input_list(user, "Choose your character's ears:", "Character Preference", snowflake_ears_list)
+ new_ears = input(user, "Choose your character's ears:", "Character Preference") as null|anything in snowflake_ears_list
if(new_ears)
features["ears"] = new_ears
@@ -2172,20 +2172,20 @@ GLOBAL_LIST_EMPTY(preferences_datums)
if((!S.ckeys_allowed) || (S.ckeys_allowed.Find(user.client.ckey)))
snowflake_ears_list[S.name] = path
var/new_ears
- new_ears = tgui_input_list(user, "Choose your character's ears:", "Character Preference", snowflake_ears_list)
+ new_ears = input(user, "Choose your character's ears:", "Character Preference") as null|anything in snowflake_ears_list
if(new_ears)
features["mam_ears"] = new_ears
//Xeno Bodyparts
if("xenohead")//Head or caste type
var/new_head
- new_head = tgui_input_list(user, "Choose your character's caste:", "Character Preference", GLOB.xeno_head_list)
+ new_head = input(user, "Choose your character's caste:", "Character Preference") as null|anything in GLOB.xeno_head_list
if(new_head)
features["xenohead"] = new_head
if("xenotail")//Currently one one type, more maybe later if someone sprites them. Might include animated variants in the future.
var/new_tail
- new_tail = tgui_input_list(user, "Choose your character's tail:", "Character Preference", GLOB.xeno_tail_list)
+ new_tail = input(user, "Choose your character's tail:", "Character Preference") as null|anything in GLOB.xeno_tail_list
if(new_tail)
features["xenotail"] = new_tail
if(new_tail != "None")
@@ -2196,7 +2196,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
if("xenodorsal")
var/new_dors
- new_dors = tgui_input_list(user, "Choose your character's dorsal tube type:", "Character Preference", GLOB.xeno_dorsal_list)
+ new_dors = input(user, "Choose your character's dorsal tube type:", "Character Preference") as null|anything in GLOB.xeno_dorsal_list
if(new_dors)
features["xenodorsal"] = new_dors
@@ -2239,7 +2239,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
if("cock_length")
var/min_D = CONFIG_GET(number/penis_min_inches_prefs)
var/max_D = CONFIG_GET(number/penis_max_inches_prefs)
- var/new_length = tgui_input_num(user, "Penis length in inches:\n([min_D]-[max_D])", "Character Preference", features["cock_length"])
+ var/new_length = input(user, "Penis length in inches:\n([min_D]-[max_D])", "Character Preference") as num|null
if(new_length)
features["cock_length"] = clamp(round(new_length), min_D, max_D)
@@ -2252,7 +2252,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
var/datum/sprite_accessory/penis/P = GLOB.cock_shapes_list[A]
if(P.taur_icon && T.taur_mode & P.accepted_taurs)
LAZYSET(hockeys, "[A] (Taur)", A)
- new_shape = tgui_input_list(user, "Penis shape:", "Character Preference", GLOB.cock_shapes_list + hockeys)
+ new_shape = input(user, "Penis shape:", "Character Preference") as null|anything in (GLOB.cock_shapes_list + hockeys)
if(new_shape)
features["cock_taur"] = FALSE
if(hockeys[new_shape])
@@ -2261,7 +2261,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
features["cock_shape"] = new_shape
if("cock_visibility")
- var/n_vis = tgui_input_list(user, "Penis Visibility", "Character Preference", CONFIG_GET(keyed_list/safe_visibility_toggles))
+ var/n_vis = input(user, "Penis Visibility", "Character Preference") as null|anything in CONFIG_GET(keyed_list/safe_visibility_toggles)
if(n_vis)
features["cock_visibility"] = n_vis
@@ -2277,18 +2277,18 @@ GLOBAL_LIST_EMPTY(preferences_datums)
to_chat(user,"Invalid color. Your color is not bright enough.")
if("balls_visibility")
- var/n_vis = tgui_input_list(user, "Testicles Visibility", "Character Preference", CONFIG_GET(keyed_list/safe_visibility_toggles))
+ var/n_vis = input(user, "Testicles Visibility", "Character Preference") as null|anything in CONFIG_GET(keyed_list/safe_visibility_toggles)
if(n_vis)
features["balls_visibility"] = n_vis
if("breasts_size")
- var/new_size = tgui_input_list(user, "Breast Size", "Character Preference", CONFIG_GET(keyed_list/breasts_cups_prefs))
+ var/new_size = input(user, "Breast Size", "Character Preference") as null|anything in CONFIG_GET(keyed_list/breasts_cups_prefs)
if(new_size)
features["breasts_size"] = new_size
if("breasts_shape")
var/new_shape
- new_shape = tgui_input_list(user, "Breast Shape", "Character Preference", GLOB.breasts_shapes_list)
+ new_shape = input(user, "Breast Shape", "Character Preference") as null|anything in GLOB.breasts_shapes_list
if(new_shape)
features["breasts_shape"] = new_shape
@@ -2304,13 +2304,13 @@ GLOBAL_LIST_EMPTY(preferences_datums)
to_chat(user,"Invalid color. Your color is not bright enough.")
if("breasts_visibility")
- var/n_vis = tgui_input_list(user, "Breasts Visibility", "Character Preference", CONFIG_GET(keyed_list/safe_visibility_toggles))
+ var/n_vis = input(user, "Breasts Visibility", "Character Preference") as null|anything in CONFIG_GET(keyed_list/safe_visibility_toggles)
if(n_vis)
features["breasts_visibility"] = n_vis
if("vag_shape")
var/new_shape
- new_shape = tgui_input_list(user, "Vagina Type", "Character Preference", GLOB.vagina_shapes_list)
+ new_shape = input(user, "Vagina Type", "Character Preference") as null|anything in GLOB.vagina_shapes_list
if(new_shape)
features["vag_shape"] = new_shape
@@ -2326,7 +2326,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
to_chat(user,"Invalid color. Your color is not bright enough.")
if("vag_visibility")
- var/n_vis = tgui_input_list(user, "Vagina Visibility", "Character Preference", CONFIG_GET(keyed_list/safe_visibility_toggles))
+ var/n_vis = input(user, "Vagina Visibility", "Character Preference") as null|anything in CONFIG_GET(keyed_list/safe_visibility_toggles)
if(n_vis)
features["vag_visibility"] = n_vis
@@ -2341,7 +2341,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
aooccolor = new_aooccolor
if("bag")
- var/new_backbag = tgui_input_list(user, "Choose your character's style of bag:", "Character Preference", GLOB.backbaglist)
+ var/new_backbag = input(user, "Choose your character's style of bag:", "Character Preference") as null|anything in GLOB.backbaglist
if(new_backbag)
backbag = new_backbag
@@ -2353,17 +2353,17 @@ GLOBAL_LIST_EMPTY(preferences_datums)
if("uplink_loc")
- var/new_loc = tgui_input_list(user, "Choose your character's traitor uplink spawn location:", "Character Preference", GLOB.uplink_spawn_loc_list)
+ var/new_loc = input(user, "Choose your character's traitor uplink spawn location:", "Character Preference") as null|anything in GLOB.uplink_spawn_loc_list
if(new_loc)
uplink_spawn_loc = new_loc
if("ai_core_icon")
- var/ai_core_icon = tgui_input_list(user, "Choose your preferred AI core display screen:", "AI Core Display Screen Selection", GLOB.ai_core_display_screens)
+ var/ai_core_icon = input(user, "Choose your preferred AI core display screen:", "AI Core Display Screen Selection") as null|anything in GLOB.ai_core_display_screens
if(ai_core_icon)
preferred_ai_core_display = ai_core_icon
if("sec_dept")
- var/department = tgui_input_list(user, "Choose your preferred security department:", "Security Departments", GLOB.security_depts_prefs)
+ var/department = input(user, "Choose your preferred security department:", "Security Departments") as null|anything in GLOB.security_depts_prefs
if(department)
prefered_security_department = department
@@ -2379,26 +2379,26 @@ GLOBAL_LIST_EMPTY(preferences_datums)
friendlyname += " (disabled)"
maplist[friendlyname] = VM.map_name
maplist[default] = null
- var/pickedmap = tgui_input_list(user, "Choose your preferred map. This will be used to help weight random map selection.", "Character Preference", maplist)
+ var/pickedmap = input(user, "Choose your preferred map. This will be used to help weight random map selection.", "Character Preference") as null|anything in maplist
if (pickedmap)
preferred_map = maplist[pickedmap]
if ("preferred_chaos")
- var/pickedchaos = tgui_input_list(user, "Choose your preferred level of chaos. This will help with dynamic threat level ratings.", "Character Preference", list(CHAOS_NONE,CHAOS_LOW,CHAOS_MED,CHAOS_HIGH,CHAOS_MAX))
+ var/pickedchaos = input(user, "Choose your preferred level of chaos. This will help with dynamic threat level ratings.", "Character Preference") as null|anything in list(CHAOS_NONE,CHAOS_LOW,CHAOS_MED,CHAOS_HIGH,CHAOS_MAX)
preferred_chaos = pickedchaos
if ("clientfps")
- var/desiredfps = tgui_input_num(user, "Choose your desired fps. (0 = synced with server tick rate (currently:[world.fps]))", "Character Preference", clientfps)
+ var/desiredfps = input(user, "Choose your desired fps. (0 = synced with server tick rate (currently:[world.fps]))", "Character Preference", clientfps) as null|num
if (!isnull(desiredfps))
clientfps = desiredfps
parent.fps = desiredfps
if("ui")
- var/pickedui = tgui_input_list(user, "Choose your UI style.", "Character Preference", GLOB.available_ui_styles)
+ var/pickedui = input(user, "Choose your UI style.", "Character Preference", UI_style) as null|anything in GLOB.available_ui_styles
if(pickedui)
UI_style = pickedui
if (parent && parent.mob && parent.mob.hud_used)
parent.mob.hud_used.update_ui_style(ui_style2icon(UI_style))
if("pda_style")
- var/pickedPDAStyle = tgui_input_list(user, "Choose your PDA style.", "Character Preference", GLOB.pda_styles)
+ var/pickedPDAStyle = input(user, "Choose your PDA style.", "Character Preference", pda_style) as null|anything in GLOB.pda_styles
if(pickedPDAStyle)
pda_style = pickedPDAStyle
if("pda_color")
@@ -2406,11 +2406,11 @@ GLOBAL_LIST_EMPTY(preferences_datums)
if(pickedPDAColor)
pda_color = pickedPDAColor
if("pda_skin")
- var/pickedPDASkin = tgui_input_list(user, "Choose your PDA reskin.", "Character Preference", pda_skin, GLOB.pda_reskins)
+ var/pickedPDASkin = input(user, "Choose your PDA reskin.", "Character Preference", pda_skin) as null|anything in GLOB.pda_reskins
if(pickedPDASkin)
pda_skin = pickedPDASkin
if ("max_chat_length")
- var/desiredlength = tgui_input_num(user, "Choose the max character length of shown Runechat messages. Valid range is 1 to [CHAT_MESSAGE_MAX_LENGTH] (default: [initial(max_chat_length)]))", "Character Preference", max_chat_length)
+ var/desiredlength = input(user, "Choose the max character length of shown Runechat messages. Valid range is 1 to [CHAT_MESSAGE_MAX_LENGTH] (default: [initial(max_chat_length)]))", "Character Preference", max_chat_length) as null|num
if (!isnull(desiredlength))
max_chat_length = clamp(desiredlength, 1, CHAT_MESSAGE_MAX_LENGTH)
@@ -2420,7 +2420,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
hud_toggle_color = new_toggle_color
if("gender")
- var/chosengender = tgui_input_list(user, "Select your character's gender.", "Gender Selection", list(MALE,FEMALE,"nonbinary","object"))
+ var/chosengender = input(user, "Select your character's gender.", "Gender Selection", gender) as null|anything in list(MALE,FEMALE,"nonbinary","object")
if(!chosengender)
return
switch(chosengender)
@@ -2435,27 +2435,27 @@ GLOBAL_LIST_EMPTY(preferences_datums)
gender = chosengender
if("body_size")
- var/new_body_size = tgui_input_num(user, "Choose your desired sprite size: (90-125%)\nWarning: This may make your character look distorted. Additionally, any size under 100% takes a 10% maximum health penalty", "Character Preference", features["body_size"]*100)
+ var/new_body_size = input(user, "Choose your desired sprite size: (90-125%)\nWarning: This may make your character look distorted. Additionally, any size under 100% takes a 10% maximum health penalty", "Character Preference", features["body_size"]*100) as num|null
if(new_body_size)
features["body_size"] = clamp(new_body_size * 0.01, CONFIG_GET(number/body_size_min), CONFIG_GET(number/body_size_max))
if("tongue")
- var/selected_custom_tongue = tgui_input_list(user, "Choose your desired tongue (none means your species tongue)", "Character Preference", GLOB.roundstart_tongues)
+ var/selected_custom_tongue = input(user, "Choose your desired tongue (none means your species tongue)", "Character Preference") as null|anything in GLOB.roundstart_tongues
if(selected_custom_tongue)
custom_tongue = selected_custom_tongue
if("speech_verb")
- var/selected_custom_speech_verb = tgui_input_list(user, "Choose your desired speech verb (none means your species speech verb)", "Character Preference", GLOB.speech_verbs)
+ var/selected_custom_speech_verb = input(user, "Choose your desired speech verb (none means your species speech verb)", "Character Preference") as null|anything in GLOB.speech_verbs
if(selected_custom_speech_verb)
custom_speech_verb = selected_custom_speech_verb
if("language")
- var/selected_language = tgui_input_list(user, "Choose your desired additional language", "Character Preference", GLOB.roundstart_languages)
+ var/selected_language = input(user, "Choose your desired additional language", "Character Preference") as null|anything in GLOB.roundstart_languages
if(selected_language)
additional_language = selected_language
if("bodysprite")
- var/selected_body_sprite = tgui_input_list(user, "Choose your desired body sprite", "Character Preference", pref_species.allowed_limb_ids)
+ var/selected_body_sprite = input(user, "Choose your desired body sprite", "Character Preference") as null|anything in pref_species.allowed_limb_ids
if(selected_body_sprite)
chosen_limb_id = selected_body_sprite //this gets sanitized before loading
@@ -2496,7 +2496,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
// add a marking
var/marking_type = href_list["marking_type"]
if(marking_type && features[marking_type])
- var/selected_limb = tgui_input_list(user, "Choose the limb to apply to.", "Character Preference", list("Head", "Chest", "Left Arm", "Right Arm", "Left Leg", "Right Leg", "All"))
+ var/selected_limb = input(user, "Choose the limb to apply to.", "Character Preference") as null|anything in list("Head", "Chest", "Left Arm", "Right Arm", "Left Leg", "Right Leg", "All")
if(selected_limb)
var/list/marking_list = GLOB.mam_body_markings_list
var/list/snowflake_markings_list = list()
@@ -2511,7 +2511,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
if((!S.ckeys_allowed) || (S.ckeys_allowed.Find(user.client.ckey)))
snowflake_markings_list[S.name] = path
- var/selected_marking = tgui_input_list(user, "Select the marking to apply to the limb.", snowflake_markings_list)
+ var/selected_marking = input(user, "Select the marking to apply to the limb.") as null|anything in snowflake_markings_list
if(selected_marking)
if(selected_limb != "All")
var/limb_value = text2num(GLOB.bodypart_values[selected_limb])
@@ -2534,7 +2534,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
options += "Secondary"
if(number_colors == 3)
options += "Tertiary"
- var/color_option = tgui_input_list(user, "Select the colour you wish to edit", "", options)
+ var/color_option = input(user, "Select the colour you wish to edit") as null|anything in options
if(color_option)
if(color_option == "Secondary") color_number = 2
if(color_option == "Tertiary") color_number = 3
@@ -2623,7 +2623,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
if("no_tetris_storage")
no_tetris_storage = !no_tetris_storage
if ("screenshake")
- var/desiredshake = tgui_input_num(user, "Set the amount of screenshake you want. \n(0 = disabled, 100 = full, 200 = maximum.)", "Character Preference", screenshake)
+ var/desiredshake = input(user, "Set the amount of screenshake you want. \n(0 = disabled, 100 = full, 200 = maximum.)", "Character Preference", screenshake) as null|num
if (!isnull(desiredshake))
screenshake = desiredshake
if("damagescreenshake")
@@ -2718,7 +2718,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
save_preferences()
if("keybindings_reset")
- var/choice = tgui_alert(user, "Would you prefer 'hotkey' or 'classic' defaults?", "Setup keybindings", list("Hotkey", "Classic", "Cancel"))
+ var/choice = tgalert(user, "Would you prefer 'hotkey' or 'classic' defaults?", "Setup keybindings", "Hotkey", "Classic", "Cancel")
if(choice == "Cancel")
ShowChoices(user)
return
@@ -2971,7 +2971,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
var/list/color_options = list()
for(var/i=1, i<=length(G.loadout_initial_colors), i++)
color_options += "Color [i]"
- var/color_to_change = tgui_input_list(user, "Polychromic options", "Recolor [name]", color_options)
+ var/color_to_change = input(user, "Polychromic options", "Recolor [name]") as null|anything in color_options
if(color_to_change)
var/color_index = text2num(copytext(color_to_change, 7))
var/current_color = user_gear[LOADOUT_COLOR][color_index]
@@ -3175,7 +3175,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
if(!namedata)
return
- var/raw_name = tgui_input_text(user, "Choose your character's [namedata["qdesc"]]:","Character Preference", custom_names[name_id])
+ var/raw_name = input(user, "Choose your character's [namedata["qdesc"]]:","Character Preference") as text|null
if(!raw_name)
if(namedata["allow_null"])
custom_names[name_id] = get_default_name(name_id)
@@ -3199,7 +3199,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
/// Resets the client's keybindings. Asks them for which
/datum/preferences/proc/force_reset_keybindings()
- var/choice = tgui_alert(parent.mob, "Your basic keybindings need to be reset, emotes will remain as before. Would you prefer 'hotkey' or 'classic' mode?", "Reset keybindings", list("Hotkey", "Classic"))
+ var/choice = tgalert(parent.mob, "Your basic keybindings need to be reset, emotes will remain as before. Would you prefer 'hotkey' or 'classic' mode?", "Reset keybindings", "Hotkey", "Classic")
hotkeys = (choice != "Classic")
force_reset_keybindings_direct(hotkeys)
diff --git a/code/modules/client/preferences_savefile.dm b/code/modules/client/preferences_savefile.dm
index 96ffd09af8..510ac9ff28 100644
--- a/code/modules/client/preferences_savefile.dm
+++ b/code/modules/client/preferences_savefile.dm
@@ -126,29 +126,29 @@ SAVEFILE UPDATING/VERSIONING - 'Simplified', or rather, more coder-friendly ~Car
var/list/json_from_file = json_decode(file2text(vr_path))
if(json_from_file)
if(json_from_file["digestable"])
- ENABLE_BITFIELD(vore_flags,DIGESTABLE)
+ vore_flags |= DIGESTABLE
if(json_from_file["devourable"])
- ENABLE_BITFIELD(vore_flags,DEVOURABLE)
+ vore_flags |= DEVOURABLE
if(json_from_file["feeding"])
- ENABLE_BITFIELD(vore_flags,FEEDING)
+ vore_flags |= FEEDING
if(json_from_file["lickable"])
- ENABLE_BITFIELD(vore_flags,LICKABLE)
+ vore_flags |= LICKABLE
belly_prefs = json_from_file["belly_prefs"]
vore_taste = json_from_file["vore_taste"]
for(var/V in all_quirks) // quirk migration
switch(V)
if("Acute hepatic pharmacokinesis")
- DISABLE_BITFIELD(cit_toggles, PENIS_ENLARGEMENT)
- DISABLE_BITFIELD(cit_toggles, BREAST_ENLARGEMENT)
- ENABLE_BITFIELD(cit_toggles,FORCED_FEM)
- ENABLE_BITFIELD(cit_toggles,FORCED_MASC)
+ cit_toggles &= ~(PENIS_ENLARGEMENT)
+ cit_toggles &= ~(BREAST_ENLARGEMENT)
+ cit_toggles |= FORCED_FEM
+ cit_toggles |= FORCED_MASC
all_quirks -= V
if("Crocin Immunity")
- ENABLE_BITFIELD(cit_toggles,NO_APHRO)
+ cit_toggles |= NO_APHRO
all_quirks -= V
if("Buns of Steel")
- ENABLE_BITFIELD(cit_toggles,NO_ASS_SLAP)
+ cit_toggles |= NO_ASS_SLAP
all_quirks -= V
if(features["meat_type"] == "Inesct")
@@ -178,13 +178,13 @@ SAVEFILE UPDATING/VERSIONING - 'Simplified', or rather, more coder-friendly ~Car
S["feeding"] >> feeding
S["lickable"] >> lickable
if(digestable)
- ENABLE_BITFIELD(vore_flags,DIGESTABLE)
+ vore_flags |= DIGESTABLE
if(devourable)
- ENABLE_BITFIELD(vore_flags,DEVOURABLE)
+ vore_flags |= DEVOURABLE
if(feeding)
- ENABLE_BITFIELD(vore_flags,FEEDING)
+ vore_flags |= FEEDING
if(lickable)
- ENABLE_BITFIELD(vore_flags,LICKABLE)
+ vore_flags |= LICKABLE
if(current_version < 30)
switch(features["taur"])
diff --git a/code/modules/client/preferences_toggles.dm b/code/modules/client/preferences_toggles.dm
index c2b06253c9..a019ade471 100644
--- a/code/modules/client/preferences_toggles.dm
+++ b/code/modules/client/preferences_toggles.dm
@@ -277,9 +277,9 @@ GLOBAL_LIST_INIT(ghost_forms, list("ghost","ghostking","ghostian2","skeleghost",
"ghost_mellow","ghost_rainbow","ghost_camo","ghost_fire", "catghost"))
/client/proc/pick_form()
if(!is_content_unlocked())
- tgui_alert(src, "This setting is for accounts with BYOND premium only.")
+ alert("This setting is for accounts with BYOND premium only.")
return
- var/new_form = tgui_input_list(src, "Thanks for supporting BYOND - Choose your ghostly form:","Thanks for supporting BYOND", GLOB.ghost_forms)
+ var/new_form = input(src, "Thanks for supporting BYOND - Choose your ghostly form:","Thanks for supporting BYOND",null) as null|anything in GLOB.ghost_forms
if(new_form)
prefs.ghost_form = new_form
prefs.save_preferences()
@@ -291,9 +291,9 @@ GLOBAL_LIST_INIT(ghost_orbits, list(GHOST_ORBIT_CIRCLE,GHOST_ORBIT_TRIANGLE,GHOS
/client/proc/pick_ghost_orbit()
if(!is_content_unlocked())
- tgui_alert(src, "This setting is for accounts with BYOND premium only.")
+ alert("This setting is for accounts with BYOND premium only.")
return
- var/new_orbit = tgui_input_list(src, "Thanks for supporting BYOND - Choose your ghostly orbit:","Thanks for supporting BYOND", GLOB.ghost_orbits)
+ var/new_orbit = input(src, "Thanks for supporting BYOND - Choose your ghostly orbit:","Thanks for supporting BYOND",null) as null|anything in GLOB.ghost_orbits
if(new_orbit)
prefs.ghost_orbit = new_orbit
prefs.save_preferences()
@@ -302,7 +302,7 @@ GLOBAL_LIST_INIT(ghost_orbits, list(GHOST_ORBIT_CIRCLE,GHOST_ORBIT_TRIANGLE,GHOS
O.ghost_orbit = new_orbit
/client/proc/pick_ghost_accs()
- var/new_ghost_accs = tgui_alert(src, "Do you want your ghost to show full accessories where possible, hide accessories but still use the directional sprites where possible, or also ignore the directions and stick to the default sprites?",,list("full accessories", "only directional sprites", "default sprites"))
+ var/new_ghost_accs = alert("Do you want your ghost to show full accessories where possible, hide accessories but still use the directional sprites where possible, or also ignore the directions and stick to the default sprites?",,"full accessories", "only directional sprites", "default sprites")
if(new_ghost_accs)
switch(new_ghost_accs)
if("full accessories")
@@ -321,7 +321,7 @@ GLOBAL_LIST_INIT(ghost_orbits, list(GHOST_ORBIT_CIRCLE,GHOST_ORBIT_TRIANGLE,GHOS
set category = "Preferences"
set desc = "Customize your ghastly appearance."
if(is_content_unlocked())
- switch(tgui_alert(src, "Which setting do you want to change?",,list("Ghost Form","Ghost Orbit","Ghost Accessories")))
+ switch(alert("Which setting do you want to change?",,"Ghost Form","Ghost Orbit","Ghost Accessories"))
if("Ghost Form")
pick_form()
if("Ghost Orbit")
@@ -335,7 +335,7 @@ GLOBAL_LIST_INIT(ghost_orbits, list(GHOST_ORBIT_CIRCLE,GHOST_ORBIT_TRIANGLE,GHOS
set name = "Ghosts of Others"
set category = "Preferences"
set desc = "Change display settings for the ghosts of other players."
- var/new_ghost_others = tgui_alert(src, "Do you want the ghosts of others to show up as their own setting, as their default sprites or always as the default white ghost?",,list("Their Setting", "Default Sprites", "White Ghost"))
+ var/new_ghost_others = alert("Do you want the ghosts of others to show up as their own setting, as their default sprites or always as the default white ghost?",,"Their Setting", "Default Sprites", "White Ghost")
if(new_ghost_others)
switch(new_ghost_others)
if("Their Setting")
diff --git a/code/modules/client/verbs/ooc.dm b/code/modules/client/verbs/ooc.dm
index f8a3cf5ffb..07087e70a3 100644
--- a/code/modules/client/verbs/ooc.dm
+++ b/code/modules/client/verbs/ooc.dm
@@ -37,7 +37,7 @@ GLOBAL_VAR_INIT(normal_ooc_colour, "#002eb8")
msg = emoji_parse(msg)
if((msg[1] in list(".",";",":","#")) || findtext_char(msg, "say", 1, 5))
- if(tgui_alert(src, "Your message \"[raw_msg]\" looks like it was meant for in game communication, say it in OOC?", "Meant for OOC?", list("No", "Yes")) != "Yes")
+ if(alert("Your message \"[raw_msg]\" looks like it was meant for in game communication, say it in OOC?", "Meant for OOC?", "No", "Yes") != "Yes")
return
if(!holder)
@@ -215,7 +215,7 @@ GLOBAL_VAR_INIT(normal_ooc_colour, "#002eb8")
else
choices[C] = C
choices = sortList(choices)
- var/selection = tgui_input_list(src, "Please, select a player!", "Ignore", choices)
+ var/selection = input("Please, select a player!", "Ignore", null, null) as null|anything in choices
if(!selection || !(selection in choices))
return
selection = choices[selection]
diff --git a/code/modules/client/verbs/suicide.dm b/code/modules/client/verbs/suicide.dm
index fbfba04996..453c22e7f2 100644
--- a/code/modules/client/verbs/suicide.dm
+++ b/code/modules/client/verbs/suicide.dm
@@ -5,7 +5,7 @@
if(!canSuicide())
return
var/oldkey = ckey
- var/confirm = tgui_alert(src, "Are you sure you want to commit suicide?", "Confirm Suicide", list("Yes", "No"))
+ var/confirm = alert("Are you sure you want to commit suicide?", "Confirm Suicide", "Yes", "No")
if(ckey != oldkey)
return
if(!canSuicide())
@@ -84,7 +84,7 @@
set hidden = 1
if(!canSuicide())
return
- var/confirm = tgui_alert(src, "Are you sure you want to commit suicide?", "Confirm Suicide", list("Yes", "No"))
+ var/confirm = alert("Are you sure you want to commit suicide?", "Confirm Suicide", "Yes", "No")
if(!canSuicide())
return
if(confirm == "Yes")
@@ -100,7 +100,7 @@
set hidden = 1
if(!canSuicide())
return
- var/confirm = tgui_alert(src, "Are you sure you want to commit suicide?", "Confirm Suicide", list("Yes", "No"))
+ var/confirm = alert("Are you sure you want to commit suicide?", "Confirm Suicide", "Yes", "No")
if(!canSuicide())
return
if(confirm == "Yes")
@@ -117,7 +117,7 @@
set hidden = 1
if(!canSuicide())
return
- var/confirm = tgui_alert(src, "Are you sure you want to commit suicide?", "Confirm Suicide", list("Yes", "No"))
+ var/confirm = alert("Are you sure you want to commit suicide?", "Confirm Suicide", "Yes", "No")
if(!canSuicide())
return
if(confirm == "Yes")
@@ -135,7 +135,7 @@
set hidden = 1
if(!canSuicide())
return
- var/confirm = tgui_alert(src, "Are you sure you want to commit suicide?", "Confirm Suicide", list("Yes", "No"))
+ var/confirm = alert("Are you sure you want to commit suicide?", "Confirm Suicide", "Yes", "No")
if(!canSuicide())
return
if(confirm == "Yes")
@@ -151,7 +151,7 @@
/mob/living/silicon/pai/verb/suicide()
set hidden = 1
- var/confirm = tgui_alert(src, "Are you sure you want to commit suicide?", "Confirm Suicide", list("Yes", "No"))
+ var/confirm = alert("Are you sure you want to commit suicide?", "Confirm Suicide", "Yes", "No")
if(confirm == "Yes")
var/turf/T = get_turf(src.loc)
T.visible_message("[src] flashes a message across its screen, \"Wiping core files. Please acquire a new personality to continue using pAI device functions.\"", null, \
@@ -167,7 +167,7 @@
set hidden = 1
if(!canSuicide())
return
- var/confirm = tgui_alert(src, "Are you sure you want to commit suicide?", "Confirm Suicide", list("Yes", "No"))
+ var/confirm = alert("Are you sure you want to commit suicide?", "Confirm Suicide", "Yes", "No")
if(!canSuicide())
return
if(confirm == "Yes")
@@ -186,7 +186,7 @@
set hidden = 1
if(!canSuicide())
return
- var/confirm = tgui_alert(src, "Are you sure you want to commit suicide?", "Confirm Suicide", list("Yes", "No"))
+ var/confirm = alert("Are you sure you want to commit suicide?", "Confirm Suicide", "Yes", "No")
if(!canSuicide())
return
if(confirm == "Yes")
diff --git a/code/modules/clothing/chameleon.dm b/code/modules/clothing/chameleon.dm
index 1713a558cd..008772663d 100644
--- a/code/modules/clothing/chameleon.dm
+++ b/code/modules/clothing/chameleon.dm
@@ -93,7 +93,7 @@
/datum/action/chameleon_outfit/proc/select_outfit(mob/user)
if(!user || !IsAvailable())
return FALSE
- var/selected = tgui_input_list(user, "Select outfit to change into", "Chameleon Outfit", outfit_options)
+ var/selected = input("Select outfit to change into", "Chameleon Outfit") as null|anything in outfit_options
if(!IsAvailable() || QDELETED(src) || QDELETED(user))
return FALSE
var/outfit_type = outfit_options[selected]
@@ -178,7 +178,7 @@
/datum/action/item_action/chameleon/change/proc/select_look(mob/user)
var/obj/item/picked_item
var/picked_name
- picked_name = tgui_input_list(user, "Select [chameleon_name] to change into", "Chameleon [chameleon_name]", chameleon_list)
+ picked_name = input("Select [chameleon_name] to change into", "Chameleon [chameleon_name]", picked_name) as null|anything in chameleon_list
if(!picked_name)
return
picked_item = chameleon_list[picked_name]
diff --git a/code/modules/clothing/clothing.dm b/code/modules/clothing/clothing.dm
index 56ddb5f5f1..492768a8e0 100644
--- a/code/modules/clothing/clothing.dm
+++ b/code/modules/clothing/clothing.dm
@@ -67,7 +67,7 @@
/obj/item/clothing/Initialize()
. = ..()
- if(CHECK_BITFIELD(clothing_flags, VOICEBOX_TOGGLABLE))
+ if((clothing_flags & VOICEBOX_TOGGLABLE))
actions_types += /datum/action/item_action/toggle_voice_box
if(ispath(pocket_storage_component_path))
LoadComponent(pocket_storage_component_path)
diff --git a/code/modules/clothing/masks/_masks.dm b/code/modules/clothing/masks/_masks.dm
index c4063108db..ef7c6a1926 100644
--- a/code/modules/clothing/masks/_masks.dm
+++ b/code/modules/clothing/masks/_masks.dm
@@ -11,9 +11,9 @@
var/datum/beepsky_fashion/beepsky_fashion //the associated datum for applying this to a secbot
/obj/item/clothing/mask/attack_self(mob/user)
- if(CHECK_BITFIELD(clothing_flags, VOICEBOX_TOGGLABLE))
- TOGGLE_BITFIELD(clothing_flags, VOICEBOX_DISABLED)
- var/status = !CHECK_BITFIELD(clothing_flags, VOICEBOX_DISABLED)
+ if((clothing_flags & VOICEBOX_TOGGLABLE))
+ (clothing_flags ^= VOICEBOX_DISABLED)
+ var/status = !(clothing_flags & VOICEBOX_DISABLED)
to_chat(user, "You turn the voice box in [src] [status ? "on" : "off"].")
/obj/item/clothing/mask/equipped(mob/M, slot)
diff --git a/code/modules/clothing/masks/miscellaneous.dm b/code/modules/clothing/masks/miscellaneous.dm
index 88fbc98280..e6a0425920 100644
--- a/code/modules/clothing/masks/miscellaneous.dm
+++ b/code/modules/clothing/masks/miscellaneous.dm
@@ -124,7 +124,7 @@
modifies_speech = TRUE
/obj/item/clothing/mask/pig/handle_speech(datum/source, list/speech_args)
- if(!CHECK_BITFIELD(clothing_flags, VOICEBOX_DISABLED))
+ if(!(clothing_flags & VOICEBOX_DISABLED))
speech_args[SPEECH_MESSAGE] = pick("Oink!","Squeeeeeeee!","Oink Oink!")
/obj/item/clothing/mask/pig/cursed //needs to be different otherwise you could turn the speedmodification off and on
@@ -150,7 +150,7 @@
modifies_speech = TRUE
/obj/item/clothing/mask/frog/handle_speech(datum/source, list/speech_args) //whenever you speak
- if(!CHECK_BITFIELD(clothing_flags, VOICEBOX_DISABLED))
+ if(!(clothing_flags & VOICEBOX_DISABLED))
if(prob(5)) //sometimes, the angry spirit finds others words to speak.
speech_args[SPEECH_MESSAGE] = pick("HUUUUU!!","SMOOOOOKIN'!!","Hello my baby, hello my honey, hello my rag-time gal.", "Feels bad, man.", "GIT DIS GUY OFF ME!!" ,"SOMEBODY STOP ME!!", "NORMIES, GET OUT!!")
else
@@ -180,7 +180,7 @@
modifies_speech = TRUE
/obj/item/clothing/mask/cowmask/handle_speech(datum/source, list/speech_args)
- if(!CHECK_BITFIELD(clothing_flags, VOICEBOX_DISABLED))
+ if(!(clothing_flags & VOICEBOX_DISABLED))
speech_args[SPEECH_MESSAGE] = pick("Moooooooo!","Moo!","Moooo!")
@@ -205,7 +205,7 @@
clothing_flags = VOICEBOX_TOGGLABLE
/obj/item/clothing/mask/horsehead/handle_speech(datum/source, list/speech_args)
- if(!CHECK_BITFIELD(clothing_flags, VOICEBOX_DISABLED))
+ if(!(clothing_flags & VOICEBOX_DISABLED))
speech_args[SPEECH_MESSAGE] = pick("NEEIIGGGHHHH!", "NEEEIIIIGHH!", "NEIIIGGHH!", "HAAWWWWW!", "HAAAWWW!")
diff --git a/code/modules/clothing/spacesuits/hardsuit.dm b/code/modules/clothing/spacesuits/hardsuit.dm
index 60db121b72..cd48a81350 100644
--- a/code/modules/clothing/spacesuits/hardsuit.dm
+++ b/code/modules/clothing/spacesuits/hardsuit.dm
@@ -986,7 +986,7 @@
to_chat(user, "You can't do that right now!")
return TRUE
- if(tgui_alert(user, "Are you sure you want to recolor your armor stripes?", "Confirm Repaint", list("Yes", "No")) == "Yes")
+ if(alert("Are you sure you want to recolor your armor stripes?", "Confirm Repaint", "Yes", "No") == "Yes")
var/energy_color_input = input(usr,"","Choose Energy Color",energy_color) as color|null
if(energy_color_input)
energy_color = sanitize_hexcolor(energy_color_input, desired_format=6, include_crunch=1)
diff --git a/code/modules/clothing/under/_under.dm b/code/modules/clothing/under/_under.dm
index 1535e9265d..59af632d2a 100644
--- a/code/modules/clothing/under/_under.dm
+++ b/code/modules/clothing/under/_under.dm
@@ -232,7 +232,7 @@
return 0
var/list/modes = list("Off", "Binary vitals", "Exact vitals", "Tracking beacon")
- var/switchMode = tgui_input_list(usr, "Select a sensor mode:", "Suit Sensor Mode", modes)
+ var/switchMode = input("Select a sensor mode:", "Suit Sensor Mode", modes[sensor_mode + 1]) in modes
if(get_dist(usr, src) > 1)
to_chat(usr, "You have moved too far away!")
return
diff --git a/code/modules/economy/paystand.dm b/code/modules/economy/paystand.dm
index 6b36c6a10b..f674bc230d 100644
--- a/code/modules/economy/paystand.dm
+++ b/code/modules/economy/paystand.dm
@@ -22,7 +22,7 @@
name = rename_msg
return
else if(user.a_intent == INTENT_GRAB)
- var/force_fee_input = tgui_input_num(user,"Set the fee!","Set a fee!",force_fee)
+ var/force_fee_input = input(user,"Set the fee!","Set a fee!",0) as num|null
if(isnull(force_fee_input) || !user.canUseTopic(src, BE_CLOSE, FALSE, NO_TK))
return
force_fee = force_fee_input
@@ -46,7 +46,7 @@
if(vbucks.registered_account)
var/momsdebitcard = 0
if(!force_fee)
- momsdebitcard = tgui_input_num(user, "How much would you like to deposit?", "Money Deposit", force_fee)
+ momsdebitcard = input(user, "How much would you like to deposit?", "Money Deposit") as null|num
else
momsdebitcard = force_fee
if(!user.canUseTopic(src, BE_CLOSE, FALSE, NO_TK))
@@ -66,7 +66,7 @@
return
if(istype(W, /obj/item/holochip))
var/obj/item/holochip/H = W
- var/cashmoney = tgui_input_num(user, "How much would you like to deposit?", "Money Deposit", force_fee)
+ var/cashmoney = input(user, "How much would you like to deposit?", "Money Deposit") as null|num
if(H.spend(cashmoney, FALSE))
purchase(user, cashmoney)
to_chat(user, "Thanks for purchasing! The vendor has been informed.")
@@ -89,7 +89,7 @@
to_chat(user, "ERROR: No identification card has been assigned to this paystand yet!")
return
if(!signaler)
- var/cash_limit = tgui_input_num(user, "Enter the minimum amount of cash needed to deposit before the signaler is activated.", "Signaler Activation Threshold", signaler_threshold)
+ var/cash_limit = input(user, "Enter the minimum amount of cash needed to deposit before the signaler is activated.", "Signaler Activation Threshold") as null|num
if(cash_limit < 1)
to_chat(user, "ERROR: Invalid amount designated.")
return
diff --git a/code/modules/events/false_alarm.dm b/code/modules/events/false_alarm.dm
index 650af7eeb8..5ac75cf087 100644
--- a/code/modules/events/false_alarm.dm
+++ b/code/modules/events/false_alarm.dm
@@ -17,8 +17,8 @@
if(!initial(event.fakeable))
continue
possible_types += E
-
- forced_type = tgui_input_list(usr, "Select the scare.","False event", possible_types)
+
+ forced_type = input(usr, "Select the scare.","False event") as null|anything in possible_types
/datum/round_event_control/falsealarm/canSpawnEvent(players_amt, gamemode)
return ..() && length(gather_false_events())
diff --git a/code/modules/events/immovable_rod.dm b/code/modules/events/immovable_rod.dm
index 0675ea39f4..2712e69362 100644
--- a/code/modules/events/immovable_rod.dm
+++ b/code/modules/events/immovable_rod.dm
@@ -19,7 +19,7 @@ In my current plan for it, 'solid' will be defined as anything with density == 1
if(!check_rights(R_FUN))
return
- var/aimed = tgui_alert(usr, "Aimed at current location?","Sniperod", list("Yes", "No"))
+ var/aimed = alert("Aimed at current location?","Sniperod", "Yes", "No")
if(aimed == "Yes")
special_target = get_turf(usr)
@@ -99,7 +99,7 @@ In my current plan for it, 'solid' will be defined as anything with density == 1
walk(src,0)
walk_towards(src, destination, 1)
-/obj/effect/immovablerod/ex_act(severity, target)
+/obj/effect/immovablerod/ex_act(severity, target, origin)
return 0
/obj/effect/immovablerod/singularity_act()
diff --git a/code/modules/events/mass_hallucination.dm b/code/modules/events/mass_hallucination.dm
index a86e7f34ef..0801e38507 100644
--- a/code/modules/events/mass_hallucination.dm
+++ b/code/modules/events/mass_hallucination.dm
@@ -10,7 +10,7 @@
if(!check_rights(R_FUN))
return
- forced_hallucination = tgui_input_list(usr, "Choose the hallucination to apply","Send Hallucination", subtypesof(/datum/hallucination))
+ forced_hallucination = input(usr, "Choose the hallucination to apply","Send Hallucination") as null|anything in subtypesof(/datum/hallucination)
/datum/round_event/mass_hallucination
fakeable = FALSE
diff --git a/code/modules/events/pirates.dm b/code/modules/events/pirates.dm
index cc02d7b7d0..31859b4fc0 100644
--- a/code/modules/events/pirates.dm
+++ b/code/modules/events/pirates.dm
@@ -145,7 +145,7 @@
/obj/machinery/shuttle_scrambler/interact(mob/user)
if(!active)
- if(tgui_alert(user, "Turning the scrambler on will make the shuttle trackable by GPS. Are you sure you want to do it?", "Scrambler", list("Yes", "Cancel")) == "Cancel")
+ if(alert(user, "Turning the scrambler on will make the shuttle trackable by GPS. Are you sure you want to do it?", "Scrambler", "Yes", "Cancel") == "Cancel")
return
if(active || !user.canUseTopic(src, BE_CLOSE))
return
diff --git a/code/modules/events/spacevine.dm b/code/modules/events/spacevine.dm
index 9f90a4e288..ed6a087cd9 100644
--- a/code/modules/events/spacevine.dm
+++ b/code/modules/events/spacevine.dm
@@ -391,7 +391,7 @@
/datum/spacevine_controller/vv_do_topic(href_list)
. = ..()
if(href_list[VV_HK_SPACEVINE_PURGE])
- if(tgui_alert(usr, "Are you sure you want to delete this spacevine cluster?", "Delete Vines", list("Yes", "No")) == "Yes")
+ if(alert(usr, "Are you sure you want to delete this spacevine cluster?", "Delete Vines", "Yes", "No") == "Yes")
DeleteVines()
/datum/spacevine_controller/proc/DeleteVines() //this is kill
@@ -507,7 +507,7 @@
if(master)
master.spawn_spacevine_piece(stepturf, src)
-/obj/structure/spacevine/ex_act(severity, target)
+/obj/structure/spacevine/ex_act(severity, target, origin)
if(istype(target, type)) //if its agressive spread vine dont do anything
return
var/i
diff --git a/code/modules/events/wizard/madness.dm b/code/modules/events/wizard/madness.dm
index 8619590b49..ac86236623 100644
--- a/code/modules/events/wizard/madness.dm
+++ b/code/modules/events/wizard/madness.dm
@@ -12,7 +12,7 @@
var/suggested = pick(strings(REDPILL_FILE, "redpill_questions"))
- forced_secret = (tgui_input_text(usr, "What horrifying truth will you reveal?", "Curse of Madness", sortList(suggested))) || suggested
+ forced_secret = (input(usr, "What horrifying truth will you reveal?", "Curse of Madness", sortList(suggested)) as text|null) || suggested
/datum/round_event/wizard/madness/start()
var/datum/round_event_control/wizard/madness/C = control
diff --git a/code/modules/food_and_drinks/drinks/drinks.dm b/code/modules/food_and_drinks/drinks/drinks.dm
index 6b8de787f0..0370c087d9 100644
--- a/code/modules/food_and_drinks/drinks/drinks.dm
+++ b/code/modules/food_and_drinks/drinks/drinks.dm
@@ -500,7 +500,7 @@
/obj/item/reagent_containers/food/drinks/soda_cans/attack_self(mob/user)
if(!is_drainable())
to_chat(user, "You pull back the tab of \the [src] with a satisfying pop.") //Ahhhhhhhh
- ENABLE_BITFIELD(reagents.reagents_holder_flags, OPENCONTAINER)
+ reagents.reagents_holder_flags |= OPENCONTAINER
playsound(src, "can_open", 50, 1)
spillable = TRUE
return
diff --git a/code/modules/food_and_drinks/kitchen_machinery/food_cart.dm b/code/modules/food_and_drinks/kitchen_machinery/food_cart.dm
index 70bfd80217..f09d3d6728 100644
--- a/code/modules/food_and_drinks/kitchen_machinery/food_cart.dm
+++ b/code/modules/food_and_drinks/kitchen_machinery/food_cart.dm
@@ -122,7 +122,7 @@
log_combat(usr, src, "dispensed [O] from", null, "with [stored_food[href_list["dispense"]]] remaining")
if(href_list["portion"])
- portion = clamp(tgui_input_num(usr, "How much drink do you want to dispense per glass?"), 0, 50)
+ portion = clamp(input("How much drink do you want to dispense per glass?") as num|null, 0, 50)
if (isnull(portion))
return
diff --git a/code/modules/food_and_drinks/kitchen_machinery/smartfridge.dm b/code/modules/food_and_drinks/kitchen_machinery/smartfridge.dm
index 0d338c583b..58769cebf1 100644
--- a/code/modules/food_and_drinks/kitchen_machinery/smartfridge.dm
+++ b/code/modules/food_and_drinks/kitchen_machinery/smartfridge.dm
@@ -213,7 +213,7 @@
if (params["amount"])
desired = text2num(params["amount"])
else
- desired = tgui_input_num(usr, "How many items?", "How many items would you like to take out?", 1)
+ desired = input("How many items?", "How many items would you like to take out?", 1) as null|num
if(QDELETED(src) || QDELETED(usr) || !usr.Adjacent(src)) // Sanity checkin' in case stupid stuff happens while we wait for input()
return FALSE
diff --git a/code/modules/food_and_drinks/pizzabox.dm b/code/modules/food_and_drinks/pizzabox.dm
index cf3e9f69b3..a2603d07ab 100644
--- a/code/modules/food_and_drinks/pizzabox.dm
+++ b/code/modules/food_and_drinks/pizzabox.dm
@@ -123,7 +123,7 @@
update_icon()
return
else
- bomb_timer = tgui_input_num(user, "Set the [bomb] timer from [BOMB_TIMER_MIN] to [BOMB_TIMER_MAX].", bomb, bomb_timer)
+ bomb_timer = input(user, "Set the [bomb] timer from [BOMB_TIMER_MIN] to [BOMB_TIMER_MAX].", bomb, bomb_timer) as num
bomb_timer = clamp(CEILING(bomb_timer / 2, 1), BOMB_TIMER_MIN, BOMB_TIMER_MAX)
bomb_defused = FALSE
diff --git a/code/modules/holiday/halloween/bartholomew.dm b/code/modules/holiday/halloween/bartholomew.dm
index 12a0858b8d..75703bce7a 100644
--- a/code/modules/holiday/halloween/bartholomew.dm
+++ b/code/modules/holiday/halloween/bartholomew.dm
@@ -10,8 +10,12 @@
speech_span = "spooky"
resistance_flags = INDESTRUCTIBLE
var/active = TRUE
+ var/BallTutorial = FALSE
/obj/item/barthpot/attackby(obj/item/I, mob/user, params)
+ if(BallTutorial)
+ say("Hello and welcome to the annual Citadelstation Spookyball 2021! CENTCOM requisitioned this old hospital as a new colony site two years ago, and we’re back again after a few additions here and there. Next to me you can find all the tools you’ll need to build a nice private house, if you’re here for that kind of thing. The axes will chop trees, and give you wood. Shovels will remove grass and things, which you can use the grass to make beds and backets. The pickaxe will allow you pick out the nearby rocks, if you’re more interested in building a cave dwelling. Finally the umbrella and light sources are because it’s spooky, and it might rain! As for interesting spots; There’s the old abandoned mansion which you can get to by going through the entrance and towards the east. There’s also a mech arena directly south, and a racetrack in the caves to the right of the arena, follow the lanterns. And make sure to explore the caves too! Lots of neat things to find!")
+ return
if(!active)
say("Meow!")
return
@@ -27,6 +31,9 @@
say("It doesn't seem like that's magical enough!")
/obj/item/barthpot/on_attack_hand(mob/user, act_intent = user.a_intent, unarmed_attack_flags)
+ if(BallTutorial)
+ say("Hello and welcome to the annual Citadelstation Spookyball 2021! CENTCOM requisitioned this old hospital as a new colony site two years ago, and we’re back again after a few additions here and there. Next to me you can find all the tools you’ll need to build a nice private house, if you’re here for that kind of thing. The axes will chop trees, and give you wood. Shovels will remove grass and things, which you can use the grass to make beds and backets. The pickaxe will allow you pick out the nearby rocks, if you’re more interested in building a cave dwelling. Finally the umbrella and light sources are because it’s spooky, and it might rain! As for interesting spots; There’s the old abandoned mansion which you can get to by going through the entrance and towards the east. There’s also a mech arena directly south, and a racetrack in the caves to the right of the arena, follow the lanterns. And make sure to explore the caves too! Lots of neat things to find!")
+ return
if(!active)
say("Meow!")
return
diff --git a/code/modules/holiday/halloween/halloween.dm b/code/modules/holiday/halloween/halloween.dm
index f468022918..0c9987fc00 100644
--- a/code/modules/holiday/halloween/halloween.dm
+++ b/code/modules/holiday/halloween/halloween.dm
@@ -268,3 +268,65 @@
category = "Holiday"
item = /obj/item/card/emag/halloween
surplus = 0
+
+/////////////////////////
+// Ball map Items //
+/////////////////////////
+
+
+/obj/item/wisp_lantern/pumpkin
+ name = "Pumpkin lantern"
+ desc = "This lantern gives off no light, but is home to a friendly Jacq o' latern."
+ icon_state = "lantern-on"
+ var/obj/effect/wisp/pumpkin/wisp2
+
+//Hoooo boy that's some wild code there.
+/obj/item/wisp_lantern/pumpkin/Initialize()
+ . = ..()
+ qdel(wisp)
+ wisp2 = new(src)
+ wisp = wisp2
+
+/obj/effect/wisp/pumpkin
+ name = "Friendly pumpkin"
+ desc = "Happy to spook your way."
+ icon = 'icons/obj/clothing/hats.dmi'
+ icon_state = "hardhat1_pumpkin_j"
+ light_range = 5
+ light_color = "#EE9933"
+ layer = 0
+ sight_flags = SEE_MOBS
+ lighting_alpha = 0
+
+/obj/effect/wisp/pumpkin/update_user_sight(mob/user) //Disables SUPERLIGHTS
+ return
+
+//Damnit LazyBones
+/mob/living/simple_animal/lazy_bones
+ name = "Lazy Bones"
+ desc = "Simply refuses to get out of bed!"
+ icon = 'icons/mob/simple_human.dmi'
+ icon_state = "skeleton"
+ icon_living = "skeleton"
+ icon_dead = "skeleton"
+ gender = NEUTER
+ mob_biotypes = list(MOB_UNDEAD, MOB_HUMANOID)
+ turns_per_move = 5
+ speak_emote = list("rattles")
+ emote_see = list("rattles")
+ maxHealth = 40
+ health = 40
+ speed = 0
+ harm_intent_damage = 0
+ melee_damage_lower = 0
+ melee_damage_upper = 0
+ minbodytemp = 0
+ maxbodytemp = 1500
+ faction = list("skeleton")
+ see_in_dark = 8
+ lighting_alpha = LIGHTING_PLANE_ALPHA_MOSTLY_INVISIBLE
+ deathmessage = "collapses into a pile of bones!"
+ del_on_death = 1
+ loot = list(/obj/effect/decal/remains/human)
+
+ stop_automated_movement = 1
diff --git a/code/modules/holiday/halloween/jacqueen.dm b/code/modules/holiday/halloween/jacqueen.dm
index 8ab4c7f975..2f7899e8e6 100644
--- a/code/modules/holiday/halloween/jacqueen.dm
+++ b/code/modules/holiday/halloween/jacqueen.dm
@@ -50,6 +50,7 @@
var/cached_z
/// I'm busy, don't move.
var/busy = FALSE
+ var/spawn_cars = FALSE
var/static/blacklisted_items = typecacheof(list(
/obj/effect,
@@ -91,6 +92,9 @@
poof()
/mob/living/simple_animal/jacq/on_attack_hand(mob/living/carbon/human/M)
+ if(spawn_cars)
+ spawn_cars(M)
+ return ..()
if(!active)
say("Hello there [gender_check(M)]!")
return ..()
@@ -101,6 +105,9 @@
..()
/mob/living/simple_animal/jacq/attack_paw(mob/living/carbon/monkey/M)
+ if(spawn_cars)
+ spawn_cars(M)
+ return ..()
if(!active)
say("Hello there [gender_check(M)]!")
return ..()
@@ -128,6 +135,8 @@
/mob/living/simple_animal/jacq/proc/poof()
+ if(!active)//if disabled, don't poof
+ return
last_poof = world.realtime
var/datum/reagents/R = new/datum/reagents(100)//Hey, just in case.
var/datum/effect_system/smoke_spread/chem/s = new()
@@ -187,7 +196,7 @@
progression["[C.real_name]"] = progression["[C.real_name]"] | JACQ_HELLO
var/choices = list("Trick", "Treat", "How do I get candies?", "Do I know you from somewhere?")
- var/choice = tgui_input_list(C, "Trick or Treat?", "Trick or Treat?", choices)
+ var/choice = input(C, "Trick or Treat?", "Trick or Treat?") in choices
switch(choice)
if("Trick")
trick(C)
@@ -211,7 +220,7 @@
visible_message("[src] gives off a glowing smile, \"What ken Ah offer ye? I can magic up an object, a potion or a plushie fer ye.\"")
jacqrunes("What ken Ah offer ye? I can magic up an object, a potion or a plushie fer ye.", C)
var/choices_reward = list("Object - 3 candies", "Potion - 2 candies", "Jacqueline Tracker - 2 candies", "Plushie - 1 candy", "Can I get to know you instead?", "Become a pumpkinhead dullahan (perma) - 4 candies")
- var/choice_reward = tgui_input_list(usr, "Trick or Treat?", "Trick or Treat?", choices_reward)
+ var/choice_reward = input(usr, "Trick or Treat?", "Trick or Treat?") in choices_reward
//rewards
switch(choice_reward)
@@ -324,7 +333,7 @@
jacqrunes("A question? Sure, it'll cost you a candy though!", C)
choices += "Nevermind"
//Candies for chitchats
- var/choice = tgui_input_list(C, "What do you want to ask?", "What do you want to ask?", choices)
+ var/choice = input(C, "What do you want to ask?", "What do you want to ask?") in choices
if(!take_candies(C, 1))
visible_message("[src] raises an eyebrow, \"It's a candy per question [gender]! Thems the rules!\"")
jacqrunes("It's a candy per question [gender]! Thems the rules!", C)
@@ -470,12 +479,36 @@
sleep(20)
poof()
+/mob/living/simple_animal/jacq/proc/spawn_cars(mob/living/carbon/C)
+ visible_message("[src] gives off a glowing smile, \"What ken Ah offer ye? I can magic up a vectorcraft in manual or automatic fer ye.\"")
+ var/choices_reward = list("Manual", "Automatic", "How do Automatics work?", "Nothing, thanks")
+ var/choice_reward = input(usr, "Trick or Treat?", "Trick or Treat?") in choices_reward
+
+ switch(choice_reward)
+ if("Manual")
+ visible_message("[src] waves their arms around, \"Great choice! 'Ere's yer car.\"")
+ jacqrunes("Great choice! 'Ere's yer car.", C)
+ new /obj/vehicle/sealed/vectorcraft(loc)
+ if("Automatic")
+ visible_message("[src] waves their arms around, \"'Ere's yer car. Not as fast as an automatic mind.\"")
+ jacqrunes("'Ere's yer car. Not as fast as an automatic mind.", C)
+ new /obj/vehicle/sealed/vectorcraft/auto(loc)
+ if("How do Automatics work?")
+ visible_message("[src] smiles, \"Hold wasd to gain speed in a direction, c to enable/disable the clutch, 1 2 3 4 to change gears (help is gear 1, disarm is gear 2, grab is gear 3 and harm is gear 4) while holding a direction (make sure the clutch is enabled when you change gears, you should hear a sound when you've successfully changed gears), r to toggle handbrake, hold alt for brake and press shift for boost (the machine will beep when the boost is recharged)! If you hear an ebbing sound like \"brbrbrbrbr\" you need to gear down, the whining sound means you need to gear up. Hearing a pleasant \"whumwhumwhum\" is optimal gearage! It can be a lil slow to start, so make sure you're in the 1st gear, andusing a boost to get you started is a good idea. If you've got a good speed you'll likely never need to dip down to gear 1 again, and make sure to hold the acceleration pedal down while changing gears (hold a direction). 1st gear is for slow movement, and it's a good idea to mvoe to 2nd gear as quick as you can, you can coldstart a car from gear one by slowly moving, then using the boost to jump you up to gear 2 speeds. The upper gears are for unlimiting your top speed.\"")
+ jacqrunes("They're a bit tricky, aye. Basically;", C)
+ if("Nothing, thanks")
+ visible_message("[src] shrugs, \"Suit yerself.\"")
+ jacqrunes("Suit yerself.", C)
+
+ visible_message("[src] shrugs, \"Oh and look after the crafts, aye? They can get a wee bit... explosive if banged up a tad too much. They move slower damaged too like. Ye can repair 'em with the welders o'er there.\"")
+ jacqrunes("Oh and look after the crafts, aye? They can get a wee bit... explosive if banged up a tad too much. They move slower damaged too like. Ye can repair 'em with the welders o'er there. ", C)
+
/mob/living/simple_animal/jacq/update_mobility()
. = ..()
if(busy)
- DISABLE_BITFIELD(., MOBILITY_MOVE)
+ . &= ~(MOBILITY_MOVE)
else
- ENABLE_BITFIELD(., MOBILITY_MOVE)
+ . |= MOBILITY_MOVE
mobility_flags = .
diff --git a/code/modules/holodeck/computer.dm b/code/modules/holodeck/computer.dm
index e94cc17041..49a5c607ec 100644
--- a/code/modules/holodeck/computer.dm
+++ b/code/modules/holodeck/computer.dm
@@ -203,7 +203,7 @@
return
emergency_shutdown()
-/obj/machinery/computer/holodeck/ex_act(severity, target)
+/obj/machinery/computer/holodeck/ex_act(severity, target, origin)
emergency_shutdown()
return ..()
diff --git a/code/modules/holodeck/holo_effect.dm b/code/modules/holodeck/holo_effect.dm
index c37ccf657b..ffff8e190e 100644
--- a/code/modules/holodeck/holo_effect.dm
+++ b/code/modules/holodeck/holo_effect.dm
@@ -78,7 +78,7 @@
// these vars are not really standardized but all would theoretically create stuff on death
for(var/v in list("butcher_results","corpse","weapon1","weapon2","blood_volume") & mob.vars)
mob.vars[v] = null
- ENABLE_BITFIELD(mob.flags_1, HOLOGRAM_1)
+ mob.flags_1 |= HOLOGRAM_1
if(isliving(mob))
var/mob/living/L = mob
L.vore_flags = 0
diff --git a/code/modules/hydroponics/beekeeping/beebox.dm b/code/modules/hydroponics/beekeeping/beebox.dm
index 1655f7769f..2857099d0f 100644
--- a/code/modules/hydroponics/beekeeping/beebox.dm
+++ b/code/modules/hydroponics/beekeeping/beebox.dm
@@ -212,7 +212,7 @@
else
visible_message("[user] disturbs the [name] to no effect!")
else
- var/option = tgui_alert(user, "What action do you wish to perform?","Apiary",list("Remove a Honey Frame","Remove the Queen Bee", "Cancel"))
+ var/option = alert(user, "What action do you wish to perform?","Apiary","Remove a Honey Frame","Remove the Queen Bee", "Cancel")
if(!Adjacent(user))
return
switch(option)
diff --git a/code/modules/hydroponics/biogenerator.dm b/code/modules/hydroponics/biogenerator.dm
index b61d9451ef..8651ea82ab 100644
--- a/code/modules/hydroponics/biogenerator.dm
+++ b/code/modules/hydroponics/biogenerator.dm
@@ -27,10 +27,10 @@
QDEL_NULL(beaker)
return ..()
-/obj/machinery/biogenerator/contents_explosion(severity, target)
+/obj/machinery/biogenerator/contents_explosion(severity, target, origin)
..()
if(beaker)
- beaker.ex_act(severity, target)
+ beaker.ex_act(severity, target, origin)
/obj/machinery/biogenerator/handle_atom_del(atom/A)
..()
diff --git a/code/modules/hydroponics/fermenting_barrel.dm b/code/modules/hydroponics/fermenting_barrel.dm
index 3d6b90eb2d..39b0bfdfde 100644
--- a/code/modules/hydroponics/fermenting_barrel.dm
+++ b/code/modules/hydroponics/fermenting_barrel.dm
@@ -59,12 +59,12 @@
/obj/structure/fermenting_barrel/on_attack_hand(mob/user, act_intent = user.a_intent, unarmed_attack_flags)
open = !open
if(open)
- DISABLE_BITFIELD(reagents.reagents_holder_flags, DRAINABLE)
- ENABLE_BITFIELD(reagents.reagents_holder_flags, REFILLABLE)
+ reagents.reagents_holder_flags &= ~(DRAINABLE)
+ reagents.reagents_holder_flags |= REFILLABLE
to_chat(user, "You open [src], letting you fill it.")
else
- DISABLE_BITFIELD(reagents.reagents_holder_flags, REFILLABLE)
- ENABLE_BITFIELD(reagents.reagents_holder_flags, DRAINABLE)
+ reagents.reagents_holder_flags &= ~(REFILLABLE)
+ reagents.reagents_holder_flags |= DRAINABLE
to_chat(user, "You close [src], letting you draw from its tap.")
update_icon()
@@ -96,12 +96,12 @@
/obj/structure/custom_keg/on_attack_hand(mob/user, act_intent = user.a_intent, unarmed_attack_flags)
open = !open
if(open)
- DISABLE_BITFIELD(reagents.reagents_holder_flags, DRAINABLE)
- ENABLE_BITFIELD(reagents.reagents_holder_flags, REFILLABLE)
+ reagents.reagents_holder_flags &= ~(DRAINABLE)
+ reagents.reagents_holder_flags |= REFILLABLE
to_chat(user, "You open [src], letting you fill it.")
else
- DISABLE_BITFIELD(reagents.reagents_holder_flags, REFILLABLE)
- ENABLE_BITFIELD(reagents.reagents_holder_flags, DRAINABLE)
+ reagents.reagents_holder_flags &= ~(REFILLABLE)
+ reagents.reagents_holder_flags |= DRAINABLE
to_chat(user, "You close [src], letting you draw from its tap.")
update_icon()
diff --git a/code/modules/hydroponics/grown/citrus.dm b/code/modules/hydroponics/grown/citrus.dm
index e199c2c6b1..b0af08d515 100644
--- a/code/modules/hydroponics/grown/citrus.dm
+++ b/code/modules/hydroponics/grown/citrus.dm
@@ -173,7 +173,7 @@
var/mob/M = loc
M.dropItemToGround(src)
-/obj/item/reagent_containers/food/snacks/grown/firelemon/ex_act(severity)
+/obj/item/reagent_containers/food/snacks/grown/firelemon/ex_act(severity, target, origin)
qdel(src) //Ensuring that it's deleted by its own explosion
/obj/item/reagent_containers/food/snacks/grown/firelemon/proc/prime(mob/living/lanced_by)
diff --git a/code/modules/hydroponics/grown/misc.dm b/code/modules/hydroponics/grown/misc.dm
index 733d973832..4e6a4f0765 100644
--- a/code/modules/hydroponics/grown/misc.dm
+++ b/code/modules/hydroponics/grown/misc.dm
@@ -224,7 +224,7 @@
if(!QDELETED(src))
qdel(src)
-/obj/item/reagent_containers/food/snacks/grown/cherry_bomb/ex_act(severity)
+/obj/item/reagent_containers/food/snacks/grown/cherry_bomb/ex_act(severity, target, origin)
qdel(src) //Ensuring that it's deleted by its own explosion. Also prevents mass chain reaction with piles of cherry bombs
/obj/item/reagent_containers/food/snacks/grown/cherry_bomb/proc/prime(mob/living/lanced_by)
@@ -365,7 +365,7 @@
opened = TRUE
spillable = !screwdrivered
reagent_flags = OPENCONTAINER
- ENABLE_BITFIELD(reagents.reagents_holder_flags, OPENCONTAINER)
+ reagents.reagents_holder_flags |= OPENCONTAINER
icon_state = screwdrivered ? "coconut_carved" : "coconut_chopped"
desc = "A coconut. [screwdrivered ? "This one's got a hole in it" : "This one's sliced open, with all its delicious contents for your eyes to savour"]."
playsound(user, W.hitsound, 50, 1, -1)
@@ -500,7 +500,7 @@
log_game("Coconut bomb detonation at [AREACOORD(T)], location [loc]")
qdel(src)
-/obj/item/reagent_containers/food/snacks/grown/coconut/ex_act(severity)
+/obj/item/reagent_containers/food/snacks/grown/coconut/ex_act(severity, target, origin)
qdel(src)
/obj/item/reagent_containers/food/snacks/grown/coconut/deconstruct(disassembled = TRUE)
diff --git a/code/modules/hydroponics/grown/towercap.dm b/code/modules/hydroponics/grown/towercap.dm
index dc7b6c576d..38e4fcc6ff 100644
--- a/code/modules/hydroponics/grown/towercap.dm
+++ b/code/modules/hydroponics/grown/towercap.dm
@@ -173,7 +173,7 @@
/obj/structure/bonfire/attackby(obj/item/W, mob/user, params)
if(istype(W, /obj/item/stack/rods) && !can_buckle && !grill)
var/obj/item/stack/rods/R = W
- var/choice = tgui_input_list(user, "What would you like to construct?", "Bonfire", list("Stake","Grill"))
+ var/choice = input(user, "What would you like to construct?", "Bonfire") as null|anything in list("Stake","Grill")
switch(choice)
if("Stake")
R.use(1)
diff --git a/code/modules/hydroponics/hydroponics.dm b/code/modules/hydroponics/hydroponics.dm
index 62f14127bf..fa7decc437 100644
--- a/code/modules/hydroponics/hydroponics.dm
+++ b/code/modules/hydroponics/hydroponics.dm
@@ -626,7 +626,7 @@
for(var/muties in myseed.mutatelist)
var/obj/item/seeds/another_mut = new muties
fresh_mut_list[another_mut.plantname] = muties
- var/locked_mutation = (tgui_input_list(user, "Select a mutation to lock.", "Plant Mutation Locks", sortList(fresh_mut_list)))
+ var/locked_mutation = (input(user, "Select a mutation to lock.", "Plant Mutation Locks") as null|anything in sortList(fresh_mut_list))
if(!user.canUseTopic(src, BE_CLOSE) || !locked_mutation)
return
myseed.mutatelist = list(fresh_mut_list[locked_mutation])
@@ -684,7 +684,7 @@
if(!anchored)
update_icon()
return FALSE
- var/warning = tgui_alert(user, "Are you sure you wish to empty the tray's nutrient beaker?","Empty Tray Nutrients?", list("Yes", "No"))
+ var/warning = alert(user, "Are you sure you wish to empty the tray's nutrient beaker?","Empty Tray Nutrients?", "Yes", "No")
if(warning == "Yes" && user.canUseTopic(src, BE_CLOSE, FALSE, NO_TK))
reagents.clear_reagents()
to_chat(user, "You empty [src]'s nutrient tank.")
diff --git a/code/modules/hydroponics/seeds.dm b/code/modules/hydroponics/seeds.dm
index 79cd96e0b2..577635cd1c 100644
--- a/code/modules/hydroponics/seeds.dm
+++ b/code/modules/hydroponics/seeds.dm
@@ -444,7 +444,7 @@
return
if(istype(O, /obj/item/pen))
- var/choice = tgui_input_list(user, "What would you like to change?", "", list("Plant Name", "Seed Description", "Product Description", "Cancel"))
+ var/choice = input("What would you like to change?") in list("Plant Name", "Seed Description", "Product Description", "Cancel")
if(!user.canUseTopic(src, BE_CLOSE))
return
switch(choice)
diff --git a/code/modules/instruments/instrument_data/_instrument_data.dm b/code/modules/instruments/instrument_data/_instrument_data.dm
index 447bcdffb1..5d937f304f 100644
--- a/code/modules/instruments/instrument_data/_instrument_data.dm
+++ b/code/modules/instruments/instrument_data/_instrument_data.dm
@@ -55,14 +55,14 @@
id = "[type]"
/datum/instrument/proc/Initialize()
- if(CHECK_BITFIELD(instrument_flags, INSTRUMENT_LEGACY | INSTRUMENT_DO_NOT_AUTOSAMPLE))
+ if(instrument_flags & (INSTRUMENT_LEGACY | INSTRUMENT_DO_NOT_AUTOSAMPLE))
return
calculate_samples()
/datum/instrument/proc/ready()
- if(CHECK_BITFIELD(instrument_flags, INSTRUMENT_LEGACY))
+ if((instrument_flags & INSTRUMENT_LEGACY))
return legacy_instrument_path && legacy_instrument_ext
- else if(CHECK_BITFIELD(instrument_flags, INSTRUMENT_DO_NOT_AUTOSAMPLE))
+ else if((instrument_flags & INSTRUMENT_DO_NOT_AUTOSAMPLE))
return length(samples)
return (length(samples) >= 128)
diff --git a/code/modules/instruments/songs/editor.dm b/code/modules/instruments/songs/editor.dm
index 47347315bd..e385eed142 100644
--- a/code/modules/instruments/songs/editor.dm
+++ b/code/modules/instruments/songs/editor.dm
@@ -127,12 +127,12 @@
else if(href_list["import"])
var/t = ""
do
- t = html_encode(tgui_input_message(usr, "Please paste the entire song, formatted:", text("[]", name), t))
+ t = html_encode(input(usr, "Please paste the entire song, formatted:", text("[]", name), t) as message)
if(!in_range(parent, usr))
return
if(length_char(t) >= MUSIC_MAXLINES * MUSIC_MAXLINECHARS)
- var/cont = tgui_input_list(usr, "Your message is too long! Would you like to continue editing it?", "", list("yes", "no"))
+ var/cont = input(usr, "Your message is too long! Would you like to continue editing it?", "", "yes") in list("yes", "no")
if(cont == "no")
break
while(length_char(t) > MUSIC_MAXLINES * MUSIC_MAXLINECHARS)
@@ -160,7 +160,7 @@
INVOKE_ASYNC(src, .proc/start_playing, usr)
else if(href_list["newline"])
- var/newline = html_encode(tgui_input_text(usr, "Enter your line: ", parent.name))
+ var/newline = html_encode(input("Enter your line: ", parent.name) as text|null)
if(!newline || !in_range(parent, usr))
return
if(lines.len > MUSIC_MAXLINES)
@@ -188,22 +188,22 @@
stop_playing()
else if(href_list["setlinearfalloff"])
- var/amount = tgui_input_num(usr, "Set linear sustain duration in seconds", "Linear Sustain Duration")
+ var/amount = input(usr, "Set linear sustain duration in seconds", "Linear Sustain Duration") as null|num
if(!isnull(amount))
set_linear_falloff_duration(round(amount * 10, world.tick_lag))
else if(href_list["setexpfalloff"])
- var/amount = tgui_input_num(usr, "Set exponential sustain factor", "Exponential sustain factor")
+ var/amount = input(usr, "Set exponential sustain factor", "Exponential sustain factor") as null|num
if(!isnull(amount))
set_exponential_drop_rate(round(amount, 0.00001))
else if(href_list["setvolume"])
- var/amount = tgui_input_num(usr, "Set volume", "Volume")
+ var/amount = input(usr, "Set volume", "Volume") as null|num
if(!isnull(amount))
set_volume(round(amount, 1))
else if(href_list["setdropoffvolume"])
- var/amount = tgui_input_num(usr, "Set dropoff threshold", "Dropoff Threshold Volume")
+ var/amount = input(usr, "Set dropoff threshold", "Dropoff Threshold Volume") as null|num
if(!isnull(amount))
set_dropoff_volume(round(amount, 0.01))
@@ -218,11 +218,11 @@
var/datum/instrument/I = SSinstruments.get_instrument(i)
if(I)
LAZYSET(categories[I.category || "ERROR CATEGORY"], I.name, I.id)
- var/cat = tgui_input_list(usr, "Select Category", "Instrument Category", categories)
+ var/cat = input(usr, "Select Category", "Instrument Category") as null|anything in categories
if(!cat)
return
var/list/instruments = categories[cat]
- var/choice = tgui_input_list(usr, "Select Instrument", "Instrument Selection", instruments)
+ var/choice = input(usr, "Select Instrument", "Instrument Selection") as null|anything in instruments
if(!choice)
return
choice = instruments[choice] //get id
@@ -230,12 +230,12 @@
set_instrument(choice)
else if(href_list["setnoteshift"])
- var/amount = tgui_input_num(usr, "Set note shift", "Note Shift", note_shift)
+ var/amount = input(usr, "Set note shift", "Note Shift") as null|num
if(!isnull(amount))
note_shift = clamp(amount, note_shift_min, note_shift_max)
else if(href_list["setsustainmode"])
- var/choice = tgui_input_list(usr, "Choose a sustain mode", "Sustain Mode", list("Linear", "Exponential"))
+ var/choice = input(usr, "Choose a sustain mode", "Sustain Mode") as null|anything in list("Linear", "Exponential")
switch(choice)
if("Linear")
sustain_mode = SUSTAIN_LINEAR
diff --git a/code/modules/integrated_electronics/core/assemblies.dm b/code/modules/integrated_electronics/core/assemblies.dm
index 2706558391..ac27b4a30e 100644
--- a/code/modules/integrated_electronics/core/assemblies.dm
+++ b/code/modules/integrated_electronics/core/assemblies.dm
@@ -294,7 +294,7 @@
if(!check_interactivity(M))
return
- var/input = reject_bad_name(tgui_input_text(usr, "What do you want to name this?", "Rename", src.name), TRUE)
+ var/input = reject_bad_name(input("What do you want to name this?", "Rename", src.name) as null|text, TRUE)
if(!check_interactivity(M))
return
if(src && input)
@@ -506,7 +506,7 @@
if(input_selection.len == 1)
choice = input_selection[input_selection[1]]
else
- var/selection = tgui_input_list(user, "Where do you want to insert that item?", "Interaction", input_selection)
+ var/selection = input(user, "Where do you want to insert that item?", "Interaction") as null|anything in input_selection
if(!check_interactivity(user))
return ..()
if(selection)
@@ -548,7 +548,7 @@
if(input_selection.len ==1)
choice = input_selection[input_selection[1]]
else
- var/selection = tgui_input_list(user, "What do you want to interact with?", "Interaction", input_selection)
+ var/selection = input(user, "What do you want to interact with?", "Interaction") as null|anything in input_selection
if(!check_interactivity(user))
return
if(selection)
diff --git a/code/modules/integrated_electronics/core/debugger.dm b/code/modules/integrated_electronics/core/debugger.dm
index 7f5dd87dbc..e3fded3a82 100644
--- a/code/modules/integrated_electronics/core/debugger.dm
+++ b/code/modules/integrated_electronics/core/debugger.dm
@@ -12,7 +12,7 @@
var/copy_values = FALSE
/obj/item/integrated_electronics/debugger/attack_self(mob/user)
- var/type_to_use = tgui_input_list(user, "Please choose a type to use.","[src] type setting", list("string","number","ref","copy","null"))
+ var/type_to_use = input("Please choose a type to use.","[src] type setting") as null|anything in list("string","number","ref","copy","null")
if(!user.IsAdvancedToolUser())
return
@@ -28,7 +28,7 @@
if("number")
accepting_refs = FALSE
copy_values = FALSE
- new_data = tgui_input_num(user, "Now type in a number.","[src] number writing")
+ new_data = input(user, "Now type in a number.","[src] number writing") as null|num
if(isnum(new_data) && user.IsAdvancedToolUser())
data_to_write = new_data
to_chat(user, "You set \the [src]'s memory to [new_data].")
diff --git a/code/modules/integrated_electronics/core/detailer.dm b/code/modules/integrated_electronics/core/detailer.dm
index 387ec22e94..9720bccfe5 100644
--- a/code/modules/integrated_electronics/core/detailer.dm
+++ b/code/modules/integrated_electronics/core/detailer.dm
@@ -40,7 +40,7 @@
/obj/item/integrated_electronics/detailer/attack_self(mob/user)
- var/color_choice = tgui_input_list(user, "Select color.", "Assembly Detailer", color_list)
+ var/color_choice = input(user, "Select color.", "Assembly Detailer") as null|anything in color_list
if(!color_list[color_choice])
return
if(!in_range(src, user))
diff --git a/code/modules/integrated_electronics/core/pins.dm b/code/modules/integrated_electronics/core/pins.dm
index 43421ec7eb..e08d77007d 100644
--- a/code/modules/integrated_electronics/core/pins.dm
+++ b/code/modules/integrated_electronics/core/pins.dm
@@ -177,7 +177,7 @@ D [1]/ ||
/datum/integrated_io/proc/ask_for_data_type(mob/user, var/default, var/list/allowed_data_types = list("string","number","null"))
- var/type_to_use = tgui_input_list(user, "Please choose a type to use.","[src] type setting", allowed_data_types)
+ var/type_to_use = input("Please choose a type to use.","[src] type setting") as null|anything in allowed_data_types
if(!holder.check_interactivity(user))
return
@@ -189,7 +189,7 @@ D [1]/ ||
to_chat(user, "You input "+new_data+" into the pin.")
return new_data
if("number")
- new_data = tgui_input_num(user, "Now type in a number.","[src] number writing", isnum(default) ? default : null)
+ new_data = input("Now type in a number.","[src] number writing", isnum(default) ? default : null) as null|num
if(isnum(new_data) && holder.check_interactivity(user) )
to_chat(user, "You input [new_data] into the pin.")
return new_data
diff --git a/code/modules/integrated_electronics/core/printer.dm b/code/modules/integrated_electronics/core/printer.dm
index b585b51a42..5f6440bffb 100644
--- a/code/modules/integrated_electronics/core/printer.dm
+++ b/code/modules/integrated_electronics/core/printer.dm
@@ -232,7 +232,7 @@
if("load")
if(cloning)
return
- var/input = tgui_input_message(usr, "Put your code there:", "loading", null, null)
+ var/input = input("Put your code there:", "loading", null, null) as message | null
if(!check_interactivity(usr) || cloning)
return
if(!input)
diff --git a/code/modules/integrated_electronics/core/special_pins/dir_pin.dm b/code/modules/integrated_electronics/core/special_pins/dir_pin.dm
index f971b28e3e..24dae1439d 100644
--- a/code/modules/integrated_electronics/core/special_pins/dir_pin.dm
+++ b/code/modules/integrated_electronics/core/special_pins/dir_pin.dm
@@ -3,7 +3,7 @@
name = "dir pin"
/datum/integrated_io/dir/ask_for_pin_data(mob/user)
- var/new_data = tgui_input_num(user, "Please type in a valid dir number. \
+ var/new_data = input("Please type in a valid dir number. \
Valid dirs are;\n\
North/Fore = [NORTH],\n\
South/Aft = [SOUTH],\n\
@@ -12,7 +12,7 @@
Northeast = [NORTHEAST],\n\
Northwest = [NORTHWEST],\n\
Southeast = [SOUTHEAST],\n\
- Southwest = [SOUTHWEST]","[src] dir writing")
+ Southwest = [SOUTHWEST]","[src] dir writing") as null|num
if(isnum(new_data) && holder.check_interactivity(user) )
to_chat(user, "You input [new_data] into the pin.")
write_data_to_pin(new_data)
diff --git a/code/modules/integrated_electronics/core/special_pins/index_pin.dm b/code/modules/integrated_electronics/core/special_pins/index_pin.dm
index 981a0c6ea0..e904c4c6d0 100644
--- a/code/modules/integrated_electronics/core/special_pins/index_pin.dm
+++ b/code/modules/integrated_electronics/core/special_pins/index_pin.dm
@@ -4,7 +4,7 @@
data = 1
/datum/integrated_io/index/ask_for_pin_data(mob/user)
- var/new_data = tgui_input_num(user, "Please type in an index.","[src] index writing")
+ var/new_data = input("Please type in an index.","[src] index writing") as num
if(isnum(new_data) && holder.check_interactivity(user))
to_chat(user, "You input [new_data] into the pin.")
write_data_to_pin(new_data)
diff --git a/code/modules/integrated_electronics/core/special_pins/list_pin.dm b/code/modules/integrated_electronics/core/special_pins/list_pin.dm
index d96a253871..3532d68d70 100644
--- a/code/modules/integrated_electronics/core/special_pins/list_pin.dm
+++ b/code/modules/integrated_electronics/core/special_pins/list_pin.dm
@@ -54,7 +54,7 @@
to_chat(user, "The list is empty, there's nothing to remove.")
return
if(!target_entry)
- target_entry = tgui_input_list(user, "Which piece of data do you want to remove?", "Remove", my_list)
+ target_entry = input(user, "Which piece of data do you want to remove?", "Remove") as null|anything in my_list
if(holder.check_interactivity(user) && target_entry)
my_list.Remove(target_entry)
@@ -64,7 +64,7 @@
to_chat(user, "The list is empty, there's nothing to modify.")
return
if(!target_entry)
- target_entry = tgui_input_list(user, "Which piece of data do you want to edit?", "Edit", my_list)
+ target_entry = input(user, "Which piece of data do you want to edit?", "Edit") as null|anything in my_list
if(holder.check_interactivity(user) && target_entry)
var/edited_entry = ask_for_data_type(user, target_entry)
if(edited_entry)
@@ -89,11 +89,11 @@
to_chat(user, "The list is empty, or too small to do any meaningful swapping.")
return
if(!first_target)
- first_target = tgui_input_list(user, "Which piece of data do you want to swap? (1)", "Swap", my_list)
+ first_target = input(user, "Which piece of data do you want to swap? (1)", "Swap") as null|anything in my_list
if(holder.check_interactivity(user) && first_target)
if(!second_target)
- second_target = tgui_input_list(user, "Which piece of data do you want to swap? (2)", "Swap", my_list - first_target)
+ second_target = input(user, "Which piece of data do you want to swap? (2)", "Swap") as null|anything in my_list - first_target
if(holder.check_interactivity(user) && second_target)
var/first_pos = my_list.Find(first_target)
diff --git a/code/modules/integrated_electronics/core/special_pins/number_pin.dm b/code/modules/integrated_electronics/core/special_pins/number_pin.dm
index 2b47739d9a..e864c3c789 100644
--- a/code/modules/integrated_electronics/core/special_pins/number_pin.dm
+++ b/code/modules/integrated_electronics/core/special_pins/number_pin.dm
@@ -3,7 +3,7 @@
name = "number pin"
/datum/integrated_io/number/ask_for_pin_data(mob/user)
- var/new_data = tgui_input_num(user, "Please type in a number.","[src] number writing")
+ var/new_data = input("Please type in a number.","[src] number writing") as null|num
if(isnum(new_data) && holder.check_interactivity(user) )
to_chat(user, "You input [new_data] into the pin.")
write_data_to_pin(new_data)
diff --git a/code/modules/integrated_electronics/subtypes/input.dm b/code/modules/integrated_electronics/subtypes/input.dm
index 4b23d83e1d..f66931e253 100644
--- a/code/modules/integrated_electronics/subtypes/input.dm
+++ b/code/modules/integrated_electronics/subtypes/input.dm
@@ -51,7 +51,7 @@
power_draw_per_use = 4
/obj/item/integrated_circuit/input/numberpad/ask_for_input(mob/user)
- var/new_input = tgui_input_num(user, "Enter a number, please.",displayed_name)
+ var/new_input = input(user, "Enter a number, please.",displayed_name) as null|num
if(isnum(new_input) && user.IsAdvancedToolUser())
set_pin_data(IC_OUTPUT, 1, new_input)
push_data()
@@ -1263,7 +1263,7 @@
var/I = get_pin_data(IC_INPUT, k)
if(istext(I))
selection.Add(I)
- var/selected = tgui_input_list(user,"Choose input.","Selection", selection)
+ var/selected = input(user,"Choose input.","Selection") in selection
if(!selected)
return
set_pin_data(IC_OUTPUT, 1, selected)
diff --git a/code/modules/integrated_electronics/subtypes/memory.dm b/code/modules/integrated_electronics/subtypes/memory.dm
index 26893af5ff..34c36883d1 100644
--- a/code/modules/integrated_electronics/subtypes/memory.dm
+++ b/code/modules/integrated_electronics/subtypes/memory.dm
@@ -104,19 +104,19 @@
var/datum/integrated_io/O = outputs[1]
if(!user.IsAdvancedToolUser())
return
- var/type_to_use = tgui_input_list(user, "Please choose a type to use.","[src] type setting", list("string","number","ref", "null"))
+ var/type_to_use = input("Please choose a type to use.","[src] type setting") as null|anything in list("string","number","ref", "null")
var/new_data = null
switch(type_to_use)
if("string")
accepting_refs = FALSE
- new_data = tgui_input_text(user, "Now type in a string.","[src] string writing")
+ new_data = input("Now type in a string.","[src] string writing") as null|text
if(istext(new_data) && user.IsAdvancedToolUser())
O.data = new_data
to_chat(user, "You set \the [src]'s memory to [O.display_data(O.data)].")
if("number")
accepting_refs = FALSE
- new_data = tgui_input_num(user, "Now type in a number.","[src] number writing")
+ new_data = input("Now type in a number.","[src] number writing") as null|num
if(isnum(new_data) && user.IsAdvancedToolUser())
O.data = new_data
to_chat(user, "You set \the [src]'s memory to [O.display_data(O.data)].")
diff --git a/code/modules/integrated_electronics/subtypes/reagents.dm b/code/modules/integrated_electronics/subtypes/reagents.dm
index f69fa08aaf..de6ad729e9 100644
--- a/code/modules/integrated_electronics/subtypes/reagents.dm
+++ b/code/modules/integrated_electronics/subtypes/reagents.dm
@@ -77,7 +77,7 @@
/obj/item/integrated_circuit/reagent/injector/Initialize()
. = ..()
- ENABLE_BITFIELD(reagents.reagents_holder_flags, OPENCONTAINER)
+ reagents.reagents_holder_flags |= OPENCONTAINER
/obj/item/integrated_circuit/reagent/injector/on_reagent_change(changetype)
push_vol()
@@ -273,7 +273,7 @@
/obj/item/integrated_circuit/reagent/storage/Initialize()
. = ..()
- ENABLE_BITFIELD(reagents.reagents_holder_flags, OPENCONTAINER)
+ reagents.reagents_holder_flags |= OPENCONTAINER
/obj/item/integrated_circuit/reagent/storage/do_work()
set_pin_data(IC_OUTPUT, 2, WEAKREF(src))
@@ -303,7 +303,7 @@
/obj/item/integrated_circuit/reagent/storage/cryo/Initialize()
. = ..()
- ENABLE_BITFIELD(reagents.reagents_holder_flags, NO_REACT)
+ reagents.reagents_holder_flags |= NO_REACT
/obj/item/integrated_circuit/reagent/storage/grinder
name = "reagent grinder"
@@ -574,7 +574,7 @@
/obj/item/integrated_circuit/reagent/smoke/Initialize()
. = ..()
- ENABLE_BITFIELD(reagents.reagents_holder_flags, OPENCONTAINER)
+ reagents.reagents_holder_flags |= OPENCONTAINER
/obj/item/integrated_circuit/reagent/smoke/on_reagent_change(changetype)
//reset warning only if we have reagents now
@@ -632,7 +632,7 @@
/obj/item/integrated_circuit/reagent/extinguisher/Initialize()
.=..()
- ENABLE_BITFIELD(reagents.reagents_holder_flags, OPENCONTAINER)
+ reagents.reagents_holder_flags |= OPENCONTAINER
set_pin_data(IC_OUTPUT,2, src)
/obj/item/integrated_circuit/reagent/extinguisher/on_reagent_change(changetype)
diff --git a/code/modules/language/language_menu.dm b/code/modules/language/language_menu.dm
index b773404da0..bffd3d59af 100644
--- a/code/modules/language/language_menu.dm
+++ b/code/modules/language/language_menu.dm
@@ -84,7 +84,7 @@
if("grant_language")
if((is_admin || isobserver(AM)) && language_datum)
var/list/choices = list("Only Spoken", "Only Understood", "Both")
- var/choice = tgui_input_list(user,"How do you want to add this language?","[language_datum]", choices)
+ var/choice = input(user,"How do you want to add this language?","[language_datum]",null) as null|anything in choices
var/spoken = FALSE
var/understood = FALSE
switch(choice)
@@ -103,7 +103,7 @@
if("remove_language")
if((is_admin || isobserver(AM)) && language_datum)
var/list/choices = list("Only Spoken", "Only Understood", "Both")
- var/choice = tgui_input_list(user,"Which part do you wish to remove?","[language_datum]", choices)
+ var/choice = input(user,"Which part do you wish to remove?","[language_datum]",null) as null|anything in choices
var/spoken = FALSE
var/understood = FALSE
switch(choice)
diff --git a/code/modules/library/lib_items.dm b/code/modules/library/lib_items.dm
index 8e132071d4..fb6992dd4e 100644
--- a/code/modules/library/lib_items.dm
+++ b/code/modules/library/lib_items.dm
@@ -140,7 +140,7 @@
create_random_books(books_to_load, src, FALSE, random_category)
load_random_books = FALSE
if(contents.len)
- var/obj/item/book/choice = tgui_input_list(user, "Which book would you like to remove from the shelf?", "", sortNames(contents.Copy()))
+ var/obj/item/book/choice = input(user, "Which book would you like to remove from the shelf?") as null|obj in sortNames(contents.Copy())
if(choice)
if(!(user.mobility_flags & MOBILITY_USE) || user.stat != CONSCIOUS || !in_range(loc, user))
return
@@ -193,6 +193,13 @@
new /obj/item/book/manual/wiki/research_and_development(src)
update_icon()
+/obj/structure/bookcase/manuals/medical
+ name = "medical manuals bookcase"
+
+/obj/structure/bookcase/manuals/medical/Initialize()
+ . = ..()
+ new /obj/item/book/manual/wiki/medical_cloning(src)
+ update_icon()
/*
* Book
@@ -239,7 +246,7 @@
if(!literate)
to_chat(user, "You scribble illegibly on the cover of [src]!")
return
- var/choice = tgui_input_list(user, "What would you like to change?", "", list("Title", "Contents", "Author", "Cancel"))
+ var/choice = input("What would you like to change?") in list("Title", "Contents", "Author", "Cancel")
if(!user.canUseTopic(src, BE_CLOSE, literate))
return
switch(choice)
diff --git a/code/modules/library/lib_machines.dm b/code/modules/library/lib_machines.dm
index 6609f56345..1125d15bca 100644
--- a/code/modules/library/lib_machines.dm
+++ b/code/modules/library/lib_machines.dm
@@ -110,19 +110,19 @@
return
if(href_list["settitle"])
- var/newtitle = tgui_input_text(usr, "Enter a title to search for:")
+ var/newtitle = input("Enter a title to search for:") as text|null
if(newtitle)
title = sanitize(newtitle)
else
title = null
if(href_list["setcategory"])
- var/newcategory = tgui_input_list(usr, "Choose a category to search for:", "", list("Any", "Fiction", "Non-Fiction", "Adult", "Reference", "Religion"))
+ var/newcategory = input("Choose a category to search for:") in list("Any", "Fiction", "Non-Fiction", "Adult", "Reference", "Religion")
if(newcategory)
category = sanitize(newcategory)
else
category = "Any"
if(href_list["setauthor"])
- var/newauthor = tgui_input_text(usr, "Enter an author to search for:")
+ var/newauthor = input("Enter an author to search for:") as text|null
if(newauthor)
author = sanitize(newauthor)
else
@@ -407,16 +407,16 @@
if(newauthor)
scanner.cache.author = newauthor
if(href_list["setcategory"])
- var/newcategory = tgui_input_list(usr, "Choose a category: ", "", list("Fiction", "Non-Fiction", "Adult", "Reference", "Religion","Technical"))
+ var/newcategory = input("Choose a category: ") in list("Fiction", "Non-Fiction", "Adult", "Reference", "Religion","Technical")
if(newcategory)
upload_category = newcategory
if(href_list["upload"])
if(scanner)
if(scanner.cache)
- var/choice = tgui_input_list(usr, "Are you certain you wish to upload this title to the Archive?", "", list("Confirm", "Abort"))
+ var/choice = input("Are you certain you wish to upload this title to the Archive?") in list("Confirm", "Abort")
if(choice == "Confirm")
if (!SSdbcore.Connect())
- tgui_alert(usr, "Connection to Archive has been severed. Aborting.")
+ alert("Connection to Archive has been severed. Aborting.")
else
var/msg = "[key_name(usr)] has uploaded the book titled [scanner.cache.name], [length(scanner.cache.dat)] signs"
var/datum/db_query/query_library_upload = SSdbcore.NewQuery({"
@@ -425,15 +425,15 @@
"}, list("title" = scanner.cache.name, "author" = scanner.cache.author, "content" = scanner.cache.dat, "category" = upload_category, "ckey" = usr.ckey, "round_id" = GLOB.round_id))
if(!query_library_upload.Execute())
qdel(query_library_upload)
- tgui_alert(usr, "Database error encountered uploading to Archive")
+ alert("Database error encountered uploading to Archive")
return
else
log_game(msg)
qdel(query_library_upload)
- tgui_alert(usr, "Upload Complete. Uploaded title will be unavailable for printing for a short period")
+ alert("Upload Complete. Uploaded title will be unavailable for printing for a short period")
if(href_list["newspost"])
if(!GLOB.news_network)
- tgui_alert(usr, "No news network found on station. Aborting.")
+ alert("No news network found on station. Aborting.")
var/channelexists = 0
for(var/datum/news/feed_channel/FC in GLOB.news_network.network_channels)
if(FC.channel_name == "Nanotrasen Book Club")
@@ -442,12 +442,12 @@
if(!channelexists)
GLOB.news_network.CreateFeedChannel("Nanotrasen Book Club", "Library", null)
GLOB.news_network.SubmitArticle(scanner.cache.dat, "[scanner.cache.name]", "Nanotrasen Book Club", null)
- tgui_alert(usr, "Upload complete. Your uploaded title is now available on station newscasters.")
+ alert("Upload complete. Your uploaded title is now available on station newscasters.")
if(href_list["orderbyid"])
if(printer_cooldown > world.time)
say("Printer unavailable. Please allow a short time before attempting to print.")
else
- var/orderid = tgui_input_num(usr, "Enter your order:")
+ var/orderid = input("Enter your order:") as num|null
if(orderid)
if(isnum(orderid) && ISINTEGER(orderid))
href_list["targetid"] = num2text(orderid)
@@ -455,7 +455,7 @@
if(href_list["targetid"])
var/id = href_list["targetid"]
if (!SSdbcore.Connect())
- tgui_alert(usr, "Connection to Archive has been severed. Aborting.")
+ alert("Connection to Archive has been severed. Aborting.")
if(printer_cooldown > world.time)
say("Printer unavailable. Please allow a short time before attempting to print.")
else
diff --git a/code/modules/library/soapstone.dm b/code/modules/library/soapstone.dm
index 86da58339e..fd268a7774 100644
--- a/code/modules/library/soapstone.dm
+++ b/code/modules/library/soapstone.dm
@@ -265,7 +265,7 @@
if("delete")
if(!is_admin)
return
- var/confirm = tgui_alert(user, "Confirm deletion of engraved message?", "Confirm Deletion", list("Yes", "No"))
+ var/confirm = alert(user, "Confirm deletion of engraved message?", "Confirm Deletion", "Yes", "No")
if(confirm == "Yes")
persists = FALSE
qdel(src)
diff --git a/code/modules/lighting/emissive_blocker.dm b/code/modules/lighting/emissive_blocker.dm
index 46dc44792b..1b4fec4e3b 100644
--- a/code/modules/lighting/emissive_blocker.dm
+++ b/code/modules/lighting/emissive_blocker.dm
@@ -26,7 +26,7 @@
color = GLOB.em_block_color
-/atom/movable/emissive_blocker/ex_act(severity)
+/atom/movable/emissive_blocker/ex_act(severity, target, origin)
return FALSE
/atom/movable/emissive_blocker/singularity_act()
diff --git a/code/modules/lighting/lighting_object.dm b/code/modules/lighting/lighting_object.dm
index 6551b1e336..bd6bfdd177 100644
--- a/code/modules/lighting/lighting_object.dm
+++ b/code/modules/lighting/lighting_object.dm
@@ -124,7 +124,7 @@
// Variety of overrides so the overlays don't get affected by weird things.
-/atom/movable/lighting_object/ex_act(severity)
+/atom/movable/lighting_object/ex_act(severity, target, origin)
return 0
/atom/movable/lighting_object/singularity_act()
diff --git a/code/modules/mafia/controller.dm b/code/modules/mafia/controller.dm
index f2e11b1bad..43d15ebffe 100644
--- a/code/modules/mafia/controller.dm
+++ b/code/modules/mafia/controller.dm
@@ -728,13 +728,13 @@
rolelist_dict = list("CANCEL", "FINISH") + rolelist_dict
while(!done)
to_chat(usr, "You have a total player count of [assoc_value_sum(debug_setup)] in this setup.")
- var/chosen_role_name = tgui_input_list(usr,"Select a role!","Custom Setup Creation", rolelist_dict)
+ var/chosen_role_name = input(usr,"Select a role!","Custom Setup Creation",rolelist_dict[1]) as null|anything in rolelist_dict
if(chosen_role_name == "CANCEL")
return
if(chosen_role_name == "FINISH")
break
var/found_path = rolelist_dict[chosen_role_name]
- var/role_count = tgui_input_num(usr,"How many? Zero to cancel.","Custom Setup Creation",0)
+ var/role_count = input(usr,"How many? Zero to cancel.","Custom Setup Creation",0) as null|num
if(role_count > 0)
debug_setup[found_path] = role_count
custom_setup = debug_setup
diff --git a/code/modules/mining/abandoned_crates.dm b/code/modules/mining/abandoned_crates.dm
index 9b83e15d8f..e97060b45d 100644
--- a/code/modules/mining/abandoned_crates.dm
+++ b/code/modules/mining/abandoned_crates.dm
@@ -152,7 +152,7 @@
/obj/structure/closet/crate/secure/loot/on_attack_hand(mob/user, act_intent = user.a_intent, unarmed_attack_flags)
if(locked)
to_chat(user, "The crate is locked with a Deca-code lock.")
- var/input = tgui_input_text(usr, "Enter [codelen] digits. All digits must be unique.", "Deca-Code Lock", "")
+ var/input = input(usr, "Enter [codelen] digits. All digits must be unique.", "Deca-Code Lock", "") as text
if(user.canUseTopic(src, BE_CLOSE))
var/list/sanitised = list()
var/sanitycheck = TRUE
diff --git a/code/modules/mining/aux_base_camera.dm b/code/modules/mining/aux_base_camera.dm
index 18eef50e80..be0a41427f 100644
--- a/code/modules/mining/aux_base_camera.dm
+++ b/code/modules/mining/aux_base_camera.dm
@@ -200,7 +200,7 @@
return
var/list/buildlist = list("Walls and Floors" = 1,"Airlocks" = 2,"Deconstruction" = 3,"Windows and Grilles" = 4)
- var/buildmode = tgui_input_list(usr, "Set construction mode.", "Base Console", buildlist)
+ var/buildmode = input("Set construction mode.", "Base Console", null) in buildlist
if(buildmode)
B.RCD.mode = buildlist[buildmode]
to_chat(owner, "Build mode is now [buildmode].")
diff --git a/code/modules/mining/equipment/marker_beacons.dm b/code/modules/mining/equipment/marker_beacons.dm
index 31025c6153..296513af8d 100644
--- a/code/modules/mining/equipment/marker_beacons.dm
+++ b/code/modules/mining/equipment/marker_beacons.dm
@@ -60,7 +60,7 @@ GLOBAL_LIST_INIT(marker_beacon_colors, list(
if(!istype(user) || !user.canUseTopic(src, BE_CLOSE))
return
. = TRUE
- var/input_color = tgui_input_list(user, "Choose a color.", "Beacon Color", GLOB.marker_beacon_colors)
+ var/input_color = input(user, "Choose a color.", "Beacon Color") as null|anything in GLOB.marker_beacon_colors
if(!istype(user) || !user.canUseTopic(src, BE_CLOSE))
return
if(input_color)
@@ -133,7 +133,7 @@ GLOBAL_LIST_INIT(marker_beacon_colors, list(
if(!istype(user) || !user.canUseTopic(src, BE_CLOSE))
return
. = TRUE
- var/input_color = tgui_input_list(user, "Choose a color.", "Beacon Color", GLOB.marker_beacon_colors)
+ var/input_color = input(user, "Choose a color.", "Beacon Color") as null|anything in GLOB.marker_beacon_colors
if(!istype(user) || !user.canUseTopic(src, BE_CLOSE))
return
if(input_color)
diff --git a/code/modules/mining/fulton.dm b/code/modules/mining/fulton.dm
index dec21100ca..5044a73c10 100644
--- a/code/modules/mining/fulton.dm
+++ b/code/modules/mining/fulton.dm
@@ -31,7 +31,7 @@ GLOBAL_LIST_EMPTY(total_extraction_beacons)
else
var/A
- A = tgui_input_list(user, "Select a beacon to connect to", "Balloon Extraction Pack", possible_beacons)
+ A = input("Select a beacon to connect to", "Balloon Extraction Pack", A) as null|anything in possible_beacons
if(!A)
return
diff --git a/code/modules/mining/lavaland/necropolis_chests.dm b/code/modules/mining/lavaland/necropolis_chests.dm
index c91663d0e6..b005822438 100644
--- a/code/modules/mining/lavaland/necropolis_chests.dm
+++ b/code/modules/mining/lavaland/necropolis_chests.dm
@@ -484,7 +484,7 @@
mouse_opacity = MOUSE_OPACITY_TRANSPARENT
anchored = TRUE
-/obj/effect/warp_cube/ex_act(severity, target)
+/obj/effect/warp_cube/ex_act(severity, target, origin)
return
//Meat Hook
@@ -607,7 +607,7 @@
/obj/effect/immortality_talisman/attackby()
return
-/obj/effect/immortality_talisman/ex_act()
+/obj/effect/immortality_talisman/ex_act(severity, target, origin)
return
/obj/effect/immortality_talisman/singularity_pull()
@@ -1138,7 +1138,7 @@
var/mob/living/L = I
da_list[L.real_name] = L
- var/choice = tgui_input_list(user,"Who do you want dead?","Choose Your Victim", da_list)
+ var/choice = input(user,"Who do you want dead?","Choose Your Victim") as null|anything in da_list
choice = da_list[choice]
diff --git a/code/modules/mining/machine_redemption.dm b/code/modules/mining/machine_redemption.dm
index 45e88a1ae0..eabab35c3b 100644
--- a/code/modules/mining/machine_redemption.dm
+++ b/code/modules/mining/machine_redemption.dm
@@ -287,7 +287,7 @@
if (params["sheets"])
desired = text2num(params["sheets"])
else
- desired = tgui_input_num(usr, "How many sheets?", "How many sheets would you like to smelt?", 1)
+ desired = input("How many sheets?", "How many sheets would you like to smelt?", 1) as null|num
var/sheets_to_remove = round(min(desired,50,stored_amount))
@@ -332,7 +332,7 @@
if (params["sheets"])
desired = text2num(params["sheets"])
else
- desired = tgui_input_num(usr, "How many sheets?", "How many sheets would you like to smelt?", 1)
+ desired = input("How many sheets?", "How many sheets would you like to smelt?", 1) as null|num
var/amount = round(min(desired,50,smelt_amount))
mat_container.use_materials(alloy.materials, amount)
materials.silo_log(src, "released", -amount, "sheets", alloy.materials)
@@ -346,7 +346,7 @@
to_chat(usr, "Required access not found.")
return TRUE
-/obj/machinery/mineral/ore_redemption/ex_act(severity, target)
+/obj/machinery/mineral/ore_redemption/ex_act(severity, target, origin)
do_sparks(5, TRUE, src)
..()
diff --git a/code/modules/mining/machine_vending.dm b/code/modules/mining/machine_vending.dm
index b1bde7d454..c7ddaebe2d 100644
--- a/code/modules/mining/machine_vending.dm
+++ b/code/modules/mining/machine_vending.dm
@@ -270,7 +270,7 @@
SSblackbox.record_feedback("tally", "crusher_voucher_redeemed", 1, selection)
qdel(voucher)
-/obj/machinery/mineral/equipment_vendor/ex_act(severity, target)
+/obj/machinery/mineral/equipment_vendor/ex_act(severity, target, origin)
do_sparks(5, TRUE, src)
if(prob(50 / severity) && severity < 3)
qdel(src)
diff --git a/code/modules/mining/ores_coins.dm b/code/modules/mining/ores_coins.dm
index 71f84e898c..264da96a27 100644
--- a/code/modules/mining/ores_coins.dm
+++ b/code/modules/mining/ores_coins.dm
@@ -152,7 +152,7 @@ GLOBAL_LIST_INIT(sand_recipes, list(\
C.forcesay("*scream")
qdel(src)
-/obj/item/stack/ore/glass/ex_act(severity, target)
+/obj/item/stack/ore/glass/ex_act(severity, target, origin)
if (severity == EXPLODE_NONE)
return
qdel(src)
@@ -314,7 +314,7 @@ GLOBAL_LIST_INIT(sand_recipes, list(\
GibtoniteReaction(P.firer)
. = ..()
-/obj/item/gibtonite/ex_act()
+/obj/item/gibtonite/ex_act(severity, target, origin)
GibtoniteReaction(null, 1)
/obj/item/gibtonite/proc/GibtoniteReaction(mob/user, triggered_by = 0)
@@ -356,7 +356,7 @@ GLOBAL_LIST_INIT(sand_recipes, list(\
pixel_x = initial(pixel_x) + rand(0, 16) - 8
pixel_y = initial(pixel_y) + rand(0, 8) - 8
-/obj/item/stack/ore/ex_act(severity, target)
+/obj/item/stack/ore/ex_act(severity, target, origin)
if (!severity || severity >= 2)
return
qdel(src)
diff --git a/code/modules/mob/dead/dead.dm b/code/modules/mob/dead/dead.dm
index d3ee2a87ea..ce767ae00d 100644
--- a/code/modules/mob/dead/dead.dm
+++ b/code/modules/mob/dead/dead.dm
@@ -79,14 +79,14 @@ INITIALIZE_IMMEDIATE(/mob/dead)
if(1)
pick = csa[1]
else
- pick = tgui_input_list(src, "Pick a server to jump to", "Server Hop", csa)
+ pick = input(src, "Pick a server to jump to", "Server Hop") as null|anything in csa
if(!pick)
return
var/addr = csa[pick]
- if(tgui_alert(src, "Jump to server [pick] ([addr])?", "Server Hop", list("Yes", "No")) != "Yes")
+ if(alert(src, "Jump to server [pick] ([addr])?", "Server Hop", "Yes", "No") != "Yes")
return
var/client/C = client
diff --git a/code/modules/mob/dead/new_player/new_player.dm b/code/modules/mob/dead/new_player/new_player.dm
index ec2dd4bc7c..2068ed47e8 100644
--- a/code/modules/mob/dead/new_player/new_player.dm
+++ b/code/modules/mob/dead/new_player/new_player.dm
@@ -258,7 +258,7 @@
var/list/days = list()
for(var/number in 1 to total_days_in_player_month)
days += number
- var/player_day = tgui_input_list(src, "What day of the month were you born in.", "", days)
+ var/player_day = input(src, "What day of the month were you born in.") as anything in days
if(player_day <= current_day)
//their birthday has passed
age_gate_result = TRUE
@@ -455,7 +455,7 @@
var/mintime = max(CONFIG_GET(number/respawn_delay), (SSticker.round_start_time + (CONFIG_GET(number/respawn_minimum_delay_roundstart) * 600)) - world.time, 0)
- var/this_is_like_playing_right = tgui_alert(src, "Are you sure you wish to observe? You will not be able to respawn for [round(mintime / 600, 0.1)] minutes!!","Player Setup",list("Yes","No"))
+ var/this_is_like_playing_right = alert(src,"Are you sure you wish to observe? You will not be able to respawn for [round(mintime / 600, 0.1)] minutes!!","Player Setup","Yes","No")
if(QDELETED(src) || !src.client || this_is_like_playing_right != "Yes")
ready = PLAYER_NOT_READY
@@ -537,11 +537,11 @@
/mob/dead/new_player/proc/AttemptLateSpawn(rank)
var/error = IsJobUnavailable(rank)
if(error != JOB_AVAILABLE)
- tgui_alert(src, get_job_unavailable_error_message(error, rank))
+ alert(src, get_job_unavailable_error_message(error, rank))
return FALSE
if(SSticker.late_join_disabled)
- tgui_alert(src, "An administrator has disabled late join spawning.")
+ alert(src, "An administrator has disabled late join spawning.")
return FALSE
if(!respawn_latejoin_check(notify = TRUE))
@@ -551,7 +551,7 @@
if(SSshuttle.arrivals)
close_spawn_windows() //In case we get held up
if(SSshuttle.arrivals.damaged && CONFIG_GET(flag/arrivals_shuttle_require_safe_latejoin))
- tgui_alert(src, "The arrivals shuttle is currently malfunctioning! You cannot join.")
+ src << alert("The arrivals shuttle is currently malfunctioning! You cannot join.")
return FALSE
if(CONFIG_GET(flag/arrivals_shuttle_require_undocked))
diff --git a/code/modules/mob/dead/new_player/sprite_accessories/body_markings.dm b/code/modules/mob/dead/new_player/sprite_accessories/body_markings.dm
index 148af35247..c477bb2cad 100644
--- a/code/modules/mob/dead/new_player/sprite_accessories/body_markings.dm
+++ b/code/modules/mob/dead/new_player/sprite_accessories/body_markings.dm
@@ -27,7 +27,7 @@
/datum/sprite_accessory/mam_body_markings/redpanda
name = "Redpanda"
icon_state = "redpanda"
- covered_limbs = list("Head" = MATRIX_RED_BLUE, "Chest" = MATRIX_RED_GREEN, "Left Leg" = MATRIX_RED_GREEN, "Right Leg" = MATRIX_RED_GREEN, "Left Arm" = MATRIX_RED_GREEN, "Right Arm" = MATRIX_RED_GREEN)
+ covered_limbs = list("Head" = MATRIX_ALL, "Chest" = MATRIX_RED_GREEN, "Left Leg" = MATRIX_RED_GREEN, "Right Leg" = MATRIX_RED_GREEN, "Left Arm" = MATRIX_RED_GREEN, "Right Arm" = MATRIX_RED_GREEN)
/datum/sprite_accessory/mam_body_markings/bat
name = "Bat"
diff --git a/code/modules/mob/dead/observer/observer.dm b/code/modules/mob/dead/observer/observer.dm
index 5f7fb58e38..0f30fe20fc 100644
--- a/code/modules/mob/dead/observer/observer.dm
+++ b/code/modules/mob/dead/observer/observer.dm
@@ -336,7 +336,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
if(stat == DEAD || sig_flags & COMPONENT_FREE_GHOSTING)
ghostize(1)
else
- var/response = tgui_alert(src, "Are you -sure- you want to ghost?\n(You are alive. If you ghost whilst alive you won't be able to re-enter this round [penalty ? "or play ghost roles [penalty == CANT_REENTER_ROUND ? "until the round is over" : "for the next [DisplayTimeText(penalty)]"]" : ""]! You can't change your mind so choose wisely!!)","Are you sure you want to ghost?",list("Ghost","Stay in body"))
+ var/response = alert(src, "Are you -sure- you want to ghost?\n(You are alive. If you ghost whilst alive you won't be able to re-enter this round [penalty ? "or play ghost roles [penalty == CANT_REENTER_ROUND ? "until the round is over" : "for the next [DisplayTimeText(penalty)]"]" : ""]! You can't change your mind so choose wisely!!)","Are you sure you want to ghost?","Ghost","Stay in body")
if(response != "Ghost")
return //didn't want to ghost after-all
if(istype(loc, /obj/machinery/cryopod))
@@ -372,7 +372,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
if(sig_flags & COMPONENT_FREE_GHOSTING)
ghostize(1)
else
- var/response = tgui_alert(src, "Are you -sure- you want to ghost?\n(You are alive. If you ghost whilst alive you won't be able to re-enter this round [penalty ? "or play ghost roles [penalty == CANT_REENTER_ROUND ? "until the round is over" : "for the next [DisplayTimeText(penalty)]"]" : ""]! You can't change your mind so choose wisely!!)","Are you sure you want to ghost?",list("Ghost","Stay in body"))
+ var/response = alert(src, "Are you -sure- you want to ghost?\n(You are alive. If you ghost whilst alive you won't be able to re-enter this round [penalty ? "or play ghost roles [penalty == CANT_REENTER_ROUND ? "until the round is over" : "for the next [DisplayTimeText(penalty)]"]" : ""]! You can't change your mind so choose wisely!!)","Are you sure you want to ghost?","Ghost","Stay in body")
if(response != "Ghost")
return
ghostize(0, penalize = TRUE)
@@ -431,7 +431,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
to_chat(usr, "You're already stuck out of your body!")
return FALSE
- var/response = tgui_alert(src, "Are you sure you want to prevent (almost) all means of resuscitation? This cannot be undone. THIS WILL ALSO STOP YOU FROM RESPAWNING!!!","Are you sure you want to stay dead and never respawn?",list("Yes","No"))
+ var/response = alert(src, "Are you sure you want to prevent (almost) all means of resuscitation? This cannot be undone. THIS WILL ALSO STOP YOU FROM RESPAWNING!!!","Are you sure you want to stay dead and never respawn?","Yes","No")
if(response != "Yes")
return
@@ -475,7 +475,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
var/area/A = V
if(!A.hidden)
filtered += A
- var/area/thearea = tgui_input_list(usr, "Area to jump to", "BOOYEA", filtered)
+ var/area/thearea = input("Area to jump to", "BOOYEA") as null|anything in filtered
if(!thearea)
return
@@ -557,7 +557,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
var/target = null //Chosen target.
dest += getpois(mobs_only = TRUE) //Fill list, prompt user with list
- target = tgui_input_list(usr, "Please, select a player!", "Jump to Mob", dest)
+ target = input("Please, select a player!", "Jump to Mob", null, null) as null|anything in dest
if (!target)//Make sure we actually have a target
return
@@ -582,7 +582,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
var/list/views = list()
for(var/i in 7 to max_view)
views |= i
- var/new_view = tgui_input_list(usr, "Choose your new view", "Modify view range", views)
+ var/new_view = input("Choose your new view", "Modify view range", 0) as null|anything in views
if(new_view)
client.view_size.setTo(clamp(new_view, 7, max_view) - 7)
else
@@ -697,7 +697,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
if(!(L in GLOB.player_list) && !L.mind)
possessible += L
- var/mob/living/target = tgui_input_list(usr, "Your new life begins today!", "Possess Mob", possessible)
+ var/mob/living/target = input("Your new life begins today!", "Possess Mob", null, null) as null|anything in possessible
if(!target)
return 0
@@ -707,7 +707,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
return 0
if(can_reenter_corpse && mind && mind.current)
- if(tgui_alert(src, "Your soul is still tied to your former life as [mind.current.name], if you go forward there is no going back to that life. Are you sure you wish to continue?", "Move On", list("Yes", "No")) == "No")
+ if(alert(src, "Your soul is still tied to your former life as [mind.current.name], if you go forward there is no going back to that life. Are you sure you wish to continue?", "Move On", "Yes", "No") == "No")
return 0
if(target.key)
to_chat(src, "Someone has taken this body while you were choosing!")
@@ -888,7 +888,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
var/eye_name = null
- eye_name = tgui_input_list(usr, "Please, select a player!", "Observe", creatures)
+ eye_name = input("Please, select a player!", "Observe", null, null) as null|anything in creatures
if (!eye_name)
return
diff --git a/code/modules/mob/dead/observer/respawn.dm b/code/modules/mob/dead/observer/respawn.dm
index 0b0c86e360..94ebf42a2a 100644
--- a/code/modules/mob/dead/observer/respawn.dm
+++ b/code/modules/mob/dead/observer/respawn.dm
@@ -21,7 +21,7 @@
if(!valid.len)
to_chat(src, "No player found that is either a ghost or is in lobby with restrictions active.")
return
- var/ckey = valid[tgui_input_list(src, "Choose a player (only showing logged in players who have restrictions)", "Unrestricted Respawn", valid)]
+ var/ckey = valid[input(src, "Choose a player (only showing logged in players who have restrictions)", "Unrestricted Respawn") as null|anything in valid]
var/client/player = GLOB.directory[ckey]
if(!player)
to_chat(src, "Client not found.")
@@ -29,7 +29,7 @@
var/mob/M = player.mob
if(istype(M, /mob/dead/observer))
var/mob/dead/observer/O = M
- var/confirm = tgui_alert(src, "Send [O]([ckey]) back to the lobby without respawn restrictions?", "Send to Lobby", list("Yes", "No"))
+ var/confirm = alert(src, "Send [O]([ckey]) back to the lobby without respawn restrictions?", "Send to Lobby", "Yes", "No")
if(confirm != "Yes")
return
message_admins("[key_name_admin(src)] gave [key_name_admin(O)] a full respawn and sent them back to the lobby.")
@@ -39,7 +39,7 @@
O.client.prefs.dnr_triggered = FALSE
else if(istype(M, /mob/dead/new_player))
var/mob/dead/new_player/NP = M
- var/confirm = tgui_alert(src, "Remove [NP]'s respawn restrictions?", "Remove Restrictions", list("Yes", "No"))
+ var/confirm = alert(src, "Remove [NP]'s respawn restrictions?", "Remove Restrictions", "Yes", "No")
if(confirm != "Yes")
return
message_admins("[key_name_admin(src)] removed [ckey]'s respawn restrictions.")
@@ -67,7 +67,7 @@
if(!valid.len)
to_chat(src, "No logged in ghosts found.")
return
- var/mob/dead/observer/O = valid[tgui_input_list(src, "Choose a player (only showing logged in)", "Remove Respawn Timer", valid)]
+ var/mob/dead/observer/O = valid[input(src, "Choose a player (only showing logged in)", "Remove Respawn Timer") as null|anything in valid]
if(!O.client)
to_chat(src, "[O] has no client.")
@@ -165,7 +165,7 @@
/**
* Actual proc that removes us and puts us back on lobby
- *
+ *
* Returns the new mob.
*/
/mob/dead/observer/proc/transfer_to_lobby()
diff --git a/code/modules/mob/living/bloodcrawl.dm b/code/modules/mob/living/bloodcrawl.dm
index b66158db8a..13803a63d2 100644
--- a/code/modules/mob/living/bloodcrawl.dm
+++ b/code/modules/mob/living/bloodcrawl.dm
@@ -11,7 +11,7 @@
/obj/effect/dummy/phased_mob/slaughter/relaymove(mob/user, direction)
forceMove(get_step(src,direction))
-/obj/effect/dummy/phased_mob/slaughter/ex_act()
+/obj/effect/dummy/phased_mob/slaughter/ex_act(severity, target, origin)
return
/obj/effect/dummy/phased_mob/slaughter/wave_ex_act(power, datum/wave_explosion/explosion, dir)
diff --git a/code/modules/mob/living/brain/brain.dm b/code/modules/mob/living/brain/brain.dm
index 8ffcce248b..91fab5f2ec 100644
--- a/code/modules/mob/living/brain/brain.dm
+++ b/code/modules/mob/living/brain/brain.dm
@@ -43,7 +43,7 @@
/mob/living/brain/update_mobility()
return ((mobility_flags = (container?.in_contents_of(/obj/mecha)? MOBILITY_FLAGS_DEFAULT : NONE)))
-/mob/living/brain/ex_act() //you cant blow up brainmobs because it makes transfer_to() freak out when borgs blow up.
+/mob/living/brain/ex_act(severity, target, origin) //you cant blow up brainmobs because it makes transfer_to() freak out when borgs blow up.
return
/mob/living/brain/wave_ex_act(power, datum/wave_explosion/explosion, dir)
diff --git a/code/modules/mob/living/brain/posibrain.dm b/code/modules/mob/living/brain/posibrain.dm
index c30c4c13eb..e1eb09405a 100644
--- a/code/modules/mob/living/brain/posibrain.dm
+++ b/code/modules/mob/living/brain/posibrain.dm
@@ -119,7 +119,7 @@ GLOBAL_VAR(posibrain_notify_cooldown)
if(!O.can_reenter_round())
return FALSE
- var/posi_ask = tgui_alert(user, "Become a [name]? (Warning, You can no longer be cloned, and all past lives will be forgotten!)","Are you positive?",list("Yes","No"))
+ var/posi_ask = alert("Become a [name]? (Warning, You can no longer be cloned, and all past lives will be forgotten!)","Are you positive?","Yes","No")
if(posi_ask == "No" || QDELETED(src))
return
transfer_personality(user)
diff --git a/code/modules/mob/living/carbon/alien/humanoid/alien_powers.dm b/code/modules/mob/living/carbon/alien/humanoid/alien_powers.dm
index b38b982e69..28d311b034 100644
--- a/code/modules/mob/living/carbon/alien/humanoid/alien_powers.dm
+++ b/code/modules/mob/living/carbon/alien/humanoid/alien_powers.dm
@@ -61,7 +61,7 @@ Doesn't work on other aliens/AI.*/
/obj/effect/proc_holder/alien/proc/check_vent_block(mob/living/user)
var/obj/machinery/atmospherics/components/unary/atmos_thing = locate() in user.loc
if(atmos_thing)
- var/rusure = tgui_alert(user, "Laying eggs and shaping resin here would block access to [atmos_thing]. Do you want to continue?", "Blocking Atmospheric Component", list("Yes", "No"))
+ var/rusure = alert(user, "Laying eggs and shaping resin here would block access to [atmos_thing]. Do you want to continue?", "Blocking Atmospheric Component", "Yes", "No")
if(rusure != "Yes")
return FALSE
return TRUE
@@ -91,13 +91,13 @@ Doesn't work on other aliens/AI.*/
var/list/options = list()
for(var/mob/living/Ms in oview(user))
options += Ms
- var/mob/living/M = tgui_input_list(user, "Select who to whisper to:","Whisper to?", options)
+ var/mob/living/M = input("Select who to whisper to:","Whisper to?",null) as null|mob in options
if(!M)
return 0
if(M.anti_magic_check(FALSE, FALSE, TRUE, 0))
to_chat(user, "As you try to communicate with [M], you're suddenly stopped by a vision of a massive tinfoil wall that streches beyond visible range. It seems you've been foiled.")
return FALSE
- var/msg = sanitize(tgui_input_text(user, "Message:", "Alien Whisper"))
+ var/msg = sanitize(input("Message:", "Alien Whisper") as text|null)
if(msg)
if(M.anti_magic_check(FALSE, FALSE, TRUE, 0))
to_chat(user, "As you try to communicate with [M], you're suddenly stopped by a vision of a massive tinfoil wall that streches beyond visible range. It seems you've been foiled.")
@@ -126,10 +126,10 @@ Doesn't work on other aliens/AI.*/
for(var/mob/living/carbon/A in oview(user))
if(A.getorgan(/obj/item/organ/alien/plasmavessel))
aliens_around.Add(A)
- var/mob/living/carbon/M = tgui_input_list(user, "Select who to transfer to:","Transfer plasma to?", aliens_around)
+ var/mob/living/carbon/M = input("Select who to transfer to:","Transfer plasma to?",null) as mob in aliens_around
if(!M)
return 0
- var/amount = tgui_input_num(user, "Amount:", "Transfer Plasma to [M]")
+ var/amount = input("Amount:", "Transfer Plasma to [M]") as num
if (amount)
amount = min(abs(round(amount)), user.getPlasma())
if (get_dist(user,M) <= 1)
@@ -169,7 +169,7 @@ Doesn't work on other aliens/AI.*/
/obj/effect/proc_holder/alien/acid/fire(mob/living/carbon/alien/user)
- var/O = tgui_input_list(user, "Select what to dissolve:","Dissolve", oview(1,user))
+ var/O = input("Select what to dissolve:","Dissolve",null) as obj|turf in oview(1,user)
if(!O || user.incapacitated())
return 0
else
@@ -272,7 +272,7 @@ Doesn't work on other aliens/AI.*/
if(!check_vent_block(user))
return FALSE
- var/choice = tgui_input_list(user, "Choose what you wish to shape.","Resin building", structures)
+ var/choice = input("Choose what you wish to shape.","Resin building") as null|anything in structures
if(!choice)
return FALSE
if (!cost_check(check_turf,user))
diff --git a/code/modules/mob/living/carbon/alien/larva/powers.dm b/code/modules/mob/living/carbon/alien/larva/powers.dm
index cb26d7b51f..7204759db5 100644
--- a/code/modules/mob/living/carbon/alien/larva/powers.dm
+++ b/code/modules/mob/living/carbon/alien/larva/powers.dm
@@ -42,7 +42,7 @@
to_chat(L, "Huntersare the most agile caste, tasked with hunting for hosts. They are faster than a human and can even pounce, but are not much tougher than a drone.")
to_chat(L, "Sentinelsare tasked with protecting the hive. With their ranged spit, invisibility, and high health, they make formidable guardians and acceptable secondhand hunters.")
to_chat(L, "Dronesare the weakest and slowest of the castes, but can grow into a praetorian and then queen if no queen exists, and are vital to maintaining a hive with their resin secretion abilities.")
- var/alien_caste = tgui_alert(L, "Please choose which alien caste you shall belong to.",,list("Hunter","Sentinel","Drone"))
+ var/alien_caste = alert(L, "Please choose which alien caste you shall belong to.",,"Hunter","Sentinel","Drone")
if(user.incapacitated()) //something happened to us while we were choosing.
return
diff --git a/code/modules/mob/living/carbon/carbon.dm b/code/modules/mob/living/carbon/carbon.dm
index 69dc2f220f..0700cba2ea 100644
--- a/code/modules/mob/living/carbon/carbon.dm
+++ b/code/modules/mob/living/carbon/carbon.dm
@@ -198,7 +198,7 @@
if(start_T && end_T)
log_combat(src, throwable_mob, "thrown", addition="grab from tile in [AREACOORD(start_T)] towards tile at [AREACOORD(end_T)]")
- else if(!CHECK_BITFIELD(I.item_flags, ABSTRACT) && !HAS_TRAIT(I, TRAIT_NODROP))
+ else if(!(I.item_flags & ABSTRACT) && !HAS_TRAIT(I, TRAIT_NODROP))
thrown_thing = I
dropItemToGround(I)
@@ -621,12 +621,12 @@
to_chat(src, "You're too exhausted to keep going...")
set_resting(TRUE, FALSE, FALSE)
SEND_SIGNAL(src, COMSIG_DISABLE_COMBAT_MODE)
- ENABLE_BITFIELD(combat_flags, COMBAT_FLAG_HARD_STAMCRIT)
+ combat_flags |= COMBAT_FLAG_HARD_STAMCRIT
filters += CIT_FILTER_STAMINACRIT
update_mobility()
if((combat_flags & COMBAT_FLAG_HARD_STAMCRIT) && total_health <= STAMINA_CRIT_REMOVAL_THRESHOLD)
to_chat(src, "You don't feel nearly as exhausted anymore.")
- DISABLE_BITFIELD(combat_flags, COMBAT_FLAG_HARD_STAMCRIT)
+ combat_flags &= ~(COMBAT_FLAG_HARD_STAMCRIT)
filters -= CIT_FILTER_STAMINACRIT
update_mobility()
UpdateStaminaBuffer()
@@ -1038,7 +1038,7 @@
if(href_list[VV_HK_MODIFY_BODYPART])
if(!check_rights(R_SPAWN))
return
- var/edit_action = tgui_input_list(usr, "What would you like to do?","Modify Body Part", list("add","remove", "augment"))
+ var/edit_action = input(usr, "What would you like to do?","Modify Body Part") as null|anything in list("add","remove", "augment")
if(!edit_action)
return
var/list/limb_list = list()
@@ -1051,7 +1051,7 @@
limb_list = list(BODY_ZONE_HEAD, BODY_ZONE_L_ARM, BODY_ZONE_R_ARM, BODY_ZONE_L_LEG, BODY_ZONE_R_LEG)
for(var/obj/item/bodypart/B in bodyparts)
limb_list -= B.body_zone
- var/result = tgui_input_list(usr, "Please choose which body part to [edit_action]","[capitalize(edit_action)] Body Part", limb_list)
+ var/result = input(usr, "Please choose which body part to [edit_action]","[capitalize(edit_action)] Body Part") as null|anything in limb_list
if(result)
var/obj/item/bodypart/BP = get_bodypart(result)
switch(edit_action)
@@ -1078,7 +1078,7 @@
if(href_list[VV_HK_MAKE_AI])
if(!check_rights(R_SPAWN))
return
- if(tgui_alert(usr, "Confirm mob type change?",,list("Transform","Cancel")) != "Transform")
+ if(alert("Confirm mob type change?",,"Transform","Cancel") != "Transform")
return
usr.client.holder.Topic("vv_override", list("makeai"=href_list[VV_HK_TARGET]))
if(href_list[VV_HK_MODIFY_ORGANS])
@@ -1093,7 +1093,7 @@
for(var/i in artpaths)
var/datum/martial_art/M = i
artnames[initial(M.name)] = M
- var/result = tgui_input_list(usr, "Choose the martial art to teach","JUDO CHOP", artnames)
+ var/result = input(usr, "Choose the martial art to teach","JUDO CHOP") as null|anything in artnames
if(!usr)
return
if(QDELETED(src))
@@ -1109,7 +1109,7 @@
if(!check_rights(NONE))
return
var/list/traumas = subtypesof(/datum/brain_trauma)
- var/result = tgui_input_list(usr, "Choose the brain trauma to apply","Traumatize", traumas)
+ var/result = input(usr, "Choose the brain trauma to apply","Traumatize") as null|anything in traumas
if(!usr)
return
if(QDELETED(src))
@@ -1131,7 +1131,7 @@
if(!check_rights(NONE))
return
var/list/hallucinations = subtypesof(/datum/hallucination)
- var/result = tgui_input_list(usr, "Choose the hallucination to apply","Send Hallucination", hallucinations)
+ var/result = input(usr, "Choose the hallucination to apply","Send Hallucination") as null|anything in hallucinations
if(!usr)
return
if(QDELETED(src))
diff --git a/code/modules/mob/living/carbon/carbon_movement.dm b/code/modules/mob/living/carbon/carbon_movement.dm
index e98ddf5954..ffb8523a9e 100644
--- a/code/modules/mob/living/carbon/carbon_movement.dm
+++ b/code/modules/mob/living/carbon/carbon_movement.dm
@@ -22,14 +22,14 @@
/mob/living/carbon/Moved()
. = ..()
- if(. && !CHECK_BITFIELD(movement_type, FLOATING)) //floating is easy
+ if(. && !(movement_type & FLOATING)) //floating is easy
if(HAS_TRAIT(src, TRAIT_NOHUNGER))
set_nutrition(NUTRITION_LEVEL_FED - 1) //just less than feeling vigorous
else if(nutrition && stat != DEAD)
var/loss = HUNGER_FACTOR/10
if(m_intent == MOVE_INTENT_RUN)
loss *= 2
- adjust_nutrition(loss)
+ adjust_nutrition(-loss)
/mob/living/carbon/can_move_under_living(mob/living/other)
. = ..()
diff --git a/code/modules/mob/living/carbon/human/examine.dm b/code/modules/mob/living/carbon/human/examine.dm
index f363aecf84..0e75595c75 100644
--- a/code/modules/mob/living/carbon/human/examine.dm
+++ b/code/modules/mob/living/carbon/human/examine.dm
@@ -113,11 +113,11 @@
. += effects_exam
//CIT CHANGES START HERE - adds genital details to examine text
- if(LAZYLEN(internal_organs) && CHECK_BITFIELD(user.client?.prefs.cit_toggles, GENITAL_EXAMINE))
+ if(LAZYLEN(internal_organs) && (user.client?.prefs.cit_toggles & GENITAL_EXAMINE))
for(var/obj/item/organ/genital/dicc in internal_organs)
if(istype(dicc) && dicc.is_exposed())
. += "[dicc.desc]"
- if(CHECK_BITFIELD(user.client?.prefs.cit_toggles, VORE_EXAMINE))
+ if(user.client?.prefs.cit_toggles & VORE_EXAMINE)
var/cursed_stuff = attempt_vr(src,"examine_bellies",args) //vore Code
if(cursed_stuff)
. += cursed_stuff
diff --git a/code/modules/mob/living/carbon/human/human.dm b/code/modules/mob/living/carbon/human/human.dm
index 55afe78e2e..8669a1458a 100644
--- a/code/modules/mob/living/carbon/human/human.dm
+++ b/code/modules/mob/living/carbon/human/human.dm
@@ -333,7 +333,7 @@
if(href_list["hud"] == "m")
if(istype(H.glasses, /obj/item/clothing/glasses/hud/health) || istype(H.getorganslot(ORGAN_SLOT_HUD), /obj/item/organ/cyberimp/eyes/hud/medical))
if(href_list["p_stat"])
- var/health_status = tgui_input_list(usr, "Specify a new physical status for this person.", "Medical HUD", list("Active", "Physically Unfit", "*Unconscious*", "*Deceased*", "Cancel"))
+ var/health_status = input(usr, "Specify a new physical status for this person.", "Medical HUD", R.fields["p_stat"]) in list("Active", "Physically Unfit", "*Unconscious*", "*Deceased*", "Cancel")
if(R)
if(!H.canUseHUD())
return
@@ -343,7 +343,7 @@
R.fields["p_stat"] = health_status
return
if(href_list["m_stat"])
- var/health_status = tgui_input_list(usr, "Specify a new mental status for this person.", "Medical HUD", list("Stable", "*Watch*", "*Unstable*", "*Insane*", "Cancel"))
+ var/health_status = input(usr, "Specify a new mental status for this person.", "Medical HUD", R.fields["m_stat"]) in list("Stable", "*Watch*", "*Unstable*", "*Insane*", "Cancel")
if(R)
if(!H.canUseHUD())
return
@@ -419,7 +419,7 @@
R = find_record("name", perpname, GLOB.data_core.security)
if(R)
if(href_list["status"])
- var/setcriminal = tgui_input_list(usr, "Specify a new criminal status for this person.", "Security HUD", list("None", "*Arrest*", "Incarcerated", "Paroled", "Discharged", "Cancel"))
+ var/setcriminal = input(usr, "Specify a new criminal status for this person.", "Security HUD", R.fields["criminal"]) in list("None", "*Arrest*", "Incarcerated", "Paroled", "Discharged", "Cancel")
if(setcriminal != "Cancel")
if(R)
if(H.canUseHUD())
@@ -452,7 +452,7 @@
return
if(href_list["add_crime"])
- switch(tgui_alert(usr, "What crime would you like to add?","Security HUD",list("Minor Crime","Major Crime","Cancel")))
+ switch(alert("What crime would you like to add?","Security HUD","Minor Crime","Major Crime","Cancel"))
if("Minor Crime")
if(R)
var/t1 = stripped_input("Please input minor crime names:", "Security HUD", "", null)
@@ -878,7 +878,7 @@
var/qname = initial(T.name)
options[has_quirk(T) ? "[qname] (Remove)" : "[qname] (Add)"] = T
- var/result = tgui_input_list(usr, "Choose quirk to add/remove","Quirk Mod", options)
+ var/result = input(usr, "Choose quirk to add/remove","Quirk Mod") as null|anything in options
if(result)
if(result == "Clear")
for(var/datum/quirk/q in roundstart_quirks)
@@ -892,31 +892,31 @@
if(href_list[VV_HK_MAKE_MONKEY])
if(!check_rights(R_SPAWN))
return
- if(tgui_alert(usr, "Confirm mob type change?",,list("Transform","Cancel")) != "Transform")
+ if(alert("Confirm mob type change?",,"Transform","Cancel") != "Transform")
return
usr.client.holder.Topic("vv_override", list("monkeyone"=href_list[VV_HK_TARGET]))
if(href_list[VV_HK_MAKE_CYBORG])
if(!check_rights(R_SPAWN))
return
- if(tgui_alert(usr, "Confirm mob type change?",,list("Transform","Cancel")) != "Transform")
+ if(alert("Confirm mob type change?",,"Transform","Cancel") != "Transform")
return
usr.client.holder.Topic("vv_override", list("makerobot"=href_list[VV_HK_TARGET]))
if(href_list[VV_HK_MAKE_ALIEN])
if(!check_rights(R_SPAWN))
return
- if(tgui_alert(usr, "Confirm mob type change?",,list("Transform","Cancel")) != "Transform")
+ if(alert("Confirm mob type change?",,"Transform","Cancel") != "Transform")
return
usr.client.holder.Topic("vv_override", list("makealien"=href_list[VV_HK_TARGET]))
if(href_list[VV_HK_MAKE_SLIME])
if(!check_rights(R_SPAWN))
return
- if(tgui_alert(usr, "Confirm mob type change?",,list("Transform","Cancel")) != "Transform")
+ if(alert("Confirm mob type change?",,"Transform","Cancel") != "Transform")
return
usr.client.holder.Topic("vv_override", list("makeslime"=href_list[VV_HK_TARGET]))
if(href_list[VV_HK_SET_SPECIES])
if(!check_rights(R_SPAWN))
return
- var/result = tgui_input_list(usr, "Please choose a new species","Species", GLOB.species_list)
+ var/result = input(usr, "Please choose a new species","Species") as null|anything in GLOB.species_list
if(result)
var/newtype = GLOB.species_list[result]
admin_ticket_log("[key_name_admin(usr)] has modified the bodyparts of [src] to [result]")
diff --git a/code/modules/mob/living/carbon/human/human_defense.dm b/code/modules/mob/living/carbon/human/human_defense.dm
index 1174fcba70..16ab351d64 100644
--- a/code/modules/mob/living/carbon/human/human_defense.dm
+++ b/code/modules/mob/living/carbon/human/human_defense.dm
@@ -319,7 +319,10 @@
var/atom/A = I
if(!QDELETED(A))
A.ex_act(severity)
- gib()
+ if(istype(origin, /datum/explosion))
+ gib(was_explosion = origin)
+ else
+ gib()
return
else
brute_loss = 500
diff --git a/code/modules/mob/living/carbon/human/innate_abilities/blobform.dm b/code/modules/mob/living/carbon/human/innate_abilities/blobform.dm
index c8f870bf2a..482268f8f5 100644
--- a/code/modules/mob/living/carbon/human/innate_abilities/blobform.dm
+++ b/code/modules/mob/living/carbon/human/innate_abilities/blobform.dm
@@ -62,7 +62,7 @@
H.add_movespeed_modifier(/datum/movespeed_modifier/slime_puddle)
- ENABLE_BITFIELD(H.pass_flags, PASSMOB) //this actually lets people pass over you
+ H.pass_flags |= PASSMOB //this actually lets people pass over you
squeak = H.AddComponent(/datum/component/squeak, custom_sounds = list('sound/effects/blobattack.ogg')) //blorble noise when people step on you
//if the user is a changeling, retract their sting
@@ -103,7 +103,7 @@
REMOVE_TRAIT(H, TRAIT_HUMAN_NO_RENDER, SLIMEPUDDLE_TRAIT)
H.update_disabled_bodyparts(silent = TRUE)
H.remove_movespeed_modifier(/datum/movespeed_modifier/slime_puddle)
- DISABLE_BITFIELD(H.pass_flags, PASSMOB)
+ H.pass_flags &= ~(PASSMOB)
is_puddle = FALSE
if(squeak)
squeak.RemoveComponent()
diff --git a/code/modules/mob/living/carbon/human/innate_abilities/customization.dm b/code/modules/mob/living/carbon/human/innate_abilities/customization.dm
index ccce6141b6..363f6ecbb2 100644
--- a/code/modules/mob/living/carbon/human/innate_abilities/customization.dm
+++ b/code/modules/mob/living/carbon/human/innate_abilities/customization.dm
@@ -22,7 +22,7 @@
/datum/action/innate/ability/humanoid_customization/proc/change_form()
var/mob/living/carbon/human/H = owner
- var/select_alteration = tgui_input_list(owner, "Select what part of your form to alter", "Form Alteration", list("Body Color","Hair Style", "Genitals", "Tail", "Snout", "Markings", "Ears", "Taur body", "Penis", "Vagina", "Penis Length", "Breast Size", "Breast Shape", "Cancel"))
+ var/select_alteration = input(owner, "Select what part of your form to alter", "Form Alteration", "cancel") in list("Body Color","Hair Style", "Genitals", "Tail", "Snout", "Markings", "Ears", "Taur body", "Penis", "Vagina", "Penis Length", "Breast Size", "Breast Shape", "Cancel")
if(select_alteration == "Body Color")
var/new_color = input(owner, "Choose your skin color:", "Race change","#"+H.dna.features["mcolor"]) as color|null
@@ -36,21 +36,21 @@
to_chat(H, "Invalid color. Your color is not bright enough.")
else if(select_alteration == "Hair Style")
if(H.gender == MALE)
- var/new_style = tgui_input_list(owner, "Select a facial hair style", "Hair Alterations", GLOB.facial_hair_styles_list)
+ var/new_style = input(owner, "Select a facial hair style", "Hair Alterations") as null|anything in GLOB.facial_hair_styles_list
if(new_style)
H.facial_hair_style = new_style
else
H.facial_hair_style = "Shaved"
//handle normal hair
- var/new_style = tgui_input_list(owner, "Select a hair style", "Hair Alterations", GLOB.hair_styles_list)
+ var/new_style = input(owner, "Select a hair style", "Hair Alterations") as null|anything in GLOB.hair_styles_list
if(new_style)
H.hair_style = new_style
H.update_hair()
else if (select_alteration == "Genitals")
- var/operation = tgui_input_list(owner, "Select organ operation.", "Organ Manipulation", list("add sexual organ", "remove sexual organ", "cancel"))
+ var/operation = input("Select organ operation.", "Organ Manipulation", "cancel") in list("add sexual organ", "remove sexual organ", "cancel")
switch(operation)
if("add sexual organ")
- var/new_organ = tgui_input_list(owner, "Select sexual organ:", "Organ Manipulation", GLOB.genitals_list)
+ var/new_organ = input("Select sexual organ:", "Organ Manipulation") as null|anything in GLOB.genitals_list
if(!new_organ)
return
H.give_genital(GLOB.genitals_list[new_organ])
@@ -60,7 +60,7 @@
for(var/obj/item/organ/genital/X in H.internal_organs)
var/obj/item/organ/I = X
organs["[I.name] ([I.type])"] = I
- var/obj/item/O = tgui_input_list(owner, "Select sexual organ:", "Organ Manipulation", organs)
+ var/obj/item/O = input("Select sexual organ:", "Organ Manipulation", null) as null|anything in organs
var/obj/item/organ/genital/G = organs[O]
if(!G)
return
@@ -77,7 +77,7 @@
if((!S.ckeys_allowed) || (S.ckeys_allowed.Find(H.client.ckey)))
snowflake_ears_list[S.name] = path
var/new_ears
- new_ears = tgui_input_list(owner, "Choose your character's ears:", "Ear Alteration", snowflake_ears_list)
+ new_ears = input(owner, "Choose your character's ears:", "Ear Alteration") as null|anything in snowflake_ears_list
if(new_ears)
H.dna.features["mam_ears"] = new_ears
H.update_body()
@@ -91,7 +91,7 @@
if((!S.ckeys_allowed) || (S.ckeys_allowed.Find(H.client.ckey)))
snowflake_snouts_list[S.name] = path
var/new_snout
- new_snout = tgui_input_list(owner, "Choose your character's face:", "Face Alteration", snowflake_snouts_list)
+ new_snout = input(owner, "Choose your character's face:", "Face Alteration") as null|anything in snowflake_snouts_list
if(new_snout)
H.dna.features["mam_snouts"] = new_snout
H.update_body()
@@ -105,7 +105,7 @@
if((!S.ckeys_allowed) || (S.ckeys_allowed.Find(H.client.ckey)))
snowflake_markings_list[S.name] = path
var/new_mam_body_markings
- new_mam_body_markings = tgui_input_list(H, "Choose your character's body markings:", "Marking Alteration", snowflake_markings_list)
+ new_mam_body_markings = input(H, "Choose your character's body markings:", "Marking Alteration") as null|anything in snowflake_markings_list
if(new_mam_body_markings)
H.dna.features["mam_body_markings"] = new_mam_body_markings
for(var/X in H.bodyparts) //propagates the markings changes
@@ -122,7 +122,7 @@
if((!S.ckeys_allowed) || (S.ckeys_allowed.Find(H.client.ckey)))
snowflake_tails_list[S.name] = path
var/new_tail
- new_tail = tgui_input_list(owner, "Choose your character's Tail(s):", "Tail Alteration", snowflake_tails_list)
+ new_tail = input(owner, "Choose your character's Tail(s):", "Tail Alteration") as null|anything in snowflake_tails_list
if(new_tail)
H.dna.features["mam_tail"] = new_tail
if(new_tail != "None")
@@ -138,7 +138,7 @@
if((!S.ckeys_allowed) || (S.ckeys_allowed.Find(H.client.ckey)))
snowflake_taur_list[S.name] = path
var/new_taur
- new_taur = tgui_input_list(owner, "Choose your character's tauric body:", "Tauric Alteration", snowflake_taur_list)
+ new_taur = input(owner, "Choose your character's tauric body:", "Tauric Alteration") as null|anything in snowflake_taur_list
if(new_taur)
H.dna.features["taur"] = new_taur
if(new_taur != "None")
@@ -149,7 +149,7 @@
for(var/obj/item/organ/genital/penis/X in H.internal_organs)
qdel(X)
var/new_shape
- new_shape = tgui_input_list(owner, "Choose your character's dong", "Genital Alteration", GLOB.cock_shapes_list)
+ new_shape = input(owner, "Choose your character's dong", "Genital Alteration") as null|anything in GLOB.cock_shapes_list
if(new_shape)
H.dna.features["cock_shape"] = new_shape
H.update_genitals()
@@ -162,7 +162,7 @@
for(var/obj/item/organ/genital/vagina/X in H.internal_organs)
qdel(X)
var/new_shape
- new_shape = tgui_input_list(owner, "Choose your character's pussy", "Genital Alteration", GLOB.vagina_shapes_list)
+ new_shape = input(owner, "Choose your character's pussy", "Genital Alteration") as null|anything in GLOB.vagina_shapes_list
if(new_shape)
H.dna.features["vag_shape"] = new_shape
H.update_genitals()
@@ -175,7 +175,7 @@
qdel(X)
var/min_D = CONFIG_GET(number/penis_min_inches_prefs)
var/max_D = CONFIG_GET(number/penis_max_inches_prefs)
- var/new_length = tgui_input_num(owner, "Penis length in inches:\n([min_D]-[max_D])", "Genital Alteration", H.dna.features["cock_length"])
+ var/new_length = input(owner, "Penis length in inches:\n([min_D]-[max_D])", "Genital Alteration") as num|null
if(new_length)
H.dna.features["cock_length"] = clamp(round(new_length), min_D, max_D)
H.update_genitals()
@@ -186,7 +186,7 @@
else if (select_alteration == "Breast Size")
for(var/obj/item/organ/genital/breasts/X in H.internal_organs)
qdel(X)
- var/new_size = tgui_input_list(owner, "Breast Size", "Genital Alteration", CONFIG_GET(keyed_list/breasts_cups_prefs))
+ var/new_size = input(owner, "Breast Size", "Genital Alteration") as null|anything in CONFIG_GET(keyed_list/breasts_cups_prefs)
if(new_size)
H.dna.features["breasts_size"] = new_size
H.update_genitals()
@@ -197,7 +197,7 @@
for(var/obj/item/organ/genital/breasts/X in H.internal_organs)
qdel(X)
var/new_shape
- new_shape = tgui_input_list(owner, "Breast Shape", "Genital Alteration", GLOB.breasts_shapes_list)
+ new_shape = input(owner, "Breast Shape", "Genital Alteration") as null|anything in GLOB.breasts_shapes_list
if(new_shape)
H.dna.features["breasts_shape"] = new_shape
H.update_genitals()
diff --git a/code/modules/mob/living/carbon/human/inventory.dm b/code/modules/mob/living/carbon/human/inventory.dm
index b135ae9cd8..c75654e10b 100644
--- a/code/modules/mob/living/carbon/human/inventory.dm
+++ b/code/modules/mob/living/carbon/human/inventory.dm
@@ -188,9 +188,9 @@
dropItemToGround(r_store, TRUE) //Again, makes sense for pockets to drop.
if(l_store)
dropItemToGround(l_store, TRUE)
- if(wear_id && !CHECK_BITFIELD(wear_id.item_flags, NO_UNIFORM_REQUIRED))
+ if(wear_id && !(wear_id.item_flags & NO_UNIFORM_REQUIRED))
dropItemToGround(wear_id)
- if(belt && !CHECK_BITFIELD(belt.item_flags, NO_UNIFORM_REQUIRED))
+ if(belt && !(belt.item_flags & NO_UNIFORM_REQUIRED))
dropItemToGround(belt)
w_uniform = null
update_suit_sensors()
diff --git a/code/modules/mob/living/carbon/human/life.dm b/code/modules/mob/living/carbon/human/life.dm
index b43cd266be..85f01e63b3 100644
--- a/code/modules/mob/living/carbon/human/life.dm
+++ b/code/modules/mob/living/carbon/human/life.dm
@@ -214,7 +214,7 @@
var/missing_body_parts_flags = ~get_body_parts_flags()
var/max_protection = 1
if(missing_body_parts_flags) //I don't like copypasta as much as proc overhead. Do you want me to make these into a macro?
- DISABLE_BITFIELD(thermal_protection_flags, missing_body_parts_flags)
+ thermal_protection_flags &= ~(missing_body_parts_flags)
if(missing_body_parts_flags & HEAD)
max_protection -= THERMAL_PROTECTION_HEAD
if(missing_body_parts_flags & CHEST)
diff --git a/code/modules/mob/living/carbon/human/species.dm b/code/modules/mob/living/carbon/human/species.dm
index 21554f25b4..3976b1ebca 100644
--- a/code/modules/mob/living/carbon/human/species.dm
+++ b/code/modules/mob/living/carbon/human/species.dm
@@ -1243,7 +1243,7 @@ GLOBAL_LIST_EMPTY(roundstart_race_names)
if(SLOT_BELT)
if(H.belt)
return FALSE
- if(!CHECK_BITFIELD(I.item_flags, NO_UNIFORM_REQUIRED))
+ if(!(I.item_flags & NO_UNIFORM_REQUIRED))
var/obj/item/bodypart/O = H.get_bodypart(BODY_ZONE_CHEST)
if(!H.w_uniform && !nojumpsuit && (!O || !O.is_robotic_limb()))
if(return_warning)
@@ -1285,7 +1285,7 @@ GLOBAL_LIST_EMPTY(roundstart_race_names)
if(SLOT_WEAR_ID)
if(H.wear_id)
return FALSE
- if(!CHECK_BITFIELD(I.item_flags, NO_UNIFORM_REQUIRED))
+ if(!(I.item_flags & NO_UNIFORM_REQUIRED))
var/obj/item/bodypart/O = H.get_bodypart(BODY_ZONE_CHEST)
if(!H.w_uniform && !nojumpsuit && (!O || !O.is_robotic_limb()))
if(return_warning)
diff --git a/code/modules/mob/living/carbon/human/species_types/dullahan.dm b/code/modules/mob/living/carbon/human/species_types/dullahan.dm
index 0418292fea..7cd582d050 100644
--- a/code/modules/mob/living/carbon/human/species_types/dullahan.dm
+++ b/code/modules/mob/living/carbon/human/species_types/dullahan.dm
@@ -31,7 +31,7 @@
/datum/species/dullahan/on_species_gain(mob/living/carbon/human/H, datum/species/old_species)
. = ..()
- DISABLE_BITFIELD(H.flags_1, HEAR_1)
+ H.flags_1 &= ~(HEAR_1)
var/obj/item/bodypart/head/head = H.get_bodypart(BODY_ZONE_HEAD)
if(head)
if(pumpkin)//Pumpkinhead!
@@ -49,7 +49,7 @@
OA.Trigger()
/datum/species/dullahan/on_species_loss(mob/living/carbon/human/H)
- ENABLE_BITFIELD(H.flags_1, HEAR_1)
+ H.flags_1 |= HEAR_1
H.reset_perspective(H)
if(myhead)
var/obj/item/dullahan_relay/DR = myhead
diff --git a/code/modules/mob/living/carbon/human/species_types/ipc.dm b/code/modules/mob/living/carbon/human/species_types/ipc.dm
index 6797881279..eb870f9624 100644
--- a/code/modules/mob/living/carbon/human/species_types/ipc.dm
+++ b/code/modules/mob/living/carbon/human/species_types/ipc.dm
@@ -51,7 +51,7 @@
/datum/action/innate/monitor_change/Activate()
var/mob/living/carbon/human/H = owner
- var/new_ipc_screen = tgui_input_list(usr, "Choose your character's screen:", "Monitor Display", GLOB.ipc_screens_list)
+ var/new_ipc_screen = input(usr, "Choose your character's screen:", "Monitor Display") as null|anything in GLOB.ipc_screens_list
if(!new_ipc_screen)
return
H.dna.features["ipc_screen"] = new_ipc_screen
diff --git a/code/modules/mob/living/carbon/human/species_types/jellypeople.dm b/code/modules/mob/living/carbon/human/species_types/jellypeople.dm
index 9e1c5e63bc..04c69a4138 100644
--- a/code/modules/mob/living/carbon/human/species_types/jellypeople.dm
+++ b/code/modules/mob/living/carbon/human/species_types/jellypeople.dm
@@ -663,7 +663,7 @@
Remove(H)
return
- var/message = sanitize(tgui_input_text(usr, "Message:", "Slime Telepathy"))
+ var/message = sanitize(input("Message:", "Slime Telepathy") as text|null)
if(!species || !(H in species.linked_mobs))
to_chat(H, "The link seems to have been severed...")
@@ -700,13 +700,13 @@
var/list/options = list()
for(var/mob/living/Ms in oview(H))
options += Ms
- var/mob/living/M = tgui_input_list(usr, "Select who to send your message to:","Send thought to?", options)
+ var/mob/living/M = input("Select who to send your message to:","Send thought to?",null) as null|mob in options
if(!M)
return
if(M.anti_magic_check(FALSE, FALSE, TRUE, 0))
to_chat(H, "As you try to communicate with [M], you're suddenly stopped by a vision of a massive tinfoil wall that streches beyond visible range. It seems you've been foiled.")
return
- var/msg = sanitize(tgui_input_text(usr, "Message:", "Telepathy"))
+ var/msg = sanitize(input("Message:", "Telepathy") as text|null)
if(msg)
if(M.anti_magic_check(FALSE, FALSE, TRUE, 0))
to_chat(H, "As you try to communicate with [M], you're suddenly stopped by a vision of a massive tinfoil wall that streches beyond visible range. It seems you've been foiled.")
diff --git a/code/modules/mob/living/carbon/life.dm b/code/modules/mob/living/carbon/life.dm
index a839a0dd83..8516d1decf 100644
--- a/code/modules/mob/living/carbon/life.dm
+++ b/code/modules/mob/living/carbon/life.dm
@@ -324,7 +324,7 @@
if(!HAS_TRAIT(src, TRAIT_NO_INTERNALS))
for(check in GET_INTERNAL_SLOTS(src))
- if(CHECK_BITFIELD(check.clothing_flags, ALLOWINTERNALS))
+ if((check.clothing_flags & ALLOWINTERNALS))
internals = TRUE
if(internal)
if(internal.loc != src)
diff --git a/code/modules/mob/living/living.dm b/code/modules/mob/living/living.dm
index a68f20aa18..5cbb68eceb 100644
--- a/code/modules/mob/living/living.dm
+++ b/code/modules/mob/living/living.dm
@@ -125,19 +125,19 @@
if(IS_STAMCRIT(src))
to_chat(src, "You're too exhausted to crawl [(CHECK_MOBILITY(L, MOBILITY_STAND)) ? "under": "over"] [L].")
return TRUE
- ENABLE_BITFIELD(combat_flags, COMBAT_FLAG_ATTEMPTING_CRAWL)
+ combat_flags &= COMBAT_FLAG_ATTEMPTING_CRAWL
visible_message("[src] is attempting to crawl [(CHECK_MOBILITY(L, MOBILITY_STAND)) ? "under" : "over"] [L].",
"You are now attempting to crawl [(CHECK_MOBILITY(L, MOBILITY_STAND)) ? "under": "over"] [L].",
target = L, target_message = "[src] is attempting to crawl [(CHECK_MOBILITY(L, MOBILITY_STAND)) ? "under" : "over"] you.")
if(!do_after(src, CRAWLUNDER_DELAY, target = src) || CHECK_MOBILITY(src, MOBILITY_STAND))
- DISABLE_BITFIELD(combat_flags, COMBAT_FLAG_ATTEMPTING_CRAWL)
+ combat_flags &= ~(COMBAT_FLAG_ATTEMPTING_CRAWL)
return TRUE
var/src_passmob = (pass_flags & PASSMOB)
pass_flags |= PASSMOB
Move(origtargetloc)
if(!src_passmob)
pass_flags &= ~PASSMOB
- DISABLE_BITFIELD(combat_flags, COMBAT_FLAG_ATTEMPTING_CRAWL)
+ combat_flags &= ~(COMBAT_FLAG_ATTEMPTING_CRAWL)
return TRUE
//END OF CIT CHANGES
@@ -489,7 +489,7 @@
to_chat(src, "You are already sleeping.")
return
else
- if(tgui_alert(src, "You sure you want to sleep for a while?", "Sleep", list("Yes", "No")) == "Yes")
+ if(alert(src, "You sure you want to sleep for a while?", "Sleep", "Yes", "No") == "Yes")
SetSleeping(400) //Short nap
/mob/proc/get_contents()
diff --git a/code/modules/mob/living/living_mobility.dm b/code/modules/mob/living/living_mobility.dm
index 2256a93fa1..af34fb54cf 100644
--- a/code/modules/mob/living/living_mobility.dm
+++ b/code/modules/mob/living/living_mobility.dm
@@ -28,7 +28,7 @@
set name = "Rest"
set category = "IC"
if(client?.prefs?.autostand)
- TOGGLE_BITFIELD(combat_flags, COMBAT_FLAG_INTENTIONALLY_RESTING)
+ (combat_flags ^= COMBAT_FLAG_INTENTIONALLY_RESTING)
to_chat(src, "You are now attempting to [(combat_flags & COMBAT_FLAG_INTENTIONALLY_RESTING) ? "[!resting ? "lay down and ": ""]stay down" : "[resting ? "get up and ": ""]stay up"].")
if((combat_flags & COMBAT_FLAG_INTENTIONALLY_RESTING) && !resting)
set_resting(TRUE, FALSE)
@@ -117,14 +117,14 @@
mobility_flags &= ~(MOBILITY_USE | MOBILITY_PICKUP | MOBILITY_STORAGE | MOBILITY_HOLD)
if(HAS_TRAIT(src, TRAIT_MOBILITY_NOMOVE))
- DISABLE_BITFIELD(mobility_flags, MOBILITY_MOVE)
+ mobility_flags &= ~(MOBILITY_MOVE)
if(HAS_TRAIT(src, TRAIT_MOBILITY_NOPICKUP))
- DISABLE_BITFIELD(mobility_flags, MOBILITY_PICKUP)
+ mobility_flags &= ~(MOBILITY_PICKUP)
if(HAS_TRAIT(src, TRAIT_MOBILITY_NOUSE))
- DISABLE_BITFIELD(mobility_flags, MOBILITY_USE)
+ mobility_flags &= ~(MOBILITY_USE)
if(daze)
- DISABLE_BITFIELD(mobility_flags, MOBILITY_USE)
+ mobility_flags &= ~(MOBILITY_USE)
//Handle update-effects.
if(!CHECK_MOBILITY(src, MOBILITY_HOLD))
diff --git a/code/modules/mob/living/living_movement.dm b/code/modules/mob/living/living_movement.dm
index 075a135f76..ca7960ff69 100644
--- a/code/modules/mob/living/living_movement.dm
+++ b/code/modules/mob/living/living_movement.dm
@@ -37,7 +37,7 @@
if(mover in buckled_mobs)
return TRUE
var/mob/living/L = mover //typecast first, check isliving and only check this if living using short circuit
- if(lying && L.lying) //if we're both lying down and aren't already being thrown/shipped around, don't pass
+ if(isliving(L) && lying && L.lying) //if we're both lying down and aren't already being thrown/shipped around, don't pass
return FALSE
return (!density || (isliving(mover)? L.can_move_under_living(src) : !mover.density))
diff --git a/code/modules/mob/living/living_sprint.dm b/code/modules/mob/living/living_sprint.dm
index 3fbc229385..e45866bcf6 100644
--- a/code/modules/mob/living/living_sprint.dm
+++ b/code/modules/mob/living/living_sprint.dm
@@ -30,7 +30,7 @@
return
if(combat_flags & COMBAT_FLAG_SPRINT_ACTIVE)
return
- ENABLE_BITFIELD(combat_flags, COMBAT_FLAG_SPRINT_ACTIVE)
+ combat_flags |= COMBAT_FLAG_SPRINT_ACTIVE
add_movespeed_modifier(/datum/movespeed_modifier/sprinting)
if(update_icon)
update_sprint_icon()
@@ -38,7 +38,7 @@
/mob/living/proc/disable_sprint_mode(update_icon = TRUE)
if(!(combat_flags & COMBAT_FLAG_SPRINT_ACTIVE) || (combat_flags & COMBAT_FLAG_SPRINT_FORCED))
return
- DISABLE_BITFIELD(combat_flags, COMBAT_FLAG_SPRINT_ACTIVE)
+ combat_flags &= ~(COMBAT_FLAG_SPRINT_ACTIVE)
remove_movespeed_modifier(/datum/movespeed_modifier/sprinting)
if(update_icon)
update_sprint_icon()
@@ -46,7 +46,7 @@
/mob/living/proc/enable_intentional_sprint_mode()
if((combat_flags & COMBAT_FLAG_SPRINT_TOGGLED) && (combat_flags & COMBAT_FLAG_SPRINT_ACTIVE))
return
- ENABLE_BITFIELD(combat_flags, COMBAT_FLAG_SPRINT_TOGGLED)
+ combat_flags |= COMBAT_FLAG_SPRINT_TOGGLED
if(!HAS_TRAIT(src, TRAIT_SPRINT_LOCKED) && !(combat_flags & COMBAT_FLAG_SPRINT_ACTIVE))
enable_sprint_mode(FALSE)
update_sprint_icon()
@@ -57,7 +57,7 @@
return
if(combat_flags & COMBAT_FLAG_SPRINT_FORCED)
return
- DISABLE_BITFIELD(combat_flags, COMBAT_FLAG_SPRINT_TOGGLED)
+ combat_flags &= ~(COMBAT_FLAG_SPRINT_TOGGLED)
if(combat_flags & COMBAT_FLAG_SPRINT_ACTIVE)
disable_sprint_mode(FALSE)
update_sprint_icon()
diff --git a/code/modules/mob/living/silicon/ai/ai.dm b/code/modules/mob/living/silicon/ai/ai.dm
index 58ba34e1fb..b2b1d2fb5f 100644
--- a/code/modules/mob/living/silicon/ai/ai.dm
+++ b/code/modules/mob/living/silicon/ai/ai.dm
@@ -271,7 +271,7 @@
to_chat(usr, "Wireless control is disabled!")
return
- var/reason = tgui_input_text(src, "What is the nature of your emergency? ([CALL_SHUTTLE_REASON_LENGTH] characters required.)", "Confirm Shuttle Call")
+ var/reason = input(src, "What is the nature of your emergency? ([CALL_SHUTTLE_REASON_LENGTH] characters required.)", "Confirm Shuttle Call") as null|text
if(incapacitated())
return
@@ -573,7 +573,7 @@
for(var/i in C.network)
cameralist[i] = i
var/old_network = network
- network = tgui_input_list(U, "Which network would you like to view?", "", cameralist)
+ network = input(U, "Which network would you like to view?") as null|anything in cameralist
if(!U.eyeobj)
U.view_core()
@@ -605,7 +605,7 @@
if(incapacitated())
return
var/list/ai_emotions = list("Very Happy", "Happy", "Neutral", "Unsure", "Confused", "Sad", "BSOD", "Blank", "Problems?", "Awesome", "Facepalm", "Thinking", "Friend Computer", "Dorfy", "Blue Glow", "Red Glow")
- var/n_emote = tgui_input_list(src, "Please, select a status!", "AI Status", ai_emotions)
+ var/n_emote = input("Please, select a status!", "AI Status", null, null) in ai_emotions
if(!n_emote)
return
emote_display = n_emote
@@ -632,7 +632,7 @@
if(incapacitated())
return
var/input
- switch(tgui_alert(src, "Would you like to select a hologram based on a crew member, an animal, or switch to a unique avatar?",,list("Crew Member","Unique","Animal")))
+ switch(alert("Would you like to select a hologram based on a crew member, an animal, or switch to a unique avatar?",,"Crew Member","Unique","Animal"))
if("Crew Member")
var/list/personnel_list = list()
@@ -640,13 +640,13 @@
personnel_list["[t.fields["name"]]: [t.fields["rank"]]"] = t.fields["image"]//Pull names, rank, and image.
if(personnel_list.len)
- input = tgui_input_list(src, "Select a crew member:", "", personnel_list)
+ input = input("Select a crew member:") as null|anything in personnel_list
var/icon/character_icon = personnel_list[input]
if(character_icon)
qdel(holo_icon)//Clear old icon so we're not storing it in memory.
holo_icon = getHologramIcon(icon(character_icon))
else
- tgui_alert(src, "No suitable records found. Aborting.")
+ alert("No suitable records found. Aborting.")
if("Animal")
var/list/icon_list = list(
@@ -665,7 +665,7 @@
"spider" = 'icons/mob/animal.dmi'
)
- input = tgui_input_list(src, "Please select a hologram:", "", icon_list)
+ input = input("Please select a hologram:") as null|anything in icon_list
if(input)
qdel(holo_icon)
switch(input)
@@ -689,7 +689,7 @@
"custom"
)
- input = tgui_input_list(src, "Please select a hologram:", "", icon_list)
+ input = input("Please select a hologram:") as null|anything in icon_list
if(input)
qdel(holo_icon)
switch(input)
@@ -949,7 +949,7 @@
to_chat(src, "No usable AI shell beacons detected.")
if(!target || !(target in possible)) //If the AI is looking for a new shell, or its pre-selected shell is no longer valid
- target = tgui_input_list(src, "Which body to control?", "", possible)
+ target = input(src, "Which body to control?") as null|anything in possible
if (!target || target.stat == DEAD || target.deployed || !(!target.connected_ai ||(target.connected_ai == src)))
return
@@ -1018,7 +1018,7 @@
if(incapacitated())
return
- switch(tgui_alert(src, "Would you like to enter cryo? This will ghost you. Remember to AHELP before cryoing out of important roles, even with no admins online.",,list("Yes.","No.")))
+ switch(alert("Would you like to enter cryo? This will ghost you. Remember to AHELP before cryoing out of important roles, even with no admins online.",,"Yes.","No."))
if("Yes.")
src.ghostize(FALSE, penalize = TRUE)
var/announce_rank = "Artificial Intelligence,"
diff --git a/code/modules/mob/living/silicon/ai/ai_defense.dm b/code/modules/mob/living/silicon/ai/ai_defense.dm
index b05b5f1aaf..b8a0a15e70 100644
--- a/code/modules/mob/living/silicon/ai/ai_defense.dm
+++ b/code/modules/mob/living/silicon/ai/ai_defense.dm
@@ -28,7 +28,7 @@
if(2)
SSshuttle.requestEvac(src,"ALERT: Energy surge detected in AI core! Station integrity may be compromised! Initiati--%m091#ar-BZZT")
-/mob/living/silicon/ai/ex_act(severity, target)
+/mob/living/silicon/ai/ex_act(severity, target, origin)
switch(severity)
if(1)
gib()
diff --git a/code/modules/mob/living/silicon/ai/say.dm b/code/modules/mob/living/silicon/ai/say.dm
index 2e9a9ef62e..2b5d3d98f2 100644
--- a/code/modules/mob/living/silicon/ai/say.dm
+++ b/code/modules/mob/living/silicon/ai/say.dm
@@ -97,11 +97,11 @@
to_chat(src, "Please wait [DisplayTimeText(announcing_vox - world.time)].")
return
- var/message = tgui_input_text(src, "WARNING: Misuse of this verb can result in you being job banned. More help is available in 'Announcement Help'", "Announcement", src.last_announcement)
+ var/message = input(src, "WARNING: Misuse of this verb can result in you being job banned. More help is available in 'Announcement Help'", "Announcement", src.last_announcement) as text
last_announcement = message
- var/voxType = tgui_input_list(src, "Male or female VOX?", "VOX-gender", list("male", "female"))
+ var/voxType = input(src, "Male or female VOX?", "VOX-gender") in list("male", "female")
if(!message || announcing_vox > world.time)
return
diff --git a/code/modules/mob/living/silicon/pai/pai_defense.dm b/code/modules/mob/living/silicon/pai/pai_defense.dm
index ca5d3ce459..9e81725731 100644
--- a/code/modules/mob/living/silicon/pai/pai_defense.dm
+++ b/code/modules/mob/living/silicon/pai/pai_defense.dm
@@ -13,7 +13,7 @@
emitter_next_use = world.time + emitter_emp_cd
//Need more effects that aren't instadeath or permanent law corruption.
-/mob/living/silicon/pai/ex_act(severity, target)
+/mob/living/silicon/pai/ex_act(severity, target, origin)
take_holo_damage(severity * 50)
switch(severity)
if(1) //RIP
diff --git a/code/modules/mob/living/silicon/pai/pai_shell.dm b/code/modules/mob/living/silicon/pai/pai_shell.dm
index 2a5cb9cdc7..63fb82082f 100644
--- a/code/modules/mob/living/silicon/pai/pai_shell.dm
+++ b/code/modules/mob/living/silicon/pai/pai_shell.dm
@@ -77,19 +77,19 @@
if(CONFIG_GET(flag/pai_custom_holoforms))
choices += "Custom"
var/old_chassis = chassis
- var/choicetype = tgui_input_list(src, "What type of chassis do you want to use?", "", choices)
+ var/choicetype = input(src, "What type of chassis do you want to use?") as null|anything in choices
if(!choicetype)
return FALSE
switch(choicetype)
if("Custom")
chassis = "custom"
if("Preset - Basic")
- var/choice = tgui_input_list(src, "What would you like to use for your holochassis composite?", "", possible_chassis)
+ var/choice = input(src, "What would you like to use for your holochassis composite?") as null|anything in possible_chassis
if(!choice)
return FALSE
chassis = choice
if("Preset - Dynamic")
- var/choice = tgui_input_list(src, "What would you like to use for your holochassis composite?", "", dynamic_chassis_icons)
+ var/choice = input(src, "What would you like to use for your holochassis composite?") as null|anything in dynamic_chassis_icons
if(!choice)
return FALSE
chassis = "dynamic"
diff --git a/code/modules/mob/living/silicon/pai/personality.dm b/code/modules/mob/living/silicon/pai/personality.dm
index 41be56268d..62f2ed7047 100644
--- a/code/modules/mob/living/silicon/pai/personality.dm
+++ b/code/modules/mob/living/silicon/pai/personality.dm
@@ -51,7 +51,7 @@
if (isnull(version) || version != 1)
fdel(path)
if (!silent)
- tgui_alert(user, "Your savefile was incompatible with this version and was deleted.")
+ alert(user, "Your savefile was incompatible with this version and was deleted.")
return 0
F["name"] >> src.name
diff --git a/code/modules/mob/living/silicon/pai/software.dm b/code/modules/mob/living/silicon/pai/software.dm
index de17c9edbe..04665401c5 100644
--- a/code/modules/mob/living/silicon/pai/software.dm
+++ b/code/modules/mob/living/silicon/pai/software.dm
@@ -147,7 +147,7 @@
radio.attack_self(src)
if("image")
- var/newImage = tgui_input_list(usr, "Select your new display image.", "Display Image", list("Happy", "Cat", "Extremely Happy", "Face", "Laugh", "Off", "Sad", "Angry", "What" , "Exclamation" ,"Question", "Sunglasses"))
+ var/newImage = input("Select your new display image.", "Display Image", "Happy") in list("Happy", "Cat", "Extremely Happy", "Face", "Laugh", "Off", "Sad", "Angry", "What" , "Exclamation" ,"Question", "Sunglasses")
var/pID = 1
switch(newImage)
@@ -222,7 +222,7 @@
pda.silent = !pda.silent
else if(href_list["target"])
if(silent)
- return tgui_alert(src, "Communications circuits remain uninitialized.")
+ return alert("Communications circuits remain uninitialized.")
var/target = locate(href_list["target"])
pda.create_message(src, target)
@@ -395,7 +395,7 @@
return dat
/mob/living/silicon/pai/proc/CheckDNA(mob/living/carbon/M, mob/living/silicon/pai/P)
- var/answer = tgui_input_list(M, "[P] is requesting a DNA sample from you. Will you allow it to confirm your identity?", "[P] Check DNA", list("Yes", "No"))
+ var/answer = input(M, "[P] is requesting a DNA sample from you. Will you allow it to confirm your identity?", "[P] Check DNA", "No") in list("Yes", "No")
if(answer == "Yes")
M.visible_message("[M] presses [M.p_their()] thumb against [P].",\
"You press your thumb against [P].",\
diff --git a/code/modules/mob/living/silicon/robot/robot.dm b/code/modules/mob/living/silicon/robot/robot.dm
index d18494fd0d..bd1c260bf5 100644
--- a/code/modules/mob/living/silicon/robot/robot.dm
+++ b/code/modules/mob/living/silicon/robot/robot.dm
@@ -150,7 +150,7 @@
if(BORG_SEC_AVAILABLE)
modulelist["Security"] = /obj/item/robot_module/security
- var/input_module = tgui_input_list(src, "Please, select a module!", "Robot", sortList(modulelist))
+ var/input_module = input("Please, select a module!", "Robot", null, null) as null|anything in sortList(modulelist)
if(!input_module || module.type != /obj/item/robot_module)
return
@@ -516,7 +516,7 @@
if(stat == DEAD)
return //won't work if dead
if(locked)
- switch(tgui_alert(src, "You cannot lock your cover again, are you sure?\n (You can still ask for a human to lock it)", "Unlock Own Cover", list("Yes", "No")))
+ switch(alert("You cannot lock your cover again, are you sure?\n (You can still ask for a human to lock it)", "Unlock Own Cover", "Yes", "No"))
if("Yes")
locked = FALSE
update_icons()
@@ -1298,7 +1298,7 @@
set desc = "Select your resting pose."
sitting = 0
bellyup = 0
- var/choice = tgui_alert(src, "Select resting pose", "", list("Resting", "Sitting", "Belly up"))
+ var/choice = alert(src, "Select resting pose", "", "Resting", "Sitting", "Belly up")
switch(choice)
if("Resting")
update_icons()
diff --git a/code/modules/mob/living/silicon/robot/robot_defense.dm b/code/modules/mob/living/silicon/robot/robot_defense.dm
index 5342638c03..d5a1058a61 100644
--- a/code/modules/mob/living/silicon/robot/robot_defense.dm
+++ b/code/modules/mob/living/silicon/robot/robot_defense.dm
@@ -184,7 +184,7 @@ GLOBAL_LIST_INIT(blacklisted_borg_hats, typecacheof(list( //Hats that don't real
gib()
return TRUE
-/mob/living/silicon/robot/ex_act(severity, target)
+/mob/living/silicon/robot/ex_act(severity, target, origin)
switch(severity)
if(1)
gib()
diff --git a/code/modules/mob/living/silicon/silicon.dm b/code/modules/mob/living/silicon/silicon.dm
index a83f4e84ca..b0ec2959d7 100644
--- a/code/modules/mob/living/silicon/silicon.dm
+++ b/code/modules/mob/living/silicon/silicon.dm
@@ -78,7 +78,7 @@
GLOB.silicon_mobs -= src
return ..()
-/mob/living/silicon/contents_explosion(severity, target)
+/mob/living/silicon/contents_explosion(severity, target, origin)
return
/mob/living/silicon/proc/cancelAlarm()
@@ -338,7 +338,7 @@
return
//Ask the user to pick a channel from what it has available.
- var/Autochan = tgui_input_list(src, "Select a channel:", "", list("Default","None") + radio.channels)
+ var/Autochan = input("Select a channel:") as null|anything in list("Default","None") + radio.channels
if(!Autochan)
return
diff --git a/code/modules/mob/living/simple_animal/bot/cleanbot.dm b/code/modules/mob/living/simple_animal/bot/cleanbot.dm
index a52e975f9a..5b812086c8 100644
--- a/code/modules/mob/living/simple_animal/bot/cleanbot.dm
+++ b/code/modules/mob/living/simple_animal/bot/cleanbot.dm
@@ -182,7 +182,7 @@
deputize(W, user)
else if(istype(W, /obj/item/mop/advanced))
- if(bot_core.allowed(user) && open && !CHECK_BITFIELD(upgrades,UPGRADE_CLEANER_ADVANCED_MOP))
+ if(bot_core.allowed(user) && open && !(upgrades & UPGRADE_CLEANER_ADVANCED_MOP))
to_chat(user, "You replace \the [src] old mop with a new better one!")
upgrades |= UPGRADE_CLEANER_ADVANCED_MOP
clean_time = 20 //2.5 the speed!
@@ -198,7 +198,7 @@
to_chat(user, "The [src] already has this mop!")
else if(istype(W, /obj/item/broom))
- if(bot_core.allowed(user) && open && !CHECK_BITFIELD(upgrades,UPGRADE_CLEANER_BROOM))
+ if(bot_core.allowed(user) && open && !(upgrades & UPGRADE_CLEANER_BROOM))
to_chat(user, "You add to \the [src] a broom speeding it up!")
upgrades |= UPGRADE_CLEANER_BROOM
base_speed = 1 //2x faster!
diff --git a/code/modules/mob/living/simple_animal/bot/floorbot.dm b/code/modules/mob/living/simple_animal/bot/floorbot.dm
index d2a2f841a3..a67642f8ca 100644
--- a/code/modules/mob/living/simple_animal/bot/floorbot.dm
+++ b/code/modules/mob/living/simple_animal/bot/floorbot.dm
@@ -124,7 +124,7 @@
to_chat(user, "You need at least one floor tile to put into [src]!")
else if(istype(W, /obj/item/storage/toolbox/artistic))
- if(bot_core.allowed(user) && open && !CHECK_BITFIELD(upgrades,UPGRADE_FLOOR_ARTBOX))
+ if(bot_core.allowed(user) && open && !(upgrades & UPGRADE_FLOOR_ARTBOX))
to_chat(user, "You upgrade \the [src] case to hold more!")
upgrades |= UPGRADE_FLOOR_ARTBOX
maxtiles += 100 //Double the storage!
@@ -139,7 +139,7 @@
to_chat(user, "The [src] already has a upgraded case!")
else if(istype(W, /obj/item/storage/toolbox/syndicate))
- if(bot_core.allowed(user) && open && !CHECK_BITFIELD(upgrades,UPGRADE_FLOOR_SYNDIBOX))
+ if(bot_core.allowed(user) && open && !(upgrades & UPGRADE_FLOOR_SYNDIBOX))
to_chat(user, "You upgrade \the [src] case to hold more!")
upgrades |= UPGRADE_FLOOR_SYNDIBOX
maxtiles += 200 //Double bse storage
@@ -181,7 +181,7 @@
empty_tiles()
if("linemode")
- var/setdir = tgui_input_list(usr, "Select construction direction:", "", list("north","east","south","west","disable"))
+ var/setdir = input("Select construction direction:") as null|anything in list("north","east","south","west","disable")
switch(setdir)
if("north")
targetdirection = 1
diff --git a/code/modules/mob/living/simple_animal/bot/medbot.dm b/code/modules/mob/living/simple_animal/bot/medbot.dm
index 25f6509ad0..b343328e7f 100644
--- a/code/modules/mob/living/simple_animal/bot/medbot.dm
+++ b/code/modules/mob/living/simple_animal/bot/medbot.dm
@@ -254,7 +254,7 @@
show_controls(user)
else if(istype(W, /obj/item/reagent_containers/syringe/piercing))
- if(bot_core.allowed(user) && open && !CHECK_BITFIELD(upgrades,UPGRADE_MEDICAL_PIERERCING))
+ if(bot_core.allowed(user) && open && !(upgrades & UPGRADE_MEDICAL_PIERERCING))
to_chat(user, "You replace \the [src] syringe with a diamond-tipped one!")
upgrades |= UPGRADE_MEDICAL_PIERERCING
qdel(W)
@@ -268,7 +268,7 @@
to_chat(user, "The [src] already has a diamond-tipped syringe!")
else if(istype(W, /obj/item/hypospray/mkii))
- if(bot_core.allowed(user) && open && !CHECK_BITFIELD(upgrades,UPGRADE_MEDICAL_HYPOSPRAY))
+ if(bot_core.allowed(user) && open && !(upgrades & UPGRADE_MEDICAL_HYPOSPRAY))
to_chat(user, "You replace \the [src] syringe base with a DeForest Medical MK.II Hypospray!")
upgrades |= UPGRADE_MEDICAL_HYPOSPRAY
injection_time = 15 //Half the time half the death!
@@ -284,7 +284,7 @@
to_chat(user, "The [src] already has a DeForest Medical Hypospray base!")
else if(istype(W, /obj/item/circuitboard/machine/chem_dispenser))
- if(bot_core.allowed(user) && open && !CHECK_BITFIELD(upgrades,UPGRADE_MEDICAL_CHEM_BOARD))
+ if(bot_core.allowed(user) && open && !(upgrades & UPGRADE_MEDICAL_CHEM_BOARD))
to_chat(user, "You add in the board upgrading \the [src] reagent banks!")
upgrades |= UPGRADE_MEDICAL_CHEM_BOARD
treatment_oxy = /datum/reagent/medicine/salbutamol //Replaces Dex with salbutamol "better" healing of o2
@@ -299,7 +299,7 @@
to_chat(user, "The [src] already has this upgrade!")
else if(istype(W, /obj/item/circuitboard/machine/cryo_tube))
- if(bot_core.allowed(user) && open && !CHECK_BITFIELD(upgrades,UPGRADE_MEDICAL_CRYO_BOARD))
+ if(bot_core.allowed(user) && open && !(upgrades & UPGRADE_MEDICAL_CRYO_BOARD))
to_chat(user, "You add in the board upgrading \the [src] reagent banks!")
upgrades |= UPGRADE_MEDICAL_CRYO_BOARD
treatment_fire = /datum/reagent/medicine/oxandrolone //Replaces Kep with oxandrolone "better" healing of burns
@@ -314,7 +314,7 @@
to_chat(user, "The [src] already has this upgrade!")
else if(istype(W, /obj/item/circuitboard/machine/chem_master))
- if(bot_core.allowed(user) && open && !CHECK_BITFIELD(upgrades,UPGRADE_MEDICAL_CHEM_MASTER))
+ if(bot_core.allowed(user) && open && !(upgrades & UPGRADE_MEDICAL_CHEM_MASTER))
to_chat(user, "You add in the board upgrading \the [src] reagent banks!")
upgrades |= UPGRADE_MEDICAL_CHEM_MASTER
treatment_brute = /datum/reagent/medicine/sal_acid //Replaces Bic with Sal Acid "better" healing of brute
@@ -329,7 +329,7 @@
to_chat(user, "the [src] already has this upgrade!")
else if(istype(W, /obj/item/circuitboard/machine/sleeper))
- if(bot_core.allowed(user) && open && !CHECK_BITFIELD(upgrades,UPGRADE_MEDICAL_SLEEP_BOARD))
+ if(bot_core.allowed(user) && open && !(upgrades & UPGRADE_MEDICAL_SLEEP_BOARD))
to_chat(user, "You add in the board upgrading \the [src] reagent banks!")
upgrades |= UPGRADE_MEDICAL_SLEEP_BOARD
treatment_tox = /datum/reagent/medicine/pen_acid //replaces charcoal with pen acid a "better" healing of toxins
@@ -359,7 +359,7 @@
audible_message("[src] buzzes oddly!")
flick("medibot_spark", src)
playsound(src, "sparks", 75, 1)
- if(!CHECK_BITFIELD(upgrades,UPGRADE_MEDICAL_PIERERCING))
+ if(!(upgrades & UPGRADE_MEDICAL_PIERERCING))
upgrades |= UPGRADE_MEDICAL_PIERERCING //Jabs even harder through the clothing!
if(user)
oldpatient = user
@@ -558,7 +558,7 @@
if(ishuman(C))
var/mob/living/carbon/human/H = C
- if (H.wear_suit && H.head && istype(H.wear_suit, /obj/item/clothing) && istype(H.head, /obj/item/clothing) && !CHECK_BITFIELD(upgrades,UPGRADE_MEDICAL_PIERERCING))
+ if (H.wear_suit && H.head && istype(H.wear_suit, /obj/item/clothing) && istype(H.head, /obj/item/clothing) && !(upgrades & UPGRADE_MEDICAL_PIERERCING))
var/obj/item/clothing/CS = H.wear_suit
var/obj/item/clothing/CH = H.head
if (CS.clothing_flags & CH.clothing_flags & THICKMATERIAL)
diff --git a/code/modules/mob/living/simple_animal/bot/mulebot.dm b/code/modules/mob/living/simple_animal/bot/mulebot.dm
index 554bd247e8..077e31062a 100644
--- a/code/modules/mob/living/simple_animal/bot/mulebot.dm
+++ b/code/modules/mob/living/simple_animal/bot/mulebot.dm
@@ -138,7 +138,7 @@
add_overlay(load)
return
-/mob/living/simple_animal/bot/mulebot/ex_act(severity)
+/mob/living/simple_animal/bot/mulebot/ex_act(severity, target, origin)
unload(0)
switch(severity)
if(1)
@@ -240,7 +240,7 @@
if("destination")
var/new_dest
if(pda)
- new_dest = tgui_input_list(user, "Enter Destination:", name, GLOB.deliverybeacontags)
+ new_dest = input(user, "Enter Destination:", name, destination) as null|anything in GLOB.deliverybeacontags
else
new_dest = params["value"]
if(new_dest)
@@ -256,7 +256,7 @@
if("sethome")
var/new_home
if(pda)
- new_home = tgui_input_list(user, "Enter Home:", name, GLOB.deliverybeacontags)
+ new_home = input(user, "Enter Home:", name, home_destination) as null|anything in GLOB.deliverybeacontags
else
new_home = params["value"]
if(new_home)
diff --git a/code/modules/mob/living/simple_animal/friendly/cockroach.dm b/code/modules/mob/living/simple_animal/friendly/cockroach.dm
index f65b2bab9b..b0d66a1209 100644
--- a/code/modules/mob/living/simple_animal/friendly/cockroach.dm
+++ b/code/modules/mob/living/simple_animal/friendly/cockroach.dm
@@ -60,5 +60,5 @@
else
visible_message("[src] avoids getting crushed.")
-/mob/living/simple_animal/cockroach/ex_act() //Explosions are a terrible way to handle a cockroach.
+/mob/living/simple_animal/cockroach/ex_act(severity, target, origin) //Explosions are a terrible way to handle a cockroach.
return
diff --git a/code/modules/mob/living/simple_animal/friendly/drone/drones_as_items.dm b/code/modules/mob/living/simple_animal/friendly/drone/drones_as_items.dm
index 921c600f5a..948be53abc 100644
--- a/code/modules/mob/living/simple_animal/friendly/drone/drones_as_items.dm
+++ b/code/modules/mob/living/simple_animal/friendly/drone/drones_as_items.dm
@@ -54,7 +54,7 @@
if(!SSticker.mode)
to_chat(user, "Can't become a drone before the game has started.")
return
- var/be_drone = tgui_alert(user, "Become a drone? (Warning, You can no longer be cloned!)",,list("Yes","No"))
+ var/be_drone = alert("Become a drone? (Warning, You can no longer be cloned!)",,"Yes","No")
if(be_drone == "No" || QDELETED(src) || !isobserver(user))
return
var/mob/living/simple_animal/drone/D = new drone_type(get_turf(loc))
diff --git a/code/modules/mob/living/simple_animal/friendly/drone/extra_drone_types.dm b/code/modules/mob/living/simple_animal/friendly/drone/extra_drone_types.dm
index 12b6447a02..f3842b507a 100644
--- a/code/modules/mob/living/simple_animal/friendly/drone/extra_drone_types.dm
+++ b/code/modules/mob/living/simple_animal/friendly/drone/extra_drone_types.dm
@@ -188,6 +188,9 @@
/mob/living/simple_animal/drone/cogscarab/update_drone_hack()
return //we don't get hacked or give a shit about it
+/mob/living/simple_animal/drone/cogscarab/death(gibbed)
+ . = ..()
+
/mob/living/simple_animal/drone/cogscarab/drone_chat(msg)
titled_hierophant_message(src, msg, "nezbere", "brass", "Construct") //HIEROPHANT DRONES
diff --git a/code/modules/mob/living/simple_animal/friendly/drone/interaction.dm b/code/modules/mob/living/simple_animal/friendly/drone/interaction.dm
index 6ab2eb5e3e..d9ea6f4a8a 100644
--- a/code/modules/mob/living/simple_animal/friendly/drone/interaction.dm
+++ b/code/modules/mob/living/simple_animal/friendly/drone/interaction.dm
@@ -8,7 +8,7 @@
/mob/living/simple_animal/drone/attack_drone(mob/living/simple_animal/drone/D)
if(D != src && stat == DEAD)
- var/d_input = tgui_alert(D, "Perform which action?","Drone Interaction",list("Reactivate","Cannibalize","Nothing"))
+ var/d_input = alert(D,"Perform which action?","Drone Interaction","Reactivate","Cannibalize","Nothing")
if(d_input)
switch(d_input)
if("Reactivate")
diff --git a/code/modules/mob/living/simple_animal/friendly/drone/verbs.dm b/code/modules/mob/living/simple_animal/friendly/drone/verbs.dm
index 710341e923..0f0d4dea72 100644
--- a/code/modules/mob/living/simple_animal/friendly/drone/verbs.dm
+++ b/code/modules/mob/living/simple_animal/friendly/drone/verbs.dm
@@ -16,7 +16,7 @@
set category = "Drone"
set name = "Drone ping"
- var/alert_s = tgui_input_list(src,"Alert severity level","Drone ping",list("Low","Medium","High","Critical"))
+ var/alert_s = input(src,"Alert severity level","Drone ping",null) as null|anything in list("Low","Medium","High","Critical")
var/area/A = get_area(loc)
diff --git a/code/modules/mob/living/simple_animal/friendly/drone/visuals_icons.dm b/code/modules/mob/living/simple_animal/friendly/drone/visuals_icons.dm
index be67455177..815c2bc0db 100644
--- a/code/modules/mob/living/simple_animal/friendly/drone/visuals_icons.dm
+++ b/code/modules/mob/living/simple_animal/friendly/drone/visuals_icons.dm
@@ -95,11 +95,11 @@
/mob/living/simple_animal/drone/proc/pickVisualAppearence()
picked = FALSE
- var/appearence = tgui_input_list(usr, "Choose your appearance!", "Appearance", list("Maintenance Drone", "Repair Drone", "Scout Drone"))
+ var/appearence = input("Choose your appearance!", "Appearance", "Maintenance Drone") in list("Maintenance Drone", "Repair Drone", "Scout Drone")
switch(appearence)
if("Maintenance Drone")
visualAppearence = MAINTDRONE
- colour = tgui_input_list(usr, "Choose your colour!", "Colour", list("grey", "blue", "red", "green", "pink", "orange"))
+ colour = input("Choose your colour!", "Colour", "grey") in list("grey", "blue", "red", "green", "pink", "orange")
icon_state = "[visualAppearence]_[colour]"
icon_living = "[visualAppearence]_[colour]"
icon_dead = "[visualAppearence]_dead"
diff --git a/code/modules/mob/living/simple_animal/friendly/plushie.dm b/code/modules/mob/living/simple_animal/friendly/plushie.dm
index 5c4b8d40f1..ff95e8fe86 100644
--- a/code/modules/mob/living/simple_animal/friendly/plushie.dm
+++ b/code/modules/mob/living/simple_animal/friendly/plushie.dm
@@ -45,7 +45,7 @@
//attacking yourself transfers your mind into the plush!
/obj/item/toy/plushie_shell/attack_self(mob/user)
if(user.mind)
- var/safety = tgui_alert(user, "The plushie is staring back at you intensely, it seems cursed! (Permanently become a plushie)", "Hugging this is a bad idea.", list("Hug it!", "Cancel"))
+ var/safety = alert(user, "The plushie is staring back at you intensely, it seems cursed! (Permanently become a plushie)", "Hugging this is a bad idea.", "Hug it!", "Cancel")
if(safety == "Cancel" || !in_range(src, user))
return
to_chat(user, "You hug the strange plushie. You fool.")
diff --git a/code/modules/mob/living/simple_animal/guardian/guardian.dm b/code/modules/mob/living/simple_animal/guardian/guardian.dm
index 547d808673..6faf8f0db5 100644
--- a/code/modules/mob/living/simple_animal/guardian/guardian.dm
+++ b/code/modules/mob/living/simple_animal/guardian/guardian.dm
@@ -273,10 +273,13 @@ GLOBAL_LIST_EMPTY(parasites) //all currently existing/living guardians
summoner.adjustCloneLoss(amount * 0.5) //dying hosts take 50% bonus damage as cloneloss
update_health_hud()
-/mob/living/simple_animal/hostile/guardian/ex_act(severity, target)
+/mob/living/simple_animal/hostile/guardian/ex_act(severity, target, origin)
switch(severity)
if(1)
- gib()
+ if(istype(origin, /datum/explosion))
+ gib(was_explosion = origin)
+ else
+ gib()
return
if(2)
adjustBruteLoss(60)
@@ -286,10 +289,10 @@ GLOBAL_LIST_EMPTY(parasites) //all currently existing/living guardians
/mob/living/simple_animal/hostile/guardian/wave_ex_act(power, datum/wave_explosion/explosion, dir)
adjustBruteLoss(EXPLOSION_POWER_STANDARD_SCALE_MOB_DAMAGE(power, explosion.mob_damage_mod * 0.33))
-/mob/living/simple_animal/hostile/guardian/gib()
+/mob/living/simple_animal/hostile/guardian/gib(no_brain, no_organs, no_bodyparts, datum/explosion/was_explosion)
if(summoner)
to_chat(summoner, "Your [src] was blown up!")
- summoner.gib()
+ summoner.gib(was_explosion = was_explosion)
ghostize()
qdel(src)
@@ -461,7 +464,7 @@ GLOBAL_LIST_EMPTY(parasites) //all currently existing/living guardians
if(P.reset)
guardians -= P //clear out guardians that are already reset
if(guardians.len)
- var/mob/living/simple_animal/hostile/guardian/G = tgui_input_list(src, "Pick the guardian you wish to reset", "Guardian Reset", guardians)
+ var/mob/living/simple_animal/hostile/guardian/G = input(src, "Pick the guardian you wish to reset", "Guardian Reset") as null|anything in guardians
if(G)
to_chat(src, "You attempt to reset [G.real_name]'s personality...")
var/list/mob/candidates = pollGhostCandidates("Do you want to play as [src.real_name]'s [G.real_name]?", ROLE_PAI, null, FALSE, 100)
@@ -555,7 +558,7 @@ GLOBAL_LIST_EMPTY(parasites) //all currently existing/living guardians
if(random)
guardiantype = pick(possible_guardians)
else
- guardiantype = tgui_input_list(user, "Pick the type of [mob_name]", "[mob_name] Creation", possible_guardians)
+ guardiantype = input(user, "Pick the type of [mob_name]", "[mob_name] Creation") as null|anything in possible_guardians
if(!guardiantype)
to_chat(user, "[failure_message]" )
used = FALSE
diff --git a/code/modules/mob/living/simple_animal/guardian/types/protector.dm b/code/modules/mob/living/simple_animal/guardian/types/protector.dm
index b3d9f01ebb..00d56edd55 100644
--- a/code/modules/mob/living/simple_animal/guardian/types/protector.dm
+++ b/code/modules/mob/living/simple_animal/guardian/types/protector.dm
@@ -11,7 +11,7 @@
toggle_button_type = /atom/movable/screen/guardian/ToggleMode
var/toggle = FALSE
-/mob/living/simple_animal/hostile/guardian/protector/ex_act(severity)
+/mob/living/simple_animal/hostile/guardian/protector/ex_act(severity, target, origin)
if(severity == 1)
adjustBruteLoss(400) //if in protector mode, will do 20 damage and not actually necessarily kill the summoner
else
diff --git a/code/modules/mob/living/simple_animal/guardian/types/ranged.dm b/code/modules/mob/living/simple_animal/guardian/types/ranged.dm
index 6a082fbc88..5df446085a 100644
--- a/code/modules/mob/living/simple_animal/guardian/types/ranged.dm
+++ b/code/modules/mob/living/simple_animal/guardian/types/ranged.dm
@@ -96,7 +96,7 @@
set name = "Remove Surveillance Snare"
set category = "Guardian"
set desc = "Disarm unwanted surveillance snares."
- var/picked_snare = tgui_input_list(src, "Pick which snare to remove", "Remove Snare", src.snares)
+ var/picked_snare = input(src, "Pick which snare to remove", "Remove Snare") as null|anything in src.snares
if(picked_snare)
src.snares -= picked_snare
qdel(picked_snare)
diff --git a/code/modules/mob/living/simple_animal/hostile/banana_spider.dm b/code/modules/mob/living/simple_animal/hostile/banana_spider.dm
index 9c1c0dae89..802f55a934 100644
--- a/code/modules/mob/living/simple_animal/hostile/banana_spider.dm
+++ b/code/modules/mob/living/simple_animal/hostile/banana_spider.dm
@@ -51,7 +51,7 @@
if(!SSticker.mode)
to_chat(user, "Can't become a banana spider before the game has started.")
return
- var/be_spider = tgui_alert(user, "Become a banana spider? (Warning, You can no longer be cloned!)",,list("Yes","No"))
+ var/be_spider = alert("Become a banana spider? (Warning, You can no longer be cloned!)",,"Yes","No")
if(be_spider == "No" || QDELETED(src) || !isobserver(user))
return
if(key)
@@ -87,7 +87,7 @@
else
visible_message("[src] avoids getting crushed.")
-/mob/living/simple_animal/banana_spider/ex_act()
+/mob/living/simple_animal/banana_spider/ex_act(severity, target, origin)
return
/mob/living/simple_animal/banana_spider/start_pulling()
diff --git a/code/modules/mob/living/simple_animal/hostile/bread.dm b/code/modules/mob/living/simple_animal/hostile/bread.dm
index 3eadc7104c..1fe1a13e75 100644
--- a/code/modules/mob/living/simple_animal/hostile/bread.dm
+++ b/code/modules/mob/living/simple_animal/hostile/bread.dm
@@ -52,7 +52,7 @@
if(!SSticker.mode)
to_chat(user, "Can't become a tumor bread before the game has started.")
return
- var/be_bread = tgui_alert(user, "Become a tumor bread? (Warning, You can no longer be cloned!)",,list("Yes","No"))
+ var/be_bread = alert("Become a tumor bread? (Warning, You can no longer be cloned!)",,"Yes","No")
if(be_bread == "No" || QDELETED(src) || !isobserver(user))
return
if(key)
@@ -62,7 +62,7 @@
user.transfer_ckey(src, FALSE)
density = TRUE
-/mob/living/simple_animal/hostile/bread/ex_act()
+/mob/living/simple_animal/hostile/bread/ex_act(severity, target, origin)
return
/mob/living/simple_animal/hostile/bread/start_pulling()
diff --git a/code/modules/mob/living/simple_animal/hostile/giant_spider.dm b/code/modules/mob/living/simple_animal/hostile/giant_spider.dm
index 9c165f3ef4..2349685a4e 100644
--- a/code/modules/mob/living/simple_animal/hostile/giant_spider.dm
+++ b/code/modules/mob/living/simple_animal/hostile/giant_spider.dm
@@ -93,7 +93,7 @@
var/mob/dead/observer/O = user
if(!O.can_reenter_round())
return FALSE
- var/spider_ask = tgui_alert(user, "Become a spider?", "Are you australian?", list("Yes", "No"))
+ var/spider_ask = alert("Become a spider?", "Are you australian?", "Yes", "No")
if(spider_ask == "No" || !src || QDELETED(src))
return TRUE
if(key)
diff --git a/code/modules/mob/living/simple_animal/hostile/hostile.dm b/code/modules/mob/living/simple_animal/hostile/hostile.dm
index 01a30bb90a..029adbe92f 100644
--- a/code/modules/mob/living/simple_animal/hostile/hostile.dm
+++ b/code/modules/mob/living/simple_animal/hostile/hostile.dm
@@ -367,7 +367,7 @@
if(vore_active)
if(isliving(target))
var/mob/living/L = target
- if(!client && L.Adjacent(src) && CHECK_BITFIELD(L.vore_flags, DEVOURABLE) && CHECK_BITFIELD(L.vore_flags, MOBVORE)) // aggressive check to ensure vore attacks can be made
+ if(!client && L.Adjacent(src) && (L.vore_flags & DEVOURABLE) && (L.vore_flags & MOBVORE)) // aggressive check to ensure vore attacks can be made
if(prob(voracious_chance))
vore_attack(src,L,src)
else
diff --git a/code/modules/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner.dm b/code/modules/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner.dm
index 08ed786252..c28fa99054 100644
--- a/code/modules/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner.dm
+++ b/code/modules/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner.dm
@@ -59,6 +59,7 @@ Difficulty: Medium
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/Initialize()
. = ..()
+ internal = new/obj/item/gps/internal/miner(src)
miner_saw = new(src)
/datum/action/innate/megafauna_attack/dash
@@ -131,7 +132,7 @@ Difficulty: Medium
return FALSE
return ..()
-/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/ex_act(severity, target)
+/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/ex_act(severity, target, origin)
if(dash())
return
return ..()
diff --git a/code/modules/mob/living/simple_animal/hostile/megafauna/bubblegum.dm b/code/modules/mob/living/simple_animal/hostile/megafauna/bubblegum.dm
index b80e6cc72f..9bcc21efa6 100644
--- a/code/modules/mob/living/simple_animal/hostile/megafauna/bubblegum.dm
+++ b/code/modules/mob/living/simple_animal/hostile/megafauna/bubblegum.dm
@@ -154,7 +154,7 @@ Difficulty: Hard
return 0
return ..()
-/mob/living/simple_animal/hostile/megafauna/bubblegum/ex_act(severity, target)
+/mob/living/simple_animal/hostile/megafauna/bubblegum/ex_act(severity, target, origin)
if(severity >= EXPLODE_LIGHT)
return
severity = EXPLODE_LIGHT // puny mortals
diff --git a/code/modules/mob/living/simple_animal/hostile/megafauna/colossus.dm b/code/modules/mob/living/simple_animal/hostile/megafauna/colossus.dm
index 46d3463684..0135984be9 100644
--- a/code/modules/mob/living/simple_animal/hostile/megafauna/colossus.dm
+++ b/code/modules/mob/living/simple_animal/hostile/megafauna/colossus.dm
@@ -421,12 +421,12 @@ Difficulty: Very Hard
if(ismob(AM))
ActivationReaction(AM, ACTIVATE_MOB_BUMP)
-/obj/machinery/anomalous_crystal/ex_act()
+/obj/machinery/anomalous_crystal/ex_act(severity, target, origin)
ActivationReaction(null, ACTIVATE_BOMB)
/obj/machinery/anomalous_crystal/honk //Strips and equips you as a clown. I apologize for nothing
observer_desc = "This crystal strips and equips its targets as clowns."
- possible_methods = list(ACTIVATE_TOUCH) //Because We love AOE transformations!
+ possible_methods = list(ACTIVATE_TOUCH) //Because We love AOE transformations!
activation_sound = 'sound/items/bikehorn.ogg'
/obj/machinery/anomalous_crystal/honk/ActivationReaction(mob/user)
@@ -574,7 +574,7 @@ Difficulty: Very Hard
if(ready_to_deploy)
if(!user.can_reenter_round())
return FALSE
- var/be_helper = tgui_alert(user, "Become a Lightgeist? (Warning, You can no longer be cloned!)",,list("Yes","No"))
+ var/be_helper = alert("Become a Lightgeist? (Warning, You can no longer be cloned!)",,"Yes","No")
if(be_helper == "Yes" && !QDELETED(src) && isobserver(user))
var/mob/living/simple_animal/hostile/lightgeist/W = new /mob/living/simple_animal/hostile/lightgeist(get_turf(loc))
user.transfer_ckey(W, FALSE)
@@ -740,7 +740,7 @@ Difficulty: Very Hard
/obj/structure/closet/stasis/emp_act()
return
-/obj/structure/closet/stasis/ex_act()
+/obj/structure/closet/stasis/ex_act(severity, target, origin)
return
/obj/structure/closet/stasis/handle_lock_addition()
diff --git a/code/modules/mob/living/simple_animal/hostile/megafauna/demonic_frost_miner.dm b/code/modules/mob/living/simple_animal/hostile/megafauna/demonic_frost_miner.dm
index 1aa0957fee..a5fc918181 100644
--- a/code/modules/mob/living/simple_animal/hostile/megafauna/demonic_frost_miner.dm
+++ b/code/modules/mob/living/simple_animal/hostile/megafauna/demonic_frost_miner.dm
@@ -147,7 +147,7 @@ Difficulty: Extremely Hard
if(isturf(target) || isobj(target))
target.ex_act(EXPLODE_HEAVY)
-/mob/living/simple_animal/hostile/megafauna/demonic_frost_miner/ex_act(severity, target)
+/mob/living/simple_animal/hostile/megafauna/demonic_frost_miner/ex_act(severity, target, origin)
adjustBruteLoss(30 * severity - 120)
visible_message("[src] absorbs the explosion!", "You absorb the explosion!")
diff --git a/code/modules/mob/living/simple_animal/hostile/megafauna/drake.dm b/code/modules/mob/living/simple_animal/hostile/megafauna/drake.dm
index a3d51744b9..dc13d870c5 100644
--- a/code/modules/mob/living/simple_animal/hostile/megafauna/drake.dm
+++ b/code/modules/mob/living/simple_animal/hostile/megafauna/drake.dm
@@ -79,7 +79,7 @@ Difficulty: Medium
. = ..()
internal = new/obj/item/gps/internal/dragon(src)
-/mob/living/simple_animal/hostile/megafauna/dragon/ex_act(severity, target)
+/mob/living/simple_animal/hostile/megafauna/dragon/ex_act(severity, target, origin)
if(severity == 3)
return
..()
@@ -387,7 +387,7 @@ Difficulty: Medium
light_range = 2
duration = 13
-/obj/effect/temp_visual/lava_warning/ex_act()
+/obj/effect/temp_visual/lava_warning/ex_act(severity, target, origin)
return
/obj/effect/temp_visual/lava_warning/Initialize(mapload, var/reset_time = 10)
diff --git a/code/modules/mob/living/simple_animal/hostile/megafauna/hierophant.dm b/code/modules/mob/living/simple_animal/hostile/megafauna/hierophant.dm
index e4c087b1e1..c1aea8db9d 100644
--- a/code/modules/mob/living/simple_animal/hostile/megafauna/hierophant.dm
+++ b/code/modules/mob/living/simple_animal/hostile/megafauna/hierophant.dm
@@ -674,7 +674,7 @@ Difficulty: Normal
layer = LOW_OBJ_LAYER
anchored = TRUE
-/obj/effect/hierophant/ex_act()
+/obj/effect/hierophant/ex_act(severity, target, origin)
return
/obj/effect/hierophant/attackby(obj/item/I, mob/user, params)
diff --git a/code/modules/mob/living/simple_animal/hostile/megafauna/megafauna.dm b/code/modules/mob/living/simple_animal/hostile/megafauna/megafauna.dm
index 3940388625..d4fed7685f 100644
--- a/code/modules/mob/living/simple_animal/hostile/megafauna/megafauna.dm
+++ b/code/modules/mob/living/simple_animal/hostile/megafauna/megafauna.dm
@@ -122,7 +122,7 @@
if(!client && ranged && ranged_cooldown <= world.time)
OpenFire()
if(L.Adjacent(src) && (L.stat != CONSCIOUS))
- if(vore_active && CHECK_BITFIELD(L.vore_flags,DEVOURABLE))
+ if(vore_active && (L.vore_flags & DEVOURABLE))
vore_attack(src,L,src)
LoseTarget()
else
@@ -138,7 +138,7 @@
adjustBruteLoss(-L.maxHealth/2)
L.gib()
-/mob/living/simple_animal/hostile/megafauna/ex_act(severity, target)
+/mob/living/simple_animal/hostile/megafauna/ex_act(severity, target, origin)
switch (severity)
if (EXPLODE_DEVASTATE)
adjustBruteLoss(250)
diff --git a/code/modules/mob/living/simple_animal/hostile/mining_mobs/basilisk.dm b/code/modules/mob/living/simple_animal/hostile/mining_mobs/basilisk.dm
index 24e595ef7e..c5be239b3b 100644
--- a/code/modules/mob/living/simple_animal/hostile/mining_mobs/basilisk.dm
+++ b/code/modules/mob/living/simple_animal/hostile/mining_mobs/basilisk.dm
@@ -50,7 +50,7 @@
if(isliving(target) && !target.Adjacent(targets_from) && ranged_cooldown <= world.time)//No more being shot at point blank or spammed with RNG beams
OpenFire(target)
-/mob/living/simple_animal/hostile/asteroid/basilisk/ex_act(severity, target)
+/mob/living/simple_animal/hostile/asteroid/basilisk/ex_act(severity, target, origin)
switch(severity)
if(1)
gib()
diff --git a/code/modules/mob/living/simple_animal/hostile/mining_mobs/elites/elite.dm b/code/modules/mob/living/simple_animal/hostile/mining_mobs/elites/elite.dm
index 82df5af169..de6b858f79 100644
--- a/code/modules/mob/living/simple_animal/hostile/mining_mobs/elites/elite.dm
+++ b/code/modules/mob/living/simple_animal/hostile/mining_mobs/elites/elite.dm
@@ -44,7 +44,7 @@
if(istype(target, /obj/structure/elite_tumor))
var/obj/structure/elite_tumor/T = target
if(T.mychild == src && T.activity == TUMOR_PASSIVE)
- var/elite_remove = tgui_alert(usr, "Re-enter the tumor?", "Despawn yourself?", list("Yes", "No"))
+ var/elite_remove = alert("Re-enter the tumor?", "Despawn yourself?", "Yes", "No")
if(elite_remove == "No" || !src || QDELETED(src))
return
T.mychild = null
diff --git a/code/modules/mob/living/simple_animal/hostile/regalrat.dm b/code/modules/mob/living/simple_animal/hostile/regalrat.dm
index 950da865f6..6995202e9c 100644
--- a/code/modules/mob/living/simple_animal/hostile/regalrat.dm
+++ b/code/modules/mob/living/simple_animal/hostile/regalrat.dm
@@ -90,7 +90,7 @@
/datum/action/cooldown/coffer/Trigger()
. = ..()
- if(!.)
+ if(!. || owner.stat != CONSCIOUS)
return
var/turf/T = get_turf(owner)
var/loot = rand(1,100)
@@ -135,7 +135,7 @@
/datum/action/cooldown/riot/Trigger()
. = ..()
- if(!.)
+ if(!. || owner.stat != CONSCIOUS)
return
var/cap = CONFIG_GET(number/ratcap)
var/something_from_nothing = FALSE
diff --git a/code/modules/mob/living/simple_animal/hostile/space_dragon.dm b/code/modules/mob/living/simple_animal/hostile/space_dragon.dm
index 74f5f0c2bf..800c7d29ca 100644
--- a/code/modules/mob/living/simple_animal/hostile/space_dragon.dm
+++ b/code/modules/mob/living/simple_animal/hostile/space_dragon.dm
@@ -99,7 +99,7 @@
if(!chosen_color)
dragon_name()
color_selection()
-
+
/mob/living/simple_animal/hostile/space_dragon/Life()
. = ..()
@@ -666,7 +666,7 @@
/obj/structure/carp_rift/proc/summon_carp(mob/user)
if(carp_stored <= 0)//Not enough carp points
return FALSE
- var/carp_ask = tgui_alert(user, "Become a carp?", "Help bring forth the horde?", list("Yes", "No"))
+ var/carp_ask = alert("Become a carp?", "Help bring forth the horde?", "Yes", "No")
if(carp_ask == "No" || !src || QDELETED(src) || QDELETED(user))
return FALSE
if(carp_stored <= 0)
diff --git a/code/modules/mob/living/simple_animal/hostile/venus_human_trap.dm b/code/modules/mob/living/simple_animal/hostile/venus_human_trap.dm
index cf86fcfe7a..cc5b0b8a75 100644
--- a/code/modules/mob/living/simple_animal/hostile/venus_human_trap.dm
+++ b/code/modules/mob/living/simple_animal/hostile/venus_human_trap.dm
@@ -157,7 +157,7 @@
/mob/living/simple_animal/hostile/venus_human_trap/proc/humanize_plant(mob/user)
if(key || !playable_plant || stat)
return
- var/plant_ask = tgui_alert(user, "Become a venus human trap?", "Are you reverse vegan?", list("Yes", "No"))
+ var/plant_ask = alert("Become a venus human trap?", "Are you reverse vegan?", "Yes", "No")
if(plant_ask == "No" || QDELETED(src))
return
if(key)
diff --git a/code/modules/mob/living/simple_animal/simple_animal.dm b/code/modules/mob/living/simple_animal/simple_animal.dm
index dc892364c4..dd7c946d3c 100644
--- a/code/modules/mob/living/simple_animal/simple_animal.dm
+++ b/code/modules/mob/living/simple_animal/simple_animal.dm
@@ -307,7 +307,7 @@
if((bodytemperature < minbodytemp) || (bodytemperature > maxbodytemp))
adjustHealth(unsuitable_atmos_damage)
-/mob/living/simple_animal/gib()
+/mob/living/simple_animal/gib(no_brain, no_organs, no_bodyparts, datum/explosion/was_explosion)
if(butcher_results)
var/atom/Tsec = drop_location()
for(var/path in butcher_results)
diff --git a/code/modules/mob/living/simple_animal/simple_animal_vr.dm b/code/modules/mob/living/simple_animal/simple_animal_vr.dm
index 355c940d76..69dee76f34 100644
--- a/code/modules/mob/living/simple_animal/simple_animal_vr.dm
+++ b/code/modules/mob/living/simple_animal/simple_animal_vr.dm
@@ -49,10 +49,10 @@
// Simple animals have only one belly. This creates it (if it isn't already set up)
/mob/living/simple_animal/init_vore()
- ENABLE_BITFIELD(vore_flags, VORE_INIT)
- if(CHECK_BITFIELD(flags_1, HOLOGRAM_1))
+ vore_flags |= VORE_INIT
+ if((flags_1 & HOLOGRAM_1))
return
- if(!vore_active || CHECK_BITFIELD(vore_flags, NO_VORE)) //If it can't vore, let's not give it a stomach.
+ if(!vore_active || (vore_flags & NO_VORE)) //If it can't vore, let's not give it a stomach.
return
if(vore_active && !IsAdvancedToolUser()) //vore active, but doesn't have thumbs to grab people with.
verbs |= /mob/living/simple_animal/proc/animal_nom
@@ -113,13 +113,13 @@
return
if(vore_selected.digest_mode == DM_HOLD)
- var/confirm = tgui_alert(usr, "Enabling digestion on [name] will cause it to digest all stomach contents. Using this to break OOC prefs is against the rules. Digestion will disable itself after 20 minutes.", "Enabling [name]'s Digestion", list("Enable", "Cancel"))
+ var/confirm = alert(usr, "Enabling digestion on [name] will cause it to digest all stomach contents. Using this to break OOC prefs is against the rules. Digestion will disable itself after 20 minutes.", "Enabling [name]'s Digestion", "Enable", "Cancel")
if(confirm == "Enable")
vore_selected.digest_mode = DM_DIGEST
sleep(20 MINUTES)
vore_selected.digest_mode = vore_default_mode
else
- var/confirm = tgui_alert(usr, "This mob is currently set to digest all stomach contents. Do you want to disable this?", "Disabling [name]'s Digestion", list("Disable", "Cancel"))
+ var/confirm = alert(usr, "This mob is currently set to digest all stomach contents. Do you want to disable this?", "Disabling [name]'s Digestion", "Disable", "Cancel")
if(confirm == "Disable")
vore_selected.digest_mode = DM_HOLD
@@ -133,6 +133,6 @@
if (stat != CONSCIOUS)
return
- if(!CHECK_BITFIELD(T.vore_flags,DEVOURABLE))
+ if(!(T.vore_flags & DEVOURABLE))
return
return vore_attack(src,T,src)
diff --git a/code/modules/mob/living/simple_animal/slime/powers.dm b/code/modules/mob/living/simple_animal/slime/powers.dm
index 6327ef77df..d93993bf1f 100644
--- a/code/modules/mob/living/simple_animal/slime/powers.dm
+++ b/code/modules/mob/living/simple_animal/slime/powers.dm
@@ -32,7 +32,7 @@
if(C!=src && Adjacent(C))
choices += C
- var/mob/living/M = tgui_input_list(src,"Who do you wish to feed on?", "", choices)
+ var/mob/living/M = input(src,"Who do you wish to feed on?") in null|choices
if(!M)
return 0
if(CanFeedon(M))
diff --git a/code/modules/mob/living/simple_animal/slime/slime.dm b/code/modules/mob/living/simple_animal/slime/slime.dm
index 68de074e07..38149494bc 100644
--- a/code/modules/mob/living/simple_animal/slime/slime.dm
+++ b/code/modules/mob/living/simple_animal/slime/slime.dm
@@ -466,7 +466,7 @@
SStun = world.time + rand(20,60)
spawn(0)
- DISABLE_BITFIELD(mobility_flags, MOBILITY_MOVE)
+ mobility_flags &= ~(MOBILITY_MOVE)
if(user)
step_away(src,user,15)
sleep(3)
diff --git a/code/modules/mob/living/simple_animal/slime/slime_mobility.dm b/code/modules/mob/living/simple_animal/slime/slime_mobility.dm
index 5be5ff4e36..77f2bde864 100644
--- a/code/modules/mob/living/simple_animal/slime/slime_mobility.dm
+++ b/code/modules/mob/living/simple_animal/slime/slime_mobility.dm
@@ -1,5 +1,5 @@
/mob/living/simple_animal/slime/update_mobility()
. = ..()
if(Tempstun && !buckled)
- DISABLE_BITFIELD(., MOBILITY_MOVE)
+ . &= ~(MOBILITY_MOVE)
mobility_flags = .
diff --git a/code/modules/mob/mob_transformation_simple.dm b/code/modules/mob/mob_transformation_simple.dm
index 7c4325fdcd..2c2efee534 100644
--- a/code/modules/mob/mob_transformation_simple.dm
+++ b/code/modules/mob/mob_transformation_simple.dm
@@ -9,7 +9,7 @@
return
if(!new_type)
- new_type = tgui_input_text(usr, "Mob type path:", "Mob type")
+ new_type = input("Mob type path:", "Mob type") as text|null
if(istext(new_type))
new_type = text2path(new_type)
diff --git a/code/modules/mob/say.dm b/code/modules/mob/say.dm
index d41f59d104..d8ef440ef9 100644
--- a/code/modules/mob/say.dm
+++ b/code/modules/mob/say.dm
@@ -5,13 +5,8 @@
set hidden = TRUE
set category = "IC"
client?.last_activity = world.time
- for(var/datum/tgui/window in tgui_open_uis)
- if(istype(window.src_object, /datum/tgui_input_dialog))
- var/datum/tgui_input_dialog/say_box = window.src_object
- if(say_box.title == "say") // Yes, i am dead serious.
- return
display_typing_indicator()
- var/message = tgui_input_text(usr, null, "say")
+ var/message = input(usr, "", "say") as text|null
// If they don't type anything just drop the message.
clear_typing_indicator() // clear it immediately!
if(!length(message))
@@ -37,13 +32,8 @@
set hidden = TRUE
set category = "IC"
client?.last_activity = world.time
- for(var/datum/tgui/window in tgui_open_uis)
- if(istype(window.src_object, /datum/tgui_input_dialog))
- var/datum/tgui_input_dialog/emote_box = window.src_object
- if(emote_box.title == "me") // Yes, i am dead serious.
- return
display_typing_indicator()
- var/message = tgui_input_message(usr, null, "me")
+ var/message = input(usr, "", "me") as message|null
// If they don't type anything just drop the message.
clear_typing_indicator() // clear it immediately!
if(!length(message))
@@ -91,7 +81,7 @@
/mob/proc/whisper_keybind()
client?.last_activity = world.time
- var/message = tgui_input_text(src, "", "whisper")
+ var/message = input(src, "", "whisper") as text|null
if(!length(message))
return
return whisper_verb(message)
diff --git a/code/modules/mob/transform_procs.dm b/code/modules/mob/transform_procs.dm
index 15e28ceaf1..fcaa77cac4 100644
--- a/code/modules/mob/transform_procs.dm
+++ b/code/modules/mob/transform_procs.dm
@@ -538,11 +538,11 @@
/mob/living/carbon/human/Animalize(mind_transfer = TRUE)
var/list/mobtypes = typesof(/mob/living/simple_animal)
- var/mobpath = tgui_input_list(usr, "Which type of mob should [src] turn into?", "Choose a type", mobtypes)
+ var/mobpath = input("Which type of mob should [src] turn into?", "Choose a type") as null|anything in mobtypes
if(!mobpath)
return
if(mind)
- mind_transfer = tgui_alert(usr, "Want to transfer their mind into the new mob", "Mind Transfer", list("Yes", "No")) == "Yes" ? TRUE : FALSE
+ mind_transfer = alert("Want to transfer their mind into the new mob", "Mind Transfer", "Yes", "No") == "Yes" ? TRUE : FALSE
if(mob_transforming)
return
@@ -573,11 +573,11 @@
/mob/proc/Animalize(mind_transfer = TRUE)
var/list/mobtypes = typesof(/mob/living/simple_animal)
- var/mobpath = tgui_input_list(usr, "Which type of mob should [src] turn into?", "Choose a type", mobtypes)
+ var/mobpath = input("Which type of mob should [src] turn into?", "Choose a type") as null|anything in mobtypes
if(!mobpath)
return
if(mind)
- mind_transfer = tgui_alert(usr, "Want to transfer their mind into the new mob", "Mind Transfer", list("Yes", "No")) == "Yes" ? TRUE : FALSE
+ mind_transfer = alert("Want to transfer their mind into the new mob", "Mind Transfer", "Yes", "No") == "Yes" ? TRUE : FALSE
var/mob/new_mob = new mobpath(src.loc)
diff --git a/code/modules/modular_computers/computers/item/computer.dm b/code/modules/modular_computers/computers/item/computer.dm
index 3cfd342122..635ec2e54c 100644
--- a/code/modules/modular_computers/computers/item/computer.dm
+++ b/code/modules/modular_computers/computers/item/computer.dm
@@ -137,7 +137,7 @@
if(enabled)
ui_interact(user)
else if(IsAdminGhost(user))
- var/response = tgui_alert(user, "This computer is turned off. Would you like to turn it on?", "Admin Override", list("Yes", "No"))
+ var/response = alert(user, "This computer is turned off. Would you like to turn it on?", "Admin Override", "Yes", "No")
if(response == "Yes")
turn_on(user)
@@ -425,7 +425,7 @@
var/obj/item/computer_hardware/H = all_components[h]
component_names.Add(H.name)
- var/choice = tgui_input_list(user, "Which component do you want to uninstall?", "Computer maintenance", sortList(component_names))
+ var/choice = input(user, "Which component do you want to uninstall?", "Computer maintenance", null) as null|anything in sortList(component_names)
if(!choice)
return
diff --git a/code/modules/modular_computers/computers/machinery/modular_computer.dm b/code/modules/modular_computers/computers/machinery/modular_computer.dm
index 090bf1c7fc..da60657f7e 100644
--- a/code/modules/modular_computers/computers/machinery/modular_computer.dm
+++ b/code/modules/modular_computers/computers/machinery/modular_computer.dm
@@ -124,9 +124,9 @@
// Stronger explosions cause serious damage to internal components
// Minor explosions are mostly mitigitated by casing.
-/obj/machinery/modular_computer/ex_act(severity)
+/obj/machinery/modular_computer/ex_act(severity, target, origin)
if(cpu)
- cpu.ex_act(severity)
+ cpu.ex_act(severity, target, origin)
// switch(severity)
// if(EXPLODE_DEVASTATE)
// SSexplosions.high_mov_atom += cpu
diff --git a/code/modules/modular_computers/file_system/programs/cargoship.dm b/code/modules/modular_computers/file_system/programs/cargoship.dm
index a023f92831..89a3b3247d 100644
--- a/code/modules/modular_computers/file_system/programs/cargoship.dm
+++ b/code/modules/modular_computers/file_system/programs/cargoship.dm
@@ -54,7 +54,7 @@
if("resetid")
payments_acc = null
if("setsplit")
- var/potential_cut = tgui_input_num(usr, "How much would you like to payout to the registered card?","Percentage Profit")
+ var/potential_cut = input("How much would you like to payout to the registered card?","Percentage Profit") as num|null
percent_cut = potential_cut ? clamp(round(potential_cut, 1), 1, 50) : 20
if("print")
if(!printer)
diff --git a/code/modules/newscaster/newscaster_machine.dm b/code/modules/newscaster/newscaster_machine.dm
index 819d7411ae..c81a8f5d1a 100644
--- a/code/modules/newscaster/newscaster_machine.dm
+++ b/code/modules/newscaster/newscaster_machine.dm
@@ -369,7 +369,7 @@ GLOBAL_LIST_EMPTY(allCasters)
if(channel_name == "" || channel_name == "\[REDACTED\]" || scanned_user == "Unknown" || check || (scanned_user in existing_authors) )
screen=7
else
- var/choice = tgui_alert(usr, "Please confirm Feed channel creation","Network Channel Handler",list("Confirm","Cancel"))
+ var/choice = alert("Please confirm Feed channel creation","Network Channel Handler","Confirm","Cancel")
if(choice=="Confirm")
scan_user(usr)
GLOB.news_network.CreateFeedChannel(channel_name, scanned_user, c_locked)
@@ -381,7 +381,7 @@ GLOBAL_LIST_EMPTY(allCasters)
for(var/datum/news/feed_channel/F in GLOB.news_network.network_channels)
if( (!F.locked || F.author == scanned_user) && !F.censored)
available_channels += F.channel_name
- channel_name = tgui_input_list(usr, "Choose receiving Feed Channel", "Network Channel Handler", available_channels)
+ channel_name = input(usr, "Choose receiving Feed Channel", "Network Channel Handler") in available_channels
updateUsrDialog()
else if(href_list["set_new_message"])
var/temp_message = trim(stripped_multiline_input(usr, "Write your Feed story", "Network Channel Handler", msg))
@@ -442,7 +442,7 @@ GLOBAL_LIST_EMPTY(allCasters)
if(msg == "" || channel_name == "" || scanned_user == "Unknown")
screen = 16
else
- var/choice = tgui_alert(usr, "Please confirm Wanted Issue [(input_param==1) ? ("creation.") : ("edit.")]","Network Security Handler",list("Confirm","Cancel"))
+ var/choice = alert("Please confirm Wanted Issue [(input_param==1) ? ("creation.") : ("edit.")]","Network Security Handler","Confirm","Cancel")
if(choice=="Confirm")
scan_user(usr)
if(input_param==1) //If input_param == 1 we're submitting a new wanted issue. At 2 we're just editing an existing one.
@@ -450,16 +450,16 @@ GLOBAL_LIST_EMPTY(allCasters)
screen = 15
else
if(GLOB.news_network.wanted_issue.isAdminMsg)
- tgui_alert(usr, "The wanted issue has been distributed by a Nanotrasen higherup. You cannot edit it.",list("Ok"))
+ alert("The wanted issue has been distributed by a Nanotrasen higherup. You cannot edit it.","Ok")
return
GLOB.news_network.submitWanted(channel_name, msg, scanned_user, picture)
screen = 19
updateUsrDialog()
else if(href_list["cancel_wanted"])
if(GLOB.news_network.wanted_issue.isAdminMsg)
- tgui_alert(usr, "The wanted issue has been distributed by a Nanotrasen higherup. You cannot take it down.",list("Ok"))
+ alert("The wanted issue has been distributed by a Nanotrasen higherup. You cannot take it down.","Ok")
return
- var/choice = tgui_alert(usr, "Please confirm Wanted Issue removal","Network Security Handler",list("Confirm","Cancel"))
+ var/choice = alert("Please confirm Wanted Issue removal","Network Security Handler","Confirm","Cancel")
if(choice=="Confirm")
GLOB.news_network.deleteWanted()
screen=17
@@ -470,21 +470,21 @@ GLOBAL_LIST_EMPTY(allCasters)
else if(href_list["censor_channel_author"])
var/datum/news/feed_channel/FC = locate(href_list["censor_channel_author"])
if(FC.is_admin_channel)
- tgui_alert(usr, "This channel was created by a Nanotrasen Officer. You cannot censor it.",list("Ok"))
+ alert("This channel was created by a Nanotrasen Officer. You cannot censor it.","Ok")
return
FC.toggleCensorAuthor()
updateUsrDialog()
else if(href_list["censor_channel_story_author"])
var/datum/news/feed_message/MSG = locate(href_list["censor_channel_story_author"])
if(MSG.is_admin_message)
- tgui_alert(usr, "This message was created by a Nanotrasen Officer. You cannot censor its author.",list("Ok"))
+ alert("This message was created by a Nanotrasen Officer. You cannot censor its author.","Ok")
return
MSG.toggleCensorAuthor()
updateUsrDialog()
else if(href_list["censor_channel_story_body"])
var/datum/news/feed_message/MSG = locate(href_list["censor_channel_story_body"])
if(MSG.is_admin_message)
- tgui_alert(usr, "This channel was created by a Nanotrasen Officer. You cannot censor it.",list("Ok"))
+ alert("This channel was created by a Nanotrasen Officer. You cannot censor it.","Ok")
return
MSG.toggleCensorBody()
updateUsrDialog()
@@ -496,7 +496,7 @@ GLOBAL_LIST_EMPTY(allCasters)
else if(href_list["toggle_d_notice"])
var/datum/news/feed_channel/FC = locate(href_list["toggle_d_notice"])
if(FC.is_admin_channel)
- tgui_alert(usr, "This channel was created by a Nanotrasen Officer. You cannot place a D-Notice upon it.",list("Ok"))
+ alert("This channel was created by a Nanotrasen Officer. You cannot place a D-Notice upon it.","Ok")
return
FC.toggleCensorDclass()
updateUsrDialog()
diff --git a/code/modules/ninja/suit/ninja_equipment_actions/ninja_net.dm b/code/modules/ninja/suit/ninja_equipment_actions/ninja_net.dm
index 1b11b320c2..ab52f3e018 100644
--- a/code/modules/ninja/suit/ninja_equipment_actions/ninja_net.dm
+++ b/code/modules/ninja/suit/ninja_equipment_actions/ninja_net.dm
@@ -12,7 +12,7 @@
*/
/obj/item/clothing/suit/space/space_ninja/proc/ninjanet()
var/mob/living/carbon/human/ninja = affecting
- var/mob/living/net_target = tgui_input_list(ninja, "Select who to capture:","Capture who?",sortNames(oview(ninja)))
+ var/mob/living/net_target = input("Select who to capture:","Capture who?",null) as null|mob in sortNames(oview(ninja))
if(QDELETED(net_target)||!(net_target in oview(ninja)))
return
diff --git a/code/modules/ninja/suit/ninja_equipment_actions/ninja_suit_initialisation.dm b/code/modules/ninja/suit/ninja_equipment_actions/ninja_suit_initialisation.dm
index 9c041977de..c1a3c77814 100644
--- a/code/modules/ninja/suit/ninja_equipment_actions/ninja_suit_initialisation.dm
+++ b/code/modules/ninja/suit/ninja_equipment_actions/ninja_suit_initialisation.dm
@@ -95,7 +95,7 @@ GLOBAL_LIST_INIT(ninja_deinitialize_messages, list(
if (!ninja || !ninja.mind)
s_busy = FALSE
return
- if (phase == 0 && tgui_alert(ninja, "Are you certain you wish to remove the suit? This will take time and remove all abilities.",,list("Yes","No")) == "No")
+ if (phase == 0 && alert("Are you certain you wish to remove the suit? This will take time and remove all abilities.",,"Yes","No") == "No")
s_busy = FALSE
return
diff --git a/code/modules/paperwork/contract.dm b/code/modules/paperwork/contract.dm
index ea2bcad3aa..f46d4bf029 100644
--- a/code/modules/paperwork/contract.dm
+++ b/code/modules/paperwork/contract.dm
@@ -228,11 +228,11 @@
var/response = "No"
if(ghost)
ghost.notify_cloning("A devil has offered you revival, at the cost of your soul.",'sound/effects/genetics.ogg', H)
- response = tgui_alert(ghost, "A devil is offering you another chance at life, at the price of your soul, do you accept?", "Infernal Resurrection", list("Yes", "No", "Never for this round"), 200, 0)
+ response = tgalert(ghost, "A devil is offering you another chance at life, at the price of your soul, do you accept?", "Infernal Resurrection", "Yes", "No", "Never for this round", 0, 200)
if(!ghost)
return //handle logouts that happen whilst the alert is waiting for a response.
else
- response = tgui_alert(target.current, "A devil is offering you another chance at life, at the price of your soul, do you accept?", "Infernal Resurrection", list("Yes", "No", "Never for this round"), 200, 0)
+ response = tgalert(target.current, "A devil is offering you another chance at life, at the price of your soul, do you accept?", "Infernal Resurrection", "Yes", "No", "Never for this round", 0, 200)
if(response == "Yes")
H.revive(1,0)
log_combat(user, H, "infernally revived via contract")
diff --git a/code/modules/paperwork/pen.dm b/code/modules/paperwork/pen.dm
index 7b19a7ad42..b4f1acbed4 100644
--- a/code/modules/paperwork/pen.dm
+++ b/code/modules/paperwork/pen.dm
@@ -123,7 +123,7 @@
desc = "It's an expensive [current_skin] fountain pen. The nib is quite sharp."
/obj/item/pen/attack_self(mob/living/carbon/user)
- var/deg = tgui_input_num(user, "What angle would you like to rotate the pen head to? (1-360)", "Rotate Pen Head")
+ var/deg = input(user, "What angle would you like to rotate the pen head to? (1-360)", "Rotate Pen Head") as null|num
if(deg && (deg > 0 && deg <= 360))
degrees = deg
to_chat(user, "You rotate the top of the pen to [degrees] degrees.")
@@ -149,7 +149,7 @@
. = ..()
//Changing name/description of items. Only works if they have the UNIQUE_RENAME object flag set
if(isobj(O) && proximity && (O.obj_flags & UNIQUE_RENAME))
- var/penchoice = tgui_input_list(user, "What would you like to edit?", "Rename, change description or reset both?", list("Rename","Change description","Reset"))
+ var/penchoice = input(user, "What would you like to edit?", "Rename, change description or reset both?") as null|anything in list("Rename","Change description","Reset")
if(QDELETED(O) || !user.canUseTopic(O, BE_CLOSE))
return
if(penchoice == "Rename")
diff --git a/code/modules/photography/camera/camera.dm b/code/modules/photography/camera/camera.dm
index a22d5f8e16..49821e55e0 100644
--- a/code/modules/photography/camera/camera.dm
+++ b/code/modules/photography/camera/camera.dm
@@ -52,8 +52,8 @@
. = ..()
if(!user.canUseTopic(src, BE_CLOSE))
return
- var/desired_x = tgui_input_num(user, "How high do you want the camera to shoot, between [picture_size_x_min] and [picture_size_x_max]?", "Zoom", picture_size_x)
- var/desired_y = tgui_input_num(user, "How wide do you want the camera to shoot, between [picture_size_y_min] and [picture_size_y_max]?", "Zoom", picture_size_y)
+ var/desired_x = input(user, "How high do you want the camera to shoot, between [picture_size_x_min] and [picture_size_x_max]?", "Zoom", picture_size_x) as num
+ var/desired_y = input(user, "How wide do you want the camera to shoot, between [picture_size_y_min] and [picture_size_y_max]?", "Zoom", picture_size_y) as num
picture_size_x = min(clamp(desired_x, picture_size_x_min, picture_size_x_max), CAMERA_PICTURE_SIZE_HARD_LIMIT)
picture_size_y = min(clamp(desired_y, picture_size_y_min, picture_size_y_max), CAMERA_PICTURE_SIZE_HARD_LIMIT)
return TRUE
@@ -204,7 +204,7 @@
to_chat(user, "[pictures_left] photos left.")
var/customise = "No"
if(can_customise)
- customise = tgui_alert(user, "Do you want to customize the photo?", "Customization", list("Yes", "No"))
+ customise = alert(user, "Do you want to customize the photo?", "Customization", "Yes", "No")
if(customise == "Yes")
var/name1 = stripped_input(user, "Set a name for this photo, or leave blank. 32 characters max.", "Name", max_length = 32)
var/desc1 = stripped_input(user, "Set a description to add to photo, or leave blank. 128 characters max.", "Caption", max_length = 128)
diff --git a/code/modules/photography/camera/silicon_camera.dm b/code/modules/photography/camera/silicon_camera.dm
index 69dcfd89a8..28a080d5f1 100644
--- a/code/modules/photography/camera/silicon_camera.dm
+++ b/code/modules/photography/camera/silicon_camera.dm
@@ -33,7 +33,7 @@
var/datum/picture/p = i
nametemp += p.picture_name
temp[p.picture_name] = p
- find = tgui_input_list(user, "Select image", "", nametemp)
+ find = input(user, "Select image") in nametemp|null
if(!find)
return
return temp[find]
diff --git a/code/modules/plumbing/ducts.dm b/code/modules/plumbing/ducts.dm
index 915678ef5b..8a27f2669c 100644
--- a/code/modules/plumbing/ducts.dm
+++ b/code/modules/plumbing/ducts.dm
@@ -407,10 +407,10 @@ All the important duct code:
. += "It's current color and layer are [duct_color] and [duct_layer]. Use in-hand to change."
/obj/item/stack/ducts/attack_self(mob/user)
- var/new_layer = tgui_input_list(user, "Select a layer", "Layer", layers)
+ var/new_layer = input("Select a layer", "Layer") as null|anything in layers
if(new_layer)
duct_layer = new_layer
- var/new_color = tgui_input_list(user, "Select a color", "Color", GLOB.pipe_paint_colors)
+ var/new_color = input("Select a color", "Color") as null|anything in GLOB.pipe_paint_colors
if(new_color)
duct_color = new_color
add_atom_colour(GLOB.pipe_paint_colors[new_color], FIXED_COLOUR_PRIORITY)
diff --git a/code/modules/plumbing/plumbers/bottler.dm b/code/modules/plumbing/plumbers/bottler.dm
index 8bab3937b9..396c7cac22 100644
--- a/code/modules/plumbing/plumbers/bottler.dm
+++ b/code/modules/plumbing/plumbers/bottler.dm
@@ -51,7 +51,7 @@
///changing input ammount with a window
/obj/machinery/plumbing/bottler/interact(mob/user)
. = ..()
- wanted_amount = clamp(round(tgui_input_num(user,"maximum is 100u","set ammount to fill with"), 1), 1, 100)
+ wanted_amount = clamp(round(input(user,"maximum is 100u","set ammount to fill with") as num|null, 1), 1, 100)
reagents.clear_reagents()
to_chat(user, " The [src] will now fill for [wanted_amount]u.")
diff --git a/code/modules/power/antimatter/containment_jar.dm b/code/modules/power/antimatter/containment_jar.dm
index 0ccbba5a0c..3066755690 100644
--- a/code/modules/power/antimatter/containment_jar.dm
+++ b/code/modules/power/antimatter/containment_jar.dm
@@ -15,7 +15,7 @@
var/stability = 100//TODO: add all the stability things to this so its not very safe if you keep hitting in on things
-/obj/item/am_containment/ex_act(severity, target)
+/obj/item/am_containment/ex_act(severity, target, origin)
switch(severity)
if(1)
explosion(get_turf(src), 1, 2, 3, 5)//Should likely be larger but this works fine for now I guess
diff --git a/code/modules/power/antimatter/control.dm b/code/modules/power/antimatter/control.dm
index 17c5bc0e4c..f8f31f6990 100644
--- a/code/modules/power/antimatter/control.dm
+++ b/code/modules/power/antimatter/control.dm
@@ -114,7 +114,7 @@
check_stability()
return
-/obj/machinery/power/am_control_unit/ex_act(severity, target)
+/obj/machinery/power/am_control_unit/ex_act(severity, target, origin)
stability -= (80 - (severity * 20))
check_stability()
return
diff --git a/code/modules/power/antimatter/shielding.dm b/code/modules/power/antimatter/shielding.dm
index 100998d7c6..52478e532e 100644
--- a/code/modules/power/antimatter/shielding.dm
+++ b/code/modules/power/antimatter/shielding.dm
@@ -94,7 +94,7 @@
/obj/machinery/am_shielding/emp_act()//Immune due to not really much in the way of electronics.
return
-/obj/machinery/am_shielding/ex_act(severity, target)
+/obj/machinery/am_shielding/ex_act(severity, target, origin)
stability -= (80 - (severity * 20))
check_stability()
return
diff --git a/code/modules/power/apc.dm b/code/modules/power/apc.dm
index 51388a236b..2e38fdd840 100644
--- a/code/modules/power/apc.dm
+++ b/code/modules/power/apc.dm
@@ -300,7 +300,7 @@
area.power_equip = FALSE
area.power_environ = FALSE
area.power_change()
- area.poweralert(FALSE, src)
+ area.poweralert(TRUE, src)
if(occupier)
malfvacate(1)
qdel(wires)
@@ -1303,7 +1303,7 @@
user.visible_message("[user] slots [card] into [src]...", "Transfer process initiated. Sending request for AI approval...")
playsound(src, 'sound/machines/click.ogg', 50, TRUE)
SEND_SOUND(occupier, sound('sound/misc/notice2.ogg')) //To alert the AI that someone's trying to card them if they're tabbed out
- if(tgui_alert(occupier, "[user] is attempting to transfer you to \a [card.name]. Do you consent to this?", "APC Transfer", list("Yes - Transfer Me", "No - Keep Me Here")) == "No - Keep Me Here")
+ if(alert(occupier, "[user] is attempting to transfer you to \a [card.name]. Do you consent to this?", "APC Transfer", "Yes - Transfer Me", "No - Keep Me Here") == "No - Keep Me Here")
to_chat(user, "AI denied transfer request. Process terminated.")
playsound(src, 'sound/machines/buzz-sigh.ogg', 50, TRUE)
transfer_in_progress = FALSE
@@ -1444,8 +1444,6 @@
lighting = autoset(lighting, AUTOSET_ON)
environ = autoset(environ, AUTOSET_ON)
area.poweralert(FALSE, src)
- if(cell.percent() > 75)
- area.poweralert(FALSE, src)
// now trickle-charge the cell
if(chargemode && charging == APC_CHARGING && operating)
diff --git a/code/modules/power/cable.dm b/code/modules/power/cable.dm
index 191ec3499f..9e779b9c1b 100644
--- a/code/modules/power/cable.dm
+++ b/code/modules/power/cable.dm
@@ -520,7 +520,7 @@ By design, d1 is the smallest direction and d2 is the highest
cost = 1
/obj/item/stack/cable_coil/cyborg/attack_self(mob/user)
- var/cable_color = tgui_input_list(user,"Pick a cable color.","Cable Color", list("red","yellow","green","blue","pink","orange","cyan","white"))
+ var/cable_color = input(user,"Pick a cable color.","Cable Color") in list("red","yellow","green","blue","pink","orange","cyan","white")
color = cable_color
update_icon()
diff --git a/code/modules/power/cell.dm b/code/modules/power/cell.dm
index 0af16013ec..10a4f5844a 100644
--- a/code/modules/power/cell.dm
+++ b/code/modules/power/cell.dm
@@ -142,7 +142,7 @@
if(charge < 0)
charge = 0
-/obj/item/stock_parts/cell/ex_act(severity, target)
+/obj/item/stock_parts/cell/ex_act(severity, target, origin)
..()
if(!QDELETED(src))
switch(severity)
@@ -187,23 +187,6 @@
/obj/item/stock_parts/cell/get_part_rating()
return rating * maxcharge
-// stuff so ipcs and synthlizards can eat power cells, taken from how moths can eat clothing
-/obj/item/reagent_containers/food/snacks/cell
- name = "oops"
- desc = "If you're reading this it means I messed up. This is related to ipcs/synths eating cells and I didn't know a better way to do it than making a new food object."
- list_reagents = list(/datum/reagent/consumable/nutriment = 0.5)
- tastes = list("electricity" = 1, "metal" = 1)
-
-/obj/item/stock_parts/cell/attack(mob/M, mob/user, def_zone)
- if(user.a_intent != INTENT_HARM && isrobotic(M))
- var/obj/item/reagent_containers/food/snacks/cell/cell_as_food = new
- cell_as_food.name = name
- if(cell_as_food.attack(M, user, def_zone))
- take_damage(40, sound_effect=FALSE)
- qdel(cell_as_food)
- else
- return ..()
-
/* Cell variants*/
/obj/item/stock_parts/cell/empty
start_charged = FALSE
diff --git a/code/modules/power/generator.dm b/code/modules/power/generator.dm
index 9213a5d2ba..f1beecacb9 100644
--- a/code/modules/power/generator.dm
+++ b/code/modules/power/generator.dm
@@ -12,6 +12,8 @@
var/lastgenlev = -1
var/lastcirc = "00"
+ var/max_efficiency = 0.45
+
/obj/machinery/power/generator/Initialize(mapload)
. = ..()
@@ -61,15 +63,12 @@
if(delta_temperature > 0 && cold_air_heat_capacity > 0 && hot_air_heat_capacity > 0)
- var/efficiency = 0.45
+ var/efficiency = LOGISTIC_FUNCTION(max_efficiency,0.0009,delta_temperature,10000)
var/energy_transfer = delta_temperature*hot_air_heat_capacity*cold_air_heat_capacity/(hot_air_heat_capacity+cold_air_heat_capacity)
- var/heat = energy_transfer*(1-efficiency)
- if(delta_temperature < 16800) // second point where derivative of below function = 1
- lastgen += LOGISTIC_FUNCTION(500000,0.0009,delta_temperature,10000)
- else
- lastgen += delta_temperature + 482102 // value of above function at 16800, or very nearly so
+ lastgen += energy_transfer * efficiency
+ var/heat = energy_transfer * (1-efficiency)
hot_air.set_temperature(hot_air.return_temperature() - energy_transfer/hot_air_heat_capacity)
cold_air.set_temperature(cold_air.return_temperature() + heat/cold_air_heat_capacity)
diff --git a/code/modules/power/gravitygenerator.dm b/code/modules/power/gravitygenerator.dm
index 3fe03978bd..3d07b60c41 100644
--- a/code/modules/power/gravitygenerator.dm
+++ b/code/modules/power/gravitygenerator.dm
@@ -31,7 +31,7 @@ GLOBAL_LIST_EMPTY(gravity_generators) // We will keep track of this by adding ne
/obj/machinery/gravity_generator/safe_throw_at(atom/target, range, speed, mob/thrower, spin = TRUE, diagonals_first = FALSE, datum/callback/callback, force = MOVE_FORCE_STRONG, gentle = FALSE)
return FALSE
-/obj/machinery/gravity_generator/ex_act(severity, target)
+/obj/machinery/gravity_generator/ex_act(severity, target, origin)
if(severity >= EXPLODE_DEVASTATE) // Very sturdy.
set_broken()
diff --git a/code/modules/power/rtg.dm b/code/modules/power/rtg.dm
index c19927e84c..10219c29c1 100644
--- a/code/modules/power/rtg.dm
+++ b/code/modules/power/rtg.dm
@@ -115,7 +115,7 @@
/obj/machinery/power/rtg/abductor/blob_act(obj/structure/blob/B)
overload()
-/obj/machinery/power/rtg/abductor/ex_act()
+/obj/machinery/power/rtg/abductor/ex_act(severity, target, origin)
if(going_kaboom)
qdel(src)
else
diff --git a/code/modules/power/singularity/containment_field.dm b/code/modules/power/singularity/containment_field.dm
index 2ca9b7513c..ff6cf99411 100644
--- a/code/modules/power/singularity/containment_field.dm
+++ b/code/modules/power/singularity/containment_field.dm
@@ -42,7 +42,7 @@
/obj/machinery/field/containment/blob_act(obj/structure/blob/B)
return FALSE
-/obj/machinery/field/containment/ex_act(severity, target)
+/obj/machinery/field/containment/ex_act(severity, target, origin)
return FALSE
/obj/machinery/field/containment/attack_animal(mob/living/simple_animal/M)
diff --git a/code/modules/power/singularity/narsie.dm b/code/modules/power/singularity/narsie.dm
index 0ebbce53cf..08d2ff5c84 100644
--- a/code/modules/power/singularity/narsie.dm
+++ b/code/modules/power/singularity/narsie.dm
@@ -143,7 +143,7 @@
A.narsie_act()
-/obj/singularity/narsie/ex_act() //No throwing bombs at her either.
+/obj/singularity/narsie/ex_act(severity, target, origin) //No throwing bombs at her either.
return
diff --git a/code/modules/power/singularity/particle_accelerator/particle.dm b/code/modules/power/singularity/particle_accelerator/particle.dm
index 7ecde364ae..58c338e44a 100644
--- a/code/modules/power/singularity/particle_accelerator/particle.dm
+++ b/code/modules/power/singularity/particle_accelerator/particle.dm
@@ -49,7 +49,7 @@
toxmob(A)
-/obj/effect/accelerated_particle/ex_act(severity, target)
+/obj/effect/accelerated_particle/ex_act(severity, target, origin)
qdel(src)
/obj/effect/accelerated_particle/singularity_pull()
diff --git a/code/modules/power/singularity/singularity.dm b/code/modules/power/singularity/singularity.dm
index ee4b9ce6ba..256e128ff4 100644
--- a/code/modules/power/singularity/singularity.dm
+++ b/code/modules/power/singularity/singularity.dm
@@ -97,7 +97,7 @@
return
return ..()
-/obj/singularity/ex_act(severity, target)
+/obj/singularity/ex_act(severity, target, origin)
switch(severity)
if(1)
if(current_size <= STAGE_TWO)
diff --git a/code/modules/power/supermatter/supermatter.dm b/code/modules/power/supermatter/supermatter.dm
index b802cc7b88..a1fbf5d7ad 100644
--- a/code/modules/power/supermatter/supermatter.dm
+++ b/code/modules/power/supermatter/supermatter.dm
@@ -894,7 +894,7 @@ GLOBAL_DATUM(main_supermatter_engine, /obj/machinery/power/supermatter_crystal)
CALCULATE_ADJACENT_TURFS(T)
//Do not blow up our internal radio
-/obj/machinery/power/supermatter_crystal/contents_explosion(severity, target)
+/obj/machinery/power/supermatter_crystal/contents_explosion(severity, target, origin)
return
/obj/machinery/power/supermatter_crystal/engine
diff --git a/code/modules/power/tesla/energy_ball.dm b/code/modules/power/tesla/energy_ball.dm
index 5d7bb9a8b6..2c8583b447 100644
--- a/code/modules/power/tesla/energy_ball.dm
+++ b/code/modules/power/tesla/energy_ball.dm
@@ -39,7 +39,7 @@
if(!is_miniball)
set_light(10, 7, "#EEEEFF")
-/obj/singularity/energy_ball/ex_act(severity, target)
+/obj/singularity/energy_ball/ex_act(severity, target, origin)
return
/obj/singularity/energy_ball/consume(severity, target)
diff --git a/code/modules/procedural_mapping/mapGenerator.dm b/code/modules/procedural_mapping/mapGenerator.dm
index 0487feb1d8..323f74d0ef 100644
--- a/code/modules/procedural_mapping/mapGenerator.dm
+++ b/code/modules/procedural_mapping/mapGenerator.dm
@@ -147,16 +147,16 @@
set category = "Debug"
var/datum/mapGenerator/nature/N = new()
- var/startInput = tgui_input_text(usr,"Start turf of Map, (X;Y;Z)", "Map Gen Settings", "1;1;1")
+ var/startInput = input(usr,"Start turf of Map, (X;Y;Z)", "Map Gen Settings", "1;1;1") as text|null
if (isnull(startInput))
return
- var/endInput = tgui_input_text(usr,"End turf of Map (X;Y;Z)", "Map Gen Settings", "[world.maxx];[world.maxy];[mob ? mob.z : 1]")
-
+ var/endInput = input(usr,"End turf of Map (X;Y;Z)", "Map Gen Settings", "[world.maxx];[world.maxy];[mob ? mob.z : 1]") as text|null
+
if (isnull(endInput))
return
-
+
//maxx maxy and current z so that if you fuck up, you only fuck up one entire z level instead of the entire universe
if(!startInput || !endInput)
to_chat(src, "Missing Input")
@@ -182,7 +182,7 @@
"Same turfs"=CLUSTER_CHECK_SAME_TURFS, "Same atoms"=CLUSTER_CHECK_SAME_ATOMS, "Different turfs"=CLUSTER_CHECK_DIFFERENT_TURFS, \
"Different atoms"=CLUSTER_CHECK_DIFFERENT_ATOMS, "All turfs"=CLUSTER_CHECK_ALL_TURFS,"All atoms"=CLUSTER_CHECK_ALL_ATOMS)
- var/moduleClusters = tgui_input_list(src, "Cluster Flags (Cancel to leave unchanged from defaults)","Map Gen Settings", clusters)
+ var/moduleClusters = input("Cluster Flags (Cancel to leave unchanged from defaults)","Map Gen Settings") as null|anything in clusters
//null for default
var/theCluster = 0
diff --git a/code/modules/projectiles/ammunition/ballistic/shotgun.dm b/code/modules/projectiles/ammunition/ballistic/shotgun.dm
index 2a41b41d1d..04e8e62029 100644
--- a/code/modules/projectiles/ammunition/ballistic/shotgun.dm
+++ b/code/modules/projectiles/ammunition/ballistic/shotgun.dm
@@ -139,7 +139,7 @@
/obj/item/ammo_casing/shotgun/dart/noreact/Initialize()
. = ..()
- ENABLE_BITFIELD(reagents.reagents_holder_flags, NO_REACT)
+ reagents.reagents_holder_flags |= NO_REACT
/obj/item/ammo_casing/shotgun/dart/bioterror
desc = "A shotgun dart filled with an obscene amount of lethal reagents. God help whoever is shot with this."
diff --git a/code/modules/projectiles/ammunition/special/syringe.dm b/code/modules/projectiles/ammunition/special/syringe.dm
index caf5da3562..4eb7dc5475 100644
--- a/code/modules/projectiles/ammunition/special/syringe.dm
+++ b/code/modules/projectiles/ammunition/special/syringe.dm
@@ -24,9 +24,10 @@
/obj/item/ammo_casing/chemgun
name = "dart synthesiser"
- desc = "A high-power spring, linked to an energy-based dart synthesiser."
+ desc = "A high-power spring, linked to an energy-based piercing dart synthesiser."
projectile_type = /obj/item/projectile/bullet/dart/piercing
firing_effect_type = null
+ var/dartvolume = 10
/obj/item/ammo_casing/chemgun/ready_proj(atom/target, mob/living/user, quiet, zone_override = "")
if(!BB)
@@ -35,11 +36,23 @@
var/obj/item/gun/chem/CG = loc
if(CG.syringes_left <= 0)
return
- CG.reagents.trans_to(BB, 10)
+ if (!CG.vial)
+ CG.syringes_left--
+ return
+ CG.vial.reagents.trans_to(BB, dartvolume)
BB.name = "chemical dart"
CG.syringes_left--
..()
+//Smart dart version of reagent launcher.
+/obj/item/ammo_casing/chemgun/smart
+ name = "smartdart synthesiser"
+ desc = "A high-power spring, linked to an energy-based smartdart synthesiser."
+ projectile_type = /obj/item/projectile/bullet/dart/syringe/dart
+ firing_effect_type = null
+ harmful = FALSE
+ dartvolume = 20
+
/obj/item/ammo_casing/dnainjector
name = "rigged syringe gun spring"
desc = "A high-power spring that throws DNA injectors."
diff --git a/code/modules/projectiles/guns/misc/blastcannon.dm b/code/modules/projectiles/guns/misc/blastcannon.dm
index 60b7565333..64cffe52e7 100644
--- a/code/modules/projectiles/guns/misc/blastcannon.dm
+++ b/code/modules/projectiles/guns/misc/blastcannon.dm
@@ -156,5 +156,5 @@
mediumr = max(mediumr - 1, 0)
lightr = max(lightr - 1, 0)
-/obj/item/projectile/blastwave/ex_act()
+/obj/item/projectile/blastwave/ex_act(severity, target, origin)
return
diff --git a/code/modules/projectiles/guns/misc/chem_gun.dm b/code/modules/projectiles/guns/misc/chem_gun.dm
index 779ab64bc2..ccc4c5bd15 100644
--- a/code/modules/projectiles/guns/misc/chem_gun.dm
+++ b/code/modules/projectiles/guns/misc/chem_gun.dm
@@ -1,8 +1,8 @@
//his isn't a subtype of the syringe gun because the syringegun subtype is made to hold syringes
//this is meant to hold reagents/obj/item/gun/syringe
/obj/item/gun/chem
- name = "reagent gun"
- desc = "A Nanotrasen syringe gun, modified to automatically synthesise chemical darts, and instead hold reagents."
+ name = "Reagent Repeater"
+ desc = "A Nanotrasen smartdart repeater rifle, modified to automatically synthesize piercing darts."
icon_state = "chemgun"
item_state = "chemgun"
w_class = WEIGHT_CLASS_NORMAL
@@ -13,21 +13,79 @@
custom_materials = list(/datum/material/iron=2000)
clumsy_check = FALSE
fire_sound = 'sound/items/syringeproj.ogg'
- var/time_per_syringe = 300
- var/syringes_left = 5
- var/max_syringes = 5
+ var/time_per_syringe = 200
+ var/syringes_left = 3
+ var/max_syringes = 6
var/last_synth = 0
+ var/obj/item/reagent_containers/glass/bottle/vial/vial
+ var/list/allowed_containers = list(/obj/item/reagent_containers/glass/bottle/vial/small, /obj/item/reagent_containers/glass/bottle/vial/large)
+ var/quickload = TRUE
/obj/item/gun/chem/Initialize()
. = ..()
chambered = new /obj/item/ammo_casing/chemgun(src)
START_PROCESSING(SSobj, src)
- create_reagents(100, OPENCONTAINER)
/obj/item/gun/chem/Destroy()
. = ..()
STOP_PROCESSING(SSobj, src)
+//bunch of hypospray copy paste
+/obj/item/gun/chem/examine(mob/user)
+ . = ..()
+ if(vial)
+ . += "[vial] has [vial.reagents.total_volume]u remaining."
+ else
+ . += "It has no vial loaded in."
+
+/obj/item/gun/chem/proc/unload_hypo(obj/item/I, mob/user)
+ if((istype(I, /obj/item/reagent_containers/glass/bottle/vial)))
+ var/obj/item/reagent_containers/glass/bottle/vial/V = I
+ V.forceMove(user.loc)
+ user.put_in_hands(V)
+ to_chat(user, "You remove [vial] from [src].")
+ vial = null
+ update_icon()
+ playsound(loc, 'sound/weapons/empty.ogg', 50, 1)
+ else
+ to_chat(user, "The weapon isn't loaded!")
+ return
+
+/obj/item/gun/chem/attackby(obj/item/I, mob/living/user)
+ if((istype(I, /obj/item/reagent_containers/glass/bottle/vial)))
+ if(vial)
+ if(!quickload)
+ to_chat(user, "[src] can not hold more than one vial!")
+ return FALSE
+ unload_hypo(vial, user)
+ var/obj/item/reagent_containers/glass/bottle/vial/V = I
+ if(!is_type_in_list(V, allowed_containers))
+ to_chat(user, "[src] doesn't accept this type of vial.")
+ return FALSE
+ if(!user.transferItemToLoc(V,src))
+ return FALSE
+ vial = V
+ user.visible_message("[user] has loaded a vial into [src].","You have loaded [vial] into [src].")
+ update_icon()
+ playsound(loc, 'sound/weapons/autoguninsert.ogg', 35, 1)
+ return TRUE
+ else
+ to_chat(user, "This doesn't fit in [src].")
+ return FALSE
+
+/obj/item/gun/chem/on_attack_hand(mob/user, act_intent = user.a_intent, unarmed_attack_flags)
+ . = ..() //Don't bother changing this or removing it from containers will break.
+
+/obj/item/gun/chem/attack_self(mob/living/user)
+ if(user && !user.incapacitated())
+ if(!vial)
+ to_chat(user, "This Hypo needs to be loaded first!")
+ else
+ unload_hypo(vial,user)
+
+/obj/item/gun/chem/attack(obj/item/I, mob/user, params)
+ return
+
/obj/item/gun/chem/can_shoot()
return syringes_left
@@ -45,3 +103,15 @@
if(chambered && !chambered.BB)
chambered.newshot()
last_synth = world.time
+
+//Smart dart version of the reagent launcher
+/obj/item/gun/chem/smart
+ name = "Smartdart repeater rifle"
+ desc = "An experimental improved version of the smartdart rifle. It synthesizes medicinal smart darts which it fills using an inserted hypovial. It can accommodate both large and small hypovials."
+ icon_state = "chemgunrepeater"
+ item_state = "syringegun"
+
+obj/item/gun/chem/smart/Initialize()
+ . = ..()
+ chambered = new /obj/item/ammo_casing/chemgun/smart(src)
+
diff --git a/code/modules/projectiles/guns/misc/syringe_gun.dm b/code/modules/projectiles/guns/misc/syringe_gun.dm
index 39b7cbf540..91275e197a 100644
--- a/code/modules/projectiles/guns/misc/syringe_gun.dm
+++ b/code/modules/projectiles/guns/misc/syringe_gun.dm
@@ -127,7 +127,7 @@
/obj/item/gun/syringe/dart/rapiddart
name = "Repeating dart gun"
icon_state = "rapiddartgun"
- item_state = "rapiddartgun"
+ item_state = "syringegun"
/obj/item/gun/syringe/dart/rapiddart/CheckParts(list/parts_list)
var/obj/item/reagent_containers/glass/beaker/B = locate(/obj/item/reagent_containers/glass/beaker) in parts_list
@@ -157,7 +157,7 @@
name = "blowgun"
desc = "Fire syringes at a short distance."
icon_state = "blowgun"
- item_state = "blowgun"
+ item_state = "syringegun"
fire_sound = 'sound/items/syringeproj.ogg'
/obj/item/gun/syringe/blowgun/process_fire(atom/target, mob/living/user, message = TRUE, params = null, zone_override = "", bonus_spread = 0, stam_cost = 0)
diff --git a/code/modules/projectiles/pins.dm b/code/modules/projectiles/pins.dm
index 2ff8130527..cef730366e 100644
--- a/code/modules/projectiles/pins.dm
+++ b/code/modules/projectiles/pins.dm
@@ -259,20 +259,20 @@
. = TRUE
if(!can_toggle || !user.canUseTopic(src, BE_CLOSE))
return
- var/selection = tgui_alert(user, "Which setting would you want to modify?", "Firing Pin Settings", list("Minimum Level Setting", "Maximum Level Setting", "Lethals Only Toggle"))
+ var/selection = alert(user, "Which setting would you want to modify?", "Firing Pin Settings", "Minimum Level Setting", "Maximum Level Setting", "Lethals Only Toggle")
if(QDELETED(src) || QDELETED(user) || !user.canUseTopic(src, BE_CLOSE))
return
var/static/list/till_designs_pr_isnt_merged = list("green", "blue", "amber", "red", "delta")
switch(selection)
if("Minimum Level Setting")
- var/input = tgui_input_list(user, "Input the new minimum level setting.", "Firing Pin Settings", till_designs_pr_isnt_merged)
+ var/input = input(user, "Input the new minimum level setting.", "Firing Pin Settings", NUM2SECLEVEL(min_sec_level)) as null|anything in till_designs_pr_isnt_merged
if(!input)
return
min_sec_level = till_designs_pr_isnt_merged.Find(input) - 1
if(min_sec_level > max_sec_level)
max_sec_level = SEC_LEVEL_DELTA
if("Maximum Level Setting")
- var/input = tgui_input_list(user, "Input the new maximum level setting.", "Firing Pin Settings", till_designs_pr_isnt_merged)
+ var/input = input(user, "Input the new maximum level setting.", "Firing Pin Settings", NUM2SECLEVEL(max_sec_level)) as null|anything in till_designs_pr_isnt_merged
if(!input)
return
max_sec_level = till_designs_pr_isnt_merged.Find(input) - 1
diff --git a/code/modules/projectiles/projectile.dm b/code/modules/projectiles/projectile.dm
index 0a7598cd79..07fc4bf9de 100644
--- a/code/modules/projectiles/projectile.dm
+++ b/code/modules/projectiles/projectile.dm
@@ -362,7 +362,7 @@
/obj/item/projectile/proc/process_hit(turf/T, atom/target, qdel_self, hit_something = FALSE) //probably needs to be reworked entirely when pixel movement is done.
if(QDELETED(src) || !T || !target) //We're done, nothing's left.
- if((qdel_self == FORCE_QDEL) || ((qdel_self == QDEL_SELF) && !temporary_unstoppable_movement && !CHECK_BITFIELD(movement_type, UNSTOPPABLE)))
+ if((qdel_self == FORCE_QDEL) || ((qdel_self == QDEL_SELF) && !temporary_unstoppable_movement && !(movement_type & UNSTOPPABLE)))
qdel(src)
return hit_something
permutated |= target //Make sure we're never hitting it again. If we ever run into weirdness with piercing projectiles needing to hit something multiple times.. well.. that's a to-do.
@@ -370,16 +370,16 @@
return process_hit(T, select_target(T), qdel_self, hit_something) //Hit whatever else we can since that didn't work.
var/result = target.bullet_act(src, def_zone)
if(result == BULLET_ACT_FORCE_PIERCE)
- if(!CHECK_BITFIELD(movement_type, UNSTOPPABLE))
+ if(!(movement_type & UNSTOPPABLE))
temporary_unstoppable_movement = TRUE
- ENABLE_BITFIELD(movement_type, UNSTOPPABLE)
+ movement_type |= UNSTOPPABLE
return process_hit(T, select_target(T), qdel_self, TRUE) //Hit whatever else we can since we're piercing through but we're still on the same tile.
else if(result == BULLET_ACT_TURF) //We hit the turf but instead we're going to also hit something else on it.
return process_hit(T, select_target(T), QDEL_SELF, TRUE)
else //Whether it hit or blocked, we're done!
qdel_self = QDEL_SELF
hit_something = TRUE
- if((qdel_self == FORCE_QDEL) || ((qdel_self == QDEL_SELF) && !temporary_unstoppable_movement && !CHECK_BITFIELD(movement_type, UNSTOPPABLE)))
+ if((qdel_self == FORCE_QDEL) || ((qdel_self == QDEL_SELF) && !temporary_unstoppable_movement && !(movement_type & UNSTOPPABLE)))
qdel(src)
return hit_something
@@ -775,7 +775,7 @@
if(.)
if(temporary_unstoppable_movement)
temporary_unstoppable_movement = FALSE
- DISABLE_BITFIELD(movement_type, UNSTOPPABLE)
+ movement_type &= ~(UNSTOPPABLE)
if(fired && can_hit_target(original, permutated, TRUE))
Bump(original)
diff --git a/code/modules/projectiles/projectile/bullets/dart_syringe.dm b/code/modules/projectiles/projectile/bullets/dart_syringe.dm
index 318acb66b5..4978e679b4 100644
--- a/code/modules/projectiles/projectile/bullets/dart_syringe.dm
+++ b/code/modules/projectiles/projectile/bullets/dart_syringe.dm
@@ -25,7 +25,7 @@
"You were protected against \the [src]!")
..(target, blocked)
- DISABLE_BITFIELD(reagents.reagents_holder_flags, NO_REACT)
+ reagents.reagents_holder_flags &= ~(NO_REACT)
reagents.handle_reactions()
return BULLET_ACT_HIT
diff --git a/code/modules/projectiles/projectile/magic.dm b/code/modules/projectiles/projectile/magic.dm
index c9ca4e9ba3..76cd1a6bc5 100644
--- a/code/modules/projectiles/projectile/magic.dm
+++ b/code/modules/projectiles/projectile/magic.dm
@@ -37,7 +37,8 @@
return BULLET_ACT_BLOCK
if(iscarbon(target))
var/mob/living/carbon/C = target
- C.regenerate_limbs()
+ if(!is_species(C, /datum/species/dullahan)) //No accidental instagibbing dullahans please
+ C.regenerate_limbs()
C.regenerate_organs()
if(target.revive(full_heal = 1))
target.grab_ghost(force = TRUE) // even suicides
diff --git a/code/modules/projectiles/projectile/special/curse.dm b/code/modules/projectiles/projectile/special/curse.dm
index d967540e6a..6c682763ae 100644
--- a/code/modules/projectiles/projectile/special/curse.dm
+++ b/code/modules/projectiles/projectile/special/curse.dm
@@ -31,7 +31,7 @@
/obj/item/projectile/curse_hand/prehit(atom/target)
if(target == original)
- DISABLE_BITFIELD(movement_type, UNSTOPPABLE)
+ movement_type &= ~(UNSTOPPABLE)
else if(!isturf(target))
return FALSE
return ..()
@@ -40,7 +40,7 @@
if(arm)
arm.End()
arm = null
- if(CHECK_BITFIELD(movement_type, UNSTOPPABLE))
+ if((movement_type & UNSTOPPABLE))
playsound(src, 'sound/effects/curse3.ogg', 25, 1, -1)
var/turf/T = get_step(src, dir)
var/obj/effect/temp_visual/dir_setting/curse/hand/leftover = new(T, dir)
diff --git a/code/modules/reagents/chem_wiki_render.dm b/code/modules/reagents/chem_wiki_render.dm
index c4f4cab0ff..018161b075 100644
--- a/code/modules/reagents/chem_wiki_render.dm
+++ b/code/modules/reagents/chem_wiki_render.dm
@@ -17,7 +17,7 @@
var/prefix = "|Name | Reagents | Reaction vars | Description | Chem properties |\n|---|---|---|-----------|---|\n"
- var/input_reagent = replacetext(lowertext(tgui_input_text(src, "Input the name/type of a reagent to get it's description on it's own, or leave blank to parse every chem.", "Input")), " ", "") //95% of the time, the reagent type is a lowercase, no spaces / underscored version of the name
+ var/input_reagent = replacetext(lowertext(input("Input the name/type of a reagent to get it's description on it's own, or leave blank to parse every chem.", "Input") as text), " ", "") //95% of the time, the reagent type is a lowercase, no spaces / underscored version of the name
if(input_reagent)
var/input_reagent2 = find_reagent(input_reagent)
if(!input_reagent2)
diff --git a/code/modules/reagents/chemistry/machinery/chem_dispenser.dm b/code/modules/reagents/chemistry/machinery/chem_dispenser.dm
index e9ae0ac1cb..6aec48182a 100644
--- a/code/modules/reagents/chemistry/machinery/chem_dispenser.dm
+++ b/code/modules/reagents/chemistry/machinery/chem_dispenser.dm
@@ -165,14 +165,14 @@
obj_flags |= EMAGGED
return TRUE
-/obj/machinery/chem_dispenser/ex_act(severity, target)
+/obj/machinery/chem_dispenser/ex_act(severity, target, origin)
if(severity < 3)
..()
-/obj/machinery/chem_dispenser/contents_explosion(severity, target)
+/obj/machinery/chem_dispenser/contents_explosion(severity, target, origin)
..()
if(beaker)
- beaker.ex_act(severity, target)
+ beaker.ex_act(severity, target, origin)
/obj/machinery/chem_dispenser/Exited(atom/movable/A, atom/newloc)
. = ..()
@@ -322,7 +322,7 @@
if("clear_recipes")
if(!is_operational())
return
- var/yesno = tgui_alert(usr, "Clear all recipes?",, list("Yes","No"))
+ var/yesno = alert("Clear all recipes?",, "Yes","No")
if(yesno == "Yes")
saved_recipes = list()
. = TRUE
@@ -337,7 +337,7 @@
var/name = stripped_input(usr,"Name","What do you want to name this recipe?", "Recipe", MAX_NAME_LEN)
if(!usr.canUseTopic(src, !hasSiliconAccessInArea(usr)))
return
- if(saved_recipes[name] && tgui_alert(usr, "\"[name]\" already exists, do you want to overwrite it?",, list("Yes", "No")) == "No")
+ if(saved_recipes[name] && alert("\"[name]\" already exists, do you want to overwrite it?",, "Yes", "No") == "No")
return
if(name && recording_recipe)
var/list/logstring = list()
diff --git a/code/modules/reagents/chemistry/machinery/chem_master.dm b/code/modules/reagents/chemistry/machinery/chem_master.dm
index e6e8070663..c49b2cc14c 100644
--- a/code/modules/reagents/chemistry/machinery/chem_master.dm
+++ b/code/modules/reagents/chemistry/machinery/chem_master.dm
@@ -46,16 +46,16 @@
for(var/obj/item/reagent_containers/glass/beaker/B in component_parts)
reagents.maximum_volume += B.reagents.maximum_volume
-/obj/machinery/chem_master/ex_act(severity, target)
+/obj/machinery/chem_master/ex_act(severity, target, origin)
if(severity < 3)
..()
-/obj/machinery/chem_master/contents_explosion(severity, target)
+/obj/machinery/chem_master/contents_explosion(severity, target, origin)
..()
if(beaker)
- beaker.ex_act(severity, target)
+ beaker.ex_act(severity, target, origin)
if(bottle)
- bottle.ex_act(severity, target)
+ bottle.ex_act(severity, target, origin)
/obj/machinery/chem_master/Exited(atom/movable/A, atom/newloc)
. = ..()
@@ -221,8 +221,7 @@
var/to_container = params["to"]
// Custom amount
if (amount == -1)
- amount = text2num(tgui_input_num(
- usr,
+ amount = text2num(input(
"Enter the amount you want to transfer:",
name, ""))
if (amount == null || amount <= 0)
@@ -257,7 +256,7 @@
// Get amount of items
var/amount = text2num(params["amount"])
if(amount == null)
- amount = text2num(tgui_input_num(usr,
+ amount = text2num(input(usr,
"Max 20. Buffer content will be split evenly.",
"How many to make?", 1))
amount = clamp(round(amount), 0, 20)
@@ -286,7 +285,7 @@
if(vol_each_text == "auto")
vol_each = vol_each_max
if(vol_each == null)
- vol_each = text2num(tgui_input_num(usr,
+ vol_each = text2num(input(usr,
"Maximum [vol_each_max] units per item.",
"How many units to fill?",
vol_each_max))
diff --git a/code/modules/reagents/chemistry/machinery/chem_synthesizer.dm b/code/modules/reagents/chemistry/machinery/chem_synthesizer.dm
index 9644cd36e6..489f9dd179 100644
--- a/code/modules/reagents/chemistry/machinery/chem_synthesizer.dm
+++ b/code/modules/reagents/chemistry/machinery/chem_synthesizer.dm
@@ -30,7 +30,7 @@
beaker = null
. = TRUE
if("input")
- var/input_reagent = replacetext(lowertext(tgui_input_text(usr, "Enter the name of any reagent", "Input")), " ", "") //95% of the time, the reagent id is a lowercase/no spaces version of the name
+ var/input_reagent = replacetext(lowertext(input("Enter the name of any reagent", "Input") as text|null), " ", "") //95% of the time, the reagent id is a lowercase/no spaces version of the name
if (isnull(input_reagent))
return
diff --git a/code/modules/reagents/chemistry/machinery/reagentgrinder.dm b/code/modules/reagents/chemistry/machinery/reagentgrinder.dm
index a53c57a3e7..65cc97f586 100644
--- a/code/modules/reagents/chemistry/machinery/reagentgrinder.dm
+++ b/code/modules/reagents/chemistry/machinery/reagentgrinder.dm
@@ -43,9 +43,9 @@
drop_all_items()
return ..()
-/obj/machinery/reagentgrinder/contents_explosion(severity, target)
+/obj/machinery/reagentgrinder/contents_explosion(severity, target, origin)
if(beaker)
- beaker.ex_act(severity, target)
+ beaker.ex_act(severity, target, origin)
/obj/machinery/reagentgrinder/RefreshParts()
speed = 1
diff --git a/code/modules/reagents/chemistry/reagents.dm b/code/modules/reagents/chemistry/reagents.dm
index d6b7201ef9..154a58cdfd 100644
--- a/code/modules/reagents/chemistry/reagents.dm
+++ b/code/modules/reagents/chemistry/reagents.dm
@@ -1,4 +1,3 @@
-#define REM REAGENTS_EFFECT_MULTIPLIER
GLOBAL_LIST_INIT(name2reagent, build_name2reagent())
/proc/build_name2reagent()
diff --git a/code/modules/reagents/chemistry/reagents/alcohol_reagents.dm b/code/modules/reagents/chemistry/reagents/alcohol_reagents.dm
index 12c91e145a..72112d9a65 100644
--- a/code/modules/reagents/chemistry/reagents/alcohol_reagents.dm
+++ b/code/modules/reagents/chemistry/reagents/alcohol_reagents.dm
@@ -47,7 +47,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
/datum/reagent/consumable/ethanol/on_mob_life(mob/living/carbon/C)
if(HAS_TRAIT(C, TRAIT_TOXIC_ALCOHOL))
- C.adjustToxLoss((boozepwr/25)*REM,forced = TRUE)
+ C.adjustToxLoss((boozepwr/25)*REAGENTS_EFFECT_MULTIPLIER,forced = TRUE)
else if(C.drunkenness < volume * boozepwr * ALCOHOL_THRESHOLD_MODIFIER)
var/booze_power = boozepwr
if(HAS_TRAIT(C, TRAIT_ALCOHOL_TOLERANCE)) //we're an accomplished drinker
@@ -1365,7 +1365,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
/datum/reagent/consumable/ethanol/neurotoxin/on_mob_life(mob/living/carbon/M)
M.set_drugginess(50)
M.dizziness +=2
- M.adjustOrganLoss(ORGAN_SLOT_BRAIN, 1*REM, 150)
+ M.adjustOrganLoss(ORGAN_SLOT_BRAIN, 1*REAGENTS_EFFECT_MULTIPLIER, 150)
if(prob(20) && !holder.has_reagent(/datum/reagent/consumable/ethanol/neuroweak))
M.adjustStaminaLoss(10)
M.drop_all_held_items()
@@ -1376,7 +1376,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
ADD_TRAIT(M, t, type)
M.adjustStaminaLoss(10)
if(current_cycle > 30)
- M.adjustOrganLoss(ORGAN_SLOT_BRAIN, 2*REM)
+ M.adjustOrganLoss(ORGAN_SLOT_BRAIN, 2*REAGENTS_EFFECT_MULTIPLIER)
if(current_cycle > 50 && prob(15))
if(!M.undergoing_cardiac_arrest() && M.can_heartattack())
M.set_heartattack(TRUE)
@@ -1401,13 +1401,13 @@ All effects don't start immediately, but rather get worse over time; the rate is
/datum/reagent/consumable/ethanol/neuroweak/on_mob_life(mob/living/carbon/M)
if(holder.has_reagent(/datum/reagent/consumable/ethanol/neurotoxin))
- M.adjustOrganLoss(ORGAN_SLOT_BRAIN, -1*REM, 150)
+ M.adjustOrganLoss(ORGAN_SLOT_BRAIN, -1*REAGENTS_EFFECT_MULTIPLIER, 150)
M.reagents.remove_reagent(/datum/reagent/consumable/ethanol/neurotoxin, 1.5 * REAGENTS_METABOLISM, FALSE)
else if(holder.has_reagent(/datum/reagent/toxin/fentanyl))
- M.adjustOrganLoss(ORGAN_SLOT_BRAIN, -1*REM, 150)
+ M.adjustOrganLoss(ORGAN_SLOT_BRAIN, -1*REAGENTS_EFFECT_MULTIPLIER, 150)
M.reagents.remove_reagent(/datum/reagent/toxin/fentanyl, 0.75 * REAGENTS_METABOLISM, FALSE)
else
- M.adjustOrganLoss(ORGAN_SLOT_BRAIN, -0.5*REM, 150)
+ M.adjustOrganLoss(ORGAN_SLOT_BRAIN, -0.5*REAGENTS_EFFECT_MULTIPLIER, 150)
M.dizziness +=2
..()
@@ -1925,7 +1925,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
/datum/reagent/consumable/ethanol/fernet/on_mob_life(mob/living/carbon/M)
if(M.nutrition <= NUTRITION_LEVEL_STARVING)
- M.adjustToxLoss(1*REM, 0)
+ M.adjustToxLoss(1*REAGENTS_EFFECT_MULTIPLIER, 0)
M.adjust_nutrition(-5)
M.overeatduration = 0
return ..()
@@ -1943,7 +1943,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
/datum/reagent/consumable/ethanol/fernet_cola/on_mob_life(mob/living/carbon/M)
if(M.nutrition <= NUTRITION_LEVEL_STARVING)
- M.adjustToxLoss(0.5*REM, 0)
+ M.adjustToxLoss(0.5*REAGENTS_EFFECT_MULTIPLIER, 0)
M.adjust_nutrition(-3)
M.overeatduration = 0
return ..()
diff --git a/code/modules/reagents/chemistry/reagents/drink_reagents.dm b/code/modules/reagents/chemistry/reagents/drink_reagents.dm
index 5059376954..4376805e2c 100644
--- a/code/modules/reagents/chemistry/reagents/drink_reagents.dm
+++ b/code/modules/reagents/chemistry/reagents/drink_reagents.dm
@@ -47,7 +47,7 @@
/datum/reagent/consumable/limejuice/on_mob_life(mob/living/carbon/M)
if(M.getToxLoss() && prob(20))
- M.adjustToxLoss(-1*REM, 0)
+ M.adjustToxLoss(-1*REAGENTS_EFFECT_MULTIPLIER, 0)
. = 1
..()
diff --git a/code/modules/reagents/chemistry/reagents/drug_reagents.dm b/code/modules/reagents/chemistry/reagents/drug_reagents.dm
index ed80804f28..4848347df2 100644
--- a/code/modules/reagents/chemistry/reagents/drug_reagents.dm
+++ b/code/modules/reagents/chemistry/reagents/drug_reagents.dm
@@ -59,7 +59,7 @@
SEND_SIGNAL(M, COMSIG_ADD_MOOD_EVENT, "smoked", /datum/mood_event/smoked, name)
M.AdjustAllImmobility(-20, 0)
M.AdjustUnconscious(-20, 0)
- M.adjustStaminaLoss(-0.5*REM, 0)
+ M.adjustStaminaLoss(-0.5*REAGENTS_EFFECT_MULTIPLIER, 0)
..()
. = 1
@@ -83,30 +83,30 @@
. = 1
/datum/reagent/drug/crank/overdose_process(mob/living/M)
- M.adjustOrganLoss(ORGAN_SLOT_BRAIN, 2*REM)
- M.adjustToxLoss(2*REM, 0)
- M.adjustBruteLoss(2*REM, 0)
+ M.adjustOrganLoss(ORGAN_SLOT_BRAIN, 2*REAGENTS_EFFECT_MULTIPLIER)
+ M.adjustToxLoss(2*REAGENTS_EFFECT_MULTIPLIER, 0)
+ M.adjustBruteLoss(2*REAGENTS_EFFECT_MULTIPLIER, 0)
..()
. = 1
/datum/reagent/drug/crank/addiction_act_stage1(mob/living/M)
- M.adjustOrganLoss(ORGAN_SLOT_BRAIN, 5*REM)
+ M.adjustOrganLoss(ORGAN_SLOT_BRAIN, 5*REAGENTS_EFFECT_MULTIPLIER)
..()
/datum/reagent/drug/crank/addiction_act_stage2(mob/living/M)
- M.adjustToxLoss(5*REM, 0)
+ M.adjustToxLoss(5*REAGENTS_EFFECT_MULTIPLIER, 0)
..()
. = 1
/datum/reagent/drug/crank/addiction_act_stage3(mob/living/M)
- M.adjustBruteLoss(5*REM, 0)
+ M.adjustBruteLoss(5*REAGENTS_EFFECT_MULTIPLIER, 0)
..()
. = 1
/datum/reagent/drug/crank/addiction_act_stage4(mob/living/M)
- M.adjustOrganLoss(ORGAN_SLOT_BRAIN, 3*REM)
- M.adjustToxLoss(5*REM, 0)
- M.adjustBruteLoss(5*REM, 0)
+ M.adjustOrganLoss(ORGAN_SLOT_BRAIN, 3*REAGENTS_EFFECT_MULTIPLIER)
+ M.adjustToxLoss(5*REAGENTS_EFFECT_MULTIPLIER, 0)
+ M.adjustBruteLoss(5*REAGENTS_EFFECT_MULTIPLIER, 0)
..()
. = 1
@@ -128,14 +128,14 @@
..()
/datum/reagent/drug/krokodil/overdose_process(mob/living/M)
- M.adjustOrganLoss(ORGAN_SLOT_BRAIN, 0.25*REM)
- M.adjustToxLoss(0.25*REM, 0)
+ M.adjustOrganLoss(ORGAN_SLOT_BRAIN, 0.25*REAGENTS_EFFECT_MULTIPLIER)
+ M.adjustToxLoss(0.25*REAGENTS_EFFECT_MULTIPLIER, 0)
..()
. = 1
/datum/reagent/drug/krokodil/addiction_act_stage1(mob/living/M)
- M.adjustOrganLoss(ORGAN_SLOT_BRAIN, 2*REM)
- M.adjustToxLoss(2*REM, 0)
+ M.adjustOrganLoss(ORGAN_SLOT_BRAIN, 2*REAGENTS_EFFECT_MULTIPLIER)
+ M.adjustToxLoss(2*REAGENTS_EFFECT_MULTIPLIER, 0)
..()
. = 1
@@ -147,7 +147,7 @@
/datum/reagent/drug/krokodil/addiction_act_stage3(mob/living/M)
if(prob(25))
to_chat(M, "Your skin starts to peel away...")
- M.adjustBruteLoss(3*REM, 0)
+ M.adjustBruteLoss(3*REAGENTS_EFFECT_MULTIPLIER, 0)
..()
. = 1
@@ -155,10 +155,10 @@
CHECK_DNA_AND_SPECIES(M)
if(!istype(M.dna.species, /datum/species/krokodil_addict))
to_chat(M, "Your skin falls off easily!")
- M.adjustBruteLoss(50*REM, 0) // holy shit your skin just FELL THE FUCK OFF
+ M.adjustBruteLoss(50*REAGENTS_EFFECT_MULTIPLIER, 0) // holy shit your skin just FELL THE FUCK OFF
M.set_species(/datum/species/krokodil_addict)
else
- M.adjustBruteLoss(5*REM, 0)
+ M.adjustBruteLoss(5*REAGENTS_EFFECT_MULTIPLIER, 0)
..()
. = 1
@@ -186,14 +186,14 @@
if(DT_PROB(2.5, delta_time))
to_chat(M, span_notice("[high_message]"))
// SEND_SIGNAL(M, COMSIG_ADD_MOOD_EVENT, "tweaking", /datum/mood_event/stimulant_medium, name)
- M.AdjustStun(-40 * REM * delta_time)
- M.AdjustKnockdown(-40 * REM * delta_time)
- M.AdjustUnconscious(-40 * REM * delta_time)
- M.AdjustParalyzed(-40 * REM * delta_time)
- M.AdjustImmobilized(-40 * REM * delta_time)
- M.adjustStaminaLoss(-2 * REM * delta_time, 0)
- M.Jitter(2 * REM * delta_time)
- M.adjustOrganLoss(ORGAN_SLOT_BRAIN, rand(1, 4) * REM * delta_time)
+ M.AdjustStun(-40 * REAGENTS_EFFECT_MULTIPLIER * delta_time)
+ M.AdjustKnockdown(-40 * REAGENTS_EFFECT_MULTIPLIER * delta_time)
+ M.AdjustUnconscious(-40 * REAGENTS_EFFECT_MULTIPLIER * delta_time)
+ M.AdjustParalyzed(-40 * REAGENTS_EFFECT_MULTIPLIER * delta_time)
+ M.AdjustImmobilized(-40 * REAGENTS_EFFECT_MULTIPLIER * delta_time)
+ M.adjustStaminaLoss(-2 * REAGENTS_EFFECT_MULTIPLIER * delta_time, 0)
+ M.Jitter(2 * REAGENTS_EFFECT_MULTIPLIER * delta_time)
+ M.adjustOrganLoss(ORGAN_SLOT_BRAIN, rand(1, 4) * REAGENTS_EFFECT_MULTIPLIER * delta_time)
if(DT_PROB(2.5, delta_time))
M.emote(pick("twitch", "shiver"))
..()
@@ -201,7 +201,7 @@
/datum/reagent/drug/methamphetamine/overdose_process(mob/living/M, delta_time, times_fired)
if(CHECK_MOBILITY(M, MOBILITY_MOVE) && !ismovable(M.loc))
- for(var/i in 1 to round(4 * REM * delta_time, 1))
+ for(var/i in 1 to round(4 * REAGENTS_EFFECT_MULTIPLIER * delta_time, 1))
step(M, pick(GLOB.cardinals))
if(DT_PROB(10, delta_time))
M.emote("laugh")
@@ -209,8 +209,8 @@
M.visible_message(span_danger("[M]'s hands flip out and flail everywhere!"))
M.drop_all_held_items()
..()
- M.adjustToxLoss(1 * REM * delta_time, 0)
- M.adjustOrganLoss(ORGAN_SLOT_BRAIN, (rand(5, 10) / 10) * REM * delta_time)
+ M.adjustToxLoss(1 * REAGENTS_EFFECT_MULTIPLIER * delta_time, 0)
+ M.adjustOrganLoss(ORGAN_SLOT_BRAIN, (rand(5, 10) / 10) * REAGENTS_EFFECT_MULTIPLIER * delta_time)
. = TRUE
/datum/reagent/drug/methamphetamine/addiction_act_stage1(mob/living/M)
@@ -486,8 +486,8 @@
H.dna.species.punchstunthreshold += 2
/datum/reagent/drug/skooma/on_mob_life(mob/living/carbon/M)
- M.adjustOrganLoss(ORGAN_SLOT_BRAIN, 1*REM)
- M.adjustToxLoss(1*REM)
+ M.adjustOrganLoss(ORGAN_SLOT_BRAIN, 1*REAGENTS_EFFECT_MULTIPLIER)
+ M.adjustToxLoss(1*REAGENTS_EFFECT_MULTIPLIER)
if(prob(10))
M.adjust_blurriness(2)
..()
@@ -531,7 +531,7 @@
value = REAGENT_VALUE_VERY_RARE
/datum/reagent/syndicateadrenals/on_mob_life(mob/living/M)
- M.adjustStaminaLoss(-5*REM)
+ M.adjustStaminaLoss(-5*REAGENTS_EFFECT_MULTIPLIER)
. = ..()
/datum/reagent/syndicateadrenals/on_mob_metabolize(mob/living/M)
diff --git a/code/modules/reagents/chemistry/reagents/food_reagents.dm b/code/modules/reagents/chemistry/reagents/food_reagents.dm
index 02b19909b0..85836ffdf3 100644
--- a/code/modules/reagents/chemistry/reagents/food_reagents.dm
+++ b/code/modules/reagents/chemistry/reagents/food_reagents.dm
@@ -658,10 +658,10 @@
/datum/reagent/consumable/honey/on_mob_life(mob/living/carbon/M)
M.reagents.add_reagent(/datum/reagent/consumable/sugar,3)
if(prob(55))
- M.adjustBruteLoss(-1*REM, 0)
- M.adjustFireLoss(-1*REM, 0)
- M.adjustOxyLoss(-1*REM, 0)
- M.adjustToxLoss(-1*REM, 0, TRUE) //heals TOXINLOVERs
+ M.adjustBruteLoss(-1*REAGENTS_EFFECT_MULTIPLIER, 0)
+ M.adjustFireLoss(-1*REAGENTS_EFFECT_MULTIPLIER, 0)
+ M.adjustOxyLoss(-1*REAGENTS_EFFECT_MULTIPLIER, 0)
+ M.adjustToxLoss(-1*REAGENTS_EFFECT_MULTIPLIER, 0, TRUE) //heals TOXINLOVERs
..()
/datum/reagent/consumable/honey/reaction_mob(mob/living/M, method=TOUCH, reac_volume)
@@ -746,9 +746,9 @@
. = 1
if(prob(20))
M.losebreath += 4
- M.adjustOrganLoss(ORGAN_SLOT_BRAIN, 2*REM, 150)
- M.adjustToxLoss(3*REM,0)
- M.adjustStaminaLoss(10*REM,0)
+ M.adjustOrganLoss(ORGAN_SLOT_BRAIN, 2*REAGENTS_EFFECT_MULTIPLIER, 150)
+ M.adjustToxLoss(3*REAGENTS_EFFECT_MULTIPLIER,0)
+ M.adjustStaminaLoss(10*REAGENTS_EFFECT_MULTIPLIER,0)
M.blur_eyes(5)
. = TRUE
..()
@@ -778,8 +778,8 @@
/datum/reagent/consumable/vitfro/on_mob_life(mob/living/carbon/M)
if(prob(80))
- M.adjustBruteLoss(-1*REM, 0)
- M.adjustFireLoss(-1*REM, 0)
+ M.adjustBruteLoss(-1*REAGENTS_EFFECT_MULTIPLIER, 0)
+ M.adjustFireLoss(-1*REAGENTS_EFFECT_MULTIPLIER, 0)
. = TRUE
..()
@@ -804,7 +804,7 @@
var/mob/living/carbon/C = M
var/obj/item/organ/stomach/ethereal/stomach = C.getorganslot(ORGAN_SLOT_STOMACH)
if(istype(stomach))
- stomach.adjust_charge(reac_volume * REM)
+ stomach.adjust_charge(reac_volume * REAGENTS_EFFECT_MULTIPLIER)
/datum/reagent/consumable/liquidelectricity/on_mob_life(mob/living/carbon/M)
if(prob(25) && !isethereal(M))
diff --git a/code/modules/reagents/chemistry/reagents/medicine_reagents.dm b/code/modules/reagents/chemistry/reagents/medicine_reagents.dm
index 72a9779726..e1f8d5366c 100644
--- a/code/modules/reagents/chemistry/reagents/medicine_reagents.dm
+++ b/code/modules/reagents/chemistry/reagents/medicine_reagents.dm
@@ -56,7 +56,7 @@
mytray.visible_message("Nothing happens...")
/datum/reagent/medicine/adminordrazine/on_mob_life(mob/living/carbon/M)
- M.reagents.remove_all_type(/datum/reagent/toxin, 5*REM, 0, 1)
+ M.reagents.remove_all_type(/datum/reagent/toxin, 5*REAGENTS_EFFECT_MULTIPLIER, 0, 1)
M.setCloneLoss(0, 0)
M.setOxyLoss(0, 0)
M.radiation = 0
@@ -299,7 +299,7 @@
..()
/datum/reagent/medicine/silver_sulfadiazine/on_mob_life(mob/living/carbon/M)
- M.adjustFireLoss(-2*REM, 0)
+ M.adjustFireLoss(-2*REAGENTS_EFFECT_MULTIPLIER, 0)
..()
. = 1
@@ -309,7 +309,7 @@
. = 1
/datum/reagent/medicine/silver_sulfadiazine/overdose_process(mob/living/M)
- M.adjustFireLoss(2*REM, 0)
+ M.adjustFireLoss(2*REAGENTS_EFFECT_MULTIPLIER, 0)
var/obj/item/organ/liver/L = M.getorganslot(ORGAN_SLOT_LIVER)
if(L)
L.applyOrganDamage(1)
@@ -328,15 +328,15 @@
/datum/reagent/medicine/oxandrolone/on_mob_life(mob/living/carbon/M)
if(M.getFireLoss() > 25)
- M.adjustFireLoss(-4*REM, 0) //Twice as effective as silver sulfadiazine for severe burns
+ M.adjustFireLoss(-4*REAGENTS_EFFECT_MULTIPLIER, 0) //Twice as effective as silver sulfadiazine for severe burns
else
- M.adjustFireLoss(-0.5*REM, 0) //But only a quarter as effective for more minor ones
+ M.adjustFireLoss(-0.5*REAGENTS_EFFECT_MULTIPLIER, 0) //But only a quarter as effective for more minor ones
..()
. = 1
/datum/reagent/medicine/oxandrolone/overdose_process(mob/living/M)
if(M.getFireLoss()) //It only makes existing burns worse
- M.adjustFireLoss(4.5*REM, 0) // it's going to be healing either 4 or 0.5
+ M.adjustFireLoss(4.5*REAGENTS_EFFECT_MULTIPLIER, 0) // it's going to be healing either 4 or 0.5
. = 1
..()
@@ -371,7 +371,7 @@
G.use(reac_volume)
/datum/reagent/medicine/styptic_powder/on_mob_life(mob/living/carbon/M)
- M.adjustBruteLoss(-2*REM, 0)
+ M.adjustBruteLoss(-2*REAGENTS_EFFECT_MULTIPLIER, 0)
..()
. = 1
@@ -381,7 +381,7 @@
. = 1
/datum/reagent/medicine/styptic_powder/overdose_process(mob/living/M)
- M.adjustBruteLoss(2*REM, 0)
+ M.adjustBruteLoss(2*REAGENTS_EFFECT_MULTIPLIER, 0)
var/obj/item/organ/liver/L = M.getorganslot(ORGAN_SLOT_LIVER)
if(L)
L.applyOrganDamage(1)
@@ -403,8 +403,8 @@
/datum/reagent/medicine/salglu_solution/on_mob_life(mob/living/carbon/human/M)
if(prob(33))
- M.adjustBruteLoss(-0.5*REM, 0)
- M.adjustFireLoss(-0.5*REM, 0)
+ M.adjustBruteLoss(-0.5*REAGENTS_EFFECT_MULTIPLIER, 0)
+ M.adjustFireLoss(-0.5*REAGENTS_EFFECT_MULTIPLIER, 0)
. = TRUE
if((HAS_TRAIT(M, TRAIT_NOMARROW)))
return ..()
@@ -414,10 +414,10 @@
if(M.functional_blood() < maximum_reachable) //Can only up to double your effective blood level.
var/new_blood_level = min(volume * 5, maximum_reachable)
last_added = new_blood_level
- M.adjust_integration_blood(new_blood_level + (extra_regen * REM))
+ M.adjust_integration_blood(new_blood_level + (extra_regen * REAGENTS_EFFECT_MULTIPLIER))
if(prob(33))
- M.adjustBruteLoss(-0.5*REM, 0)
- M.adjustFireLoss(-0.5*REM, 0)
+ M.adjustBruteLoss(-0.5*REAGENTS_EFFECT_MULTIPLIER, 0)
+ M.adjustFireLoss(-0.5*REAGENTS_EFFECT_MULTIPLIER, 0)
. = TRUE
..()
@@ -436,8 +436,8 @@
holder.add_reagent(/datum/reagent/consumable/sugar, 1)
holder.remove_reagent(/datum/reagent/medicine/salglu_solution, 0.5)
if(prob(33))
- M.adjustBruteLoss(0.5*REM, 0)
- M.adjustFireLoss(0.5*REM, 0)
+ M.adjustBruteLoss(0.5*REAGENTS_EFFECT_MULTIPLIER, 0)
+ M.adjustFireLoss(0.5*REAGENTS_EFFECT_MULTIPLIER, 0)
. = TRUE
..()
@@ -452,9 +452,9 @@
/datum/reagent/medicine/mine_salve/on_mob_life(mob/living/carbon/C)
C.hal_screwyhud = SCREWYHUD_HEALTHY
- C.adjustBruteLoss(-0.25*REM, 0)
- C.adjustFireLoss(-0.25*REM, 0)
- C.adjustStaminaLoss(-0.5*REM, 0)
+ C.adjustBruteLoss(-0.25*REAGENTS_EFFECT_MULTIPLIER, 0)
+ C.adjustFireLoss(-0.25*REAGENTS_EFFECT_MULTIPLIER, 0)
+ C.adjustStaminaLoss(-0.5*REAGENTS_EFFECT_MULTIPLIER, 0)
..()
return TRUE
@@ -531,7 +531,7 @@
pH = 5
/datum/reagent/medicine/charcoal/on_mob_life(mob/living/carbon/M)
- M.adjustToxLoss(-2*REM, 0)
+ M.adjustToxLoss(-2*REAGENTS_EFFECT_MULTIPLIER, 0)
. = 1
for(var/A in M.reagents.reagent_list)
var/datum/reagent/R = A
@@ -551,18 +551,18 @@
var/healing = 0.5
/datum/reagent/medicine/omnizine/on_mob_life(mob/living/carbon/M)
- M.adjustToxLoss(-healing*REM, 0)
- M.adjustOxyLoss(-healing*REM, 0)
- M.adjustBruteLoss(-healing*REM, 0)
- M.adjustFireLoss(-healing*REM, 0)
+ M.adjustToxLoss(-healing*REAGENTS_EFFECT_MULTIPLIER, 0)
+ M.adjustOxyLoss(-healing*REAGENTS_EFFECT_MULTIPLIER, 0)
+ M.adjustBruteLoss(-healing*REAGENTS_EFFECT_MULTIPLIER, 0)
+ M.adjustFireLoss(-healing*REAGENTS_EFFECT_MULTIPLIER, 0)
..()
. = 1
/datum/reagent/medicine/omnizine/overdose_process(mob/living/M)
- M.adjustToxLoss(1.5*REM, 0)
- M.adjustOxyLoss(1.5*REM, 0)
- M.adjustBruteLoss(1.5*REM, 0)
- M.adjustFireLoss(1.5*REM, 0)
+ M.adjustToxLoss(1.5*REAGENTS_EFFECT_MULTIPLIER, 0)
+ M.adjustOxyLoss(1.5*REAGENTS_EFFECT_MULTIPLIER, 0)
+ M.adjustBruteLoss(1.5*REAGENTS_EFFECT_MULTIPLIER, 0)
+ M.adjustFireLoss(1.5*REAGENTS_EFFECT_MULTIPLIER, 0)
..()
. = 1
@@ -587,7 +587,7 @@
if(R != src)
M.reagents.remove_reagent(R.type,2.5)
if(M.health > 20)
- M.adjustToxLoss(2.5*REM, 0)
+ M.adjustToxLoss(2.5*REAGENTS_EFFECT_MULTIPLIER, 0)
. = 1
..()
@@ -630,7 +630,7 @@
/datum/reagent/medicine/pen_acid/on_mob_life(mob/living/carbon/M)
M.radiation -= max(M.radiation-RAD_MOB_SAFE, 0)/50
- M.adjustToxLoss(-2*REM, 0, healtoxinlover)
+ M.adjustToxLoss(-2*REAGENTS_EFFECT_MULTIPLIER, 0, healtoxinlover)
for(var/A in M.reagents.reagent_list)
var/datum/reagent/R = A
if(R != src)
@@ -659,15 +659,15 @@
/datum/reagent/medicine/sal_acid/on_mob_life(mob/living/carbon/M)
if(M.getBruteLoss() > 25)
- M.adjustBruteLoss(-4*REM, 0) //Twice as effective as styptic powder for severe bruising
+ M.adjustBruteLoss(-4*REAGENTS_EFFECT_MULTIPLIER, 0) //Twice as effective as styptic powder for severe bruising
else
- M.adjustBruteLoss(-0.5*REM, 0) //But only a quarter as effective for more minor ones
+ M.adjustBruteLoss(-0.5*REAGENTS_EFFECT_MULTIPLIER, 0) //But only a quarter as effective for more minor ones
..()
. = 1
/datum/reagent/medicine/sal_acid/overdose_process(mob/living/M)
if(M.getBruteLoss()) //It only makes existing bruises worse
- M.adjustBruteLoss(4.5*REM, 0) // it's going to be healing either 4 or 0.5
+ M.adjustBruteLoss(4.5*REAGENTS_EFFECT_MULTIPLIER, 0) // it's going to be healing either 4 or 0.5
. = 1
..()
@@ -680,7 +680,7 @@
pH = 2
/datum/reagent/medicine/salbutamol/on_mob_life(mob/living/carbon/M)
- M.adjustOxyLoss(-3*REM, 0)
+ M.adjustOxyLoss(-3*REAGENTS_EFFECT_MULTIPLIER, 0)
if(M.losebreath >= 4)
M.losebreath -= 2
M.Jitter(5)
@@ -696,11 +696,11 @@
pH = 11
/datum/reagent/medicine/perfluorodecalin/on_mob_life(mob/living/carbon/human/M)
- M.adjustOxyLoss(-12*REM, 0)
+ M.adjustOxyLoss(-12*REAGENTS_EFFECT_MULTIPLIER, 0)
M.silent = max(M.silent, 5)
if(prob(33))
- M.adjustBruteLoss(-0.5*REM, 0)
- M.adjustFireLoss(-0.5*REM, 0)
+ M.adjustBruteLoss(-0.5*REAGENTS_EFFECT_MULTIPLIER, 0)
+ M.adjustFireLoss(-0.5*REAGENTS_EFFECT_MULTIPLIER, 0)
..()
return TRUE
@@ -731,8 +731,8 @@
// to_chat(M, span_notice("Your hands spaz out and you drop what you were holding!"))
// M.Jitter(10)
- M.AdjustAllImmobility(-20 * REM * delta_time)
- M.adjustStaminaLoss(-1 * REM * delta_time, FALSE)
+ M.AdjustAllImmobility(-20 * REAGENTS_EFFECT_MULTIPLIER * delta_time)
+ M.adjustStaminaLoss(-1 * REAGENTS_EFFECT_MULTIPLIER * delta_time, FALSE)
..()
return TRUE
@@ -754,28 +754,28 @@
/datum/reagent/medicine/ephedrine/addiction_act_stage1(mob/living/M)
if(prob(33))
- M.adjustToxLoss(2*REM, 0)
+ M.adjustToxLoss(2*REAGENTS_EFFECT_MULTIPLIER, 0)
M.losebreath += 2
. = 1
..()
/datum/reagent/medicine/ephedrine/addiction_act_stage2(mob/living/M)
if(prob(33))
- M.adjustToxLoss(3*REM, 0)
+ M.adjustToxLoss(3*REAGENTS_EFFECT_MULTIPLIER, 0)
M.losebreath += 3
. = 1
..()
/datum/reagent/medicine/ephedrine/addiction_act_stage3(mob/living/M)
if(prob(33))
- M.adjustToxLoss(4*REM, 0)
+ M.adjustToxLoss(4*REAGENTS_EFFECT_MULTIPLIER, 0)
M.losebreath += 4
. = 1
..()
/datum/reagent/medicine/ephedrine/addiction_act_stage4(mob/living/M)
if(prob(33))
- M.adjustToxLoss(5*REM, 0)
+ M.adjustToxLoss(5*REAGENTS_EFFECT_MULTIPLIER, 0)
M.losebreath += 5
. = 1
..()
@@ -841,7 +841,7 @@
/datum/reagent/medicine/morphine/addiction_act_stage2(mob/living/M)
if(prob(33))
M.drop_all_held_items()
- M.adjustToxLoss(1*REM, 0)
+ M.adjustToxLoss(1*REAGENTS_EFFECT_MULTIPLIER, 0)
. = 1
M.Dizzy(3)
M.Jitter(3)
@@ -850,7 +850,7 @@
/datum/reagent/medicine/morphine/addiction_act_stage3(mob/living/M)
if(prob(33))
M.drop_all_held_items()
- M.adjustToxLoss(2*REM, 0)
+ M.adjustToxLoss(2*REAGENTS_EFFECT_MULTIPLIER, 0)
. = 1
M.Dizzy(4)
M.Jitter(4)
@@ -859,7 +859,7 @@
/datum/reagent/medicine/morphine/addiction_act_stage4(mob/living/M)
if(prob(33))
M.drop_all_held_items()
- M.adjustToxLoss(3*REM, 0)
+ M.adjustToxLoss(3*REAGENTS_EFFECT_MULTIPLIER, 0)
. = 1
M.Dizzy(5)
M.Jitter(5)
@@ -907,10 +907,10 @@
/datum/reagent/medicine/atropine/on_mob_life(mob/living/carbon/M)
if(M.health < 0)
- M.adjustToxLoss(-2*REM, 0)
- M.adjustBruteLoss(-2*REM, 0)
- M.adjustFireLoss(-2*REM, 0)
- M.adjustOxyLoss(-5*REM, 0)
+ M.adjustToxLoss(-2*REAGENTS_EFFECT_MULTIPLIER, 0)
+ M.adjustBruteLoss(-2*REAGENTS_EFFECT_MULTIPLIER, 0)
+ M.adjustFireLoss(-2*REAGENTS_EFFECT_MULTIPLIER, 0)
+ M.adjustOxyLoss(-5*REAGENTS_EFFECT_MULTIPLIER, 0)
. = 1
M.losebreath = 0
if(prob(20))
@@ -919,7 +919,7 @@
..()
/datum/reagent/medicine/atropine/overdose_process(mob/living/M)
- M.adjustToxLoss(0.5*REM, 0)
+ M.adjustToxLoss(0.5*REAGENTS_EFFECT_MULTIPLIER, 0)
. = 1
M.Dizzy(1)
M.Jitter(1)
@@ -936,16 +936,16 @@
/datum/reagent/medicine/epinephrine/on_mob_life(mob/living/carbon/M)
if(M.health < 0)
- M.adjustToxLoss(-0.5*REM, 0)
- M.adjustBruteLoss(-0.5*REM, 0)
- M.adjustFireLoss(-0.5*REM, 0)
+ M.adjustToxLoss(-0.5*REAGENTS_EFFECT_MULTIPLIER, 0)
+ M.adjustBruteLoss(-0.5*REAGENTS_EFFECT_MULTIPLIER, 0)
+ M.adjustFireLoss(-0.5*REAGENTS_EFFECT_MULTIPLIER, 0)
if(M.oxyloss > 35)
M.setOxyLoss(35, 0)
if(M.losebreath >= 4)
M.losebreath -= 2
if(M.losebreath < 0)
M.losebreath = 0
- M.adjustStaminaLoss(-0.5*REM, 0)
+ M.adjustStaminaLoss(-0.5*REAGENTS_EFFECT_MULTIPLIER, 0)
. = 1
if(prob(20))
M.AdjustAllImmobility(-20, 0)
@@ -954,8 +954,8 @@
/datum/reagent/medicine/epinephrine/overdose_process(mob/living/M)
if(prob(33))
- M.adjustStaminaLoss(2.5*REM, 0)
- M.adjustToxLoss(1*REM, 0)
+ M.adjustStaminaLoss(2.5*REAGENTS_EFFECT_MULTIPLIER, 0)
+ M.adjustToxLoss(1*REAGENTS_EFFECT_MULTIPLIER, 0)
M.losebreath++
. = 1
..()
@@ -1021,8 +1021,8 @@
/datum/reagent/medicine/strange_reagent/on_mob_life(mob/living/carbon/M)
- M.adjustBruteLoss(0.5*REM, 0)
- M.adjustFireLoss(0.5*REM, 0)
+ M.adjustBruteLoss(0.5*REAGENTS_EFFECT_MULTIPLIER, 0)
+ M.adjustFireLoss(0.5*REAGENTS_EFFECT_MULTIPLIER, 0)
..()
. = 1
@@ -1033,7 +1033,7 @@
pH = 10.4
/datum/reagent/medicine/mannitol/on_mob_life(mob/living/carbon/C)
- C.adjustOrganLoss(ORGAN_SLOT_BRAIN, -2*REM)
+ C.adjustOrganLoss(ORGAN_SLOT_BRAIN, -2*REAGENTS_EFFECT_MULTIPLIER)
if(prob(10))
C.cure_trauma_type(resilience = TRAUMA_RESILIENCE_BASIC)
..()
@@ -1091,8 +1091,8 @@
M.drowsyness = 0
M.slurring = 0
M.confused = 0
- M.reagents.remove_all_type(/datum/reagent/consumable/ethanol, 3*REM, 0, 1)
- M.adjustToxLoss(-0.2*REM, 0)
+ M.reagents.remove_all_type(/datum/reagent/consumable/ethanol, 3*REAGENTS_EFFECT_MULTIPLIER, 0, 1)
+ M.adjustToxLoss(-0.2*REAGENTS_EFFECT_MULTIPLIER, 0)
if(ishuman(M))
var/mob/living/carbon/human/H = M
H.drunkenness = max(H.drunkenness - 10, 0)
@@ -1120,20 +1120,20 @@
/datum/reagent/medicine/stimulants/on_mob_life(mob/living/carbon/M)
if(M.health < 50 && M.health > 0)
- M.adjustOxyLoss(-1*REM, FALSE)
- M.adjustToxLoss(-1*REM, FALSE)
- M.adjustBruteLoss(-1*REM, FALSE)
- M.adjustFireLoss(-1*REM, FALSE)
+ M.adjustOxyLoss(-1*REAGENTS_EFFECT_MULTIPLIER, FALSE)
+ M.adjustToxLoss(-1*REAGENTS_EFFECT_MULTIPLIER, FALSE)
+ M.adjustBruteLoss(-1*REAGENTS_EFFECT_MULTIPLIER, FALSE)
+ M.adjustFireLoss(-1*REAGENTS_EFFECT_MULTIPLIER, FALSE)
M.AdjustAllImmobility(-60, FALSE)
M.AdjustUnconscious(-60, FALSE)
- M.adjustStaminaLoss(-20*REM, FALSE)
+ M.adjustStaminaLoss(-20*REAGENTS_EFFECT_MULTIPLIER, FALSE)
..()
. = 1
/datum/reagent/medicine/stimulants/overdose_process(mob/living/M)
if(prob(33))
- M.adjustStaminaLoss(2.5*REM, FALSE)
- M.adjustToxLoss(1*REM, FALSE)
+ M.adjustStaminaLoss(2.5*REAGENTS_EFFECT_MULTIPLIER, FALSE)
+ M.adjustToxLoss(1*REAGENTS_EFFECT_MULTIPLIER, FALSE)
M.losebreath++
. = 1
..()
@@ -1162,12 +1162,12 @@
pH = 5
/datum/reagent/medicine/bicaridine/on_mob_life(mob/living/carbon/M)
- M.adjustBruteLoss(-2*REM, FALSE)
+ M.adjustBruteLoss(-2*REAGENTS_EFFECT_MULTIPLIER, FALSE)
..()
. = 1
/datum/reagent/medicine/bicaridine/overdose_process(mob/living/M)
- M.adjustBruteLoss(4*REM, FALSE)
+ M.adjustBruteLoss(4*REAGENTS_EFFECT_MULTIPLIER, FALSE)
..()
. = 1
@@ -1180,12 +1180,12 @@
pH = 9.7
/datum/reagent/medicine/dexalin/on_mob_life(mob/living/carbon/M)
- M.adjustOxyLoss(-2*REM, FALSE)
+ M.adjustOxyLoss(-2*REAGENTS_EFFECT_MULTIPLIER, FALSE)
..()
. = 1
/datum/reagent/medicine/dexalin/overdose_process(mob/living/M)
- M.adjustOxyLoss(4*REM, FALSE)
+ M.adjustOxyLoss(4*REAGENTS_EFFECT_MULTIPLIER, FALSE)
..()
. = 1
@@ -1198,12 +1198,12 @@
pH = 9
/datum/reagent/medicine/kelotane/on_mob_life(mob/living/carbon/M)
- M.adjustFireLoss(-2*REM, FALSE)
+ M.adjustFireLoss(-2*REAGENTS_EFFECT_MULTIPLIER, FALSE)
..()
. = 1
/datum/reagent/medicine/kelotane/overdose_process(mob/living/M)
- M.adjustFireLoss(4*REM, FALSE)
+ M.adjustFireLoss(4*REAGENTS_EFFECT_MULTIPLIER, FALSE)
..()
. = 1
@@ -1217,14 +1217,14 @@
pH = 10
/datum/reagent/medicine/antitoxin/on_mob_life(mob/living/carbon/M)
- M.adjustToxLoss(-2*REM, FALSE)
+ M.adjustToxLoss(-2*REAGENTS_EFFECT_MULTIPLIER, FALSE)
for(var/datum/reagent/toxin/R in M.reagents.reagent_list)
M.reagents.remove_reagent(R.type,1)
..()
. = 1
/datum/reagent/medicine/antitoxin/overdose_process(mob/living/M)
- M.adjustToxLoss(4*REM, FALSE) // End result is 2 toxin loss taken, because it heals 2 and then removes 4.
+ M.adjustToxLoss(4*REAGENTS_EFFECT_MULTIPLIER, FALSE) // End result is 2 toxin loss taken, because it heals 2 and then removes 4.
..()
. = 1
@@ -1255,18 +1255,18 @@
/datum/reagent/medicine/tricordrazine/on_mob_life(mob/living/carbon/M)
if(prob(80))
- M.adjustBruteLoss(-1*REM, FALSE)
- M.adjustFireLoss(-1*REM, FALSE)
- M.adjustOxyLoss(-1*REM, FALSE)
- M.adjustToxLoss(-1*REM, FALSE)
+ M.adjustBruteLoss(-1*REAGENTS_EFFECT_MULTIPLIER, FALSE)
+ M.adjustFireLoss(-1*REAGENTS_EFFECT_MULTIPLIER, FALSE)
+ M.adjustOxyLoss(-1*REAGENTS_EFFECT_MULTIPLIER, FALSE)
+ M.adjustToxLoss(-1*REAGENTS_EFFECT_MULTIPLIER, FALSE)
. = 1
..()
/datum/reagent/medicine/tricordrazine/overdose_process(mob/living/M)
- M.adjustToxLoss(2*REM, FALSE)
- M.adjustOxyLoss(2*REM, FALSE)
- M.adjustBruteLoss(2*REM, FALSE)
- M.adjustFireLoss(2*REM, FALSE)
+ M.adjustToxLoss(2*REAGENTS_EFFECT_MULTIPLIER, FALSE)
+ M.adjustOxyLoss(2*REAGENTS_EFFECT_MULTIPLIER, FALSE)
+ M.adjustBruteLoss(2*REAGENTS_EFFECT_MULTIPLIER, FALSE)
+ M.adjustFireLoss(2*REAGENTS_EFFECT_MULTIPLIER, FALSE)
..()
. = 1
@@ -1279,10 +1279,10 @@
value = REAGENT_VALUE_COMMON
/datum/reagent/medicine/regen_jelly/on_mob_life(mob/living/carbon/M)
- M.adjustBruteLoss(-1.5*REM, FALSE)
- M.adjustFireLoss(-1.5*REM, FALSE)
- M.adjustOxyLoss(-1.5*REM, FALSE)
- M.adjustToxLoss(-1.5*REM, 0, TRUE) //heals TOXINLOVERs
+ M.adjustBruteLoss(-1.5*REAGENTS_EFFECT_MULTIPLIER, FALSE)
+ M.adjustFireLoss(-1.5*REAGENTS_EFFECT_MULTIPLIER, FALSE)
+ M.adjustOxyLoss(-1.5*REAGENTS_EFFECT_MULTIPLIER, FALSE)
+ M.adjustToxLoss(-1.5*REAGENTS_EFFECT_MULTIPLIER, 0, TRUE) //heals TOXINLOVERs
. = 1
..()
@@ -1295,13 +1295,13 @@
value = REAGENT_VALUE_EXCEPTIONAL
/datum/reagent/medicine/syndicate_nanites/on_mob_life(mob/living/carbon/M)
- M.adjustBruteLoss(-5*REM, FALSE) //A ton of healing - this is a 50 telecrystal investment.
- M.adjustFireLoss(-5*REM, FALSE)
+ M.adjustBruteLoss(-5*REAGENTS_EFFECT_MULTIPLIER, FALSE) //A ton of healing - this is a 50 telecrystal investment.
+ M.adjustFireLoss(-5*REAGENTS_EFFECT_MULTIPLIER, FALSE)
M.adjustOxyLoss(-15, FALSE)
- M.adjustToxLoss(-5*REM, FALSE)
- M.adjustOrganLoss(ORGAN_SLOT_BRAIN, -15*REM)
- M.adjustCloneLoss(-3*REM, FALSE)
- M.adjustStaminaLoss(-25*REM,FALSE)
+ M.adjustToxLoss(-5*REAGENTS_EFFECT_MULTIPLIER, FALSE)
+ M.adjustOrganLoss(ORGAN_SLOT_BRAIN, -15*REAGENTS_EFFECT_MULTIPLIER)
+ M.adjustCloneLoss(-3*REAGENTS_EFFECT_MULTIPLIER, FALSE)
+ M.adjustStaminaLoss(-25*REAGENTS_EFFECT_MULTIPLIER,FALSE)
if(M.blood_volume < (BLOOD_VOLUME_NORMAL*M.blood_ratio))
M.adjust_integration_blood(40) // blood fall out man bad
..()
@@ -1316,13 +1316,13 @@
value = REAGENT_VALUE_VERY_RARE
/datum/reagent/medicine/lesser_syndicate_nanites/on_mob_life(mob/living/carbon/M)
- M.adjustBruteLoss(-2*REM, FALSE)
- M.adjustFireLoss(-2*REM, FALSE)
- M.adjustOxyLoss(-5*REM, FALSE)
- M.adjustToxLoss(-2*REM, FALSE)
- M.adjustOrganLoss(ORGAN_SLOT_BRAIN, -5*REM)
- M.adjustCloneLoss(-1.25*REM, FALSE)
- M.adjustStaminaLoss(-4*REM,FALSE)
+ M.adjustBruteLoss(-2*REAGENTS_EFFECT_MULTIPLIER, FALSE)
+ M.adjustFireLoss(-2*REAGENTS_EFFECT_MULTIPLIER, FALSE)
+ M.adjustOxyLoss(-5*REAGENTS_EFFECT_MULTIPLIER, FALSE)
+ M.adjustToxLoss(-2*REAGENTS_EFFECT_MULTIPLIER, FALSE)
+ M.adjustOrganLoss(ORGAN_SLOT_BRAIN, -5*REAGENTS_EFFECT_MULTIPLIER)
+ M.adjustCloneLoss(-1.25*REAGENTS_EFFECT_MULTIPLIER, FALSE)
+ M.adjustStaminaLoss(-4*REAGENTS_EFFECT_MULTIPLIER,FALSE)
if(M.blood_volume < (BLOOD_VOLUME_NORMAL*M.blood_ratio))
M.adjust_integration_blood(3)
..()
@@ -1340,17 +1340,17 @@
value = REAGENT_VALUE_UNCOMMON
/datum/reagent/medicine/neo_jelly/on_mob_life(mob/living/carbon/M)
- M.adjustBruteLoss(-1.5*REM, FALSE)
- M.adjustFireLoss(-1.5*REM, FALSE)
- M.adjustOxyLoss(-1.5*REM, FALSE)
- M.adjustToxLoss(-1.5*REM, 0, TRUE) //heals TOXINLOVERs
+ M.adjustBruteLoss(-1.5*REAGENTS_EFFECT_MULTIPLIER, FALSE)
+ M.adjustFireLoss(-1.5*REAGENTS_EFFECT_MULTIPLIER, FALSE)
+ M.adjustOxyLoss(-1.5*REAGENTS_EFFECT_MULTIPLIER, FALSE)
+ M.adjustToxLoss(-1.5*REAGENTS_EFFECT_MULTIPLIER, 0, TRUE) //heals TOXINLOVERs
. = 1
..()
/datum/reagent/medicine/neo_jelly/overdose_process(mob/living/M)
- M.adjustOxyLoss(2.6*REM, FALSE)
- M.adjustBruteLoss(3.5*REM, FALSE)
- M.adjustFireLoss(3.5*REM, FALSE)
+ M.adjustOxyLoss(2.6*REAGENTS_EFFECT_MULTIPLIER, FALSE)
+ M.adjustBruteLoss(3.5*REAGENTS_EFFECT_MULTIPLIER, FALSE)
+ M.adjustFireLoss(3.5*REAGENTS_EFFECT_MULTIPLIER, FALSE)
..()
. = 1
@@ -1378,13 +1378,13 @@
myseed.adjust_production(-round(chems.get_reagent_amount(src.type) * 0.5))
/datum/reagent/medicine/earthsblood/on_mob_life(mob/living/carbon/M)
- M.adjustBruteLoss(-3 * REM, FALSE)
- M.adjustFireLoss(-3 * REM, FALSE)
- M.adjustOxyLoss(-15 * REM, FALSE)
- M.adjustToxLoss(-3 * REM, FALSE, TRUE) //Heals TOXINLOVERS
- M.adjustOrganLoss(ORGAN_SLOT_BRAIN, 2 * REM, 150) //This does, after all, come from ambrosia, and the most powerful ambrosia in existence, at that!
- M.adjustCloneLoss(-1 * REM, FALSE)
- M.adjustStaminaLoss(-13 * REM, FALSE)
+ M.adjustBruteLoss(-3 * REAGENTS_EFFECT_MULTIPLIER, FALSE)
+ M.adjustFireLoss(-3 * REAGENTS_EFFECT_MULTIPLIER, FALSE)
+ M.adjustOxyLoss(-15 * REAGENTS_EFFECT_MULTIPLIER, FALSE)
+ M.adjustToxLoss(-3 * REAGENTS_EFFECT_MULTIPLIER, FALSE, TRUE) //Heals TOXINLOVERS
+ M.adjustOrganLoss(ORGAN_SLOT_BRAIN, 2 * REAGENTS_EFFECT_MULTIPLIER, 150) //This does, after all, come from ambrosia, and the most powerful ambrosia in existence, at that!
+ M.adjustCloneLoss(-1 * REAGENTS_EFFECT_MULTIPLIER, FALSE)
+ M.adjustStaminaLoss(-13 * REAGENTS_EFFECT_MULTIPLIER, FALSE)
M.jitteriness = min(max(0, M.jitteriness + 3), 30)
M.druggy = min(max(0, M.druggy + 10), 15) //See above
..()
@@ -1392,7 +1392,7 @@
/datum/reagent/medicine/earthsblood/overdose_process(mob/living/M)
M.hallucination = min(max(0, M.hallucination + 5), 60)
- M.adjustToxLoss(8 * REM, FALSE, TRUE) //Hurts TOXINLOVERS
+ M.adjustToxLoss(8 * REAGENTS_EFFECT_MULTIPLIER, FALSE, TRUE) //Hurts TOXINLOVERS
..()
. = 1
@@ -1414,8 +1414,8 @@
if (M.hallucination >= 5)
M.hallucination -= 5
if(prob(20))
- M.adjustOrganLoss(ORGAN_SLOT_BRAIN, 1*REM, 50)
- M.adjustStaminaLoss(2.5*REM, 0)
+ M.adjustOrganLoss(ORGAN_SLOT_BRAIN, 1*REAGENTS_EFFECT_MULTIPLIER, 50)
+ M.adjustStaminaLoss(2.5*REAGENTS_EFFECT_MULTIPLIER, 0)
..()
return TRUE
@@ -1434,9 +1434,9 @@
return TRUE
/datum/reagent/medicine/lavaland_extract/overdose_process(mob/living/M)
- M.adjustBruteLoss(3*REM, 0)
- M.adjustFireLoss(3*REM, 0)
- M.adjustToxLoss(3*REM, 0)
+ M.adjustBruteLoss(3*REAGENTS_EFFECT_MULTIPLIER, 0)
+ M.adjustFireLoss(3*REAGENTS_EFFECT_MULTIPLIER, 0)
+ M.adjustToxLoss(3*REAGENTS_EFFECT_MULTIPLIER, 0)
..()
return TRUE
@@ -1450,10 +1450,10 @@
/datum/reagent/medicine/changelingadrenaline/on_mob_life(mob/living/carbon/metabolizer, delta_time, times_fired)
..()
- metabolizer.AdjustAllImmobility(-20 * REM * delta_time)
- metabolizer.adjustStaminaLoss(-30 * REM * delta_time, 0)
- metabolizer.Jitter(10 * REM * delta_time)
- metabolizer.Dizzy(10 * REM * delta_time)
+ metabolizer.AdjustAllImmobility(-20 * REAGENTS_EFFECT_MULTIPLIER * delta_time)
+ metabolizer.adjustStaminaLoss(-30 * REAGENTS_EFFECT_MULTIPLIER * delta_time, 0)
+ metabolizer.Jitter(10 * REAGENTS_EFFECT_MULTIPLIER * delta_time)
+ metabolizer.Dizzy(10 * REAGENTS_EFFECT_MULTIPLIER * delta_time)
return TRUE
/datum/reagent/medicine/changelingadrenaline/on_mob_metabolize(mob/living/L)
@@ -1471,7 +1471,7 @@
L.Jitter(0)
/datum/reagent/medicine/changelingadrenaline/overdose_process(mob/living/metabolizer, delta_time, times_fired)
- metabolizer.adjustToxLoss(1 * REM * delta_time, 0)
+ metabolizer.adjustToxLoss(1 * REAGENTS_EFFECT_MULTIPLIER * delta_time, 0)
..()
return TRUE
@@ -1546,7 +1546,7 @@
overdose_threshold = overdose_threshold + rand(-10,10)/10 // for extra fun
M.AdjustAllImmobility(-5, 0)
M.AdjustUnconscious(-5, 0)
- M.adjustStaminaLoss(-1*REM, 0)
+ M.adjustStaminaLoss(-1*REAGENTS_EFFECT_MULTIPLIER, 0)
M.Jitter(1)
metabolization_rate = 0.01 * REAGENTS_METABOLISM * rand(5,20) // randomizes metabolism between 0.02 and 0.08 per tick
. = TRUE
@@ -1566,8 +1566,8 @@
if(prob(50))
M.losebreath++
if(41 to 80)
- M.adjustOxyLoss(0.1*REM, 0)
- M.adjustStaminaLoss(0.1*REM, 0)
+ M.adjustOxyLoss(0.1*REAGENTS_EFFECT_MULTIPLIER, 0)
+ M.adjustStaminaLoss(0.1*REAGENTS_EFFECT_MULTIPLIER, 0)
M.jitteriness = min(M.jitteriness+1, 20)
M.stuttering = min(M.stuttering+1, 20)
M.Dizzy(10)
@@ -1579,12 +1579,12 @@
M.DefaultCombatKnockdown(20, 1, 0) // you should be in a bad spot at this point unless epipen has been used
if(81)
to_chat(M, "You feel too exhausted to continue!") // at this point you will eventually die unless you get charcoal
- M.adjustOxyLoss(0.1*REM, 0)
- M.adjustStaminaLoss(0.1*REM, 0)
+ M.adjustOxyLoss(0.1*REAGENTS_EFFECT_MULTIPLIER, 0)
+ M.adjustStaminaLoss(0.1*REAGENTS_EFFECT_MULTIPLIER, 0)
if(82 to INFINITY)
M.Sleeping(100, 0, TRUE)
- M.adjustOxyLoss(1.5*REM, 0)
- M.adjustStaminaLoss(1.5*REM, 0)
+ M.adjustOxyLoss(1.5*REAGENTS_EFFECT_MULTIPLIER, 0)
+ M.adjustStaminaLoss(1.5*REAGENTS_EFFECT_MULTIPLIER, 0)
..()
return TRUE
@@ -1674,7 +1674,7 @@
value = REAGENT_VALUE_UNCOMMON // while it's 'rare', it can be milked from the wisdom cow
/datum/reagent/medicine/liquid_wisdom/on_mob_life(mob/living/carbon/C) //slightly stronger mannitol, from the wisdom cow
- C.adjustOrganLoss(ORGAN_SLOT_BRAIN, -3*REM)
+ C.adjustOrganLoss(ORGAN_SLOT_BRAIN, -3*REAGENTS_EFFECT_MULTIPLIER)
if(prob(20))
C.cure_trauma_type(resilience = TRAUMA_RESILIENCE_BASIC)
if(prob(3))
diff --git a/code/modules/reagents/chemistry/reagents/other_reagents.dm b/code/modules/reagents/chemistry/reagents/other_reagents.dm
index bf93c933de..a378880567 100644
--- a/code/modules/reagents/chemistry/reagents/other_reagents.dm
+++ b/code/modules/reagents/chemistry/reagents/other_reagents.dm
@@ -58,7 +58,7 @@
var/blood_id = C.get_blood_id()
if((blood_id in GLOB.blood_reagent_types) && !HAS_TRAIT(C, TRAIT_NOMARROW))
if(!data || !(data["blood_type"] in get_safe_blood(C.dna.blood_type))) //we only care about bloodtype here because this is where the poisoning should be
- C.adjustToxLoss(rand(2,8)*REM, TRUE, TRUE) //forced to ensure people don't use it to gain beneficial toxin as slime person
+ C.adjustToxLoss(rand(2,8)*REAGENTS_EFFECT_MULTIPLIER, TRUE, TRUE) //forced to ensure people don't use it to gain beneficial toxin as slime person
..()
/datum/reagent/blood/reaction_obj(obj/O, volume)
@@ -175,10 +175,10 @@
if(prob(10))
if(M.dna?.species?.exotic_bloodtype != "GEL")
to_chat(M, "Your insides are burning!")
- M.adjustToxLoss(rand(20,60)*REM, 0)
+ M.adjustToxLoss(rand(20,60)*REAGENTS_EFFECT_MULTIPLIER, 0)
. = 1
else if(prob(40) && isjellyperson(M))
- M.heal_bodypart_damage(2*REM)
+ M.heal_bodypart_damage(2*REAGENTS_EFFECT_MULTIPLIER)
. = 1
..()
@@ -1019,7 +1019,7 @@
mytray.adjustWeeds(-rand(1,3))
/datum/reagent/chlorine/on_mob_life(mob/living/carbon/M)
- M.take_bodypart_damage(1*REM, 0, 0, 0)
+ M.take_bodypart_damage(1*REAGENTS_EFFECT_MULTIPLIER, 0, 0, 0)
. = 1
..()
@@ -1041,7 +1041,7 @@
mytray.adjustWeeds(-rand(1,4))
/datum/reagent/fluorine/on_mob_life(mob/living/carbon/M)
- M.adjustToxLoss(1*REM, 0)
+ M.adjustToxLoss(1*REAGENTS_EFFECT_MULTIPLIER, 0)
. = 1
..()
@@ -1098,7 +1098,7 @@
mytray.adjustToxic(round(chems.get_reagent_amount(src.type) * 1))
/datum/reagent/radium/on_mob_life(mob/living/carbon/M)
- M.apply_effect(2*REM/M.metabolism_efficiency,EFFECT_IRRADIATE,0)
+ M.apply_effect(2*REAGENTS_EFFECT_MULTIPLIER/M.metabolism_efficiency,EFFECT_IRRADIATE,0)
..()
/datum/reagent/radium/reaction_turf(turf/T, reac_volume)
@@ -1398,7 +1398,7 @@
/datum/reagent/impedrezene/on_mob_life(mob/living/carbon/M)
M.jitteriness = max(M.jitteriness-5,0)
if(prob(80))
- M.adjustOrganLoss(ORGAN_SLOT_BRAIN, 2*REM)
+ M.adjustOrganLoss(ORGAN_SLOT_BRAIN, 2*REAGENTS_EFFECT_MULTIPLIER)
if(prob(50))
M.drowsyness = max(M.drowsyness, 3)
if(prob(10))
@@ -1574,7 +1574,7 @@
..()
/datum/reagent/stimulum/on_mob_life(mob/living/carbon/M)
- M.adjustStaminaLoss(-2*REM, 0)
+ M.adjustStaminaLoss(-2*REAGENTS_EFFECT_MULTIPLIER, 0)
current_cycle++
holder.remove_reagent(type, 0.99) //Gives time for the next tick of life().
. = TRUE //Update status effects.
@@ -1687,7 +1687,7 @@
/datum/reagent/plantnutriment/on_mob_life(mob/living/carbon/M)
if(prob(tox_prob))
- M.adjustToxLoss(1*REM, 0)
+ M.adjustToxLoss(1*REAGENTS_EFFECT_MULTIPLIER, 0)
. = 1
..()
@@ -2533,7 +2533,7 @@
var/obj/item/bodypart/wounded_part = W.limb
if(wounded_part)
wounded_part.heal_damage(0.25, 0.25)
- M.adjustStaminaLoss(-0.25*REM) // the more wounds, the more stamina regen
+ M.adjustStaminaLoss(-0.25*REAGENTS_EFFECT_MULTIPLIER) // the more wounds, the more stamina regen
..()
/datum/reagent/eldritch
diff --git a/code/modules/reagents/chemistry/reagents/toxin_reagents.dm b/code/modules/reagents/chemistry/reagents/toxin_reagents.dm
index 7dd8cac452..7cefc48159 100644
--- a/code/modules/reagents/chemistry/reagents/toxin_reagents.dm
+++ b/code/modules/reagents/chemistry/reagents/toxin_reagents.dm
@@ -18,7 +18,7 @@
/datum/reagent/toxin/on_mob_life(mob/living/carbon/M)
if(toxpwr)
- M.adjustToxLoss(toxpwr*REM, 0)
+ M.adjustToxLoss(toxpwr*REAGENTS_EFFECT_MULTIPLIER, 0)
. = TRUE
..()
@@ -79,7 +79,7 @@
/datum/reagent/toxin/plasma/on_mob_life(mob/living/carbon/C)
if(holder.has_reagent(/datum/reagent/medicine/epinephrine))
- holder.remove_reagent(/datum/reagent/medicine/epinephrine, 2*REM)
+ holder.remove_reagent(/datum/reagent/medicine/epinephrine, 2*REAGENTS_EFFECT_MULTIPLIER)
C.adjustPlasma(20)
return ..()
@@ -136,10 +136,10 @@
/datum/reagent/toxin/slimejelly/on_mob_life(mob/living/carbon/M)
if(prob(10))
to_chat(M, "Your insides are burning!")
- M.adjustToxLoss(rand(20,60)*REM, 0)
+ M.adjustToxLoss(rand(20,60)*REAGENTS_EFFECT_MULTIPLIER, 0)
. = 1
else if(prob(40))
- M.heal_bodypart_damage(5*REM)
+ M.heal_bodypart_damage(5*REAGENTS_EFFECT_MULTIPLIER)
. = 1
..()
@@ -191,7 +191,7 @@
..()
/datum/reagent/toxin/zombiepowder/reaction_mob(mob/living/L, method=TOUCH, reac_volume)
- L.adjustOxyLoss(0.5*REM, 0)
+ L.adjustOxyLoss(0.5*REAGENTS_EFFECT_MULTIPLIER, 0)
if(method == INGEST)
fakedeath_active = TRUE
L.fakedeath(type)
@@ -230,7 +230,7 @@
..()
/datum/reagent/toxin/ghoulpowder/on_mob_life(mob/living/carbon/M)
- M.adjustOxyLoss(1*REM, 0)
+ M.adjustOxyLoss(1*REAGENTS_EFFECT_MULTIPLIER, 0)
..()
. = 1
@@ -365,7 +365,7 @@
. = 1
if(51 to INFINITY)
M.Sleeping(40, 0)
- M.adjustToxLoss((current_cycle - 50)*REM, 0)
+ M.adjustToxLoss((current_cycle - 50)*REAGENTS_EFFECT_MULTIPLIER, 0)
. = 1
..()
@@ -387,7 +387,7 @@
M.Sleeping(40, 0)
if(51 to INFINITY)
M.Sleeping(40, 0)
- M.adjustToxLoss((current_cycle - 50)*REM, 0)
+ M.adjustToxLoss((current_cycle - 50)*REAGENTS_EFFECT_MULTIPLIER, 0)
return ..()
/datum/reagent/toxin/coffeepowder
@@ -437,7 +437,7 @@
value = REAGENT_VALUE_UNCOMMON
/datum/reagent/toxin/staminatoxin/on_mob_life(mob/living/carbon/M)
- M.adjustStaminaLoss(REM * data, 0)
+ M.adjustStaminaLoss(REAGENTS_EFFECT_MULTIPLIER * data, 0)
data = max(data - 1, 5)
..()
. = 1
@@ -478,14 +478,14 @@
if(4)
if(prob(75))
to_chat(M, "You scratch at an itch.")
- M.adjustBruteLoss(2*REM, 0)
+ M.adjustBruteLoss(2*REAGENTS_EFFECT_MULTIPLIER, 0)
. = 1
..()
/datum/reagent/toxin/histamine/overdose_process(mob/living/M)
- M.adjustOxyLoss(2*REM, 0)
- M.adjustBruteLoss(2*REM, 0)
- M.adjustToxLoss(2*REM, 0)
+ M.adjustOxyLoss(2*REAGENTS_EFFECT_MULTIPLIER, 0)
+ M.adjustBruteLoss(2*REAGENTS_EFFECT_MULTIPLIER, 0)
+ M.adjustToxLoss(2*REAGENTS_EFFECT_MULTIPLIER, 0)
..()
. = 1
@@ -515,7 +515,7 @@
/datum/reagent/toxin/venom/on_mob_life(mob/living/carbon/M)
toxpwr = 0.2*volume
- M.adjustBruteLoss((0.3*volume)*REM, 0)
+ M.adjustBruteLoss((0.3*volume)*REAGENTS_EFFECT_MULTIPLIER, 0)
. = 1
if(prob(15))
M.reagents.add_reagent(/datum/reagent/toxin/histamine, pick(5,10))
@@ -532,9 +532,9 @@
toxpwr = 0
/datum/reagent/toxin/fentanyl/on_mob_life(mob/living/carbon/M)
- M.adjustOrganLoss(ORGAN_SLOT_BRAIN, 3*REM, 150)
+ M.adjustOrganLoss(ORGAN_SLOT_BRAIN, 3*REAGENTS_EFFECT_MULTIPLIER, 150)
if(M.toxloss <= 60)
- M.adjustToxLoss(1*REM, 0)
+ M.adjustToxLoss(1*REAGENTS_EFFECT_MULTIPLIER, 0)
if(current_cycle >= 18)
M.Sleeping(40, 0)
..()
@@ -555,7 +555,7 @@
if(prob(8))
to_chat(M, "You feel horrendously weak!")
M.Stun(40, 0)
- M.adjustToxLoss(2*REM, 0)
+ M.adjustToxLoss(2*REAGENTS_EFFECT_MULTIPLIER, 0)
return ..()
/datum/reagent/toxin/bad_food
@@ -583,15 +583,15 @@
/datum/reagent/toxin/itching_powder/on_mob_life(mob/living/carbon/M)
if(prob(15))
to_chat(M, "You scratch at your head.")
- M.adjustBruteLoss(0.2*REM, 0)
+ M.adjustBruteLoss(0.2*REAGENTS_EFFECT_MULTIPLIER, 0)
. = 1
if(prob(15))
to_chat(M, "You scratch at your leg.")
- M.adjustBruteLoss(0.2*REM, 0)
+ M.adjustBruteLoss(0.2*REAGENTS_EFFECT_MULTIPLIER, 0)
. = 1
if(prob(15))
to_chat(M, "You scratch at your arm.")
- M.adjustBruteLoss(0.2*REM, 0)
+ M.adjustBruteLoss(0.2*REAGENTS_EFFECT_MULTIPLIER, 0)
. = 1
if(prob(3))
M.reagents.add_reagent(/datum/reagent/toxin/histamine,rand(1,3))
@@ -660,7 +660,7 @@
/datum/reagent/toxin/sodium_thiopental/on_mob_life(mob/living/carbon/M)
if(current_cycle >= 10)
M.Sleeping(40, 0)
- M.adjustStaminaLoss(10*REM, 0)
+ M.adjustStaminaLoss(10*REAGENTS_EFFECT_MULTIPLIER, 0)
..()
return TRUE
@@ -687,7 +687,7 @@
value = REAGENT_VALUE_RARE
/datum/reagent/toxin/amanitin/on_mob_end_metabolize(mob/living/M)
- var/toxdamage = current_cycle*3*REM
+ var/toxdamage = current_cycle*3*REAGENTS_EFFECT_MULTIPLIER
M.log_message("has taken [toxdamage] toxin damage from amanitin toxin", LOG_ATTACK)
M.adjustToxLoss(toxdamage)
..()
@@ -703,7 +703,7 @@
/datum/reagent/toxin/lipolicide/on_mob_life(mob/living/carbon/M)
if(M.nutrition <= NUTRITION_LEVEL_STARVING)
- M.adjustToxLoss(1*REM, 0)
+ M.adjustToxLoss(1*REAGENTS_EFFECT_MULTIPLIER, 0)
M.adjust_nutrition(-3) // making the chef more valuable, one meme trap at a time
M.overeatduration = 0
return ..()
@@ -759,7 +759,7 @@
/datum/reagent/toxin/curare/on_mob_life(mob/living/carbon/M)
if(current_cycle >= 11)
M.DefaultCombatKnockdown(60, 0)
- M.adjustOxyLoss(1*REM, 0)
+ M.adjustOxyLoss(1*REAGENTS_EFFECT_MULTIPLIER, 0)
. = 1
..()
@@ -942,7 +942,7 @@
/datum/reagent/toxin/delayed/on_mob_life(mob/living/carbon/M)
if(current_cycle > delay)
holder.remove_reagent(type, actual_metaboliztion_rate * M.metabolism_efficiency)
- M.adjustToxLoss(actual_toxpwr*REM, 0)
+ M.adjustToxLoss(actual_toxpwr*REAGENTS_EFFECT_MULTIPLIER, 0)
if(prob(10))
M.DefaultCombatKnockdown(20, 0)
. = 1
diff --git a/code/modules/reagents/reagent_containers.dm b/code/modules/reagents/reagent_containers.dm
index 375aef573c..8744af7b28 100644
--- a/code/modules/reagents/reagent_containers.dm
+++ b/code/modules/reagents/reagent_containers.dm
@@ -47,7 +47,7 @@
set name = "Set Transfer Amount"
set category = "Object"
set waitfor = FALSE
- var/N = tgui_input_list(usr, "Amount per transfer from this:","[src]", possible_transfer_amounts)
+ var/N = input("Amount per transfer from this:","[src]") as null|anything in possible_transfer_amounts
if(N)
amount_per_transfer_from_this = N
to_chat(usr, "[src]'s transfer amount is now [amount_per_transfer_from_this] units.")
@@ -88,10 +88,10 @@
return 0
return 1
-/obj/item/reagent_containers/ex_act()
+/obj/item/reagent_containers/ex_act(severity, target, origin)
if(reagents)
for(var/datum/reagent/R in reagents.reagent_list)
- R.on_ex_act()
+ R.on_ex_act(severity)
if(!QDELETED(src))
..()
diff --git a/code/modules/reagents/reagent_containers/borghypo.dm b/code/modules/reagents/reagent_containers/borghypo.dm
index 5dd0273372..3388018280 100644
--- a/code/modules/reagents/reagent_containers/borghypo.dm
+++ b/code/modules/reagents/reagent_containers/borghypo.dm
@@ -122,7 +122,7 @@ Borg Hypospray
log_combat(user, M, "injected", src, "(CHEMICALS: [english_list(injected)])")
/obj/item/reagent_containers/borghypo/attack_self(mob/user)
- var/chosen_reagent = modes[reagent_names[tgui_input_list(user, "What reagent do you want to dispense?", "", reagent_names)]]
+ var/chosen_reagent = modes[reagent_names[input(user, "What reagent do you want to dispense?") as null|anything in reagent_names]]
if(!chosen_reagent)
return
mode = chosen_reagent
diff --git a/code/modules/reagents/reagent_containers/chem_pack.dm b/code/modules/reagents/reagent_containers/chem_pack.dm
index 77d6067d3b..139a5f626f 100644
--- a/code/modules/reagents/reagent_containers/chem_pack.dm
+++ b/code/modules/reagents/reagent_containers/chem_pack.dm
@@ -30,8 +30,8 @@
SplashReagents(user)
return
else
- DISABLE_BITFIELD(reagents.reagents_holder_flags, OPENCONTAINER)
- ENABLE_BITFIELD(reagents.reagents_holder_flags, DRAWABLE |INJECTABLE )
+ reagents.reagents_holder_flags &= ~(OPENCONTAINER)
+ reagents.reagents_holder_flags |= (DRAWABLE|INJECTABLE)
spillable = FALSE
sealed = TRUE
to_chat(user, "You seal the bag.")
diff --git a/code/modules/reagents/reagent_containers/rags.dm b/code/modules/reagents/reagent_containers/rags.dm
index 8a6e2bf2e7..c26ed4db31 100644
--- a/code/modules/reagents/reagent_containers/rags.dm
+++ b/code/modules/reagents/reagent_containers/rags.dm
@@ -141,11 +141,11 @@
/obj/item/reagent_containers/rag/towel/attack(mob/living/M, mob/living/user)
if(user.a_intent == INTENT_HARM)
- DISABLE_BITFIELD(item_flags, NOBLUDGEON)
+ item_flags &= ~(NOBLUDGEON)
. = TRUE
..()
if(.)
- ENABLE_BITFIELD(item_flags, NOBLUDGEON)
+ item_flags |= NOBLUDGEON
/obj/item/reagent_containers/rag/towel/equipped(mob/living/user, slot)
. = ..()
diff --git a/code/modules/reagents/reagent_containers/spray.dm b/code/modules/reagents/reagent_containers/spray.dm
index 17366e31d4..f59e45ff01 100644
--- a/code/modules/reagents/reagent_containers/spray.dm
+++ b/code/modules/reagents/reagent_containers/spray.dm
@@ -111,7 +111,7 @@
set src in usr
if(usr.incapacitated())
return
- if (tgui_alert(usr, "Are you sure you want to empty that?", "Empty Bottle:", list("Yes", "No")) != "Yes")
+ if (alert(usr, "Are you sure you want to empty that?", "Empty Bottle:", "Yes", "No") != "Yes")
return
if(isturf(usr.loc) && src.loc == usr)
to_chat(usr, "You empty \the [src] onto the floor.")
diff --git a/code/modules/reagents/reagent_dispenser.dm b/code/modules/reagents/reagent_dispenser.dm
index db82e5cdb2..8215c9d8db 100644
--- a/code/modules/reagents/reagent_dispenser.dm
+++ b/code/modules/reagents/reagent_dispenser.dm
@@ -151,7 +151,7 @@
/obj/structure/reagent_dispensers/fueltank/blob_act(obj/structure/blob/B)
boom()
-/obj/structure/reagent_dispensers/fueltank/ex_act()
+/obj/structure/reagent_dispensers/fueltank/ex_act(severity, target, origin)
boom()
/obj/structure/reagent_dispensers/fueltank/fire_act(exposed_temperature, exposed_volume)
diff --git a/code/modules/recycling/disposal/holder.dm b/code/modules/recycling/disposal/holder.dm
index f739057699..bce1b3d98d 100644
--- a/code/modules/recycling/disposal/holder.dm
+++ b/code/modules/recycling/disposal/holder.dm
@@ -130,5 +130,5 @@
/obj/structure/disposalholder/AllowDrop()
return TRUE
-/obj/structure/disposalholder/ex_act(severity, target)
+/obj/structure/disposalholder/ex_act(severity, target, origin)
return
diff --git a/code/modules/recycling/disposal/pipe.dm b/code/modules/recycling/disposal/pipe.dm
index 45d3d9da25..f6c27f4a79 100644
--- a/code/modules/recycling/disposal/pipe.dm
+++ b/code/modules/recycling/disposal/pipe.dm
@@ -132,10 +132,10 @@
// pipe affected by explosion
-/obj/structure/disposalpipe/contents_explosion(severity, target)
+/obj/structure/disposalpipe/contents_explosion(severity, target, origin)
var/obj/structure/disposalholder/H = locate() in src
if(H)
- H.contents_explosion(severity, target)
+ H.contents_explosion(severity, target, origin)
/obj/structure/disposalpipe/run_obj_armor(damage_amount, damage_type, damage_flag = 0, attack_dir)
diff --git a/code/modules/recycling/sortingmachinery.dm b/code/modules/recycling/sortingmachinery.dm
index b47f0de032..008e093b74 100644
--- a/code/modules/recycling/sortingmachinery.dm
+++ b/code/modules/recycling/sortingmachinery.dm
@@ -18,9 +18,9 @@
AM.forceMove(T)
return ..()
-/obj/structure/bigDelivery/contents_explosion(severity, target)
+/obj/structure/bigDelivery/contents_explosion(severity, target, origin)
for(var/atom/movable/AM in contents)
- AM.ex_act()
+ AM.ex_act(severity, target, origin)
/obj/structure/bigDelivery/attackby(obj/item/W, mob/user, params)
if(istype(W, /obj/item/destTagger))
@@ -82,9 +82,9 @@
var/giftwrapped = 0
var/sortTag = 0
-/obj/item/smallDelivery/contents_explosion(severity, target)
+/obj/item/smallDelivery/contents_explosion(severity, target, origin)
for(var/atom/movable/AM in contents)
- AM.ex_act()
+ AM.ex_act(severity, target, origin)
/obj/item/smallDelivery/attack_self(mob/user)
user.temporarilyRemoveItemFromInventory(src, TRUE)
diff --git a/code/modules/research/designs/medical_designs.dm b/code/modules/research/designs/medical_designs.dm
index 88c37ce2a2..663cf1fdd7 100644
--- a/code/modules/research/designs/medical_designs.dm
+++ b/code/modules/research/designs/medical_designs.dm
@@ -122,6 +122,17 @@
category = list("Medical Designs")
departmental_flags = DEPARTMENTAL_FLAG_MEDICAL
+/datum/design/smartdartrepeater
+ name = "Smartdart Repeater"
+ desc = "An experimental smartdart rifle. It can make its own smart darts and is loaded with a hypovial."
+ id = "smartdartrepeater"
+ build_type = PROTOLATHE
+ materials = list(/datum/material/glass = 2000, /datum/material/plastic = 1000, /datum/material/iron = 2000,/datum/material/titanium = 1000 )
+ build_path = /obj/item/gun/chem/smart
+ category = list("Medical Designs")
+ departmental_flags = DEPARTMENTAL_FLAG_MEDICAL
+
+
/datum/design/plasmarefiller
name = "Plasma-Man Jumpsuit Refill"
desc = "A refill pack for the auto-extinguisher on Plasma-man suits."
@@ -201,7 +212,7 @@
build_path = /obj/item/storage/hypospraykit // let's not summon new hyposprays thanks
category = list("Medical Designs")
departmental_flags = DEPARTMENTAL_FLAG_MEDICAL | DEPARTMENTAL_FLAG_SCIENCE
-
+
/datum/design/hypospray/mkii
name = "Hypospray Mk. II"
id = "hypospray_mkii"
diff --git a/code/modules/research/destructive_analyzer.dm b/code/modules/research/destructive_analyzer.dm
index 5df70f7e56..cc02e271f9 100644
--- a/code/modules/research/destructive_analyzer.dm
+++ b/code/modules/research/destructive_analyzer.dm
@@ -116,7 +116,7 @@ Note: Must be placed within 3 tiles of the R&D Console
differences[i] = value
if(length(worths) && !length(differences))
return FALSE
- var/choice = tgui_input_list(user, "Are you sure you want to destroy [loaded_item] to [!length(worths) ? "reveal [TN.display_name]" : "boost [TN.display_name] by [json_encode(differences)] point\s"]?", "", list("Proceed", "Cancel"))
+ var/choice = input("Are you sure you want to destroy [loaded_item] to [!length(worths) ? "reveal [TN.display_name]" : "boost [TN.display_name] by [json_encode(differences)] point\s"]?") in list("Proceed", "Cancel")
if(choice == "Cancel")
return FALSE
if(QDELETED(loaded_item) || QDELETED(linked_console) || !user.Adjacent(linked_console) || QDELETED(src))
@@ -134,7 +134,7 @@ Note: Must be placed within 3 tiles of the R&D Console
user_mode_string = " for [json_encode(point_value)] points"
else if(loaded_item.custom_materials?.len)
user_mode_string = " for material reclamation"
- var/choice = tgui_input_list(user, "Are you sure you want to destroy [loaded_item][user_mode_string]?", "", list("Proceed", "Cancel"))
+ var/choice = input("Are you sure you want to destroy [loaded_item][user_mode_string]?") in list("Proceed", "Cancel")
if(choice == "Cancel")
return FALSE
if(QDELETED(loaded_item) || QDELETED(linked_console) || !user.Adjacent(linked_console) || QDELETED(src))
diff --git a/code/modules/research/techweb/nodes/weaponry_nodes.dm b/code/modules/research/techweb/nodes/weaponry_nodes.dm
index e17d7e1e7b..999000c57b 100644
--- a/code/modules/research/techweb/nodes/weaponry_nodes.dm
+++ b/code/modules/research/techweb/nodes/weaponry_nodes.dm
@@ -45,7 +45,7 @@
display_name = "Medical Weaponry"
description = "Weapons using medical technology."
prereq_ids = list("adv_biotech", "adv_weaponry")
- design_ids = list("rapidsyringe", "shotgundartcryostatis")
+ design_ids = list("rapidsyringe", "shotgundartcryostatis","smartdartrepeater")
research_costs = list(TECHWEB_POINT_TYPE_GENERIC = 2000)
/datum/techweb_node/beam_weapons
diff --git a/code/modules/research/xenobiology/crossbreeding/_misc.dm b/code/modules/research/xenobiology/crossbreeding/_misc.dm
index cb6a2f25bc..4684352ef5 100644
--- a/code/modules/research/xenobiology/crossbreeding/_misc.dm
+++ b/code/modules/research/xenobiology/crossbreeding/_misc.dm
@@ -100,7 +100,7 @@
return
if(M.mind)
to_chat(user, "You offer the device to [M].")
- if(tgui_alert(M, "Would you like to enter [user]'s capture device?", "Gold Capture Device", list("Yes", "No")) == "Yes")
+ if(alert(M, "Would you like to enter [user]'s capture device?", "Gold Capture Device", "Yes", "No") == "Yes")
if(user.canUseTopic(src, BE_CLOSE) && user.canUseTopic(M, BE_CLOSE))
to_chat(user, "You store [M] in the capture device.")
to_chat(M, "The world warps around you, and you're suddenly in an endless void, with a window to the outside floating in front of you.")
diff --git a/code/modules/research/xenobiology/crossbreeding/charged.dm b/code/modules/research/xenobiology/crossbreeding/charged.dm
index e4d344f9ba..75a15be9ce 100644
--- a/code/modules/research/xenobiology/crossbreeding/charged.dm
+++ b/code/modules/research/xenobiology/crossbreeding/charged.dm
@@ -153,7 +153,7 @@ Charged extracts:
if(!istype(H))
to_chat(user, "You must be a humanoid to use this!")
return
- var/racechoice = tgui_input_list(H, "Choose your slime subspecies.", "Slime Selection", subtypesof(/datum/species/jelly))
+ var/racechoice = input(H, "Choose your slime subspecies.", "Slime Selection") as null|anything in subtypesof(/datum/species/jelly)
if(!racechoice)
to_chat(user, "You decide not to become a slime for now.")
return
diff --git a/code/modules/research/xenobiology/crossbreeding/selfsustaining.dm b/code/modules/research/xenobiology/crossbreeding/selfsustaining.dm
index bc1597aac8..a88b5cd35b 100644
--- a/code/modules/research/xenobiology/crossbreeding/selfsustaining.dm
+++ b/code/modules/research/xenobiology/crossbreeding/selfsustaining.dm
@@ -28,7 +28,7 @@ Self-sustaining extracts:
return INITIALIZE_HINT_QDEL
/obj/item/autoslime/attack_self(mob/user)
- var/reagentselect = tgui_input_list(user, "Choose the reagent the extract will produce.", "Self-sustaining Reaction", extract.activate_reagents)
+ var/reagentselect = input(user, "Choose the reagent the extract will produce.", "Self-sustaining Reaction") as null|anything in extract.activate_reagents
var/amount = 5
var/secondary
diff --git a/code/modules/research/xenobiology/crossbreeding/stabilized.dm b/code/modules/research/xenobiology/crossbreeding/stabilized.dm
index 5fc7a628da..69bd2c7e28 100644
--- a/code/modules/research/xenobiology/crossbreeding/stabilized.dm
+++ b/code/modules/research/xenobiology/crossbreeding/stabilized.dm
@@ -115,7 +115,7 @@ Stabilized extracts:
generate_mobtype()
/obj/item/slimecross/stabilized/gold/attack_self(mob/user)
- var/choice = tgui_input_list(user, "Which do you want to reset?", "Familiar Adjustment", list("Familiar Location", "Familiar Species", "Familiar Sentience", "Familiar Name"))
+ var/choice = input(user, "Which do you want to reset?", "Familiar Adjustment") as null|anything in list("Familiar Location", "Familiar Species", "Familiar Sentience", "Familiar Name")
if(!user.canUseTopic(src, BE_CLOSE))
return
if(isliving(user))
diff --git a/code/modules/research/xenobiology/xenobiology.dm b/code/modules/research/xenobiology/xenobiology.dm
index d9679d0fb3..70cd28718c 100644
--- a/code/modules/research/xenobiology/xenobiology.dm
+++ b/code/modules/research/xenobiology/xenobiology.dm
@@ -737,7 +737,7 @@
return
prompted = 1
- if(tgui_alert(usr, "This will permanently transfer your consciousness to [SM]. Are you sure you want to do this?",,list("Yes","No"))=="No")
+ if(alert("This will permanently transfer your consciousness to [SM]. Are you sure you want to do this?",,"Yes","No")=="No")
prompted = 0
return
diff --git a/code/modules/ruins/objects_and_mobs/necropolis_gate.dm b/code/modules/ruins/objects_and_mobs/necropolis_gate.dm
index cccb37a359..d62b3c2611 100644
--- a/code/modules/ruins/objects_and_mobs/necropolis_gate.dm
+++ b/code/modules/ruins/objects_and_mobs/necropolis_gate.dm
@@ -169,7 +169,7 @@ GLOBAL_DATUM(necropolis_gate, /obj/structure/necropolis_gate/legion_gate)
/obj/structure/necropolis_gate/legion_gate/on_attack_hand(mob/user, act_intent = user.a_intent, unarmed_attack_flags)
if(!open && !changing_openness)
- var/safety = tgui_alert(user, "You think this might be a bad idea...", "Knock on the door?", list("Proceed", "Abort"))
+ var/safety = alert(user, "You think this might be a bad idea...", "Knock on the door?", "Proceed", "Abort")
if(safety == "Abort" || !in_range(src, user) || !src || open || changing_openness || user.incapacitated())
return
user.visible_message("[user] knocks on [src]...", "You tentatively knock on [src]...")
diff --git a/code/modules/ruins/spaceruin_code/hilbertshotel.dm b/code/modules/ruins/spaceruin_code/hilbertshotel.dm
index 89fd64f3ad..7109c87999 100644
--- a/code/modules/ruins/spaceruin_code/hilbertshotel.dm
+++ b/code/modules/ruins/spaceruin_code/hilbertshotel.dm
@@ -47,7 +47,7 @@ GLOBAL_VAR_INIT(hhmysteryRoomNumber, 1337)
promptAndCheckIn(user)
/obj/item/hilbertshotel/proc/promptAndCheckIn(mob/user)
- var/chosenRoomNumber = tgui_input_num(user, "What number room will you be checking into?", "Room Number")
+ var/chosenRoomNumber = input(user, "What number room will you be checking into?", "Room Number") as null|num
if(!chosenRoomNumber || !user.CanReach(src))
return
if(chosenRoomNumber > SHORT_REAL_LIMIT)
@@ -258,7 +258,7 @@ GLOBAL_VAR_INIT(hhmysteryRoomNumber, 1337)
if(!parentSphere)
to_chat(user, "The door seems to be malfunctioning and refuses to operate!")
return
- if(tgui_alert(user, "Hilbert's Hotel would like to remind you that while we will do everything we can to protect the belongings you leave behind, we make no guarantees of their safety while you're gone, especially that of the health of any living creatures. With that in mind, are you ready to leave?", "Exit", list("Leave", "Stay")) == "Leave")
+ if(alert(user, "Hilbert's Hotel would like to remind you that while we will do everything we can to protect the belongings you leave behind, we make no guarantees of their safety while you're gone, especially that of the health of any living creatures. With that in mind, are you ready to leave?", "Exit", "Leave", "Stay") == "Leave")
if(!CHECK_MOBILITY(user, MOBILITY_MOVE) || (get_dist(get_turf(src), get_turf(user)) > 1)) //no teleporting around if they're dead or moved away during the prompt.
return
user.forceMove(get_turf(parentSphere))
diff --git a/code/modules/shuttle/assault_pod.dm b/code/modules/shuttle/assault_pod.dm
index 43877819a3..1258b9f4b8 100644
--- a/code/modules/shuttle/assault_pod.dm
+++ b/code/modules/shuttle/assault_pod.dm
@@ -35,7 +35,7 @@
/obj/item/assault_pod/attack_self(mob/living/user)
var/target_area
- target_area = tgui_input_list(user, "Area to land", "Select a Landing Zone", GLOB.teleportlocs)
+ target_area = input("Area to land", "Select a Landing Zone", target_area) as null|anything in GLOB.teleportlocs
if(!target_area)
return
var/area/picked_area = GLOB.teleportlocs[target_area]
diff --git a/code/modules/shuttle/navigation_computer.dm b/code/modules/shuttle/navigation_computer.dm
index 05ecb3f05c..a215b58b55 100644
--- a/code/modules/shuttle/navigation_computer.dm
+++ b/code/modules/shuttle/navigation_computer.dm
@@ -346,7 +346,7 @@
L["([L.len]) [nav_beacon.name] locked"] = null
playsound(console, 'sound/machines/terminal_prompt.ogg', 25, 0)
- var/selected = tgui_input_list(usr, "Choose location to jump to", "Locations", L)
+ var/selected = input("Choose location to jump to", "Locations", null) as null|anything in L
if(QDELETED(src) || QDELETED(target) || !isliving(target))
return
playsound(src, "terminal_type", 25, 0)
diff --git a/code/modules/shuttle/spaceship_navigation_beacon.dm b/code/modules/shuttle/spaceship_navigation_beacon.dm
index de826af62f..dbf81d791e 100644
--- a/code/modules/shuttle/spaceship_navigation_beacon.dm
+++ b/code/modules/shuttle/spaceship_navigation_beacon.dm
@@ -43,7 +43,7 @@
if(!I.tool_behaviour == TOOL_MULTITOOL)
return
if(panel_open)
- var/new_name = "Beacon_[tgui_input_list(user, "Enter the custom name for this beacon", "It be Beacon ..your input..")]"
+ var/new_name = "Beacon_[input("Enter the custom name for this beacon", "It be Beacon ..your input..") as text]"
if(new_name && Adjacent(user))
name = new_name
to_chat(user, "You change beacon name to [name].")
diff --git a/code/modules/shuttle/special.dm b/code/modules/shuttle/special.dm
index 87f9b55aa9..05450fd7c2 100644
--- a/code/modules/shuttle/special.dm
+++ b/code/modules/shuttle/special.dm
@@ -44,7 +44,7 @@
/obj/machinery/power/emitter/energycannon/magical/attackby(obj/item/W, mob/user, params)
return
-/obj/machinery/power/emitter/energycannon/magical/ex_act(severity)
+/obj/machinery/power/emitter/energycannon/magical/ex_act(severity, target, origin)
return
/obj/machinery/power/emitter/energycannon/magical/emag_act(mob/user)
diff --git a/code/modules/smithing/anvil.dm b/code/modules/smithing/anvil.dm
index c89f338f29..9dffc883d4 100644
--- a/code/modules/smithing/anvil.dm
+++ b/code/modules/smithing/anvil.dm
@@ -115,7 +115,7 @@
currentquality += qualitychange
var/list/shapingsteps = list("weak hit", "strong hit", "heavy hit", "fold", "draw", "shrink", "bend", "punch", "upset") //weak/strong/heavy hit affect strength. All the other steps shape.
workpiece_state = WORKPIECE_INPROGRESS
- var/stepdone = tgui_input_list(user, "How would you like to work the metal?", "", shapingsteps)
+ var/stepdone = input(user, "How would you like to work the metal?") in shapingsteps
var/steptime = 50
if(user.mind.skill_holder)
var/skillmod = user.mind.get_skill_level(/datum/skill/level/dwarfy/blacksmithing)/10 + 1
diff --git a/code/modules/spells/spell.dm b/code/modules/spells/spell.dm
index c999f01794..2272a14612 100644
--- a/code/modules/spells/spell.dm
+++ b/code/modules/spells/spell.dm
@@ -376,11 +376,11 @@ GLOBAL_LIST_INIT(spells, typesof(/obj/effect/proc_holder/spell)) //needed for th
continue
possible_targets += M
- //targets += tgui_input_list(user, "Choose the target for the spell.", "Targeting", possible_targets)
+ //targets += input("Choose the target for the spell.", "Targeting") as mob in possible_targets
//Adds a safety check post-input to make sure those targets are actually in range.
var/mob/M
if(!random_target)
- M = tgui_input_list(user, "Choose the target for the spell.", "Targeting", sortNames(possible_targets))
+ M = input("Choose the target for the spell.", "Targeting") as null|mob in sortNames(possible_targets)
else
switch(random_target_priority)
if(TARGET_RANDOM)
diff --git a/code/modules/spells/spell_types/area_teleport.dm b/code/modules/spells/spell_types/area_teleport.dm
index 19a0d12a2b..50d5ee0ad6 100644
--- a/code/modules/spells/spell_types/area_teleport.dm
+++ b/code/modules/spells/spell_types/area_teleport.dm
@@ -28,7 +28,7 @@
var/A = null
if(!randomise_selection)
- A = tgui_input_list(usr, "Area to teleport to", "Teleport", GLOB.teleportlocs)
+ A = input("Area to teleport to", "Teleport", A) as null|anything in GLOB.teleportlocs
else
A = pick(GLOB.teleportlocs)
if(!A)
diff --git a/code/modules/spells/spell_types/devil.dm b/code/modules/spells/spell_types/devil.dm
index 3ff78e24c2..3b76107905 100644
--- a/code/modules/spells/spell_types/devil.dm
+++ b/code/modules/spells/spell_types/devil.dm
@@ -54,7 +54,7 @@
user.put_in_hands(contract)
else
var/obj/item/paper/contract/infernal/contract // = new(user.loc, C.mind, contractType, user.mind)
- var/contractTypeName = tgui_input_list(user, "What type of contract?", "", list("Power", "Wealth", "Prestige", "Magic", "Knowledge", "Friendship"))
+ var/contractTypeName = input(user, "What type of contract?") in list ("Power", "Wealth", "Prestige", "Magic", "Knowledge", "Friendship")
switch(contractTypeName)
if("Power")
contract = new /obj/item/paper/contract/infernal/power(C.loc, C.mind, user.mind)
diff --git a/code/modules/spells/spell_types/devil_boons.dm b/code/modules/spells/spell_types/devil_boons.dm
index 2be22f6ecb..cf11466d19 100644
--- a/code/modules/spells/spell_types/devil_boons.dm
+++ b/code/modules/spells/spell_types/devil_boons.dm
@@ -43,7 +43,7 @@
for(var/mob/C in targets)
if(!C.client)
continue
- C.client.view_size.setTo((tgui_input_list(user, "Select view range:", "Range", ranges - 7)))
+ C.client.view_size.setTo((input("Select view range:", "Range", 4) in ranges) - 7)
/obj/effect/proc_holder/spell/targeted/summon_friend
name = "Summon Friend"
diff --git a/code/modules/spells/spell_types/ethereal_jaunt.dm b/code/modules/spells/spell_types/ethereal_jaunt.dm
index 7a05583071..1bc3a054b7 100644
--- a/code/modules/spells/spell_types/ethereal_jaunt.dm
+++ b/code/modules/spells/spell_types/ethereal_jaunt.dm
@@ -105,7 +105,7 @@
forceMove(newLoc)
-/obj/effect/dummy/phased_mob/spell_jaunt/ex_act(blah)
+/obj/effect/dummy/phased_mob/spell_jaunt/ex_act(severity, target, origin)
return
/obj/effect/dummy/phased_mob/spell_jaunt/wave_ex_act(power, datum/wave_explosion/explosion, dir)
diff --git a/code/modules/spells/spell_types/shadow_walk.dm b/code/modules/spells/spell_types/shadow_walk.dm
index 821bf73425..9b311ee1a6 100644
--- a/code/modules/spells/spell_types/shadow_walk.dm
+++ b/code/modules/spells/spell_types/shadow_walk.dm
@@ -87,7 +87,7 @@
qdel(src)
check_light_level()
-/obj/effect/dummy/phased_mob/shadow/ex_act()
+/obj/effect/dummy/phased_mob/shadow/ex_act(severity, target, origin)
return
/obj/effect/dummy/phased_mob/shadow/wave_ex_act(power, datum/wave_explosion/explosion, dir)
diff --git a/code/modules/spells/spell_types/shapeshift.dm b/code/modules/spells/spell_types/shapeshift.dm
index f686fdfcd5..67c2e3e941 100644
--- a/code/modules/spells/spell_types/shapeshift.dm
+++ b/code/modules/spells/spell_types/shapeshift.dm
@@ -34,7 +34,7 @@
for(var/path in possible_shapes)
var/mob/living/simple_animal/A = path
animal_list[initial(A.name)] = path
- var/new_shapeshift_type = tgui_input_list(M, "Choose Your Animal Form!", "It's Morphing Time!", animal_list)
+ var/new_shapeshift_type = input(M, "Choose Your Animal Form!", "It's Morphing Time!", null) as null|anything in animal_list
if(shapeshift_type)
return
shapeshift_type = new_shapeshift_type
diff --git a/code/modules/spells/spell_types/voice_of_god.dm b/code/modules/spells/spell_types/voice_of_god.dm
index 77a66f74ae..fa41b59c0d 100644
--- a/code/modules/spells/spell_types/voice_of_god.dm
+++ b/code/modules/spells/spell_types/voice_of_god.dm
@@ -24,7 +24,7 @@
/obj/effect/proc_holder/spell/voice_of_god/choose_targets(mob/user = usr)
perform(user=user)
/obj/effect/proc_holder/spell/voice_of_god/perform(list/targets, recharge = 1, mob/user = usr)
- command = tgui_input_text(user, "Speak with the Voice of God", "Command")
+ command = input(user, "Speak with the Voice of God", "Command")
if(QDELETED(src) || QDELETED(user))
return
if(!command)
diff --git a/code/modules/station_goals/bsa.dm b/code/modules/station_goals/bsa.dm
index 442038c563..2f0cba0056 100644
--- a/code/modules/station_goals/bsa.dm
+++ b/code/modules/station_goals/bsa.dm
@@ -226,7 +226,7 @@
invisibility = INVISIBILITY_ABSTRACT
var/obj/machinery/parent
-/obj/structure/filler/ex_act()
+/obj/structure/filler/ex_act(severity, target, origin)
return
/obj/machinery/computer/bsa_control
@@ -286,7 +286,7 @@
var/list/options = gps_locators
if(area_aim)
options += GLOB.teleportlocs
- var/V = tgui_input_list(user,"Select target", "Select target", options)
+ var/V = input(user,"Select target", "Select target",null) in options|null
target = options[V]
diff --git a/code/modules/surgery/graft_synthtissue.dm b/code/modules/surgery/graft_synthtissue.dm
index b036d86005..afe8c9d1d1 100644
--- a/code/modules/surgery/graft_synthtissue.dm
+++ b/code/modules/surgery/graft_synthtissue.dm
@@ -37,7 +37,7 @@
O.on_find(user)
organs -= O
organs[O.name] = O
- chosen_organ = tgui_input_list(user, "Target which organ?", "Surgery", organs)
+ chosen_organ = input("Target which organ?", "Surgery", null, null) as null|anything in organs
chosen_organ = organs[chosen_organ]
if(!chosen_organ)
return -1
diff --git a/code/modules/surgery/helpers.dm b/code/modules/surgery/helpers.dm
index c28c7d9848..652c49519a 100644
--- a/code/modules/surgery/helpers.dm
+++ b/code/modules/surgery/helpers.dm
@@ -53,7 +53,7 @@
if(!available_surgeries.len)
return
- var/P = tgui_input_list(user, "Begin which procedure?", "Surgery", available_surgeries)
+ var/P = input("Begin which procedure?", "Surgery", null, null) as null|anything in available_surgeries
if(P && user && user.Adjacent(M) && (I in user))
var/datum/surgery/S = available_surgeries[P]
diff --git a/code/modules/surgery/organ_manipulation.dm b/code/modules/surgery/organ_manipulation.dm
index 0cbd232afc..0876357e8e 100644
--- a/code/modules/surgery/organ_manipulation.dm
+++ b/code/modules/surgery/organ_manipulation.dm
@@ -105,7 +105,7 @@
O.on_find(user)
organs -= O
organs[O.name] = O
- I = tgui_input_list(user, "Remove which organ?", "Surgery", organs)
+ I = input("Remove which organ?", "Surgery", null, null) as null|anything in organs
if(I && user && target && user.Adjacent(target) && user.get_active_held_item() == tool)
I = organs[I]
if(!I)
diff --git a/code/modules/surgery/organs/augments_arms.dm b/code/modules/surgery/organs/augments_arms.dm
index e3c32ad009..0d2659dff8 100644
--- a/code/modules/surgery/organs/augments_arms.dm
+++ b/code/modules/surgery/organs/augments_arms.dm
@@ -326,49 +326,79 @@
desc = "An internal power cord hooked up to a battery. Useful if you run on electricity. Not so much otherwise."
icon = 'icons/obj/power.dmi'
icon_state = "wire1"
+ var/in_use = FALSE //No stacking doafters
/obj/item/apc_powercord/afterattack(atom/target, mob/user, proximity_flag, click_parameters)
- if(!istype(target, /obj/machinery/power/apc) || !ishuman(user) || !proximity_flag)
+ if((!istype(target, /obj/machinery/power/apc) && !istype(target, /obj/item/stock_parts/cell)) || !ishuman(user) || !proximity_flag)
return ..()
user.DelayNextAction(CLICK_CD_MELEE)
- var/obj/machinery/power/apc/A = target
var/mob/living/carbon/human/H = user
+ if(in_use)
+ to_chat(H, "[src] is already connected to something!")
+ return
var/obj/item/organ/stomach/ipc/cell = locate(/obj/item/organ/stomach/ipc) in H.internal_organs
if(!cell)
- to_chat(H, "You try to siphon energy from the [A], but your power cell is gone!")
+ to_chat(H, "You try to siphon energy from [target], but your power cell is gone!")
return
-
- if(A.cell && A.cell.charge > 0)
- if(H.nutrition >= NUTRITION_LEVEL_WELL_FED)
- to_chat(user, "You are already fully charged!")
+ if(H.nutrition >= NUTRITION_LEVEL_WELL_FED)
+ to_chat(user, "You are already fully charged!")
+ return
+ if(istype(target, /obj/machinery/power/apc))
+ var/obj/machinery/power/apc/A = target
+ if(A.cell && A.cell.charge > 0)
+ in_use = TRUE
+ apc_powerdraw_loop(A, H)
return
- else
- powerdraw_loop(A, H)
+ else //We only let through cells and APCs, so this has to be a cell
+ var/obj/item/stock_parts/cell/C = target
+ if(C.charge > 0)
+ in_use = TRUE
+ cell_powerdraw_loop(C, H)
return
- to_chat(user, "There is no charge to draw from that APC.")
+ to_chat(user, "There is no charge to draw from [target].")
-/obj/item/apc_powercord/proc/powerdraw_loop(obj/machinery/power/apc/A, mob/living/carbon/human/H)
- H.visible_message("[H] inserts a power connector into the [A].", "You begin to draw power from the [A].")
+/obj/item/apc_powercord/proc/apc_powerdraw_loop(obj/machinery/power/apc/A, mob/living/carbon/human/H)
+ H.visible_message("[H] inserts a power connector into [A].", "You begin to draw power from [A].")
while(do_after(H, 10, target = A))
if(loc != H)
to_chat(H, "You must keep your connector out while charging!")
break
if(A.cell.charge == 0)
- to_chat(H, "The [A] doesn't have enough charge to spare.")
+ to_chat(H, "[A] doesn't have enough charge to spare.")
break
A.charging = 1
if(A.cell.charge >= 500)
do_sparks(1, FALSE, A)
- H.nutrition += 50
- A.cell.charge -= 150
+ H.adjust_nutrition(50)
+ A.cell.use(150)
to_chat(H, "You siphon off some of the stored charge for your own use.")
else
- H.nutrition += A.cell.charge/10
- A.cell.charge = 0
- to_chat(H, "You siphon off as much as the [A] can spare.")
+ H.adjust_nutrition(A.cell.charge/10)
+ A.cell.use(A.cell.charge)
+ to_chat(H, "You siphon off as much as [A] can spare.")
break
if(H.nutrition > NUTRITION_LEVEL_WELL_FED)
to_chat(H, "You are now fully charged.")
break
- H.visible_message("[H] unplugs from the [A].", "You unplug from the [A].")
+ in_use = FALSE
+ H.visible_message("[H] unplugs from [A].", "You unplug from [A].")
+
+/obj/item/apc_powercord/proc/cell_powerdraw_loop(obj/item/stock_parts/cell/C, mob/living/carbon/human/H)
+ H.visible_message("[H] connects a power cord to [C]", "You begin to draw power from [C].")
+ while(do_after(H, 10, target = C))
+ if(loc != H)
+ to_chat(H, "You must keep your connector out while charging!")
+ break
+ if(C.charge == 0)
+ to_chat(H, "[C] doesn't have any charge remaining.")
+ break
+ var/siphoned_charge = min(C.charge, 2000)
+ C.use(siphoned_charge)
+ do_sparks(1, FALSE, C)
+ H.adjust_nutrition(siphoned_charge / 100) //Less efficient on a pure power basis than APC recharge. Still a very viable way of gaining nutrition. (100 nutrition / base 10k cell)
+ if(H.nutrition > NUTRITION_LEVEL_WELL_FED)
+ to_chat(H, "You are now fully charged.")
+ break
+ in_use = FALSE
+ H.visible_message("[H] disconnects [src] from [C].", "You disconnect from [C].")
diff --git a/code/modules/surgery/organs/eyes.dm b/code/modules/surgery/organs/eyes.dm
index bc35298953..9861a1b639 100644
--- a/code/modules/surgery/organs/eyes.dm
+++ b/code/modules/surgery/organs/eyes.dm
@@ -280,7 +280,7 @@
var/C = input(owner, "Select Color", "Select color", "#ffffff") as color|null
if(!C || QDELETED(src) || QDELETED(user) || QDELETED(owner) || owner != user)
return
- var/range = tgui_input_num(user, "Enter range (0 - [max_light_beam_distance])", "Range Select", 0)
+ var/range = input(user, "Enter range (0 - [max_light_beam_distance])", "Range Select", 0) as null|num
if(!isnum(range))
return
diff --git a/code/modules/surgery/organs/lungs.dm b/code/modules/surgery/organs/lungs.dm
index 897c7610a1..553cc2d043 100644
--- a/code/modules/surgery/organs/lungs.dm
+++ b/code/modules/surgery/organs/lungs.dm
@@ -90,6 +90,11 @@
max = safe_breath_dam_max,
damage_type = safe_damage_type
)
+ if(ispath(breathing_class))
+ var/datum/breathing_class/class = GLOB.gas_data.breathing_classes[breathing_class]
+ for(var/g in class.gases)
+ if(class.gases[g] > 0)
+ gas_min -= g
//TODO: lung health affects lung function
/obj/item/organ/lungs/onDamage(damage_mod) //damage might be too low atm.
@@ -196,9 +201,9 @@
mole_adjustments[entry] = -required_moles
mole_adjustments[breath_results[entry]] = required_moles
if(required_pp < safe_min)
- var/multiplier = 0
+ var/multiplier = handle_too_little_breath(H, required_pp, safe_min, required_moles)
if(required_moles > 0)
- multiplier = handle_too_little_breath(H, required_pp, safe_min, required_moles) / required_moles
+ multiplier /= required_moles
for(var/adjustment in mole_adjustments)
mole_adjustments[adjustment] *= multiplier
if(alert_category)
@@ -222,8 +227,7 @@
alert_category = breathing_class.high_alert_category
alert_type = breathing_class.high_alert_datum
danger_reagent = breathing_class.danger_reagent
- for(var/gas in gases)
- found_pp += PP(breath, gas)
+ found_pp = breathing_class.get_effective_pp(breath)
else
danger_reagent = danger_reagents[entry]
if(entry in breath_alert_info)
@@ -517,17 +521,20 @@
var/total_moles = breath.total_moles()
for(var/id in breath.get_gases())
var/this_pressure = PP(breath, id)
- var/req_pressure = (this_pressure * SAFE_THRESHOLD_RATIO) - 1
- if(req_pressure > 0)
- gas_min[id] = req_pressure
+ if(id in gas_min)
+ var/req_pressure = (this_pressure * SAFE_THRESHOLD_RATIO) - 1
+ if(req_pressure > 0)
+ gas_min[id] = req_pressure
+ else
+ gas_min -= id // if there's not even enough of the gas to register, we shouldn't need it
if(id in gas_max)
gas_max[id] += this_pressure
- var/bz = breath.get_moles(GAS_BZ)
+ var/bz = breath.get_moles(GAS_BZ) // snowflaked cause it's got special behavior, of course
if(bz)
BZ_trip_balls_min += bz
BZ_brain_damage_min += bz
- gas_max[GAS_N2] = PP(breath, GAS_N2) + 5
+ gas_max[GAS_N2] = max(15, PP(breath, GAS_N2) + 3) // don't want ash lizards breathing on station; sometimes they might be able to, though
var/datum/breathing_class/class = GLOB.gas_data.breathing_classes[breathing_class]
var/o2_pp = class.get_effective_pp(breath)
safe_breath_min = min(3, 0.3 * o2_pp)
diff --git a/code/modules/surgery/organs/organ_internal.dm b/code/modules/surgery/organs/organ_internal.dm
index 1800fe221b..de8e3d623d 100644
--- a/code/modules/surgery/organs/organ_internal.dm
+++ b/code/modules/surgery/organs/organ_internal.dm
@@ -106,7 +106,7 @@
applyOrganDamage(maxHealth * decay_factor * (seconds * 0.5))
/obj/item/organ/proc/can_decay()
- if(CHECK_BITFIELD(organ_flags, ORGAN_NO_SPOIL | ORGAN_SYNTHETIC | ORGAN_FAILING))
+ if(organ_flags & (ORGAN_NO_SPOIL | ORGAN_SYNTHETIC | ORGAN_FAILING))
return FALSE
return TRUE
diff --git a/code/modules/surgery/organs/vocal_cords.dm b/code/modules/surgery/organs/vocal_cords.dm
index e2ddfe6cab..e41980cdd3 100644
--- a/code/modules/surgery/organs/vocal_cords.dm
+++ b/code/modules/surgery/organs/vocal_cords.dm
@@ -46,7 +46,7 @@
/datum/action/item_action/organ_action/use/adamantine_vocal_cords/Trigger()
if(!IsAvailable())
return
- var/message = tgui_input_text(owner, "Resonate a message to all nearby golems.", "Resonate")
+ var/message = input(owner, "Resonate a message to all nearby golems.", "Resonate")
if(QDELETED(src) || QDELETED(owner) || !message)
return
owner.say(".x[message]")
@@ -100,7 +100,7 @@
if(world.time < cords.next_command)
to_chat(owner, "You must wait [DisplayTimeText(cords.next_command - world.time)] before Speaking again.")
return
- var/command = tgui_input_text(owner, "Speak with the Voice of God", "Command")
+ var/command = input(owner, "Speak with the Voice of God", "Command")
if(QDELETED(src) || QDELETED(owner))
return
if(!command)
@@ -644,7 +644,7 @@
/datum/action/item_action/organ_action/velvet/Trigger()
. = ..()
- var/command = tgui_input_text(owner, "Speak in a sultry tone", "Command")
+ var/command = input(owner, "Speak in a sultry tone", "Command")
if(QDELETED(src) || QDELETED(owner))
return
if(!command)
@@ -1220,7 +1220,7 @@
if (E.mental_capacity >= 5)
var/trigger = html_decode(stripped_input(user, "Enter the trigger phrase", MAX_MESSAGE_LEN))
var/custom_words_words_list = list("Speak", "Echo", "Shock", "Cum", "Kneel", "Strip", "Trance", "Cancel")
- var/trigger2 = tgui_input_list(user, "Pick an effect", "Effects", custom_words_words_list)
+ var/trigger2 = input(user, "Pick an effect", "Effects") in custom_words_words_list
trigger2 = lowertext(trigger2)
if ((findtext(trigger2, custom_words_words)))
if (trigger2 == "speak" || trigger2 == "echo")
@@ -1260,7 +1260,7 @@
H.SetStun(1000)
var/trigger = stripped_input(user, "Enter the loop phrase", MAX_MESSAGE_LEN)
var/customSpan = list("Notice", "Warning", "Hypnophrase", "Love", "Velvet")
- var/trigger2 = tgui_input_list(user, "Pick the style", "Style", customSpan)
+ var/trigger2 = input(user, "Pick the style", "Style") in customSpan
trigger2 = lowertext(trigger2)
E.customEcho = trigger
E.customSpan = trigger2
diff --git a/code/modules/surgery/plastic_surgery.dm b/code/modules/surgery/plastic_surgery.dm
index 91809859c0..d3597ba516 100644
--- a/code/modules/surgery/plastic_surgery.dm
+++ b/code/modules/surgery/plastic_surgery.dm
@@ -30,7 +30,7 @@
for(var/_i in 1 to 9)
names += "Subject [target.gender == MALE ? "i" : "o"]-[pick("a", "b", "c", "d", "e")]-[rand(10000, 99999)]"
names += target.dna.species.random_name(target.gender, TRUE) //give one normal name in case they want to do regular plastic surgery
- var/chosen_name = tgui_input_list(user, "Choose a new name to assign.", "Plastic Surgery", names)
+ var/chosen_name = input(user, "Choose a new name to assign.", "Plastic Surgery") as null|anything in names
if(!chosen_name)
return
var/oldname = target.real_name
diff --git a/code/modules/surgery/surgery.dm b/code/modules/surgery/surgery.dm
index 859c5c6d40..0ffae2bb7d 100644
--- a/code/modules/surgery/surgery.dm
+++ b/code/modules/surgery/surgery.dm
@@ -71,7 +71,7 @@
var/turf/T = get_turf(patient)
var/obj/structure/table/optable/table = locate(/obj/structure/table/optable, T)
- if(table?.computer && !CHECK_BITFIELD(table.computer.stat, NOPOWER|BROKEN))
+ if(table?.computer && !(table.computer.stat & (NOPOWER|BROKEN)))
advanced_surgeries |= table.computer.advanced_surgeries
if(istype(tool, /obj/item/surgical_drapes/advanced))
diff --git a/code/modules/tcg/cards.dm b/code/modules/tcg/cards.dm
index 6b1cbd9884..f5c7c47aaf 100644
--- a/code/modules/tcg/cards.dm
+++ b/code/modules/tcg/cards.dm
@@ -214,11 +214,11 @@
result = show_radial_menu(user, src, possible_actions, require_near = TRUE, tooltips = TRUE)
switch(result)
if("Health")
- card_datum.health = tgui_input_num(user, "What do you want health to be?", "Changing [src]'s health", card_datum.health)
+ card_datum.health = input(user, "What do you want health to be?", "Changing [src]'s health") as num|null
if("Attack")
- card_datum.attack = tgui_input_num(user, "What do you want attack to be?", "Changing [src]'s attack", card_datum.attack)
+ card_datum.attack = input(user, "What do you want attack to be?", "Changing [src]'s attack") as num|null
if("Mana")
- card_datum.mana_cost = tgui_input_num(user, "What do you want mana cost to be?", "Changing [src]'s mana cost", card_datum.mana_cost)
+ card_datum.mana_cost = input(user, "What do you want mana cost to be?", "Changing [src]'s mana cost") as num|null
user.visible_message("[user] changes [src]'s [result].")
/obj/item/tcg_card/equipped(mob/user, slot, initial)
@@ -575,7 +575,7 @@
qdel(I)
if(istype(I, /obj/item/tcgcard_deck))
var/obj/item/tcgcard_deck/deck = I
- var/named = tgui_input_text(user, "How will this deck be named? Leave this field empty if you don't want to save this deck.")
+ var/named = input(user, "How will this deck be named? Leave this field empty if you don't want to save this deck.")
if(named)
decks[named] = list()
for(var/obj/item/tcg_card/card in deck.contents)
diff --git a/code/modules/tgui/tgui_input_text.dm b/code/modules/tgui/tgui_input_text.dm
deleted file mode 100644
index a8dcb6a984..0000000000
--- a/code/modules/tgui/tgui_input_text.dm
+++ /dev/null
@@ -1,299 +0,0 @@
-/**
- * Creates a TGUI input text window and returns the user's response.
- *
- * This proc should be used to create alerts that the caller will wait for a response from.
- * Arguments:
- * * user - The user to show the input box to.
- * * message - The content of the input box, shown in the body of the TGUI window.
- * * title - The title of the input box, shown on the top of the TGUI window.
- * * default - The default value pre-populated in the input box.
- * * timeout - The timeout of the input box, after which the input box will close and qdel itself. Set to zero for no timeout.
- */
-/proc/tgui_input_text(mob/user, message, title, default, timeout = 0)
- if (istext(user))
- stack_trace("tgui_input_text() received text for user instead of mob")
- return
- if (!user)
- user = usr
- if (!istype(user))
- if (istype(user, /client))
- var/client/client = user
- user = client.mob
- else
- return
- var/datum/tgui_input_dialog/input = new(user, message, title, default, timeout)
- input.input_type = "text"
- input.ui_interact(user)
- input.wait()
- if (input)
- . = input.choice
- qdel(input)
-
-/**
- * Creates a TGUI input message window and returns the user's response.
- *
- * This proc should be used to create alerts that the caller will wait for a response from.
- * Arguments:
- * * user - The user to show the input box to.
- * * message - The content of the input box, shown in the body of the TGUI window.
- * * title - The title of the input box, shown on the top of the TGUI window.
- * * default - The default value pre-populated in the input box.
- * * timeout - The timeout of the input box, after which the input box will close and qdel itself. Set to zero for no timeout.
- */
-/proc/tgui_input_message(mob/user, message, title, default, timeout = 0)
- if (istext(user))
- stack_trace("tgui_input_message() received text for user instead of mob")
- return
- if (!user)
- user = usr
- if (!istype(user))
- if (istype(user, /client))
- var/client/client = user
- user = client.mob
- else
- return
- var/datum/tgui_input_dialog/input = new(user, message, title, default, timeout)
- input.input_type = "message"
- input.ui_interact(user)
- input.wait()
- if (input)
- . = input.choice
- qdel(input)
-
-/**
- * Creates a TGUI input num window and returns the user's response.
- *
- * This proc should be used to create alerts that the caller will wait for a response from.
- * Arguments:
- * * user - The user to show the input box to.
- * * message - The content of the input box, shown in the body of the TGUI window.
- * * title - The title of the input box, shown on the top of the TGUI window.
- * * default - The default value pre-populated in the input box.
- * * timeout - The timeout of the input box, after which the input box will close and qdel itself. Set to zero for no timeout.
- */
-/proc/tgui_input_num(mob/user, message, title, default, timeout = 0)
- if (istext(user))
- stack_trace("tgui_input_num() received text for user instead of mob")
- return
- if (!user)
- user = usr
- if (!istype(user))
- if (istype(user, /client))
- var/client/client = user
- user = client.mob
- else
- return
- var/datum/tgui_input_dialog/input = new(user, message, title, default, timeout)
- input.input_type = "num"
- input.ui_interact(user)
- input.wait()
- if (input)
- . = input.choice
- qdel(input)
-
-/**
- * Creates an asynchronous TGUI input text window with an associated callback.
- *
- * This proc should be used to create inputs that invoke a callback with the user's chosen option.
- * Arguments:
- * * user - The user to show the input box to.
- * * message - The content of the input box, shown in the body of the TGUI window.
- * * title - The title of the input box, shown on the top of the TGUI window.
- * * default - The default value pre-populated in the input box.
- * * callback - The callback to be invoked when a choice is made.
- * * timeout - The timeout of the input box, after which the menu will close and qdel itself. Set to zero for no timeout.
- */
-/proc/tgui_input_text_async(mob/user, message, title, default, datum/callback/callback, timeout = 60 SECONDS)
- if (istext(user))
- stack_trace("tgui_input_text_async() received text for user instead of mob")
- return
- if (!user)
- user = usr
- if (!istype(user))
- if (istype(user, /client))
- var/client/client = user
- user = client.mob
- else
- return
- var/datum/tgui_input_dialog/async/input = new(user, message, title, default, callback, timeout)
- input.input_type = "text"
- input.ui_interact(user)
-
-/**
- * Creates an asynchronous TGUI input message window with an associated callback.
- *
- * This proc should be used to create inputs that invoke a callback with the user's chosen option.
- * Arguments:
- * * user - The user to show the input box to.
- * * message - The content of the input box, shown in the body of the TGUI window.
- * * title - The title of the input box, shown on the top of the TGUI window.
- * * default - The default value pre-populated in the input box.
- * * callback - The callback to be invoked when a choice is made.
- * * timeout - The timeout of the input box, after which the menu will close and qdel itself. Set to zero for no timeout.
- */
-/proc/tgui_input_message_async(mob/user, message, title, default, datum/callback/callback, timeout = 60 SECONDS)
- if (istext(user))
- stack_trace("tgui_input_message_async() received text for user instead of mob")
- return
- if (!user)
- user = usr
- if (!istype(user))
- if (istype(user, /client))
- var/client/client = user
- user = client.mob
- else
- return
- var/datum/tgui_input_dialog/async/input = new(user, message, title, default, callback, timeout)
- input.input_type = "message"
- input.ui_interact(user)
-
-/**
- * Creates an asynchronous TGUI input num window with an associated callback.
- *
- * This proc should be used to create inputs that invoke a callback with the user's chosen option.
- * Arguments:
- * * user - The user to show the input box to.
- * * message - The content of the input box, shown in the body of the TGUI window.
- * * title - The title of the input box, shown on the top of the TGUI window.
- * * default - The default value pre-populated in the input box.
- * * callback - The callback to be invoked when a choice is made.
- * * timeout - The timeout of the input box, after which the menu will close and qdel itself. Set to zero for no timeout.
- */
-/proc/tgui_input_num_async(mob/user, message, title, default, datum/callback/callback, timeout = 60 SECONDS)
- if (istext(user))
- stack_trace("tgui_input_num_async() received text for user instead of mob")
- return
- if (!user)
- user = usr
- if (!istype(user))
- if (istype(user, /client))
- var/client/client = user
- user = client.mob
- else
- return
- var/datum/tgui_input_dialog/async/input = new(user, message, title, default, callback, timeout)
- input.input_type = "num"
- input.ui_interact(user)
-
-/**
- * # tgui_input_dialog
- *
- * Datum used for instantiating and using a TGUI-controlled input that prompts the user with
- * a message and a box for accepting text/message/num input.
- */
-/datum/tgui_input_dialog
- /// The title of the TGUI window
- var/title
- /// The textual body of the TGUI window
- var/message
- /// The default value to initially populate the input box.
- var/initial
- /// The value that the user input into the input box, null if cancelled.
- var/choice
- /// The time at which the tgui_text_input was created, for displaying timeout progress.
- var/start_time
- /// The lifespan of the tgui_text_input, after which the window will close and delete itself.
- var/timeout
- /// Boolean field describing if the tgui_text_input was closed by the user.
- var/closed
- /// Indicates the data type we want to collect ("text", "message", "num")
- var/input_type = "text"
-
-/datum/tgui_input_dialog/New(mob/user, message, title, default, timeout)
- src.title = title
- src.message = message
- // TODO - Do we need to sanitize the initial value for illegal characters?
- src.initial = default
- if (timeout)
- src.timeout = timeout
- start_time = world.time
- QDEL_IN(src, timeout)
-
-/datum/tgui_input_dialog/Destroy(force, ...)
- SStgui.close_uis(src)
- . = ..()
-
-/**
- * Waits for a user's response to the tgui_text_input's prompt before returning. Returns early if
- * the window was closed by the user.
- */
-/datum/tgui_input_dialog/proc/wait()
- while (!choice && !closed)
- stoplag(1)
-
-/datum/tgui_input_dialog/ui_interact(mob/user, datum/tgui/ui)
- ui = SStgui.try_update_ui(user, src, ui)
- if(!ui)
- ui = new(user, src, "InputModal")
- ui.open()
-
-/datum/tgui_input_dialog/ui_close(mob/user)
- . = ..()
- closed = TRUE
-
-/datum/tgui_input_dialog/ui_state(mob/user)
- return GLOB.always_state
-
-/datum/tgui_input_dialog/ui_static_data(mob/user)
- . = list(
- "title" = title,
- "message" = message,
- "initial" = initial,
- "input_type" = input_type
- )
-
-/datum/tgui_input_dialog/ui_data(mob/user)
- . = list()
- if(timeout)
- .["timeout"] = clamp((timeout - (world.time - start_time) - 1 SECONDS) / (timeout - 1 SECONDS), 0, 1)
-
-/datum/tgui_input_dialog/ui_act(action, list/params)
- . = ..()
- if (.)
- return
- switch(action)
- if("choose")
- set_choice(params["choice"])
- if(isnull(src.choice))
- return
- SStgui.close_uis(src)
- return TRUE
- if("cancel")
- SStgui.close_uis(src)
- closed = TRUE
- return TRUE
-
-/datum/tgui_input_dialog/proc/set_choice(choice)
- if(input_type == "num")
- src.choice = text2num(choice)
- return
- src.choice = choice
-
-/**
- * # async tgui_text_input
- *
- * An asynchronous version of tgui_text_input to be used with callbacks instead of waiting on user responses.
- */
-/datum/tgui_input_dialog/async
- /// The callback to be invoked by the tgui_text_input upon having a choice made.
- var/datum/callback/callback
-
-/datum/tgui_input_dialog/async/New(mob/user, message, title, default, callback, timeout)
- ..(user, title, message, default, timeout)
- src.callback = callback
-
-/datum/tgui_input_dialog/async/Destroy(force, ...)
- QDEL_NULL(callback)
- . = ..()
-
-/datum/tgui_input_dialog/async/ui_close(mob/user)
- . = ..()
- qdel(src)
-
-/datum/tgui_input_dialog/async/set_choice(choice)
- . = ..()
- if(!isnull(src.choice))
- callback?.InvokeAsync(src.choice)
-
-/datum/tgui_input_dialog/async/wait()
- return
diff --git a/code/modules/tgui_panel/external.dm b/code/modules/tgui_panel/external.dm
index 3db779c758..89973a925d 100644
--- a/code/modules/tgui_panel/external.dm
+++ b/code/modules/tgui_panel/external.dm
@@ -17,7 +17,7 @@
nuke_chat()
// Failed to fix
- action = tgui_alert(src, "Did that work?", "", list("Yes", "No, switch to old ui"))
+ action = alert(src, "Did that work?", "", "Yes", "No, switch to old ui")
if (action == "No, switch to old ui")
winset(src, "output", "on-show=&is-disabled=0&is-visible=1")
winset(src, "browseroutput", "is-disabled=1;is-visible=0")
diff --git a/code/modules/vending/_vending.dm b/code/modules/vending/_vending.dm
index 6434a694b1..eab1c55ca9 100644
--- a/code/modules/vending/_vending.dm
+++ b/code/modules/vending/_vending.dm
@@ -1141,7 +1141,7 @@ GLOBAL_LIST_EMPTY(vending_products)
var/price = 1
/obj/item/price_tagger/attack_self(mob/user)
- price = max(1, round(tgui_input_num(user,"set price","price"), 1))
+ price = max(1, round(input(user,"set price","price") as num|null, 1))
to_chat(user, " The [src] will now give things a [price] cr tag.")
/obj/item/price_tagger/afterattack(atom/target, mob/user, proximity)
diff --git a/code/modules/vending/clothesmate.dm b/code/modules/vending/clothesmate.dm
index 8822ef2ff0..05166bf2c3 100644
--- a/code/modules/vending/clothesmate.dm
+++ b/code/modules/vending/clothesmate.dm
@@ -192,7 +192,8 @@
/obj/item/clothing/under/costume/cheongsam = 3,
/obj/item/clothing/under/costume/cheongsam/white = 3,
/obj/item/clothing/under/costume/cheongsam/red = 3,
- /obj/item/storage/backpack/snail = 3)
+ /obj/item/storage/backpack/snail = 3,
+ /obj/item/umbrella = 5)
contraband = list(/obj/item/clothing/accessory/turtleneck/tactifool/syndicate = 3,
/obj/item/clothing/under/syndicate/tacticool = 3,
/obj/item/clothing/under/syndicate/tacticool/skirt = 3,
diff --git a/code/modules/vore/eating/belly_obj.dm b/code/modules/vore/eating/belly_obj.dm
index 8e74dd3c92..474c912c23 100644
--- a/code/modules/vore/eating/belly_obj.dm
+++ b/code/modules/vore/eating/belly_obj.dm
@@ -278,14 +278,14 @@
SEND_SIGNAL(OW, COMSIG_ADD_MOOD_EVENT, "emptypred", /datum/mood_event/emptypred)
SEND_SIGNAL(ML, COMSIG_ADD_MOOD_EVENT, "emptyprey", /datum/mood_event/emptyprey)
- if(CHECK_BITFIELD(ML.vore_flags,ABSORBED))
- DISABLE_BITFIELD(ML.vore_flags,ABSORBED)
+ if((ML.vore_flags & ABSORBED))
+ ML.vore_flags &= ~(ABSORBED)
if(ishuman(M) && ishuman(OW))
var/mob/living/carbon/human/Prey = M
var/mob/living/carbon/human/Pred = OW
var/absorbed_count = 2 //Prey that we were, plus the pred gets a portion
for(var/mob/living/P in contents)
- if(CHECK_BITFIELD(P.vore_flags,ABSORBED))
+ if((P.vore_flags & ABSORBED))
absorbed_count++
Pred.reagents.trans_to(Prey, Pred.reagents.total_volume / absorbed_count)
@@ -390,7 +390,7 @@
formatted_message = replacetext(formatted_message,"%pred",owner)
formatted_message = replacetext(formatted_message,"%prey",english_list(contents))
for(var/mob/living/P in contents)
- if(!CHECK_BITFIELD(P.vore_flags, ABSORBED)) //This is required first, in case there's a person absorbed and not absorbed in a stomach.
+ if(!(P.vore_flags & ABSORBED)) //This is required first, in case there's a person absorbed and not absorbed in a stomach.
total_bulge += P.mob_size
if(total_bulge >= bulge_size && bulge_size != 0)
return("[formatted_message] ")
@@ -485,7 +485,7 @@
// Handle a mob being absorbed
/obj/belly/proc/absorb_living(var/mob/living/M)
- ENABLE_BITFIELD(M.vore_flags, ABSORBED)
+ M.vore_flags |= ABSORBED
to_chat(M,"[owner]'s [lowertext(name)] absorbs your body, making you part of them.")
to_chat(owner,"Your [lowertext(name)] absorbs [M]'s body, making them part of you.")
@@ -499,7 +499,7 @@
for(var/belly in M.vore_organs)
var/obj/belly/B = belly
for(var/mob/living/Mm in B)
- if(CHECK_BITFIELD(Mm.vore_flags, ABSORBED))
+ if((Mm.vore_flags & ABSORBED))
absorb_living(Mm)
//Update owner
diff --git a/code/modules/vore/eating/bellymodes.dm b/code/modules/vore/eating/bellymodes.dm
index 8d64ee28f1..7828de8cde 100644
--- a/code/modules/vore/eating/bellymodes.dm
+++ b/code/modules/vore/eating/bellymodes.dm
@@ -76,7 +76,7 @@
play_sound = pick(pred_digest)
//Pref protection!
- if (!CHECK_BITFIELD(M.vore_flags, DIGESTABLE) || M.vore_flags & ABSORBED)
+ if (!(M.vore_flags & DIGESTABLE) || M.vore_flags & ABSORBED)
continue
//Person just died in guts!
@@ -165,7 +165,7 @@
for (var/mob/living/M in contents)
if(M.vore_flags & ABSORBED && owner.nutrition >= 100)
- DISABLE_BITFIELD(M.vore_flags, ABSORBED)
+ M.vore_flags &= ~(ABSORBED)
to_chat(M,"You suddenly feel solid again ")
to_chat(owner,"You feel like a part of you is missing.")
owner.adjust_nutrition(-100)
diff --git a/code/modules/vore/eating/living.dm b/code/modules/vore/eating/living.dm
index f65ffd3f82..1f4950eaa7 100644
--- a/code/modules/vore/eating/living.dm
+++ b/code/modules/vore/eating/living.dm
@@ -33,7 +33,7 @@
return TRUE
/mob/living/proc/init_vore()
- ENABLE_BITFIELD(vore_flags, VORE_INIT)
+ vore_flags |= VORE_INIT
//Something else made organs, meanwhile.
if(LAZYLEN(vore_organs))
return TRUE
@@ -75,7 +75,7 @@
lazy_init_belly()
if(pred == prey) //you click your target
- if(!CHECK_BITFIELD(pred.vore_flags,FEEDING))
+ if(!(pred.vore_flags & FEEDING))
to_chat(user, "They aren't able to be fed.")
to_chat(pred, "[user] tried to feed you themselves, but you aren't voracious enough to be fed.")
return
@@ -85,11 +85,11 @@
feed_grabbed_to_self(user, prey)
else // click someone other than you/prey
- if(!CHECK_BITFIELD(pred.vore_flags,FEEDING))
+ if(!(pred.vore_flags & FEEDING))
to_chat(user, "They aren't voracious enough to be fed.")
to_chat(pred, "[user] tried to feed you [prey], but you aren't voracious enough to be fed.")
return
- if(!CHECK_BITFIELD(prey.vore_flags,FEEDING))
+ if(!(prey.vore_flags & FEEDING))
to_chat(user, "They aren't able to be fed to someone.")
to_chat(prey, "[user] tried to feed you to [pred], but you aren't able to be fed to them.")
return
@@ -104,12 +104,12 @@
/mob/living/proc/feed_self_to_grabbed(var/mob/living/user, var/mob/living/pred)
pred.lazy_init_belly()
- var/belly = tgui_input_list(user, "Choose Belly", "", pred.vore_organs)
+ var/belly = input("Choose Belly") in pred.vore_organs
return perform_the_nom(user, user, pred, belly)
/mob/living/proc/feed_grabbed_to_other(var/mob/living/user, var/mob/living/prey, var/mob/living/pred)
pred.lazy_init_belly()
- var/belly = tgui_input_list(user, "Choose Belly", "", pred.vore_organs)
+ var/belly = input("Choose Belly") in pred.vore_organs
return perform_the_nom(user, prey, pred, belly)
//
@@ -122,7 +122,7 @@
testing("[user] attempted to feed [prey] to [pred], via [lowertext(belly.name)] but it went wrong.")
return
- if (!CHECK_BITFIELD(prey.vore_flags, DEVOURABLE))
+ if (!(prey.vore_flags & DEVOURABLE))
to_chat(user, "This can't be eaten!")
return FALSE
@@ -226,7 +226,7 @@
//You're in a belly!
if(isbelly(loc))
var/obj/belly/B = loc
- var/confirm = tgui_alert(src, "You're in a mob. If you're otherwise unable to escape from a pred AFK for a long time, use this.", "Confirmation", list("Okay", "Cancel"))
+ var/confirm = alert(src, "You're in a mob. If you're otherwise unable to escape from a pred AFK for a long time, use this.", "Confirmation", "Okay", "Cancel")
if(!confirm == "Okay" || loc != B)
return
//Actual escaping
@@ -246,7 +246,7 @@
else if(istype(loc, /obj/item/dogborg/sleeper))
var/obj/item/dogborg/sleeper/belly = loc //The belly!
- var/confirm = tgui_alert(src, "You're in a dogborg sleeper. This is for escaping from preference-breaking or if your predator disconnects/AFKs. You can also resist out naturally too.", "Confirmation", list("Okay", "Cancel"))
+ var/confirm = alert(src, "You're in a dogborg sleeper. This is for escaping from preference-breaking or if your predator disconnects/AFKs. You can also resist out naturally too.", "Confirmation", "Okay", "Cancel")
if(!confirm == "Okay" || loc != belly)
return
//Actual escaping
@@ -283,7 +283,7 @@
if(!client || !client.prefs)
to_chat(src,"You attempted to apply your vore prefs but somehow you're in this character without a client.prefs variable. Tell a dev.")
return FALSE
- ENABLE_BITFIELD(vore_flags,VOREPREF_INIT)
+ vore_flags |= VOREPREF_INIT
COPY_SPECIFIC_BITFIELDS(vore_flags, client.prefs.vore_flags, DIGESTABLE | DEVOURABLE | FEEDING | LICKABLE | SMELLABLE | ABSORBABLE | MOBVORE)
vore_taste = client.prefs.vore_taste
vore_smell = client.prefs.vore_smell
diff --git a/code/modules/vore/eating/vorepanel.dm b/code/modules/vore/eating/vorepanel.dm
index 6ea0693df2..a44760ae69 100644
--- a/code/modules/vore/eating/vorepanel.dm
+++ b/code/modules/vore/eating/vorepanel.dm
@@ -181,15 +181,15 @@
data["selected"] = selected_list
data["prefs"] = list(
- "digestable" = CHECK_BITFIELD(host.vore_flags, DIGESTABLE),
- "devourable" = CHECK_BITFIELD(host.vore_flags, DEVOURABLE),
- "feeding" = CHECK_BITFIELD(host.vore_flags, FEEDING),
- "absorbable" = CHECK_BITFIELD(host.vore_flags, ABSORBABLE),
- "allowmobvore" = CHECK_BITFIELD(host.vore_flags, MOBVORE),
- "vore_sounds" = CHECK_BITFIELD(host.client.prefs.cit_toggles, EATING_NOISES),
- "digestion_sounds" = CHECK_BITFIELD(host.client.prefs.cit_toggles, DIGESTION_NOISES),
- "lickable" = CHECK_BITFIELD(host.vore_flags, LICKABLE),
- "smellable" = CHECK_BITFIELD(host.vore_flags, SMELLABLE),
+ "digestable" = (host.vore_flags & DIGESTABLE),
+ "devourable" = (host.vore_flags & DEVOURABLE),
+ "feeding" = (host.vore_flags & FEEDING),
+ "absorbable" = (host.vore_flags & ABSORBABLE),
+ "allowmobvore" = (host.vore_flags & MOBVORE),
+ "vore_sounds" = (host.client.prefs.cit_toggles & EATING_NOISES),
+ "digestion_sounds" = (host.client.prefs.cit_toggles & DIGESTION_NOISES),
+ "lickable" = (host.vore_flags & LICKABLE),
+ "smellable" = (host.vore_flags & SMELLABLE),
)
return data
@@ -222,7 +222,7 @@
if(host.vore_organs.len >= BELLIES_MAX)
return FALSE
- var/new_name = html_encode(tgui_input_text(usr,"New belly's name:","New Belly"))
+ var/new_name = html_encode(input(usr,"New belly's name:","New Belly") as text|null)
var/failure_msg
if(length(new_name) > BELLIES_NAME_MAX || length(new_name) < BELLIES_NAME_MIN)
@@ -283,7 +283,7 @@
unsaved_changes = FALSE
return TRUE
if("setflavor")
- var/new_flavor = html_encode(tgui_input_message(usr,"What your character tastes like (400ch limit). This text will be printed to the pred after 'X tastes of...' so just put something like 'strawberries and cream':","Character Flavor",host.vore_taste))
+ var/new_flavor = html_encode(input(usr,"What your character tastes like (400ch limit). This text will be printed to the pred after 'X tastes of...' so just put something like 'strawberries and cream':","Character Flavor",host.vore_taste) as text|null)
if(!new_flavor)
return FALSE
@@ -295,7 +295,7 @@
unsaved_changes = TRUE
return TRUE
if("setsmell")
- var/new_smell = html_encode(tgui_input_message(usr,"What your character smells like (400ch limit). This text will be printed to the pred after 'X smells of...' so just put something like 'strawberries and cream':","Character Smell",host.vore_smell))
+ var/new_smell = html_encode(input(usr,"What your character smells like (400ch limit). This text will be printed to the pred after 'X smells of...' so just put something like 'strawberries and cream':","Character Smell",host.vore_smell) as text|null)
if(!new_smell)
return FALSE
@@ -307,49 +307,49 @@
unsaved_changes = TRUE
return TRUE
if("toggle_digest")
- TOGGLE_BITFIELD(host.vore_flags, DIGESTABLE)
+ (host.vore_flags ^= DIGESTABLE)
if(host.client.prefs)
COPY_SPECIFIC_BITFIELDS(host.client.prefs.vore_flags, host.vore_flags, DIGESTABLE)
unsaved_changes = TRUE
return TRUE
if("toggle_devour")
- TOGGLE_BITFIELD(host.vore_flags, DEVOURABLE)
+ (host.vore_flags ^= DEVOURABLE)
if(host.client.prefs)
COPY_SPECIFIC_BITFIELDS(host.client.prefs.vore_flags, host.vore_flags, DEVOURABLE)
unsaved_changes = TRUE
return TRUE
if("toggle_feed")
- TOGGLE_BITFIELD(host.vore_flags, FEEDING)
+ (host.vore_flags ^= FEEDING)
if(host.client.prefs)
COPY_SPECIFIC_BITFIELDS(host.client.prefs.vore_flags, host.vore_flags, FEEDING)
unsaved_changes = TRUE
return TRUE
if("toggle_absorbable")
- TOGGLE_BITFIELD(host.vore_flags, ABSORBABLE)
+ (host.vore_flags ^= ABSORBABLE)
if(host.client.prefs)
COPY_SPECIFIC_BITFIELDS(host.client.prefs.vore_flags, host.vore_flags, ABSORBABLE)
unsaved_changes = TRUE
return TRUE
if("toggle_mobvore")
- TOGGLE_BITFIELD(host.vore_flags, MOBVORE)
+ (host.vore_flags ^= MOBVORE)
if(host.client.prefs)
COPY_SPECIFIC_BITFIELDS(host.client.prefs.vore_flags, host.vore_flags, MOBVORE)
unsaved_changes = TRUE
return TRUE
if("toggle_vore_sounds")
- TOGGLE_BITFIELD(host.client.prefs.cit_toggles, EATING_NOISES)
+ (host.client.prefs.cit_toggles ^= EATING_NOISES)
unsaved_changes = TRUE
return TRUE
if("toggle_digestion_sounds")
- TOGGLE_BITFIELD(host.client.prefs.cit_toggles, DIGESTION_NOISES)
+ (host.client.prefs.cit_toggles ^= DIGESTION_NOISES)
unsaved_changes = TRUE
return TRUE
if("toggle_lickable")
- TOGGLE_BITFIELD(host.vore_flags, LICKABLE)
+ (host.vore_flags ^= LICKABLE)
unsaved_changes = TRUE
return TRUE
if("toggle_smellable")
- TOGGLE_BITFIELD(host.vore_flags, SMELLABLE)
+ (host.vore_flags ^= SMELLABLE)
unsaved_changes = TRUE
return TRUE
@@ -504,7 +504,7 @@
var/attr = params["attribute"]
switch(attr)
if("b_name")
- var/new_name = html_encode(tgui_input_text(usr,"Belly's new name:","New Name", host.vore_selected.name))
+ var/new_name = html_encode(input(usr,"Belly's new name:","New Name") as text|null)
var/failure_msg
if(length(new_name) > BELLIES_NAME_MAX || length(new_name) < BELLIES_NAME_MIN)
@@ -538,7 +538,7 @@
host.vore_selected.digest_mode = new_mode
. = TRUE
if("b_desc")
- var/new_desc = html_encode(tgui_input_message(usr,"Belly Description ([BELLIES_DESC_MAX] char limit):","New Description",host.vore_selected.desc))
+ var/new_desc = html_encode(input(usr,"Belly Description ([BELLIES_DESC_MAX] char limit):","New Description",host.vore_selected.desc) as message|null)
if(new_desc)
new_desc = readd_quotes(new_desc)
@@ -552,27 +552,27 @@
var/help = " Press enter twice to separate messages. '%pred' will be replaced with your name. '%prey' will be replaced with the prey's name. '%belly' will be replaced with your belly's name. '%count' will be replaced with the number of anything in your belly (will not work for absorbed examine). '%countprey' will be replaced with the number of living prey in your belly (or absorbed prey for absorbed examine)."
switch(params["msgtype"])
if("dmp")
- var/new_message = tgui_input_message(user,"These are sent to prey when they expire. Write them in 2nd person ('you feel X'). Avoid using %prey in this type."+help,"Digest Message (to prey)",host.vore_selected.get_messages("dmp"))
+ var/new_message = input(user,"These are sent to prey when they expire. Write them in 2nd person ('you feel X'). Avoid using %prey in this type."+help,"Digest Message (to prey)",host.vore_selected.get_messages("dmp")) as message
if(new_message)
host.vore_selected.set_messages(new_message,"dmp")
if("dmo")
- var/new_message = tgui_input_message(user,"These are sent to you when prey expires in you. Write them in 2nd person ('you feel X'). Avoid using %pred in this type."+help,"Digest Message (to you)",host.vore_selected.get_messages("dmo"))
+ var/new_message = input(user,"These are sent to you when prey expires in you. Write them in 2nd person ('you feel X'). Avoid using %pred in this type."+help,"Digest Message (to you)",host.vore_selected.get_messages("dmo")) as message
if(new_message)
host.vore_selected.set_messages(new_message,"dmo")
if("smo")
- var/new_message = tgui_input_message(user,"These are sent to those nearby when prey struggles. Write them in 3rd person ('X's Y bulges')."+help,"Struggle Message (outside)",host.vore_selected.get_messages("smo"))
+ var/new_message = input(user,"These are sent to those nearby when prey struggles. Write them in 3rd person ('X's Y bulges')."+help,"Struggle Message (outside)",host.vore_selected.get_messages("smo")) as message
if(new_message)
host.vore_selected.set_messages(new_message,"smo")
if("smi")
- var/new_message = tgui_input_message(user,"These are sent to prey when they struggle. Write them in 2nd person ('you feel X'). Avoid using %prey in this type."+help,"Struggle Message (inside)",host.vore_selected.get_messages("smi"))
+ var/new_message = input(user,"These are sent to prey when they struggle. Write them in 2nd person ('you feel X'). Avoid using %prey in this type."+help,"Struggle Message (inside)",host.vore_selected.get_messages("smi")) as message
if(new_message)
host.vore_selected.set_messages(new_message,"smi")
if("em")
- var/new_message = tgui_input_message(user,"These are sent to people who examine you when this belly has contents. Write them in 3rd person ('Their %belly is bulging')."+help,"Examine Message (when full)",host.vore_selected.get_messages("em"))
+ var/new_message = input(user,"These are sent to people who examine you when this belly has contents. Write them in 3rd person ('Their %belly is bulging')."+help,"Examine Message (when full)",host.vore_selected.get_messages("em")) as message
if(new_message)
host.vore_selected.set_messages(new_message,"em")
@@ -587,7 +587,7 @@
host.vore_selected.emote_lists = initial(host.vore_selected.emote_lists)
. = TRUE
if("b_verb")
- var/new_verb = html_encode(tgui_input_text(usr,"New verb when eating (infinitive tense, e.g. nom or swallow):","New Verb", host.vore_selected.vore_verb))
+ var/new_verb = html_encode(input(usr,"New verb when eating (infinitive tense, e.g. nom or swallow):","New Verb") as text|null)
if(length(new_verb) > BELLIES_NAME_MAX || length(new_verb) < BELLIES_NAME_MIN)
tgui_alert_async(usr, "Entered verb length invalid (must be longer than [BELLIES_NAME_MIN], no longer than [BELLIES_NAME_MAX]).","Error")
@@ -626,7 +626,7 @@
host.vore_selected.can_taste = !host.vore_selected.can_taste
. = TRUE
if("b_bulge_size")
- var/new_bulge = tgui_input_num(user, "Choose the required size prey must be to show up on examine, ranging from 25% to 200% Set this to 0 for no text on examine.", "Set Belly Examine Size.", host.vore_selected.bulge_size)
+ var/new_bulge = input(user, "Choose the required size prey must be to show up on examine, ranging from 25% to 200% Set this to 0 for no text on examine.", "Set Belly Examine Size.") as num|null
if(new_bulge == null)
return FALSE
if(new_bulge == 0) //Disable.
@@ -650,17 +650,17 @@
host.vore_selected.escapable = 0
. = TRUE
if("b_escapechance")
- var/escape_chance_input = tgui_input_num(user, "Set prey escape chance on resist (as %)", "Prey Escape Chance", host.vore_selected.escapechance)
+ var/escape_chance_input = input(user, "Set prey escape chance on resist (as %)", "Prey Escape Chance") as num|null
if(!isnull(escape_chance_input)) //These have to be 'null' because both cancel and 0 are valid, separate options
host.vore_selected.escapechance = sanitize_integer(escape_chance_input, 0, 100, initial(host.vore_selected.escapechance))
. = TRUE
if("b_escapetime")
- var/escape_time_input = tgui_input_num(user, "Set number of seconds for prey to escape on resist (1-60)", "Prey Escape Time", host.vore_selected.escapetime)
+ var/escape_time_input = input(user, "Set number of seconds for prey to escape on resist (1-60)", "Prey Escape Time") as num|null
if(!isnull(escape_time_input))
host.vore_selected.escapetime = sanitize_integer(escape_time_input*10, 10, 600, initial(host.vore_selected.escapetime))
. = TRUE
if("b_transferchance")
- var/transfer_chance_input = tgui_input_num(user, "Set belly transfer chance on resist (as %). You must also set the location for this to have any effect.", "Prey Escape Time", host.vore_selected.transferchance)
+ var/transfer_chance_input = input(user, "Set belly transfer chance on resist (as %). You must also set the location for this to have any effect.", "Prey Escape Time") as num|null
if(!isnull(transfer_chance_input))
host.vore_selected.transferchance = sanitize_integer(transfer_chance_input, 0, 100, initial(host.vore_selected.transferchance))
. = TRUE
@@ -675,12 +675,12 @@
host.vore_selected.transferlocation = choice.name
. = TRUE
if("b_absorbchance")
- var/absorb_chance_input = tgui_input_num(user, "Set belly absorb mode chance on resist (as %)", "Prey Absorb Chance", host.vore_selected.absorbchance)
+ var/absorb_chance_input = input(user, "Set belly absorb mode chance on resist (as %)", "Prey Absorb Chance") as num|null
if(!isnull(absorb_chance_input))
host.vore_selected.absorbchance = sanitize_integer(absorb_chance_input, 0, 100, initial(host.vore_selected.absorbchance))
. = TRUE
if("b_digestchance")
- var/digest_chance_input = tgui_input_num(user, "Set belly digest mode chance on resist (as %)", "Prey Digest Chance", host.vore_selected.digestchance)
+ var/digest_chance_input = input(user, "Set belly digest mode chance on resist (as %)", "Prey Digest Chance") as num|null
if(!isnull(digest_chance_input))
host.vore_selected.digestchance = sanitize_integer(digest_chance_input, 0, 100, initial(host.vore_selected.digestchance))
. = TRUE
diff --git a/config/maps.txt b/config/maps.txt
index a90fea7595..fdd211b27f 100644
--- a/config/maps.txt
+++ b/config/maps.txt
@@ -43,6 +43,10 @@ endmap
map runtimestation
endmap
+map spookystation
+ minplayers 150
+endmap
+
map multiz_debug
endmap
diff --git a/html/changelog.html b/html/changelog.html
index a8b3701bbd..bca94a7f8e 100644
--- a/html/changelog.html
+++ b/html/changelog.html
@@ -50,6 +50,176 @@
-->
+
21 November 2021
+
DeltaFire15 updated:
+
+
Power cord implants can now also be connected to cells to recharge.
+
Synthetics can no longer bite power cells.
+
+
LetterN updated:
+
+
Search option on the cwc slab
+
+
MrJWhit updated:
+
+
Reduces the HP from loot piles to 100, from 300.
+
+
TripleShades updated:
+
+
(Pubby) Loot piles to maint halls remove: (Pubby) CMO's sex dungeon tweak: (Pubby) Surgery layout is now more open
+
+
keronshb updated:
+
+
Adds Cogscarab spell tweak: Cogscarabs gib now because I have no idea how to fix the issue of dead pogscarabs eating up the limit.
+
+
+
20 November 2021
+
SandPoot updated:
+
+
Acid will disappear when not existant.
+
Updates component Destroy code, might result in less component related runtimes.
+
+
+
19 November 2021
+
shellspeed1 updated:
+
+
An experimental smart dart repeater rifle has been added by NT. It accepts both a large and small hypovials and uses it to fill the smart darts it synthesizes. It can hold 6 smart darts and makes a new one every 20 seconds. To research it, grab the medical weaponry node. tweak: Reagent gun renamed to reagent repeater
+
reagent repeater now holds 6 syringes.
+
Reagent repeater and smart dart repeater rifle start with 4 syringes instead of a full clip.
+
reagent repeater synthesizes a new syringe every 20 seconds. tweak: smart dart guns now use the syringe gun as an inhands sprite.
+
+
+
18 November 2021
+
DeltaFire15 updated:
+
+
Devastation level explosions no longer delete your organs after gibbing you.
+
Adjusted all overrides of ex_act() and contents_explosion() to take account of current args for them.
+
Reebe can now be loaded via a proc. tweak: The clockwork relay in reebe is now indestructible and not deconstrutible to avoid some issues.
+
+
Putnam3145 updated:
+
+
Regal rat can no longer keep spawning stuff while dead
+
+
SandPoot updated:
+
+
When your statpanel doesn't load, you'll get a message with a button to fix it.
+
The fix chat message button now works.
+
+
keronshb updated:
+
+
Ball
+
Spookystation Map
+
Tree chopping/Grass cutting
+
Vectorcars
+
+
+
16 November 2021
+
Putnam3145 updated:
+
+
Lavaland can no longer go below 281 kelvins
+
+
TripleShades updated:
+
+
(Pubby) Engineering security checkpoint no longer has a duplicate records console
+
+
+
14 November 2021
+
TripleShades updated:
+
+
(Pubby) Surgery table to Brig Medical
+
(Pubby) Dirt decals added to Command maint
+
(Pubby) Decals and gavel block to Courtroom
+
(Pubby) Training bomb to Birg
+
(Pubby) Chapel stripper pole room
+
(Pubby) Command maint storage shed room tweak: (Pubby) Makes Arrivals atmos room into a main atmos grid room akin to what Meta has
+
(Pubby) Gulag shuttle spawning in a tile off from the airlocks
+
(Pubby) Air Injector in Medical maints having no power
+
(Pubby) Incorrect area on one side at AI Sat where the turrets are
+
(Pubby) Arrivals atmos is now linked to the main atmos grid
+
(Pubby) Medbay front airlocks access
+
+
keronshb updated:
+
+
Admins get messaged if dynamic midrounds fail to hijack
+
+
+
13 November 2021
+
Putnam3145 updated:
+
+
Chonker cubans pete now no longer have a reasonable chance to be unbeatable
+
+
+
11 November 2021
+
DrPainis updated:
+
+
The universe has realized that not every species uses hemoglobin again.
+
+
Putnam3145 updated:
+
+
"REM" removed, replaced with "REAGENTS_EFFECT_MULTIPLIER", which "REM" is short for
+
+
+
10 November 2021
+
Ethan4303 updated:
+
+
Added two wire nodes under the engineering PA room Apc and under the HOS office APC
+
Added cables to connect the second floor relay to the power grid
+
Removed the generic broken computer from Hos Office
+
Fixed Hos office not having the Security records console
+
+
Putnam3145 updated:
+
+
Power alerts now work
+
No longer have too much O2 from too much CO2
+
+
SandPoot updated:
+
+
Crayon precision mode.
+
+
+
08 November 2021
+
timothyteakettle updated:
+
+
fixes party pod sprite
+
fixes red panda head marking
+
+
+
06 November 2021
+
Putnam3145 updated:
+
+
Ashwalkers should no longer suffocate on lavaland (and hypothetical other future problems)
+
A gas mix with 0 oxygen should now properly suffocate you (or 0 plasma, for ashwalkers)
+
+
+
05 November 2021
+
keronshb updated:
+
+
removes required enemies
+
Lowers assassination threat threshold
+
+
+
31 October 2021
+
DeltaFire15 updated:
+
+
You can now drag things over prone people again.
+
+
DrPainis updated:
+
+
Walking no longer makes you fat.
+
+
keronshb updated:
+
+
Christmas trees are now indestructible
+
+
+
30 October 2021
+
keronshb updated:
+
+
Jacq can't burn in the cremator anymore
+
Jacq also can't be cheesed off station
+
Barth also cannot be destroyed
+
+
28 October 2021
Hatterhat updated:
@@ -239,278 +409,6 @@
limb damage changes reverted
crawling can't be adrenals'd
-
-
20 September 2021
-
BlueWildrose updated:
-
-
Slime regenerative extracts now require five seconds of wait before they are used. They add 25 disgust when used.
-
-
DeltaFire15 updated:
-
-
Catsurgeons should now spawn at more reasonable locations if possible.
-
carded AIs can now be converted by conversion sigils (clockcult)
-
There is now a way to acquire nanite storage protocols (bepis, like the other protocols), as opposed to them existing with no way to acquire them.
-
Plastic golems are back to ventcrawler_nude instead of ventcrawler_always
-
-
Putnam3145 updated:
-
-
monstermos config added, disabled
-
-
buffyuwu updated:
-
-
fixed medihound sleeper ui display
-
Adds 4 redesigned jackets and 2 redesigned shirts to loadout
-
Holoparasites no long rename and recolor on relog
-
-
dapnee updated:
-
-
attaches an air vent that was just there on the AI sat, changes some areas to what they'd logically be
-
-
keronshb updated:
-
-
Plague Rats will no longer spawn thousands of dirt decals
-
Plague Rats will no longer spawn thousands of corpses
-
Plague Rats can't spawn or transform off station z anymore
-
Plague Rats shouldn't explosively grow instantly
-
Plague Rats won't spawn infinite miasma anymore.
-
Plague Rats health is now 100.
-
Plague Rats can now ventcrawl through everything to prevent farming.
-
Slaughter Demons Slam will now wound again on hit.
-
Damage for demons back up to 30
-
Wound Bonus for demons now at 0. image_add: Adds a sprite for the action bar
-
Changed the CTRL+SHIFT Click to an action button. People can see the cooldown now too.
-
PAIs can be emagged to reset master
-
-
qweq12yt updated:
-
-
Fixed space heaters not being able to be interacted/turned on in non powered areas
-
-
timothyteakettle updated:
-
-
removes passkey from access circuits as its not used anymore
-
a new mild trauma, **[REDACTED]**
-
-
zeroisthebiggay updated:
-
-
glass has do_after
-
box perma has power
-
missing madness mask sprites
-
The Spider Clan has recently taken up the Space Ninja project again along with the Syndicate. Space Ninjas have been drastically changed as a result, becoming much weaker and more stealth oriented. As a result of cutting costs per ninja, more ninjas were able to be hired. Expect to see them around more often.
-
prisoners cannot latejoin anymore
-
bone satchel onmob sprites
-
new tips
-
old tips
-
all medipens get inhands
-
some more brainhurt lines
-
-
-
18 September 2021
-
kiwedespars updated:
-
-
blacklisted morphine and haloperidol from dart guns
-
-
-
17 September 2021
-
DeltaFire15 updated:
-
-
Techweb hidden nodes should now show less weird behavior.
-
-
-
14 September 2021
-
Hatterhat updated:
-
-
The Syndicate zero-day'd the NT IRN program on modular computers through cryptographic sequencing technology. NanoTrasen's cybersecurity divisions are seething.
-
-
LetterN updated:
-
-
sync mafia code
-
-
Putnam3145 updated:
-
-
Nerfed bad toxins bombs and buffed good toxins bombs. There's no longer an arbitrary hard research points cap.
-
-
keronshb updated:
-
-
Removes zap obj damage and machinery explosion from the SM arcs
-
Fixes hitby runtime.
-
-
zeroisthebiggay updated:
-
-
the permabrig erp role
-
changeling adrenals buff
-
speedups
-
bread goes in mouth and not on head
-
-
-
12 September 2021
-
LetterN updated:
-
-
lowers the audio volume of ark sfx
-
readded cwc theme in the index.js once more
-
-
timothyteakettle updated:
-
-
allows custom taste text and color on the custom ice cream setting in the ice cream vat
-
-
-
11 September 2021
-
LetterN updated:
-
-
Tickers, GC, MC, FS updates
-
rust_g update. It is default that we use their urlencode/unencode now.
-
updates CBT to juke
-
CI Cache works properly now
-
-
Putnam3145 updated:
-
-
Removed some crashes
-
-
SandPoot updated:
-
-
Cyborg grippers now have a preview of the item you are holding. tweak: Cyborg grippers no longer drop using alt-click, instead, you try to drop the gripper to drop the item, and then you can drop the gripper. tweak: You can now use the "Pick up" verb on the right click menu to take items with a cyborg gripper.
-
You should be able to access the interface of airlock electronics once again as a borg.
-
Reworks a lot of stuff that was being used on the grippers.
-
-
timothyteakettle updated:
-
-
arachnid legs now show up properly
-
-
zeroisthebiggay updated:
-
-
reinforcing the mining hardsuit with goliath hide now makes the sprite cooler
-
The SWAT helmet is now consistent between its front, side and back sprites for coloration.
-
new riot armor sprites
-
-
-
10 September 2021
-
BlueWildrose updated:
-
-
CTRL + (combat mode) Right Click - positional dropping and item rotation.
-
-
keronshb updated:
-
-
Readds Reebe
-
Added the ability to dye your hair with gradients by using a hair dye spray.
-
The new Colorist quirk, allowing you to spawn with a hair dye spray.
-
Adds Hair gradients to preferences
-
Three new hair gradients, a pair of shorter fades and a spiky wave.
-
Adds viewers for mask of madness so it doesn't wallhack
-
-
zeroisthebiggay updated:
-
-
Replaced the DNA probe's old sprite (Hypospray) with a unique sprite
-
added some icons and images for hyposprays and medipens so they stand out
-
added inhands for the cautery, retractor, drapes and hemostat.
-
New icon and sprites for the DNA probe
-
Emergency survival boxes now have an unique blue sprite and description to tell them apart from regular boxes.
-
Added craftable normal/extended emergency oxygen tank boxes to put your emergency oxygen tank collection inside.
-
Emergency first aid kits now look visually consistent with full first aid kits.
-
Ports new Hypospray, Combat Autoinjector, Pestle, Mortar and Dropper sprites from Shiptest!
-
Adds a new sprite for pill bottles!
-
new surgical tool sprites
-
The cyborg toolset is now all new and improved, with a new coat of paint!
-
Updates pride hammer sprites!
-
Replaced old Mjolnir sprites with new Mjolnir sprites.
-
-
-
08 September 2021
-
keronshb updated:
-
-
Adds the parade outfit for the HoS and Centcomm
-
Recolors the parade outfit for the Captain
-
Adds a toggle option for the parade outfits
-
Observers can no longer highlight your items
-
-
-
07 September 2021
-
bunny232 updated:
-
-
fixed some jank in pubby's xenobiological secure pen
-
-
keronshb updated:
-
-
Gremlins no longer have AA when dead
-
-
zeroisthebiggay updated:
-
-
you can just about
-
-
-
05 September 2021
-
DeltaFire15 updated:
-
-
Unreadied player gamemode votes now actually get ignored (if the config for this is enabled).
-
-
-
04 September 2021
-
Putnam3145 updated:
-
-
Might've fixed some ghost sprite oddities nobody even knew about
-
-
WanderingFox95 updated:
-
-
Lavaland architects don't screw up so badly anymore and do in fact not somehow leave holes through the planet surface all the way into space under their bookshelves.
-
Snow was removed from Lavaland Ruins.
-
-
keronshb updated:
-
-
Fixes entering an occupied VR sleeper bug
-
-
timothyteakettle updated:
-
-
makes the arm/leg markings for synthetic lizards appear as an option again
-
-
-
03 September 2021
-
timothyteakettle updated:
-
-
fixes losing your additional language upon changing species
-
-
-
01 September 2021
-
BlueWildrose updated:
-
-
The waddle component now takes size into account when running rotating animations, thus not reverting character sizes to default size.
-
-
ma44 updated:
-
-
Weapon rechargers now have their recharger indicators again.
-
Energy guns now update when switching modes again.
-
Stabilized yellow slime extracts will now update cells and guns it recharges.
-
Weapon rechargers will now be more noticeable when it has finished recharging something.
-
-
zeroisthebiggay updated:
-
-
the fucking chainsaw sprite
-
-
-
28 August 2021
-
DeltaFire15 updated:
-
-
Demons now drop bodies on their own tile instead of scattering them across the station. tweak: Space dragon content ejection is now slightly safer.
-
Space dragons no longer delete their contents if they die due to timeout, ejecting them instead.
-
Carp rifts created by space dragons now have their armor work correctly.
-
-
Putnam3145 updated:
-
-
Planetary monstermos can now be disabled with varedit
-
Lavaland/ice planet atmos is no longer a preset gas mixture and varies per round
-
-
keronshb updated:
-
-
Ports Inventory Outlines
-
Re-adds the old glue sprite
-
Adds Plague Rats
-
Gives Plague Rat spawn conditions for regular mice
-
Plague Rat sprite
-
Gremlin
-
Gremlin sprites
-
-
zeroisthebiggay updated:
-
-
grilles as maintenance loot
-
sevensune tail from hyperstation
-
GoonStation 13 Development Team
diff --git a/html/changelogs/.all_changelog.yml b/html/changelogs/.all_changelog.yml
index 5e72e5e4de..1aa25dae05 100644
--- a/html/changelogs/.all_changelog.yml
+++ b/html/changelogs/.all_changelog.yml
@@ -30184,3 +30184,121 @@ DO NOT EDIT THIS FILE BY HAND! AUTOMATICALLY GENERATED BY ss13_genchangelog.py.
- balance: -40 wound bonus for DSword
- balance: -20 Wound bonus for Hyper Eu
- bugfix: Fixes hyper eu's slowdown when it's not wielded
+2021-10-30:
+ keronshb:
+ - balance: Jacq can't burn in the cremator anymore
+ - balance: Jacq also can't be cheesed off station
+ - balance: Barth also cannot be destroyed
+2021-10-31:
+ DeltaFire15:
+ - bugfix: You can now drag things over prone people again.
+ DrPainis:
+ - bugfix: Walking no longer makes you fat.
+ keronshb:
+ - balance: Christmas trees are now indestructible
+2021-11-05:
+ keronshb:
+ - balance: removes required enemies
+ - balance: Lowers assassination threat threshold
+2021-11-06:
+ Putnam3145:
+ - bugfix: Ashwalkers should no longer suffocate on lavaland (and hypothetical other
+ future problems)
+ - bugfix: A gas mix with 0 oxygen should now properly suffocate you (or 0 plasma,
+ for ashwalkers)
+2021-11-08:
+ timothyteakettle:
+ - bugfix: fixes party pod sprite
+ - bugfix: fixes red panda head marking
+2021-11-10:
+ Ethan4303:
+ - rscadd: Added two wire nodes under the engineering PA room Apc and under the HOS
+ office APC
+ - rscadd: Added cables to connect the second floor relay to the power grid
+ - rscdel: Removed the generic broken computer from Hos Office
+ - bugfix: Fixed Hos office not having the Security records console
+ Putnam3145:
+ - bugfix: Power alerts now work
+ - bugfix: No longer have too much O2 from too much CO2
+ SandPoot:
+ - rscadd: Crayon precision mode.
+2021-11-11:
+ DrPainis:
+ - bugfix: The universe has realized that not every species uses hemoglobin again.
+ Putnam3145:
+ - refactor: '"REM" removed, replaced with "REAGENTS_EFFECT_MULTIPLIER", which "REM"
+ is short for'
+2021-11-13:
+ Putnam3145:
+ - balance: Chonker cubans pete now no longer have a reasonable chance to be unbeatable
+2021-11-14:
+ TripleShades:
+ - rscadd: (Pubby) Surgery table to Brig Medical
+ - rscadd: (Pubby) Dirt decals added to Command maint
+ - rscadd: (Pubby) Decals and gavel block to Courtroom
+ - rscadd: (Pubby) Training bomb to Birg
+ - rscdel: (Pubby) Chapel stripper pole room
+ - rscdel: '(Pubby) Command maint storage shed room tweak: (Pubby) Makes Arrivals
+ atmos room into a main atmos grid room akin to what Meta has'
+ - bugfix: (Pubby) Gulag shuttle spawning in a tile off from the airlocks
+ - bugfix: (Pubby) Air Injector in Medical maints having no power
+ - bugfix: (Pubby) Incorrect area on one side at AI Sat where the turrets are
+ - bugfix: (Pubby) Arrivals atmos is now linked to the main atmos grid
+ - bugfix: (Pubby) Medbay front airlocks access
+ keronshb:
+ - admin: Admins get messaged if dynamic midrounds fail to hijack
+2021-11-16:
+ Putnam3145:
+ - bugfix: Lavaland can no longer go below 281 kelvins
+ TripleShades:
+ - bugfix: (Pubby) Engineering security checkpoint no longer has a duplicate records
+ console
+2021-11-18:
+ DeltaFire15:
+ - bugfix: Devastation level explosions no longer delete your organs after gibbing
+ you.
+ - code_imp: Adjusted all overrides of ex_act() and contents_explosion() to take
+ account of current args for them.
+ - code_imp: 'Reebe can now be loaded via a proc. tweak: The clockwork relay in reebe
+ is now indestructible and not deconstrutible to avoid some issues.'
+ Putnam3145:
+ - bugfix: Regal rat can no longer keep spawning stuff while dead
+ SandPoot:
+ - rscadd: When your statpanel doesn't load, you'll get a message with a button to
+ fix it.
+ - bugfix: The fix chat message button now works.
+ keronshb:
+ - rscadd: Ball
+ - rscadd: Spookystation Map
+ - rscadd: Tree chopping/Grass cutting
+ - rscadd: Vectorcars
+2021-11-19:
+ shellspeed1:
+ - rscadd: 'An experimental smart dart repeater rifle has been added by NT. It accepts
+ both a large and small hypovials and uses it to fill the smart darts it synthesizes.
+ It can hold 6 smart darts and makes a new one every 20 seconds. To research
+ it, grab the medical weaponry node. tweak: Reagent gun renamed to reagent repeater'
+ - balance: reagent repeater now holds 6 syringes.
+ - balance: Reagent repeater and smart dart repeater rifle start with 4 syringes
+ instead of a full clip.
+ - balance: 'reagent repeater synthesizes a new syringe every 20 seconds. tweak:
+ smart dart guns now use the syringe gun as an inhands sprite.'
+2021-11-20:
+ SandPoot:
+ - bugfix: Acid will disappear when not existant.
+ - code_imp: Updates component Destroy code, might result in less component related
+ runtimes.
+2021-11-21:
+ DeltaFire15:
+ - rscadd: Power cord implants can now also be connected to cells to recharge.
+ - rscdel: Synthetics can no longer bite power cells.
+ LetterN:
+ - rscadd: Search option on the cwc slab
+ MrJWhit:
+ - balance: Reduces the HP from loot piles to 100, from 300.
+ TripleShades:
+ - rscadd: '(Pubby) Loot piles to maint halls remove: (Pubby) CMO''s sex dungeon
+ tweak: (Pubby) Surgery layout is now more open'
+ keronshb:
+ - rscadd: 'Adds Cogscarab spell tweak: Cogscarabs gib now because I have no idea
+ how to fix the issue of dead pogscarabs eating up the limit.'
diff --git a/html/changelogs/AutoChangeLog-pr-15310.yml b/html/changelogs/AutoChangeLog-pr-15310.yml
deleted file mode 100644
index a761c92fb2..0000000000
--- a/html/changelogs/AutoChangeLog-pr-15310.yml
+++ /dev/null
@@ -1,6 +0,0 @@
-author: "keronshb"
-delete-after: True
-changes:
- - balance: "Jacq can't burn in the cremator anymore"
- - balance: "Jacq also can't be cheesed off station"
- - balance: "Barth also cannot be destroyed"
diff --git a/icons/effects/blood.dmi b/icons/effects/blood.dmi
index bee16d4d90..c5a3756907 100644
Binary files a/icons/effects/blood.dmi and b/icons/effects/blood.dmi differ
diff --git a/icons/effects/weather_effects.dmi b/icons/effects/weather_effects.dmi
index 4ae2387692..f8a4872848 100644
Binary files a/icons/effects/weather_effects.dmi and b/icons/effects/weather_effects.dmi differ
diff --git a/icons/mob/inhands/items_lefthand.dmi b/icons/mob/inhands/items_lefthand.dmi
index 384159b299..d0ebbb4501 100644
Binary files a/icons/mob/inhands/items_lefthand.dmi and b/icons/mob/inhands/items_lefthand.dmi differ
diff --git a/icons/mob/inhands/items_righthand.dmi b/icons/mob/inhands/items_righthand.dmi
index 3d22f8d4b1..0d87e7871c 100644
Binary files a/icons/mob/inhands/items_righthand.dmi and b/icons/mob/inhands/items_righthand.dmi differ
diff --git a/icons/obj/guns/projectile.dmi b/icons/obj/guns/projectile.dmi
index 1504b9f0c7..5bbcca9791 100644
Binary files a/icons/obj/guns/projectile.dmi and b/icons/obj/guns/projectile.dmi differ
diff --git a/icons/obj/items_and_weapons.dmi b/icons/obj/items_and_weapons.dmi
index 454e174550..bc887e707d 100644
Binary files a/icons/obj/items_and_weapons.dmi and b/icons/obj/items_and_weapons.dmi differ
diff --git a/icons/obj/machines/sleeper.dmi b/icons/obj/machines/sleeper.dmi
index ff9e2b197a..134448fc4e 100644
Binary files a/icons/obj/machines/sleeper.dmi and b/icons/obj/machines/sleeper.dmi differ
diff --git a/icons/obj/vehicles.dmi b/icons/obj/vehicles.dmi
index 14b19caef8..2520e98bba 100644
Binary files a/icons/obj/vehicles.dmi and b/icons/obj/vehicles.dmi differ
diff --git a/interface/interface.dm b/interface/interface.dm
index fdcc461b6d..2aece7cb6c 100644
--- a/interface/interface.dm
+++ b/interface/interface.dm
@@ -24,7 +24,7 @@
set hidden = 1
var/forumurl = CONFIG_GET(string/forumurl)
if(forumurl)
- if(tgui_alert(src, "This will open the forum in your browser. Are you sure?",,list("Yes","No"))!="Yes")
+ if(alert("This will open the forum in your browser. Are you sure?",,"Yes","No")!="Yes")
return
src << link(forumurl)
else
@@ -37,7 +37,7 @@
set hidden = 1
var/rulesurl = CONFIG_GET(string/rulesurl)
if(rulesurl)
- if(tgui_alert(src, "This will open the rules in your browser. Are you sure?",,list("Yes","No"))!="Yes")
+ if(alert("This will open the rules in your browser. Are you sure?",,"Yes","No")!="Yes")
return
src << link(rulesurl)
else
@@ -50,7 +50,7 @@
set hidden = 1
var/githuburl = CONFIG_GET(string/githuburl)
if(githuburl)
- if(tgui_alert(src, "This will open the Github repository in your browser. Are you sure?",,list("Yes","No"))!="Yes")
+ if(alert("This will open the Github repository in your browser. Are you sure?",,"Yes","No")!="Yes")
return
src << link(githuburl)
else
@@ -67,7 +67,7 @@
if(GLOB.revdata.testmerge.len)
message += " The following experimental changes are active and are probably the cause of any new or sudden issues you may experience. If possible, please try to find a specific thread for your issue instead of posting to the general issue tracker: "
message += GLOB.revdata.GetTestMergeInfo(FALSE)
- if(tgalert(src, message, "Report Issue","Yes","No")!="Yes") //Untouched, issues must be reported at all costs.
+ if(tgalert(src, message, "Report Issue","Yes","No")!="Yes")
return
var/static/issue_template = file2text(".github/ISSUE_TEMPLATE.md")
var/servername = CONFIG_GET(string/servername)
diff --git a/modular_citadel/code/modules/client/loadout/__donator.dm b/modular_citadel/code/modules/client/loadout/__donator.dm
index c1489da94a..ea40ceb850 100644
--- a/modular_citadel/code/modules/client/loadout/__donator.dm
+++ b/modular_citadel/code/modules/client/loadout/__donator.dm
@@ -560,3 +560,9 @@
slot = SLOT_IN_BACKPACK
path = /obj/item/clothing/mask/gas/military
ckeywhitelist = list("unclebourbon")
+
+/datum/gear/donator/clownmask
+ name = "Clown Mask"
+ path = SLOT_WEAR_MASK
+ path = /obj/item/clothing/mask/gas/clown_hat
+ ckeywhitelist = list("djkouta")
diff --git a/modular_citadel/code/modules/eventmaps/Spookystation/JTGSZwork.dm b/modular_citadel/code/modules/eventmaps/Spookystation/JTGSZwork.dm
new file mode 100644
index 0000000000..98ca2005dc
--- /dev/null
+++ b/modular_citadel/code/modules/eventmaps/Spookystation/JTGSZwork.dm
@@ -0,0 +1,1127 @@
+/*
+⢀⡴⠑⡄⠀⠀⠀⠀⠀⠀⠀⣀⣀⣤⣤⣤⣀⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀
+⠸⡇⠀⠿⡀⠀⠀⠀⣀⡴⢿⣿⣿⣿⣿⣿⣿⣿⣷⣦⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀
+⠀⠀⠀⠀⠑⢄⣠⠾⠁⣀⣄⡈⠙⣿⣿⣿⣿⣿⣿⣿⣿⣆⠀⠀⠀⠀⠀⠀⠀⠀
+⠀⠀⠀⠀⢀⡀⠁⠀⠀⠈⠙⠛⠂⠈⣿⣿⣿⣿⣿⠿⡿⢿⣆⠀⠀⠀⠀⠀⠀⠀
+⠀⠀⠀⢀⡾⣁⣀⠀⠴⠂⠙⣗⡀⠀⢻⣿⣿⠭⢤⣴⣦⣤⣹⠀⠀⠀⢀⢴⣶⣆
+⠀⠀⢀⣾⣿⣿⣿⣷⣮⣽⣾⣿⣥⣴⣿⣿⡿⢂⠔⢚⡿⢿⣿⣦⣴⣾⠁⠸⣼⡿
+⠀⢀⡞⠁⠙⠻⠿⠟⠉⠀⠛⢹⣿⣿⣿⣿⣿⣌⢤⣼⣿⣾⣿⡟⠉⠀⠀⠀⠀⠀
+⠀⣾⣷⣶⠇⠀⠀⣤⣄⣀⡀⠈⠻⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⡇⠀⠀⠀⠀⠀⠀ WARNING: THE SHITCODE BELOW HAS BEEN HASTILY
+⠀⠉⠈⠉⠀⠀⢦⡈⢻⣿⣿⣿⣶⣶⣶⣶⣤⣽⡹⣿⣿⣿⣿⡇⠀⠀⠀⠀⠀⠀ COPY AND PASTED, PORTED FROM AWKWARD PLACES, AND PROBABLY MADE WORSE.
+⠀⠀⠀⠀⠀⠀⠀⠉⠲⣽⡻⢿⣿⣿⣿⣿⣿⣿⣷⣜⣿⣿⣿⡇⠀⠀⠀⠀⠀⠀
+⠀⠀⠀⠀⠀⠀⠀⠀⢸⣿⣿⣷⣶⣮⣭⣽⣿⣿⣿⣿⣿⣿⣿⠀⠀⠀⠀⠀⠀⠀
+⠀⠀⠀⠀⠀⠀⣀⣀⣈⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⠇⠀⠀⠀⠀⠀⠀⠀ WELCOME TO JT's TG-CODE HALLOWEEN BALL CODEFILE.
+⠀⠀⠀⠀⠀⠀⢿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⠃⠀⠀⠀⠀⠀⠀⠀⠀ ALL OF IT WILL HOPEFULLY BE BELOW.
+⠀⠀⠀⠀⠀⠀⠀⠹⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⡿⠟⠁⠀⠀⠀⠀⠀⠀⠀⠀⠀
+⠀⠀⠀⠀⠀⠀⠀⠀⠀⠉⠛⠻⠿⠿⠿⠿⠛⠉
+*/
+//Also Shrek will crash your dmlang server repeatedly if you edit him.
+//JT is weird, considering my handle is a acronym.
+//Considering I can't grab defines from everywhere, I hope you enjoy strings and numbers plebs.
+//Update - Moved to modular citadel so we are after everything has loaded...probably we gucci - jtgsz
+
+/*
+ AREAS
+ */
+//This is generally how you handle planet areas, gen 1 large outside area is good for outside effects.
+//PS: Mountain has a soundloop, outside has a soundloop, inside has a soundloop, mountaininside is silent
+//This is for the rain weather my man.
+/area/eventmap
+ name = "Dont use this" //Its the parent to any dunces out there.
+ has_gravity = STANDARD_GRAVITY //We have gravity
+ icon = 'modular_citadel/code/modules/eventmaps/Spookystation/areas.dmi' //It unsets the icon. don't make a err icon.
+ requires_power = 0 // We don't need power anywhere.
+ flags_1 = NONE
+ dynamic_lighting = DYNAMIC_LIGHTING_FORCED
+
+/area/eventmap/outside //We are outside
+ name = "Outside"
+ icon_state = "outside"
+ outdoors = 0 //I set outdoors to false. So areas can be edited.
+
+/area/eventmap/inside //We are inside, all things are pretty normal.
+ name = "Inside"
+ icon_state = "inside"
+
+/area/eventmap/mountain //Mostly so I can see the area lines of the mountain area in the minimap.
+ name = "Mountain"
+ icon_state = "mountain"
+ var/mountain = 1
+
+/area/eventmap/mountaininside
+ name = "Silent Mountain Inside"
+ icon_state = "mountain_inside"
+ outdoors = 0
+
+/*
+ OUTSIDE WALLS I WANT NOT NEED
+ */
+//These exist mostly to limit the amount of space we use organically really.
+//Decided to just use the denserock within the regular code.
+
+/turf/closed/indestructible/spookytime/matrixblocker //Two times the reference power.
+ name = "matrix"
+ icon = 'modular_citadel/code/modules/eventmaps/Spookystation/iconfile32.dmi'
+ icon_state = "matrix"
+ desc = "You suddenly realize the truth - there is no spoon. Digital simulation ends here ONCE AGAIN."
+
+/*
+ OUTSIDE TURFS WITH NO GEN JUS MIDNIGHT LIGHT BABY
+ */
+
+//In a ideal world, we would have split the turfs onto a single parent.
+//Then we would tree from INSIDE and OUTSIDE, with outside having the lighting set, for the day/night subsystem to change.
+//Outside would also have the planetary atmos and config on it.
+//Inside would be a case to case basis depending on if you want it to scrub or not.. and not have the lighting.
+//Along with what needs to be constructed on etc.
+//This is not a ideal world so enjoy the overload.
+
+//Parent of all our outside turfs. Both the inside and outside should be on a parent like this.
+/turf/open/floor/spooktime //But for now, we just handle what is outside, for light control etc.
+ name = "You fucked up pal"
+ desc = "Don't use this turf its a parent and just a holder."
+ planetary_atmos = 1 //REVERT TO INITIAL AIR GASMIX OVER TIME WITH LINDA. AKA SUPERSCRUBBER
+ light_range = 3 //MIDNIGHT BLUE
+ light_power = 0.15 //NOT PITCH BLACK, JUST REALLY DARK
+ light_color = "#00111a" //The light can technically cycle on a timer worldwide, but no daynight cycle.
+ baseturfs = /turf/open/floor/plating/spookbase/dirtattachmentpoint //If we explode or die somehow, we just become grass
+ gender = PLURAL //THE GENDER IS PLURAL
+ tiled_dirt = 0 //NO TILESMOOTHING DIRT/DIRT SPAWNS OR SOME SHIT
+
+/turf/open/floor/spooktime/break_tile()
+ return
+/turf/open/floor/spooktime/burn_tile()
+ return
+
+/turf/open/floor/spooktime/pry_tile(obj/item/I, mob/user, silent = FALSE)
+ return //No prying these tiles, you instead shovel it if avail.
+
+/*
+ Baseturf, when we call scrapeaway() after a shoveling. So people can attach tiles
+ */
+
+//WARNING VERY IMPORTANT AND HACKJOBBISH - Basically this handles construction on everything.
+/turf/open/floor/plating/spookbase/dirtattachmentpoint //Lighted variant
+ name = "the ground"
+ desc = "Looks like its been dugged out and prepped for construction"
+ icon = 'modular_citadel/code/modules/eventmaps/Spookystation/iconfile32.dmi'
+ icon_state = "dugdirt"
+ footstep = FOOTSTEP_GRASS
+ barefootstep = FOOTSTEP_GRASS
+ clawfootstep = FOOTSTEP_GRASS
+ heavyfootstep = FOOTSTEP_GENERIC_HEAVY
+ attachment_holes = TRUE
+ planetary_atmos = 1
+ light_range = 3 //We reset this
+ light_power = 0.15 //The lighting will unset when people place their tiles/etc on it.
+ light_color = "#00111a" //It should be fine
+
+ baseturfs = /turf/open/floor/plating/spookbase/dirtattachmentpoint //No going lower than this.
+
+/turf/open/floor/plating/spookbase/dirtattachmentpoint/mountain
+ name = "the ground"
+ desc = "It has been dug out and prepared for construction."
+ light_range = 0
+ light_power = 0
+
+ baseturfs = /turf/open/floor/plating/spookbase/dirtattachmentpoint/mountain
+
+/turf/open/floor/plating/spookbase/sandattachmentpoint
+ name = "the sand"
+ desc = "Looks like its been dugged out and prepped for construction"
+ icon = 'modular_citadel/code/modules/eventmaps/Spookystation/iconfile32.dmi'
+ icon_state = "dugsand"
+ footstep = FOOTSTEP_GRASS
+ barefootstep = FOOTSTEP_GRASS
+ clawfootstep = FOOTSTEP_GRASS
+ heavyfootstep = FOOTSTEP_GENERIC_HEAVY
+ attachment_holes = TRUE
+ planetary_atmos = 1
+ light_range = 3
+ light_power = 0.15
+ light_color = "#00111a"
+
+ baseturfs = /turf/open/floor/plating/spookbase/sandattachmentpoint // The sand version.
+
+/*
+ FLOOR TILES
+ */
+/obj/item/stack/tile/nonspooktimegrass
+ name = "clumps of grass"
+ singular_name = "clump of grass"
+ desc = "This is a clump of grass."
+ icon = 'modular_citadel/code/modules/eventmaps/Spookystation/iconfile32.dmi'
+ icon_state = "grass_clump"
+ turf_type = /turf/open/floor/spooktime/nonspooktimegrass
+ resistance_flags = FLAMMABLE
+
+/obj/item/stack/tile/normalasssand
+ name = "piles of sand"
+ singular_name = "pile of sand"
+ desc = "This is a pile of sand"
+ icon = 'modular_citadel/code/modules/eventmaps/Spookystation/iconfile32.dmi'
+ icon_state = "sand_clump"
+ turf_type = /turf/open/floor/spooktime/beach
+
+/*
+ IMPORTANT TURFS */
+
+//Grass with no flora generation on it.
+/turf/open/floor/spooktime/nonspooktimegrass
+ name = "grass patch"
+ desc = "You can't tell if this is real grass... Ah, who are you kidding, it totally is real grass."
+ icon_state = "grass_1" //Grass of the varied variety.
+ icon = 'modular_citadel/code/modules/eventmaps/Spookystation/iconfile32.dmi'
+ baseturfs = /turf/open/floor/plating/spookbase/dirtattachmentpoint
+ footstep = FOOTSTEP_GRASS
+ barefootstep = FOOTSTEP_GRASS
+ clawfootstep = FOOTSTEP_GRASS
+ heavyfootstep = FOOTSTEP_GENERIC_HEAVY
+ var/turfverb = "dig out"
+
+/turf/open/floor/spooktime/nonspooktimegrass/Initialize() //Init rng icon.
+ . = ..()
+ icon_state = "grass_[rand(1,3)]"
+
+/turf/open/floor/spooktime/nonspooktimegrass/attackby(obj/item/C, mob/user, params) //We dig it out with a shovel.
+ if((C.tool_behaviour == TOOL_SHOVEL) && params) //And beneath it we reveal dirt
+ new /obj/item/stack/tile/nonspooktimegrass(src)
+ user.visible_message("[user] digs up [src].", "You [turfverb] [src].")
+ playsound(src, 'sound/effects/shovel_dig.ogg', 50, 1)
+ make_plating()
+ if(..())
+ return
+
+
+//Dirt patches with no lighting.
+/turf/open/floor/spooktime/dirtpatch
+ name = "clearly dirt"
+ desc = "Its dirt alright"
+ icon = 'modular_citadel/code/modules/eventmaps/Spookystation/iconfile32.dmi'
+ icon_state = "smoothdarkdirt"
+ light_range = 0 //We set the lights to nothing on the CLEARLY DIRT
+ light_power = 0 //ayep
+ footstep = FOOTSTEP_SAND
+ barefootstep = FOOTSTEP_SAND
+ clawfootstep = FOOTSTEP_SAND
+ heavyfootstep = FOOTSTEP_GENERIC_HEAVY
+ baseturfs = /turf/open/floor/plating/spookbase/dirtattachmentpoint/mountain //no light variant
+ var/turfverb = "dig out"
+
+/turf/open/floor/spooktime/dirtpatch/attackby(obj/item/C, mob/user, params) //We dig it out with a shovel.
+ if((C.tool_behaviour == TOOL_SHOVEL) && params) //And beneath it we reveal dirt
+ user.visible_message("[user] digs up [src].", "You [turfverb] [src].")
+ playsound(src, 'sound/effects/shovel_dig.ogg', 50, 1)
+ make_plating()
+ if(..())
+ return
+
+//Snow with no planetary atmos, so the map doesn't atmos crash.
+/turf/open/floor/spooktime/snow
+ gender = PLURAL
+ name = "snow"
+ icon = 'icons/turf/snow.dmi'
+ desc = "Looks cold."
+ icon_state = "snow"
+ slowdown = 2
+ light_range = 0
+ light_power = 0
+ bullet_sizzle = 1
+ footstep = FOOTSTEP_SAND
+ barefootstep = FOOTSTEP_SAND
+ clawfootstep = FOOTSTEP_SAND
+ heavyfootstep = FOOTSTEP_GENERIC_HEAVY
+
+/turf/open/floor/spooktime/snow/try_replace_tile(obj/item/stack/tile/T, mob/user, params)
+ return
+
+/turf/open/floor/spooktime/snow/crowbar_act(mob/living/user, obj/item/I)
+ return
+
+/*
+ Basic Grass turf w Flora gen
+ */
+/turf/open/floor/spooktime/spooktimegrass
+ name = "the ground"
+ desc = "It clearly looks like grass and dirt, clearly."
+ icon_state = "grass_1"
+ icon = 'modular_citadel/code/modules/eventmaps/Spookystation/iconfile32.dmi' //32x32 iconfile, sry we had different sizes.
+ broken_states = list("sand")
+ footstep = FOOTSTEP_GRASS //Finally I can have my footstep noises
+ barefootstep = FOOTSTEP_GRASS
+ clawfootstep = FOOTSTEP_GRASS
+ heavyfootstep = FOOTSTEP_GENERIC_HEAVY
+ var/turfverb = "dig out"
+
+
+ baseturfs = /turf/open/floor/plating/spookbase/dirtattachmentpoint //beneath the grass there is dirt.
+
+ //Holders for what can occur on the turf.
+ var/obj/structure/flora/turfGrass = null
+ var/obj/structure/flora/turfTree = null
+ var/obj/structure/flora/turfAusflora = null
+ var/obj/structure/flora/turfRocks = null
+ var/obj/structure/flora/turfDebris = null
+
+
+/turf/open/floor/spooktime/spooktimegrass/Initialize() //Considering adding dirtgen here too.
+ . = ..()
+ if(prob(1))
+ icon_state = "smoothdarkdirt" //Sometimes we can be dirt.
+ else
+ icon_state = "grass_[rand(1,3)]" //Icon state variation for how many states of grass I got... 3 lul
+ //If no fences, machines (soil patches are machines), etc. try to plant grass
+ if(!(\
+ (locate(/obj/structure) in src) || \
+ (locate(/obj/machinery) in src) ))
+ floraGen() //And off we go riding into hell.
+ update_icon()
+
+/turf/open/floor/spooktime/spooktimegrass/attackby(obj/item/C, mob/user, params) //We dig it out with a shovel.
+ if((C.tool_behaviour == TOOL_SHOVEL) && params) //And beneath it we reveal dirt)
+ new /obj/item/stack/tile/nonspooktimegrass(src)
+ user.visible_message("[user] digs up [src].", "You [turfverb] [src].")
+ playsound(src, 'sound/effects/shovel_dig.ogg', 50, 1)
+ make_plating()
+ if(..())
+ return
+
+/turf/open/floor/spooktime/spooktimegrass/try_replace_tile(obj/item/stack/tile/T, mob/user, params)
+ return //No replacing it
+
+/turf/open/floor/spooktime/spooktimegrass/burn_tile()
+ return //No burning it
+
+/turf/open/floor/spooktime/spooktimegrass/MakeSlippery(wet_setting, min_wet_time, wet_time_to_add, max_wet_time, permanent)
+ return //No slippery
+
+/turf/open/floor/spooktime/spooktimegrass/MakeDry()
+ return //No making it dry.
+
+/*
+ FLORA GEN PROCEDURE
+ */
+
+//This is mostly for flora/doodads. I don't feel like there needs to be lake/cave and animals generation..
+//For the halloween map at least, so I used the f13 flora gen and appended to it instead of usin cellular automata.
+//Soooo, its just tied to the turf initialize on init right now.
+//Right now each segment generates independantly, but it wouldn't be hard to do it in a chain
+//And check for what else is there before a list of objects has the option to appear.
+//Or even change weighting based on the weight of other things that the turf has checked in its range.
+//But at the same time, the stacked flora/rocks etc look pretty okay together honestly.
+//On the other side of the coin, you could even adjust their pixel x and y for better thickets.
+//Since after-all things in nature don't just occupy one spot each a lot of the time.
+
+//That being said you have somewhere around 50 seconds of init, and 160 seconds of pre-game time.
+//To finish generation if you need to split it up by chunks and add more checks.
+//Its more time than you could ever want considering how fast it finishes like this without hiccups really.
+//Ironically, not very resource intensive or slow to do this much of it.
+
+//I have turned what used to be simple into hell.
+//We can keep appending stuff here as we go, it basically just spawns it all on turf spooktimegrass on init.
+
+//============> Current Set value // JTGSZ Tuned Reference Value <==============
+#define GRASS_SPONTANEOUS 2//2 //chance it appears on the tile on its own
+#define GRASS_WEIGHT 4//4 //multiplier increase if theres some nearby
+#define TREE_SPONTANEOUS 4//4
+#define TREE_WEIGHT 4//4
+#define AUSFLORA_SPONTANEOUS 2//2
+#define AUSFLORA_WEIGHT 3//3
+#define ROCKS_SPONTANEOUS 2//2 //Technically this can be moved to the desolate spawn list tied to grass.
+#define ROCKS_WEIGHT 1//1 //Lower weight cause rock clusters were too common...But cool honestly.
+#define DEBRIS_SPONTANEOUS 2//2
+#define DEBRIS_WEIGHT 2//2
+
+//These are basically what can spawn in the lists, the number is the weight.
+//The weight dictates how likely it is to spawn over other things in the lists. If you were to use pickweight.
+#define LUSH_GRASS_SPAWN_LIST list(/obj/structure/flora/grass/spookytime = 4,\
+ /obj/structure/flora/ausbushes/lavendergrass = 3,\
+ /obj/structure/flora/ausbushes/sparsegrass = 6,\
+ /obj/structure/flora/ausbushes/fullgrass = 1\
+ )
+
+#define TREE_SPAWN_LIST list(/obj/structure/flora/tree/spookytime = 9,\
+ /obj/structure/flora/tree/spookytimexl = 2,\
+ /obj/structure/flora/tree/jungle = 1,\
+ /obj/structure/flora/tree/jungle/small = 1\
+ )
+
+#define AUSFLORA_SPAWN_LIST list(/obj/structure/flora/ausbushes = 3,\
+ /obj/structure/flora/ausbushes/grassybush = 3,\
+ /obj/structure/flora/ausbushes/fernybush = 1,\
+ /obj/structure/flora/ausbushes/sunnybush = 1,\
+ /obj/structure/flora/ausbushes/reedbush = 1,\
+ /obj/structure/flora/ausbushes/palebush = 1,\
+ /obj/structure/flora/ausbushes/stalkybush = 1\
+ )
+
+#define ROCKS_SPAWN_LIST list(/obj/structure/flora/spookyrock = 1\
+ )
+
+#define DEBRIS_SPAWN_LIST list(/obj/structure/flora/tree/spookybranch = 5, \
+ /obj/structure/flora/tree/spookylog = 1\
+ )
+
+//Lists that occur when the cluster doesn't happen but probability dictates it tries.
+#define DESOLATE_SPAWN_LIST list(/obj/structure/flora/grass/spookytime = 1,\
+ /obj/structure/flora/ausbushes/sparsegrass = 1\
+ )
+
+//I just kinda made it worse... Like a lot worse. Ngl man.
+/turf/open/floor/spooktime/spooktimegrass/proc/floraGen()
+ var/grassWeight = 0 //grassWeight holders for each individual layer
+ var/treeWeight = 0
+ var/ausfloraWeight = 0
+ var/rocksWeight = 0
+ var/debrisWeight = 0
+
+ var/randGrass = null //The random plant picked
+ var/randTree = null //The random deadtree picked
+ var/randAusflora = null //The random Ausflora picked
+ var/randRocks = null //The random rock picked
+ var/randDebris = null //The random wood debris picked
+
+ //spontaneously spawn the objects based on probability from the define.
+ //Ngl, a lot of this is going to be have to generate in certain orders later in this proc.
+ if(prob(GRASS_SPONTANEOUS)) //If probability THE DEFINE NUMBER
+ randGrass = pickweight(LUSH_GRASS_SPAWN_LIST) //randgrass is assigned a obj from the weighted list
+ turfGrass = new randGrass(src) //The var on the turf now has a new randgrass from the list.
+
+ if(prob(TREE_SPONTANEOUS))
+ randTree = pickweight(TREE_SPAWN_LIST)
+ turfTree = new randTree(src)
+
+ if(prob(AUSFLORA_SPONTANEOUS))
+ randAusflora = pickweight(AUSFLORA_SPAWN_LIST)
+ turfAusflora = new randAusflora(src)
+
+ if(prob(ROCKS_SPONTANEOUS))
+ randRocks = pickweight(ROCKS_SPAWN_LIST)
+ turfRocks = new randRocks(src)
+
+ if(prob(DEBRIS_SPONTANEOUS))
+ randDebris = pickweight(DEBRIS_SPAWN_LIST)
+ turfDebris = new randDebris(src)
+
+
+ //loop through neighbouring turfs, if they have grass, then increase weight, cluster prep.
+ for(var/turf/open/floor/spooktime/spooktimegrass/T in RANGE_TURFS(3, src))
+ if(T.turfGrass) //We check what is around our turf
+ grassWeight += GRASS_WEIGHT //The weight is increased by grass weight per every grass we find
+ if(T.turfTree)
+ treeWeight += TREE_WEIGHT
+ if(T.turfAusflora)
+ ausfloraWeight += AUSFLORA_WEIGHT
+ if(T.turfRocks)
+ rocksWeight += ROCKS_WEIGHT
+ if(T.turfDebris)
+ debrisWeight += DEBRIS_WEIGHT
+
+
+ //Below is where we handle clusters really.
+ //use weight to try to spawn grass
+ if(prob(grassWeight)) //Basically the probability goes by the DEFINE WEIGHT the more of it is around.
+ //If surrounded on 5+ sides, pick from lush
+ if(grassWeight == (5 * GRASS_WEIGHT)) //If we are five times the define value, aka 5 detected.
+ randGrass = pickweight(LUSH_GRASS_SPAWN_LIST) //We weighted pick from the lush list, aka boys that can be together.
+ else //Else.
+ randGrass = pickweight(DESOLATE_SPAWN_LIST) //We weighted pick from boys that are fine being alone.
+ turfGrass = new randGrass(src) //And at the end we set the turfgrass to this object.
+
+ if(prob(treeWeight)) //We can technically redirect individuals down here too, but lets just focus on clumps.
+ randTree = pickweight(TREE_SPAWN_LIST)
+ turfTree = new randTree(src)
+
+ if(prob(ausfloraWeight))
+ randAusflora = pickweight(AUSFLORA_SPAWN_LIST)
+ turfAusflora = new randAusflora(src)
+
+ if(prob(rocksWeight))
+ randRocks = pickweight(ROCKS_SPAWN_LIST)
+ turfRocks = new randRocks(src)
+
+ if(prob(debrisWeight))
+ randDebris = pickweight(DEBRIS_SPAWN_LIST)
+ turfDebris = new randDebris(src)
+
+//Make sure we delete the objects if we ever change turfs
+/turf/open/floor/spooktime/spooktimegrass/ChangeTurf(flags = CHANGETURF_INHERIT_AIR)
+ if(turfGrass)
+ qdel(turfGrass)
+ //if(turfTree)
+ // qdel(turfTree)
+ if(turfAusflora)
+ qdel(turfAusflora)
+ if(turfRocks)
+ qdel(turfRocks)
+ if(turfDebris)
+ qdel(turfDebris)
+ . = ..()
+
+//Grass baseturf helper, more than likely completely unneeded since its set on the original turf too.
+/obj/effect/baseturf_helper/spooktimegrass
+ name = "grass baseturf helper" //Basically just changes the baseturf into grass
+ baseturf = /turf/open/floor/spooktime/spooktimegrass //Wherever it is at.
+
+/*
+ HERE COMES THE MOTHERFUCKING RAIN
+ */
+/datum/weather/long_rain
+ name = "Long rain at midnight"
+ desc = "The planet sometimes rains, nothing special about it really."
+
+ telegraph_duration = 130
+ telegraph_message = "Water droplets begin falling from the sky."
+ telegraph_overlay = "regular_rain" //Ya my apologies for not making a new rain icon
+
+ weather_message = "The droplets become a downpour, rain now falls all around you from the night sky."
+ weather_overlay = "regular_rain" //But I need to work on my mouse on the day of 10/24/2019, so lets call it here.
+ weather_duration_lower = 12000 //these are deciseconds.
+ weather_duration_upper = 15000
+
+ end_duration = 100
+ end_message = "The downpour gradually slows until it stops."
+
+ area_type = /area/eventmap/outside
+ target_trait = ZTRAIT_STATION
+
+ barometer_predictable = TRUE
+
+ var/datum/looping_sound/active_outside_longrain/sound_ao = new(list(), FALSE, TRUE) //Outside
+ var/datum/looping_sound/active_inside_longrain/sound_ai = new(list(), FALSE, TRUE) //Inside
+ var/datum/looping_sound/active_mountain_longrain/sound_am = new(list(), FALSE, TRUE) //Mountain
+
+/datum/weather/long_rain/telegraph() //Yeah, I'm sorry but I just stole ash storm sound loops
+ . = ..()
+ var/list/inside_areas = list() //It already handled inside and outside areas lol.
+ var/list/outside_areas = list() //Now this is what I call, some real disgusting lazy list abuse
+ var/list/mountain_areas = list()
+ var/list/eligible_areas = list()
+ for(var/z in impacted_z_levels) //We check the Z level
+ eligible_areas += SSmapping.areas_in_z["[z]"] //And append them to eligible areas list
+ for(var/i in 1 to eligible_areas.len) //We check the list
+ var/area/place = eligible_areas[i] //Place is the list
+ if(istype(place, /area/eventmap/outside)) //If the place is this path
+ outside_areas += place //Outside areas is the place
+ if(istype(place, /area/eventmap/inside))
+ inside_areas += place
+ if(istype(place, /area/eventmap/mountain))
+ mountain_areas += place
+ CHECK_TICK //We check the tick this all occurs on.
+
+ sound_ao.output_atoms = outside_areas //The output atom is now set to the areas
+ sound_ai.output_atoms = inside_areas
+ sound_am.output_atoms = mountain_areas
+
+ sound_ao.start() //Outside - We can hear it begin
+
+/datum/weather/long_rain/start()
+ . = ..()
+ sound_am.start() //Mountain - We only hear after it begins
+ sound_ai.start() //Inside - Ditto
+
+/datum/weather/long_rain/end()
+ . = ..()
+ sound_am.stop() //Mountain
+
+ sound_ao.stop() //Outside - And then we stop it all, but only people outside hear the entire segment
+ sound_ai.stop() //Inside
+
+/datum/looping_sound/active_outside_longrain
+ mid_sounds = list('modular_citadel/code/modules/eventmaps/Spookystation/outsideloop1.ogg'=1,
+ 'modular_citadel/code/modules/eventmaps/Spookystation/outsideloop2.ogg'=1)
+ mid_length = 3.8 //ahahaa aaaaaaaaaa fucking shit man, but its what I got.
+ volume = 70
+ start_sound = 'sound/ambience/acidrain_start.ogg'
+ start_length = 13
+ end_sound = 'sound/ambience/acidrain_end.ogg'
+
+/datum/looping_sound/active_inside_longrain
+ mid_sounds = list('modular_citadel/code/modules/eventmaps/Spookystation/insideloop1.ogg'=1,
+ 'modular_citadel/code/modules/eventmaps/Spookystation/insideloop2.ogg'=1,
+ 'modular_citadel/code/modules/eventmaps/Spookystation/insideloop3.ogg'=1,
+ 'modular_citadel/code/modules/eventmaps/Spookystation/insideloop4.ogg'=1)
+ mid_length = 5.1 //AAAAAAAAAAAAAAAAAAAAAAA
+ volume = 60
+
+/datum/looping_sound/active_mountain_longrain
+ mid_sounds = list('modular_citadel/code/modules/eventmaps/Spookystation/basecaveloop.ogg'=1)
+ mid_length = 12 //Why are we still here? Just to suffer?
+ volume = 60
+
+/*
+ GRANDFATHER CLOCK
+ */
+
+/*
+ 1:00 AM - overlay-2
+ 2:00 AM - overlay-2
+ 3:00 AM - overlay-3
+ 4:00 AM - overlay-4
+ 5:00 AM - overlay-4
+ 6:00 AM - overlay-6
+ 7:00 AM - overlay-7
+ 8:00 AM - overlay-7
+ 9:00 AM - overlay-9
+ 10:00 AM - overlay-10
+ 11:00 AM - overlay-10
+ 12:00 AM - overlay-0
+ */
+
+/obj/machinery/grandfatherclock
+ name = "Grandfather Clock"
+ desc = "Keeps track of the time with its dials."
+ icon = 'modular_citadel/code/modules/eventmaps/Spookystation/clock32x49.dmi'
+ icon_state = "grandfathermk4right"
+ density = 1
+ anchored = 1
+ use_power = 0
+ max_integrity = 250
+ var/HRimgstate = "asshouroverlay-0"
+ var/MMimgstate = "assminuteoverlay-0"
+ var/ticktock = 0 // We hold this here
+ var/dyndial_cycle_ticker = 0 //How many
+ var/playchime = 1 //Procs will reset their vars.
+
+/obj/machinery/grandfatherclock/Initialize()
+ . = ..()
+ update_icon() //We get it done
+
+/obj/machinery/grandfatherclock/process()
+ doodad_clock_ticker()
+
+
+/obj/machinery/grandfatherclock/proc/doodad_clock_ticker() //We basically throttle the rest of this machine here.
+
+ dyndial_cycle_ticker++
+
+ if(ticktock) //If we are true
+ playsound(src.loc, 'modular_citadel/code/modules/eventmaps/Spookystation/Tock.ogg', 100,0)
+ icon_state = "grandfathermk4right"
+ flick("tick", src)
+ ticktock = 0 //Play this noise set to false
+ else
+ playsound(src.loc, 'modular_citadel/code/modules/eventmaps/Spookystation/Tick.ogg', 100,0)
+ flick("tock", src)
+ icon_state = "grandfathermk4left"
+ ticktock = 1 //If we are not true, play this noise set to true
+
+ if(dyndial_cycle_ticker >= 20) //Handles the dynamic dial
+ dyndial_cycle()
+ dyndial_cycle_ticker = 0
+
+/obj/machinery/grandfatherclock/proc/dyndial_cycle()
+ var/ass_time = STATION_TIME(TRUE, world.time) //Fun fact, space station time has a timezone offset, If its not on display time. I added world.time to fix the compile error. I dunno if it works as intended still!!
+ var/hour = (text2num(time2text(ass_time, "hh"))%12)
+ var/minute = text2num(time2text(ass_time, "mm"))
+
+ //to_chat(world, "dyndial cycle current says: [hour]:[minute] - Ass_time currently says [ass_time]")
+ if(playchime && hour == 0)
+ playsound(src.loc, 'modular_citadel/code/modules/eventmaps/Spookystation/midnightchime.ogg', 100, 0)
+ playchime = 0
+ if(!playchime && hour == 11)
+ playchime = 1
+
+ switch(hour)
+ if(1 || 2)
+ HRimgstate = "asshouroverlay-2" //Now it is ass, mostly because someones going to kill me for the other names.
+ if(3)
+ HRimgstate = "asshouroverlay-3"
+ if(4 || 5)
+ HRimgstate = "asshouroverlay-4"
+ if(6)
+ HRimgstate = "asshouroverlay-6"
+ if(7 || 8)
+ HRimgstate = "asshouroverlay-7"
+ if(9)
+ HRimgstate = "asshouroverlay-9"
+ if(10 || 11)
+ HRimgstate = "asshouroverlay-10"
+ else
+ HRimgstate = "asshouroverlay-0" //Station time wraps to 0, and so does our hours.
+
+ switch(minute)
+ if(0 to 3)
+ MMimgstate = "assminuteoverlay-0"
+ if(4 to 15)
+ MMimgstate = "assminuteoverlay-2"
+ if(16 to 22)
+ MMimgstate = "assminuteoverlay-3"
+ if(23 to 28)
+ MMimgstate = "assminuteoverlay-4"
+ if(29 to 33)
+ MMimgstate = "assminuteoverlay-6"
+ if(34 to 41)
+ MMimgstate = "assminuteoverlay-7"
+ if(42 to 49)
+ MMimgstate = "assminuteoverlay-9"
+ if(50 to 57)
+ MMimgstate = "assminuteoverlay-10"
+ else
+ MMimgstate = "assminuteoverlay-0" //This has 58 to 60 and everything else.
+
+ update_icon() //Everything is set, lets update.
+
+/obj/machinery/grandfatherclock/update_icon()
+ cut_overlays() //We cut the overlays.
+
+ add_overlay(MMimgstate) //And append our new states, Minute
+ add_overlay(HRimgstate) //Hour.
+
+/*
+ The Flora that is generated onto the basic grassturf, or can be placed for tone building.
+ */
+
+//For ease of use, I should have appended it all here..
+//Stripped the other segments out, people don't need hay and interactions right now you know man?
+//Technically we could also randomize the pixel_x, pixel_y placement of these guys for more dynamic thickets.
+/obj/structure/flora/grass/spookytime
+ icon = 'modular_citadel/code/modules/eventmaps/Spookystation/iconfile32.dmi' //32x32 iconfile
+ desc = "Some dry, virtually dead grass, cause its fall and not a wasteland this time."
+ icon_state = "tall_grass_1"
+
+/obj/structure/flora/grass/spookytime/New()
+ ..()
+ icon_state = "tall_grass_[rand(1,8)]" //We have 8 states.
+
+/obj/structure/flora/grass/spookytime/attackby(obj/item/W, mob/user, params)
+ if(W.sharpness && W.force > 0 && !(NODECONSTRUCT_1 in flags_1))
+ to_chat(user, "You begin to harvest [src]...")
+ if(do_after(user, 100/W.force, target = user))
+ to_chat(user, "You've collected [src]")
+ var/obj/item/stack/sheet/hay/H = user.get_inactive_held_item()
+ if(istype(H))
+ H.add(1)
+ else
+ new /obj/item/stack/sheet/hay/(get_turf(src))
+ qdel(src)
+ return 1
+ else
+ . = ..()
+
+/obj/structure/flora/tree/spookytime
+ name = "dead tree"
+ desc = "It's a tree. Useful for combustion and/or construction."
+ icon = 'modular_citadel/code/modules/eventmaps/Spookystation/iconfile64.dmi' //64x64 iconfile
+ icon_state = "deadtree_1"
+ log_amount = 3
+ density = 1
+ obj_integrity = 100
+ max_integrity = 100
+
+/obj/structure/flora/tree/spookytime/New()
+ icon_state = "deadtree_[rand(1,6)]" //We have 6 states
+ ..()
+
+/obj/structure/flora/tree/spookytimexl
+ name = "tall dead tree"
+ desc = "It's a tree. Useful for combustion and/or construction. This ones quite tall"
+ icon = 'modular_citadel/code/modules/eventmaps/Spookystation/talltree128.dmi'
+ icon_state = "tree_1"
+ log_amount = 12
+ density = 1
+ obj_integrity = 200
+ max_integrity = 200
+
+/obj/structure/flora/tree/spookytimexl/New()
+ icon_state = "tree_[rand(1,3)]" //We have 3 states.
+ ..()
+
+/obj/structure/flora/tree/spookybranch
+ name = "fallen branch"
+ desc = "A branch from a tree"
+ icon = 'modular_citadel/code/modules/eventmaps/Spookystation/iconfile32.dmi'
+ icon_state = "branch_1"
+ log_amount = 1
+ density = 0
+ obj_integrity = 30
+ max_integrity = 30
+
+/obj/structure/flora/tree/spookybranch/New()
+ icon_state = "branch_[rand(1,4)]"
+ ..()
+
+/obj/structure/flora/tree/spookylog
+ name = "fallen tree"
+ desc = "A tree, that turned horizontal after it died"
+ icon = 'modular_citadel/code/modules/eventmaps/Spookystation/iconfile32.dmi'
+ icon_state = "timber"
+ log_amount = 5
+ density = 0
+ obj_integrity = 100
+ max_integrity = 100 //only got one state man.
+
+/obj/structure/flora/spookyrock
+ name = "rock"
+ desc = "Its a rock man. Hard as shit, and for you quite impassible."
+ icon = 'modular_citadel/code/modules/eventmaps/Spookystation/iconfile32.dmi'
+ icon_state = "rock_1"
+ density = 1
+
+/obj/structure/flora/spookyrock/New()
+ icon_state = "rock_[rand(1,3)]"
+ ..()
+
+/*
+ WALLS - BECAUSE I HAD TO REPLACE ALL OF THEM ON THE MAP AND DO IT RIGHT THIS TIME
+ */
+/turf/closed/wall/mineral/wood
+
+
+/obj/structure/falsewall/wood
+
+//Due to the behavior of walls generally, I'm not going to make a microcosm of full flexibility
+//and functionability for a ball map, but heres everything we are usually using for future reference.
+
+/*
+ TURF DIRECTIONALS, OVERALL SPAMMED STUFF ETC
+ */
+
+//Mostly here because I was tired of searching the top stuff.
+//Damaged plasteel plates, cause fuck varediting all these icons my man.
+//Just search damturf for the tree
+
+/turf/open/floor/plasteel/damturf //ez search plasteel parent
+/turf/open/floor/plasteel/damturf/damage1
+ icon_state = "damaged1"
+/turf/open/floor/plasteel/damturf/damage2
+ icon_state = "damaged2"
+/turf/open/floor/plasteel/damturf/
+ icon_state = "damaged3"
+/turf/open/floor/plasteel/damturf/damage4
+ icon_state = "damaged4"
+/turf/open/floor/plasteel/damturf/damage5
+ icon_state = "damaged5"
+/turf/open/floor/plasteel/damturf/scorched
+ icon_state = "panelscorched"
+/turf/open/floor/plasteel/damturf/scorched1
+ icon_state = "floorscorched1"
+/turf/open/floor/plasteel/damturf/scorched2
+ icon_state = "floorscorched2"
+/turf/open/floor/plasteel/damturf/platdmg1
+ icon_state = "platingdmg1"
+/turf/open/floor/plasteel/damturf/platdmg2
+ icon_state = "platingdmg2"
+/turf/open/floor/plasteel/damturf/platdmg3
+ icon_state = "platingdmg3"
+
+/turf/open/floor/wood/damturf //ez search wood parent
+/turf/open/floor/wood/damturf/broken1
+ icon_state = "wood-broken"
+/turf/open/floor/wood/damturf/broken2
+ icon_state = "wood-broken2"
+/turf/open/floor/wood/damturf/broken3
+ icon_state = "wood-broken3"
+/turf/open/floor/wood/damturf/broken4
+ icon_state = "wood-broken4"
+/turf/open/floor/wood/damturf/broken5
+ icon_state = "wood-broken5"
+/turf/open/floor/wood/damturf/broken6
+ icon_state = "wood-broken6"
+/turf/open/floor/wood/damturf/broken7
+ icon_state = "wood-broken7"
+
+//Parent that goes into coasts too
+/turf/open/floor/spooktime/beach //laketime
+ gender = PLURAL
+ name = "sand"
+ desc = "ITS SAND!"
+ icon = 'modular_citadel/code/modules/eventmaps/Spookystation/iconfile32.dmi'
+ icon_state = "sand"
+ bullet_bounce_sound = null
+ tiled_dirt = 0
+ var/turfverb = "dig up"
+
+ baseturfs = /turf/open/floor/plating/spookbase/sandattachmentpoint //Alas, now people can dig out lakes.
+
+/turf/open/floor/spooktime/beach/attackby(obj/item/C, mob/user, params) //We dig it out with a shovel.
+ if((C.tool_behaviour == TOOL_SHOVEL) && params) //And beneath it we reveal dirt
+ new /obj/item/stack/tile/normalasssand(src) //EDIT THIS
+ user.visible_message("[user] digs up [src].", "You [turfverb] [src].")
+ playsound(src, 'sound/effects/shovel_dig.ogg', 50, 1)
+ make_plating()
+ if(..())
+ return
+
+//Beaches and coasts and sand and shit.
+/turf/open/floor/spooktime/beach/coasts
+ gender = NEUTER
+ name = "coastline"
+ desc = "The coastline of a sandy shore"
+ icon_state = "sandwater_t_S"
+
+/turf/open/floor/spooktime/beach/coasts/attackby(obj/item/C, mob/user, params)
+ return //Upon testing, digging out the coasts makes the map look like ass.
+
+//The water that follows the coastline also animated.
+/turf/open/floor/spooktime/beach/coasts/coastS
+ icon_state = "sandwater_t_S"
+/turf/open/floor/spooktime/beach/coasts/coastN
+ icon_state = "sandwater_t_N"
+/turf/open/floor/spooktime/beach/coasts/coastE
+ icon_state = "sandwater_t_E"
+/turf/open/floor/spooktime/beach/coasts/coastW
+ icon_state = "sandwater_t_W"
+/turf/open/floor/spooktime/beach/coasts/coastSE
+ icon_state = "sandwater_t_SE"
+/turf/open/floor/spooktime/beach/coasts/coastSW
+ icon_state = "sandwater_t_SW"
+/turf/open/floor/spooktime/beach/coasts/coastNE
+ icon_state = "sandwater_t_NE"
+/turf/open/floor/spooktime/beach/coasts/coastNW
+ icon_state = "sandwater_t_NW"
+
+//The coastline itself with sand
+/turf/open/floor/spooktime/beach/coasts/watercoastS
+ icon_state = "sandwater_b_S"
+/turf/open/floor/spooktime/beach/coasts/watercoastN
+ icon_state = "sandwater_b_N"
+/turf/open/floor/spooktime/beach/coasts/watercoastW
+ icon_state = "sandwater_b_W"
+/turf/open/floor/spooktime/beach/coasts/watercoastE
+ icon_state = "sandwater_b_E"
+/turf/open/floor/spooktime/beach/coasts/watercoastSE
+ icon_state = "sandwater_b_SE"
+/turf/open/floor/spooktime/beach/coasts/watercoastSW
+ icon_state = "sandwater_b_SW"
+/turf/open/floor/spooktime/beach/coasts/watercoastNE
+ icon_state = "sandwater_b_NE"
+/turf/open/floor/spooktime/beach/coasts/watercoastNW
+ icon_state = "sandwater_b_NW"
+
+//Beach corners
+/turf/open/floor/spooktime/beach/coasts/innerN
+ icon_state = "sandwater_inner_N"
+/turf/open/floor/spooktime/beach/coasts/innerS
+ icon_state = "sandwater_inner_S"
+/turf/open/floor/spooktime/beach/coasts/innerE
+ icon_state = "sandwater_inner_E"
+/turf/open/floor/spooktime/beach/coasts/innerW
+ icon_state = "sandwater_inner_W"
+
+//Shallow water same color as beach water
+/turf/open/floor/spooktime/beach/water
+ name = "water"
+ desc = "Its water that seems to be a bit deep, still can wade through though."
+ icon_state = "water"
+ bullet_sizzle = 1
+ footstep = FOOTSTEP_WATER
+ barefootstep = FOOTSTEP_WATER
+ clawfootstep = FOOTSTEP_WATER
+ heavyfootstep = FOOTSTEP_WATER
+
+/turf/open/floor/spooktime/beach/water/attackby(obj/item/C, mob/user, params)
+ return //haha nope
+
+//Slightly darker than the beach water color.
+/turf/open/floor/spooktime/beach/watersolid //Gotta stop you at a certain point man
+ name = "water"
+ desc = "Water thats deep enough to where your spaceman ass cannot swim."
+ icon_state = "water2" //Now its darker lol
+ bullet_sizzle = 1
+ density = 1 //We are now dense
+ footstep = FOOTSTEP_WATER
+ barefootstep = FOOTSTEP_WATER
+ clawfootstep = FOOTSTEP_WATER
+ heavyfootstep = FOOTSTEP_WATER
+
+/turf/open/floor/spooktime/beach/watersolid/attackby(obj/item/C, mob/user, params)
+ return //You aren't digging my lake out unless I want you to fool.
+
+//Motion river water with the lighting on it.
+/turf/open/floor/spooktime/riverwatermotion
+ gender = PLURAL
+ name = "water"
+ desc = "Shallow water."
+ icon = 'modular_citadel/code/modules/eventmaps/Spookystation/iconfile32.dmi'
+ icon_state = "riverwater_motion"
+ slowdown = 1
+ bullet_sizzle = 1
+ bullet_bounce_sound = null //needs a splashing sound one day.
+ footstep = FOOTSTEP_WATER
+ barefootstep = FOOTSTEP_WATER
+ clawfootstep = FOOTSTEP_WATER
+ heavyfootstep = FOOTSTEP_WATER
+
+//No motion river water with the lighting on it.
+/turf/open/floor/spooktime/riverwatermotion/nomotion
+ icon_state = "riverwater"
+
+//Cobblestone and all of its directions tied to the parent.
+/turf/open/floor/spooktime/cobble //Middle and parent
+ name = "cobblestone path" //We don't use directional varedits otherwise the map can load them incorrect.
+ desc = "A simple but beautiful path made of various sized stones."
+ icon = 'modular_citadel/code/modules/eventmaps/Spookystation/iconfile32.dmi'
+ icon_state = "cobble_mid" //as to why? Sometimes it will spawn the turf elsewhere and move it into place.
+ //That means the direction will change because of this movement, usually when theres things ontop of it.
+ footstep = FOOTSTEP_FLOOR
+ barefootstep = FOOTSTEP_HARD_BAREFOOT
+ clawfootstep = FOOTSTEP_HARD_CLAW
+ heavyfootstep = FOOTSTEP_GENERIC_HEAVY
+ tiled_dirt = 0
+
+/turf/open/floor/spooktime/cobble/cornerNW //First corner
+ icon_state = "cobble_corner_nw"
+/turf/open/floor/spooktime/cobble/cornerNE //Now that these are hardcoded individuals.
+ icon_state = "cobble_corner_ne" //Movement won't change what they are on mapload.
+/turf/open/floor/spooktime/cobble/cornerSW
+ icon_state = "cobble_corner_sw"
+/turf/open/floor/spooktime/cobble/cornerSE //I found i don't need most of these but still lol.
+ icon_state = "cobble_corner_se"
+
+/turf/open/floor/spooktime/cobble/sideN //First Side
+ icon_state = "cobble_side_n"
+/turf/open/floor/spooktime/cobble/sideS
+ icon_state = "cobble_side_s"
+/turf/open/floor/spooktime/cobble/sideE
+ icon_state = "cobble_side_e"
+/turf/open/floor/spooktime/cobble/sideW
+ icon_state = "cobble_side_w"
+
+//A tiny tiny bit of the total road icon file from f13 edited for grass not desert hastily.
+//Theres something like 30 pieces including crosswalks, sidewalks, potholes and other shit in it man.
+/turf/open/floor/spooktime/cobble/roadmid //Center piece
+ name = "road"
+ desc = "Its asphault alright"
+ icon_state = "road"
+
+/turf/open/floor/spooktime/cobble/roadsideN //road edges, I have a lot of these
+ icon_state = "road_side_N"
+/turf/open/floor/spooktime/cobble/roadsideS //But i don't feel like adding them all for a temp map.
+ icon_state = "road_side_S"
+/turf/open/floor/spooktime/cobble/roadsideE
+ icon_state = "road_side_E"
+/turf/open/floor/spooktime/cobble/roadsideW
+ icon_state = "road_side_W"
+/turf/open/floor/spooktime/cobble/roadcornerSW
+ icon_state = "road_corner_sw"
+
+/turf/open/indestructible/spooknecropolis
+ name = "necropolis floor"
+ desc = "It's regarding you suspiciously."
+ icon = 'icons/turf/floors.dmi'
+ icon_state = "necro1"
+ baseturfs = /turf/open/indestructible/necropolis
+ footstep = FOOTSTEP_LAVA
+ barefootstep = FOOTSTEP_LAVA
+ clawfootstep = FOOTSTEP_LAVA
+ heavyfootstep = FOOTSTEP_LAVA
+ tiled_dirt = FALSE
+
+//Fermis's umbrella
+
+/obj/item/umbrella
+ name = "umbrella"
+ desc = "To keep the rain off you. Use with caution on windy days."
+ icon = 'icons/obj/items_and_weapons.dmi'
+ lefthand_file = 'icons/mob/inhands/items_lefthand.dmi'
+ righthand_file = 'icons/mob/inhands/items_righthand.dmi'
+ icon_state = "umbrella_closed"
+ slot_flags = SLOT_BELT
+ force = 5
+ throwforce = 5
+ w_class = WEIGHT_CLASS_SMALL
+ var/open = FALSE
+
+/obj/item/umbrella/Initialize()
+ ..()
+ color = RANDOM_COLOUR
+ update_icon()
+
+/obj/item/umbrella/attack_self()
+ toggle_umbrella()
+
+/obj/item/umbrella/proc/toggle_umbrella()
+ open = !open
+ icon_state = "umbrella_[open ? "open" : "closed"]"
+ item_state = icon_state
+ update_icon()
+
+//Keep the mechs out of the mech arena
+/obj/structure/trap/ctf/nomech
+ name = "anti-mech barrier"
+ desc = "attempts to bring mechs into the regular ball space may result in spontaneous crabification"
+
+/obj/structure/trap/ctf/nomech/Crossed(atom/movable/AM)
+ if(is_type_in_typecache(AM, ignore_typecache))
+ return
+ flare()
+ if(ismecha(AM) || istype(AM, /obj/item/mecha_parts) || istype(AM, /obj/structure/mecha_wreckage))
+ qdel(AM)
+
+/*
+ Shitty Hay Objects Sprited by me in a rush when I was half-asleep at 9am + The material
+ */
+
+GLOBAL_LIST_INIT(hay_recipes, list ( \
+ new/datum/stack_recipe("Rice Hat", /obj/item/clothing/head/rice_hat, 4, time = 5, one_per_turf = 0, on_floor = 0), \
+ new/datum/stack_recipe("Hay Bed", /obj/structure/bed/badhaybed, 4, time = 15, one_per_turf = 1, on_floor = 0), \
+ new/datum/stack_recipe("Wicker Basket", /obj/structure/closet/crate/awfulwickerbasket, 5, time = 40, one_per_turf = 0, on_floor = 1), \
+))
+//Thanks Gomble
+/obj/item/stack/sheet/hay
+ name = "hay"
+ desc = "A bundle of hay. Food for livestock, and useful for weaving. Hail the Wickerman."
+ singular_name = "hay stalk"
+ icon = 'modular_citadel/code/modules/eventmaps/Spookystation/iconfile32.dmi'
+ icon_state = "hay"
+ item_state = "hay"
+ force = 1
+ throwforce = 1
+ throw_speed = 1
+ throw_range = 2
+ max_amount = 500
+ attack_verb = list("tickled", "poked", "whipped")
+ hitsound = 'sound/weapons/grenadelaunch.ogg'
+
+/obj/item/stack/sheet/hay/Initialize(mapload, new_amount, merge = TRUE)
+ recipes = GLOB.hay_recipes
+ return ..()
+
+/obj/item/stack/sheet/hay/fifty
+ amount = 50
+
+/obj/item/stack/sheet/hay/twenty
+ amount = 20
+
+/obj/item/stack/sheet/hay/ten
+ amount = 10
+
+/obj/item/stack/sheet/hay/five
+ amount = 5
+
+
+/obj/item/stack/sheet/hay/update_icon()
+ var/amount = get_amount()
+ if((amount <= 4) && (amount > 0))
+ icon_state = "hay[amount]"
+ else
+ icon_state = "hay"
+
+/*
+ Hay Objects hastily drawn by me at 9am in a rush.
+ */
+//Shitty bed
+/obj/structure/bed/badhaybed
+ name = "Low-quality Hay Bed"
+ desc = "It looks like someone hastily put this together, even if the builder didn't."
+ icon = 'modular_citadel/code/modules/eventmaps/Spookystation/iconfile32.dmi'
+ icon_state = "shitty_hay_bed"
+ anchored = 1
+ can_buckle = 1
+ buckle_lying = 1
+ resistance_flags = FLAMMABLE
+ max_integrity = 50
+ integrity_failure = 30
+ buildstacktype = /obj/item/stack/sheet/hay
+ buildstackamount = 5
+
+//Awful Wicker Basket
+/obj/structure/closet/crate/awfulwickerbasket
+ name = "Low-quality Wicker Basket"
+ desc = "A handmade wicker basket, you don't know why it looks like this. But you probably don't like it."
+ icon = 'modular_citadel/code/modules/eventmaps/Spookystation/iconfile32.dmi'
+ icon_state = "shitty_basket" //yes, there is no space on crates so the other state is shitty_basketopen
+ resistance_flags = FLAMMABLE
+ material_drop = /obj/item/stack/sheet/hay
+ material_drop_amount = 5
diff --git a/modular_citadel/code/modules/eventmaps/Spookystation/Tick.ogg b/modular_citadel/code/modules/eventmaps/Spookystation/Tick.ogg
new file mode 100644
index 0000000000..a3e0e3931e
Binary files /dev/null and b/modular_citadel/code/modules/eventmaps/Spookystation/Tick.ogg differ
diff --git a/modular_citadel/code/modules/eventmaps/Spookystation/Tock.ogg b/modular_citadel/code/modules/eventmaps/Spookystation/Tock.ogg
new file mode 100644
index 0000000000..265d775e9c
Binary files /dev/null and b/modular_citadel/code/modules/eventmaps/Spookystation/Tock.ogg differ
diff --git a/modular_citadel/code/modules/eventmaps/Spookystation/areas.dmi b/modular_citadel/code/modules/eventmaps/Spookystation/areas.dmi
new file mode 100644
index 0000000000..f442b76f11
Binary files /dev/null and b/modular_citadel/code/modules/eventmaps/Spookystation/areas.dmi differ
diff --git a/modular_citadel/code/modules/eventmaps/Spookystation/basecaveloop.ogg b/modular_citadel/code/modules/eventmaps/Spookystation/basecaveloop.ogg
new file mode 100644
index 0000000000..da25ab77a0
Binary files /dev/null and b/modular_citadel/code/modules/eventmaps/Spookystation/basecaveloop.ogg differ
diff --git a/modular_citadel/code/modules/eventmaps/Spookystation/baseinsideloop.ogg b/modular_citadel/code/modules/eventmaps/Spookystation/baseinsideloop.ogg
new file mode 100644
index 0000000000..a08cfa32ad
Binary files /dev/null and b/modular_citadel/code/modules/eventmaps/Spookystation/baseinsideloop.ogg differ
diff --git a/modular_citadel/code/modules/eventmaps/Spookystation/baseoutsideloop.ogg b/modular_citadel/code/modules/eventmaps/Spookystation/baseoutsideloop.ogg
new file mode 100644
index 0000000000..8fed222a90
Binary files /dev/null and b/modular_citadel/code/modules/eventmaps/Spookystation/baseoutsideloop.ogg differ
diff --git a/modular_citadel/code/modules/eventmaps/Spookystation/caveloop1.ogg b/modular_citadel/code/modules/eventmaps/Spookystation/caveloop1.ogg
new file mode 100644
index 0000000000..6ff1b3da76
Binary files /dev/null and b/modular_citadel/code/modules/eventmaps/Spookystation/caveloop1.ogg differ
diff --git a/modular_citadel/code/modules/eventmaps/Spookystation/caveloop2.ogg b/modular_citadel/code/modules/eventmaps/Spookystation/caveloop2.ogg
new file mode 100644
index 0000000000..2a5a971adc
Binary files /dev/null and b/modular_citadel/code/modules/eventmaps/Spookystation/caveloop2.ogg differ
diff --git a/modular_citadel/code/modules/eventmaps/Spookystation/caveloop3.ogg b/modular_citadel/code/modules/eventmaps/Spookystation/caveloop3.ogg
new file mode 100644
index 0000000000..4b13c59382
Binary files /dev/null and b/modular_citadel/code/modules/eventmaps/Spookystation/caveloop3.ogg differ
diff --git a/modular_citadel/code/modules/eventmaps/Spookystation/caveloop4.ogg b/modular_citadel/code/modules/eventmaps/Spookystation/caveloop4.ogg
new file mode 100644
index 0000000000..22d6e54e89
Binary files /dev/null and b/modular_citadel/code/modules/eventmaps/Spookystation/caveloop4.ogg differ
diff --git a/modular_citadel/code/modules/eventmaps/Spookystation/clock32x49.dmi b/modular_citadel/code/modules/eventmaps/Spookystation/clock32x49.dmi
new file mode 100644
index 0000000000..4f0083950a
Binary files /dev/null and b/modular_citadel/code/modules/eventmaps/Spookystation/clock32x49.dmi differ
diff --git a/modular_citadel/code/modules/eventmaps/Spookystation/halloweenPersiWork.dm b/modular_citadel/code/modules/eventmaps/Spookystation/halloweenPersiWork.dm
new file mode 100644
index 0000000000..f14846744f
--- /dev/null
+++ b/modular_citadel/code/modules/eventmaps/Spookystation/halloweenPersiWork.dm
@@ -0,0 +1,311 @@
+//Halloween Fluff Papers!
+
+/obj/item/paper/pamphlet/balls/spookyasylum
+ name = "ASYLUMNAME Pamphlet"
+ info = "
The Twin Nexus Hotel
A place of Sanctuary
Welcome to The Twin-Nexus Hotel, \[insert name here]! The loyal staff stride to their best effort to cater for the best possible experience for all space(wo)men! If you have any questions or comments, please ask one of our on-board staff for more information.
"
+
+/obj/item/paper/fluff/balls/spookyasylum/cell03
+ name = "Cell 3 Patient Information"
+ info = "Name: J. Crane Age: 46 Gender: M Height: 183cm Weight: 81kg Notes: Patient exhibits violent tendencies and is not to be released from restraints under any circumstances. To reduce risk of violent outbreaks, birds; which patient has a strong phobia towards; are no longer allowed in proximity of cells, this includes the chief of staff's pet parrot."
+
+/obj/item/paper/fluff/balls/spookyasylum/cell04
+ name = "Cell 4 Patient Information"
+ info = "Name: Fidel S. Age: 20 Gender: M Height: 170cm Weight: 68kg Notes: Patient appears to be under the delusion that he is a dog, suffers from incontinence, and bites staff. Patient to be kept restrained in cell after attacking orderly Robinson, do not remove patient's muzzle outside designated meal periods."
+
+/obj/item/paper/fluff/balls/spookyasylum/traffickingvictim
+ name = "Cell 1 Patient Information"
+ info = "Name: S. Albright Age: 26 Gender: F Height: 174cm Weight: 63kg Notes: \[The notes are crossed out and unreadable, but there is writing on the back of the paper] Buyer found in Sol system, wealthy Martian man looking for a cheap bride, doesn't mind poor condition of the merchandise. Will be packaging with the next supply ship for transport."
+
+/obj/item/paper/fluff/balls/spookyasylum/healstaffnote
+ name = "Shipping Manifest 'Healing Staves'"
+ info = "Contained in this chest are several magical healing staves created by NT sanctioned warlocks, please use them in the event an employee is injured during the festivities. We hope you have a safe and enjoyable celebration, remember you are expected to return to work promptly at its conclusion. We apologize in the unlikely event the contents of the crate are scattered around the asylum by its teleportation."
+
+//Dorm Buttons
+
+/obj/machinery/button/door/dorms/dorm01
+ name = "dorm 1 button"
+ id = "D100"
+ normaldoorcontrol = 1
+ pixel_x = 24
+ specialfunctions = 4
+
+/obj/machinery/button/door/dorms/dorm02
+ name = "dorm 2 button"
+ id = "D101"
+ normaldoorcontrol = 1
+ pixel_x = 24
+ specialfunctions = 4
+
+/obj/machinery/button/door/dorms/dorm03
+ name = "dorm 3 button"
+ id = "D102"
+ normaldoorcontrol = 1
+ pixel_x = 24
+ specialfunctions = 4
+
+/obj/machinery/button/door/dorms/dorm04
+ name = "dorm 4 button"
+ id = "D103"
+ normaldoorcontrol = 1
+ pixel_x = 24
+ specialfunctions = 4
+
+/obj/machinery/button/door/dorms/dorm05
+ name = "dorm 5 button"
+ id = "D104"
+ normaldoorcontrol = 1
+ pixel_x = -24
+ specialfunctions = 4
+
+/obj/machinery/button/door/dorms/dorm06
+ name = "dorm 6 button"
+ id = "D105"
+ normaldoorcontrol = 1
+ pixel_x = -24
+ specialfunctions = 4
+
+/obj/machinery/button/door/dorms/dorm07
+ name = "dorm 7 button"
+ id = "D106"
+ normaldoorcontrol = 1
+ pixel_x = -24
+ specialfunctions = 4
+
+/obj/machinery/button/door/dorms/dorm08
+ name = "dorm 8 button"
+ id = "D107"
+ normaldoorcontrol = 1
+ pixel_x = 24
+ specialfunctions = 4
+
+/obj/machinery/button/door/dorms/dorm09
+ name = "dorm 9 button"
+ id = "D108"
+ normaldoorcontrol = 1
+ pixel_x = 24
+ specialfunctions = 4
+
+/obj/machinery/button/door/dorms/dorm10
+ name = "dorm 10 button"
+ id = "D109"
+ normaldoorcontrol = 1
+ pixel_x = 24
+ specialfunctions = 4
+
+/obj/machinery/button/door/dorms/dorm11
+ name = "dorm 11 button"
+ id = "D110"
+ normaldoorcontrol = 1
+ pixel_x = -24
+ specialfunctions = 4
+
+/obj/machinery/button/door/dorms/dorm12
+ name = "dorm 12 button"
+ id = "D111"
+ normaldoorcontrol = 1
+ pixel_x = -24
+ specialfunctions = 4
+
+/obj/machinery/button/door/dorms/dorm13
+ name = "dorm 13 button"
+ id = "D112"
+ normaldoorcontrol = 1
+ pixel_x = -24
+ specialfunctions = 4
+
+/obj/machinery/button/door/dorms/dorm14
+ name = "dorm 14 button"
+ id = "D113"
+ normaldoorcontrol = 1
+ pixel_x = 24
+ specialfunctions = 4
+
+/obj/machinery/button/door/dorms/dorm15
+ name = "dorm 15 button"
+ id = "D114"
+ normaldoorcontrol = 1
+ pixel_x = 24
+ specialfunctions = 4
+
+/obj/machinery/button/door/dorms/dorm16
+ name = "dorm 16 button"
+ id = "D115"
+ normaldoorcontrol = 1
+ pixel_x = 24
+ specialfunctions = 4
+
+/obj/machinery/button/door/dorms/dorm17
+ name = "dorm 17 button"
+ id = "D116"
+ normaldoorcontrol = 1
+ pixel_x = -24
+ specialfunctions = 4
+
+/obj/machinery/button/door/dorms/dorm18
+ name = "dorm 18 button"
+ id = "D117"
+ normaldoorcontrol = 1
+ pixel_x = -24
+ specialfunctions = 4
+
+/obj/machinery/button/door/dorms/dorm19
+ name = "dorm 19 button"
+ id = "D118"
+ normaldoorcontrol = 1
+ pixel_x = -24
+ specialfunctions = 4
+
+/obj/machinery/button/door/dorms/dorm20
+ name = "dorm 20 button"
+ id = "D119"
+ normaldoorcontrol = 1
+ pixel_x = -24
+ specialfunctions = 4
+
+/obj/machinery/button/door/dorms/patient1
+ name = "door bolt"
+ id = "D120"
+ normaldoorcontrol = 1
+ pixel_x = 24
+ pixel_y = -8
+ specialfunctions = 4
+
+/obj/machinery/button/door/dorms/patient2
+ name = "door bolt"
+ id = "D121"
+ normaldoorcontrol = 1
+ pixel_x = 24
+ pixel_y = -8
+ specialfunctions = 4
+
+/obj/machinery/button/door/dorms/luxury1
+ name = "Privacy Shutter Control"
+ id = "L00"
+ pixel_x = -8
+ pixel_y = -24
+
+/obj/machinery/button/door/dorms/luxury2
+ name = "Privacy Shutter Control"
+ id = "L01"
+ pixel_x = 8
+ pixel_y = -24
+
+/obj/machinery/button/door/dorms/luxury3
+ name = "Privacy Shutter Control"
+ id = "L02"
+ pixel_x = 8
+ pixel_y = 24
+
+/obj/machinery/button/door/dorms/luxury4
+ name = "Privacy Shutter Control"
+ id = "L03"
+ pixel_x = -24
+ pixel_y = 8
+
+//Dorm Doors
+
+/obj/machinery/door/airlock/wood/dorms/dorm01
+ name = "Room 1"
+ id_tag = "D100"
+
+/obj/machinery/door/airlock/wood/dorms/dorm02
+ name = "Room 2"
+ id_tag = "D101"
+
+/obj/machinery/door/airlock/wood/dorms/dorm03
+ name = "Room 3"
+ id_tag = "D102"
+
+/obj/machinery/door/airlock/wood/dorms/dorm04
+ name = "Room 4"
+ id_tag = "D103"
+
+/obj/machinery/door/airlock/wood/dorms/dorm05
+ name = "Room 5"
+ id_tag = "D104"
+
+/obj/machinery/door/airlock/wood/dorms/dorm06
+ name = "Room 6"
+ id_tag = "D105"
+
+/obj/machinery/door/airlock/wood/dorms/dorm07
+ name = "Room 7"
+ id_tag = "D106"
+
+/obj/machinery/door/airlock/wood/dorms/dorm08
+ name = "Room 8"
+ id_tag = "D107"
+
+/obj/machinery/door/airlock/wood/dorms/dorm09
+ name = "Room 9"
+ id_tag = "D108"
+
+/obj/machinery/door/airlock/wood/dorms/dorm10
+ name = "Room 10"
+ id_tag = "D109"
+
+/obj/machinery/door/airlock/wood/dorms/dorm11
+ name = "Room 11"
+ id_tag = "D110"
+
+/obj/machinery/door/airlock/wood/dorms/dorm12
+ name = "Room 12"
+ id_tag = "D111"
+
+/obj/machinery/door/airlock/wood/dorms/dorm13
+ name = "Room 13"
+ id_tag = "D112"
+
+/obj/machinery/door/airlock/wood/dorms/dorm14
+ name = "Room 14"
+ id_tag = "D113"
+
+/obj/machinery/door/airlock/wood/dorms/dorm15
+ name = "Room 15"
+ id_tag = "D114"
+
+/obj/machinery/door/airlock/wood/dorms/dorm16
+ name = "Room 16"
+ id_tag = "D115"
+
+/obj/machinery/door/airlock/wood/dorms/dorm17
+ name = "Room 17"
+ id_tag = "D116"
+
+/obj/machinery/door/airlock/wood/dorms/dorm18
+ name = "Room 18"
+ id_tag = "D117"
+
+/obj/machinery/door/airlock/wood/dorms/dorm19
+ name = "Room 19"
+ id_tag = "D118"
+
+/obj/machinery/door/airlock/wood/dorms/dorm20
+ name = "Room 20"
+ id_tag = "D119"
+
+/obj/machinery/door/airlock/wood/dorms/patient1
+ name = "Recovery Room 1"
+ id_tag = "D120"
+
+/obj/machinery/door/airlock/wood/dorms/patient2
+ name = "Recovery Room 2"
+ id_tag = "D121"
+
+//Luxury Dorm Shutters
+
+/obj/machinery/door/poddoor/shutters/preopen/luxury_dorms/luxury01
+ name = "Privacy Shutters"
+ id = "L00"
+
+/obj/machinery/door/poddoor/shutters/preopen/luxury_dorms/luxury02
+ name = "Privacy Shutters"
+ id = "L01"
+
+/obj/machinery/door/poddoor/shutters/preopen/luxury_dorms/luxury03
+ name = "Privacy Shutters"
+ id = "L02"
+
+/obj/machinery/door/poddoor/shutters/preopen/luxury_dorms/luxury04
+ name = "Privacy Shutters"
+ id = "L03"
diff --git a/modular_citadel/code/modules/eventmaps/Spookystation/iconfile32.dmi b/modular_citadel/code/modules/eventmaps/Spookystation/iconfile32.dmi
new file mode 100644
index 0000000000..21ac510615
Binary files /dev/null and b/modular_citadel/code/modules/eventmaps/Spookystation/iconfile32.dmi differ
diff --git a/modular_citadel/code/modules/eventmaps/Spookystation/iconfile64.dmi b/modular_citadel/code/modules/eventmaps/Spookystation/iconfile64.dmi
new file mode 100644
index 0000000000..5643a969df
Binary files /dev/null and b/modular_citadel/code/modules/eventmaps/Spookystation/iconfile64.dmi differ
diff --git a/modular_citadel/code/modules/eventmaps/Spookystation/insideloop1.ogg b/modular_citadel/code/modules/eventmaps/Spookystation/insideloop1.ogg
new file mode 100644
index 0000000000..e271d8e681
Binary files /dev/null and b/modular_citadel/code/modules/eventmaps/Spookystation/insideloop1.ogg differ
diff --git a/modular_citadel/code/modules/eventmaps/Spookystation/insideloop2.ogg b/modular_citadel/code/modules/eventmaps/Spookystation/insideloop2.ogg
new file mode 100644
index 0000000000..de527107bb
Binary files /dev/null and b/modular_citadel/code/modules/eventmaps/Spookystation/insideloop2.ogg differ
diff --git a/modular_citadel/code/modules/eventmaps/Spookystation/insideloop3.ogg b/modular_citadel/code/modules/eventmaps/Spookystation/insideloop3.ogg
new file mode 100644
index 0000000000..db17ab45b3
Binary files /dev/null and b/modular_citadel/code/modules/eventmaps/Spookystation/insideloop3.ogg differ
diff --git a/modular_citadel/code/modules/eventmaps/Spookystation/insideloop4.ogg b/modular_citadel/code/modules/eventmaps/Spookystation/insideloop4.ogg
new file mode 100644
index 0000000000..aeba02c11e
Binary files /dev/null and b/modular_citadel/code/modules/eventmaps/Spookystation/insideloop4.ogg differ
diff --git a/modular_citadel/code/modules/eventmaps/Spookystation/midnightchime.ogg b/modular_citadel/code/modules/eventmaps/Spookystation/midnightchime.ogg
new file mode 100644
index 0000000000..95ac3a0284
Binary files /dev/null and b/modular_citadel/code/modules/eventmaps/Spookystation/midnightchime.ogg differ
diff --git a/modular_citadel/code/modules/eventmaps/Spookystation/outsideloop1.ogg b/modular_citadel/code/modules/eventmaps/Spookystation/outsideloop1.ogg
new file mode 100644
index 0000000000..d7122821af
Binary files /dev/null and b/modular_citadel/code/modules/eventmaps/Spookystation/outsideloop1.ogg differ
diff --git a/modular_citadel/code/modules/eventmaps/Spookystation/outsideloop2.ogg b/modular_citadel/code/modules/eventmaps/Spookystation/outsideloop2.ogg
new file mode 100644
index 0000000000..f4b8526b5c
Binary files /dev/null and b/modular_citadel/code/modules/eventmaps/Spookystation/outsideloop2.ogg differ
diff --git a/modular_citadel/code/modules/eventmaps/Spookystation/talltree128.dmi b/modular_citadel/code/modules/eventmaps/Spookystation/talltree128.dmi
new file mode 100644
index 0000000000..96be612bad
Binary files /dev/null and b/modular_citadel/code/modules/eventmaps/Spookystation/talltree128.dmi differ
diff --git a/modular_citadel/code/modules/eventmaps/Spookystation/treefall.ogg b/modular_citadel/code/modules/eventmaps/Spookystation/treefall.ogg
new file mode 100644
index 0000000000..cd5379ca77
Binary files /dev/null and b/modular_citadel/code/modules/eventmaps/Spookystation/treefall.ogg differ
diff --git a/modular_citadel/code/modules/eventmaps/Spookystation/woodchop.ogg b/modular_citadel/code/modules/eventmaps/Spookystation/woodchop.ogg
new file mode 100644
index 0000000000..0ef5a9edbe
Binary files /dev/null and b/modular_citadel/code/modules/eventmaps/Spookystation/woodchop.ogg differ
diff --git a/modular_citadel/code/modules/mentor/mentor_memo.dm b/modular_citadel/code/modules/mentor/mentor_memo.dm
index 24b7ed32d2..59ea92febd 100644
--- a/modular_citadel/code/modules/mentor/mentor_memo.dm
+++ b/modular_citadel/code/modules/mentor/mentor_memo.dm
@@ -6,7 +6,7 @@
if(!SSdbcore.IsConnected())
to_chat(src, "Failed to establish database connection.", confidential = TRUE)
return
- var/memotask = tgui_input_list(usr,"Choose task.","Memo", list("Show","Write","Edit","Remove"))
+ var/memotask = input(usr,"Choose task.","Memo") in list("Show","Write","Edit","Remove")
if(!memotask)
return
mentor_memo_output(memotask)
@@ -43,7 +43,7 @@
return
qdel(query_memocheck)
- var/memotext = tgui_input_message(src,"Write your Memo","Memo")
+ var/memotext = input(src,"Write your Memo","Memo") as message
if(!memotext)
return
var/datum/db_query/query_memoadd = SSdbcore.NewQuery({"
@@ -73,7 +73,7 @@
if(!memolist.len)
to_chat(src, "No memos found in database.")
return
- var/target_ckey = tgui_input_list(src, "Select whose memo to edit", "Select memo", memolist)
+ var/target_ckey = input(src, "Select whose memo to edit", "Select memo") as null|anything in memolist
if(!target_ckey)
return
var/datum/db_query/query_memofind = SSdbcore.NewQuery({"
@@ -87,7 +87,7 @@
if(query_memofind.NextRow())
var/old_memo = query_memofind.item[1]
qdel(query_memofind)
- var/new_memo = tgui_input_message(src, "Input new memo", "New Memo", "[old_memo]")
+ var/new_memo = input("Input new memo", "New Memo", "[old_memo]", null) as message
if(!new_memo)
return
var/edit_text = "Edited by [ckey] on [SQLtime()] from [old_memo] to [new_memo]"
@@ -146,7 +146,7 @@
if(!memolist.len)
to_chat(src, "No memos found in database.")
return
- var/target_ckey = tgui_input_list(src, "Select whose mentor memo to delete", "Select mentor memo", memolist)
+ var/target_ckey = input(src, "Select whose mentor memo to delete", "Select mentor memo") as null|anything in memolist
if(!target_ckey)
return
var/datum/db_query/query_memodel = SSdbcore.NewQuery({"
diff --git a/modular_citadel/code/modules/mentor/mentorpm.dm b/modular_citadel/code/modules/mentor/mentorpm.dm
index b99f1cdde1..3260e96767 100644
--- a/modular_citadel/code/modules/mentor/mentorpm.dm
+++ b/modular_citadel/code/modules/mentor/mentorpm.dm
@@ -10,7 +10,7 @@
targets["[T]"] = T
var/list/sorted = sortList(targets)
- var/target = tgui_input_list(src,"To whom shall we send a message?","Mentor PM",sorted)
+ var/target = input(src,"To whom shall we send a message?","Mentor PM",null) in sorted|null
cmd_mentor_pm(targets[target],null)
SSblackbox.record_feedback("tally", "Mentor_verb", 1, "APM") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
@@ -36,7 +36,7 @@
//get message text, limit it's length.and clean/escape html
if(!msg)
- msg = tgui_input_text(src,"Message:", "Private message")
+ msg = input(src,"Message:", "Private message") as text|null
if(!msg)
if (is_mentor(whom))
diff --git a/modular_citadel/code/modules/projectiles/guns/ballistic/rifles.dm b/modular_citadel/code/modules/projectiles/guns/ballistic/rifles.dm
index eacb7a7038..e89bb92b33 100644
--- a/modular_citadel/code/modules/projectiles/guns/ballistic/rifles.dm
+++ b/modular_citadel/code/modules/projectiles/guns/ballistic/rifles.dm
@@ -98,7 +98,7 @@
wound_bonus = 15
sharpness = SHARP_EDGED
wound_falloff_tile = 0
-
+
///ammo casings (CASELESS AMMO CASINGS WOOOOOOOO)///
/obj/item/ammo_casing/caseless/flechetteap
@@ -239,7 +239,7 @@
if(user.incapacitated() || !istype(user))
to_chat(user, "You can't do that right now!")
return
- if(tgui_alert(user, "Are you sure you want to recolor your gun?", "Confirm Repaint", list("Yes", "No")) == "Yes")
+ if(alert("Are you sure you want to recolor your gun?", "Confirm Repaint", "Yes", "No") == "Yes")
var/body_color_input = input(usr,"","Choose Shroud Color",body_color) as color|null
if(body_color_input)
body_color = sanitize_hexcolor(body_color_input, desired_format=6, include_crunch=1)
diff --git a/modular_citadel/code/modules/projectiles/guns/energy/energy_gun.dm b/modular_citadel/code/modules/projectiles/guns/energy/energy_gun.dm
index 5a5f20652f..9a8ee4bab1 100644
--- a/modular_citadel/code/modules/projectiles/guns/energy/energy_gun.dm
+++ b/modular_citadel/code/modules/projectiles/guns/energy/energy_gun.dm
@@ -33,7 +33,7 @@
if(user.incapacitated() || !istype(user))
to_chat(user, "You can't do that right now!")
return
- if(tgui_alert(user, "Are you sure you want to repaint your gun?", "Confirm Repaint", list("Yes", "No")) == "Yes")
+ if(alert("Are you sure you want to repaint your gun?", "Confirm Repaint", "Yes", "No") == "Yes")
var/body_color_input = input(usr,"","Choose Body Color",body_color) as color|null
if(body_color_input)
body_color = sanitize_hexcolor(body_color_input, desired_format=6, include_crunch=1)
diff --git a/modular_citadel/code/modules/vectorcrafts/vector_process.dm b/modular_citadel/code/modules/vectorcrafts/vector_process.dm
new file mode 100644
index 0000000000..cc4bd1d074
--- /dev/null
+++ b/modular_citadel/code/modules/vectorcrafts/vector_process.dm
@@ -0,0 +1,28 @@
+PROCESSING_SUBSYSTEM_DEF(vectorcraft)
+ name = "Vectorcraft Movement"
+ priority = 40
+ wait = 2
+ stat_tag = "VC"
+ flags = SS_NO_INIT|SS_TICKER|SS_KEEP_TIMING
+
+ //var/flightsuit_processing = FLIGHTSUIT_PROCESSING_FULL
+
+
+/* unsure if needed
+/datum/controller/subsystem/processing/vectorcraft/Initialize()
+ sync_flightsuit_processing()
+
+/datum/controller/subsystem/processing/vectorcraft/vv_edit_var(var_name, var_value)
+ ..()
+ switch(var_name)
+ if("flightsuit_processing")
+ sync_flightsuit_processing()
+
+/datum/controller/subsystem/processing/vectorcraft/proc/sync_flightsuit_processing()
+ for(var/obj/vehicle/sealed/vectorcraft/VC in processing)
+ VC.sync_processing(src)
+ if(flightsuit_processing == FLIGHTSUIT_PROCESSING_NONE) //Don't even bother firing.
+ can_fire = FALSE
+ else
+ can_fire = TRUE
+*/
diff --git a/modular_citadel/code/modules/vectorcrafts/vectorcar_heads.dm b/modular_citadel/code/modules/vectorcrafts/vectorcar_heads.dm
new file mode 100644
index 0000000000..e89f8b147e
--- /dev/null
+++ b/modular_citadel/code/modules/vectorcrafts/vectorcar_heads.dm
@@ -0,0 +1,28 @@
+/obj/vehicle/sealed/vectorcraft/CMO
+ name = "CMO's hovercar"
+ icon_state = "zoomscoot_CMO"
+
+/obj/vehicle/sealed/vectorcraft/RD
+ name = "RD's hovercar"
+ icon_state = "zoomscoot_RD"
+
+/obj/vehicle/sealed/vectorcraft/hop
+ name = "HOP\'s hovercar"
+ icon_state = "zoomscoot_HOP"
+
+/obj/vehicle/sealed/vectorcraft/hos
+ name = "HOS\'s hovercar"
+ icon_state = "zoomscoot_HOS"
+
+/obj/vehicle/sealed/vectorcraft/CE
+ name = "CE\'s hovercar"
+ icon_state = "zoomscoot_CE"
+
+/obj/vehicle/sealed/vectorcraft/QM
+ name = "QM\'s hovercar"
+ icon_state = "zoomscoot_QM"
+
+/obj/vehicle/sealed/vectorcraft/CAPT
+ name = "Captain\'s hovercar"
+ icon_state = "zoomscoot_CAPT"
+ boost_power = 20 //gosh capt how come CC lets you have more boost power?
diff --git a/modular_citadel/code/modules/vectorcrafts/vectorcraft.dm b/modular_citadel/code/modules/vectorcrafts/vectorcraft.dm
new file mode 100644
index 0000000000..21913e4453
--- /dev/null
+++ b/modular_citadel/code/modules/vectorcrafts/vectorcraft.dm
@@ -0,0 +1,603 @@
+#define SPEED_MOD 5
+#define PX_OFFSET 16 //half of total px size of sprite
+//Cars that drfit
+//By Fermi!
+
+
+/obj/vehicle/sealed/vectorcraft
+ name = "all-terrain hovercraft"
+ desc = "An all-terrain vehicle built for traversing rough terrain with ease. One of the few old-Earth technologies that are still relevant on most planet-bound outposts."
+ icon_state = "zoomscoot"
+ movedelay = 5
+ //allow_diagonal_dir = TRUE - find fix for this later
+ inertia_moving = FALSE
+ animate_movement = 0
+ max_integrity = 100
+ //key_type = /obj/item/key
+ var/obj/structure/trunk //Trunkspace of craft
+ var/vector = list("x" = 0, "y" = 0) //vector math
+ var/tile_loc = list("x" = 0, "y" = 0) //x y offset of tile
+ var/max_acceleration = 5.25
+ var/accel_step = 0.3
+ var/acceleration = 0.4
+ var/max_deceleration = 2
+ var/max_velocity = 110
+ var/boost_power = 15
+ var/enginesound_delay = 0
+ var/gear
+ var/boost_cooldown
+
+
+ var/mob/living/carbon/human/driver
+
+/obj/vehicle/sealed/vectorcraft/mob_enter(mob/living/M)
+ if(!driver)
+ driver = M
+ if(gear != "auto")
+ gear = driver.a_intent
+ start_engine()
+ to_chat(M, "How to drive: \nHold wasd to gain speed in a direction, c to enable/disable the clutch, 1 2 3 4 to change gears while holding a direction (make sure the clutch is enabled when you change gears, you should hear a sound when you've successfully changed gears), r to toggle handbrake, hold alt for brake and press shift for boost (the machine will beep when the boost is recharged)! If you hear an ebbing sound like \"brbrbrbrbr\" you need to gear down, the whining sound means you need to gear up. Hearing a pleasant \"whumwhumwhum\" is optimal gearage! It can be a lil slow to start, so make sure you're in the 1st gear.\n")
+ return ..()
+
+/obj/vehicle/sealed/vectorcraft/mob_exit(mob/living/M)
+ .=..()
+ if(!driver)
+ stop_engine()
+ return
+ if(driver.client)
+ driver.client.pixel_x = 0
+ driver.client.pixel_y = 0
+ driver.pixel_x = 0
+ driver.pixel_y = 0
+ if(M == driver)
+ driver = null
+ gear = initial(gear)
+ stop_engine()
+
+
+//////////////////////////////////////////////////////////////
+// Main driving checks //
+//////////////////////////////////////////////////////////////
+
+/obj/vehicle/sealed/vectorcraft/proc/start_engine()
+ if(dead_check())
+ return
+ START_PROCESSING(SSvectorcraft, src)
+ check_gears()
+ if(!driver)
+ stop_engine()
+
+
+/obj/vehicle/sealed/vectorcraft/proc/stop_engine()
+ STOP_PROCESSING(SSvectorcraft, src)
+ vector = list("x" = 0, "y" = 0)
+ acceleration = initial(acceleration)
+
+/obj/vehicle/sealed/vectorcraft/proc/dead_check()
+ if(driver.stat > 0)
+ mob_exit(driver)
+ stop_engine()
+ return TRUE
+ return FALSE
+
+
+
+//Move the damn car
+/obj/vehicle/sealed/vectorcraft/vehicle_move(cached_direction)
+ if(!driver)
+ stop_engine()
+ if(driver.stat == DEAD)
+ mob_exit(driver)
+ dir = cached_direction
+ check_gears()
+ check_boost()
+ calc_acceleration()
+ calc_vector(cached_direction)
+ /*
+ var/direction = calc_angle()
+ if(!direction)
+ direction = cached_direction
+ return
+ */
+
+ /* depreciated
+ //movespeed
+ if(lastmove + movedelay > world.time)
+ return FALSE
+ lastmove = world.time
+ if(trailer)
+ var/dir_to_move = get_dir(trailer.loc, loc)
+ var/did_move = step(src, direction)
+ if(did_move)
+ step(trailer, dir_to_move)
+ return did_move
+ else
+ after_move(direction)
+ return step(src, direction)
+ */
+
+//Passive hover drift
+/obj/vehicle/sealed/vectorcraft/proc/hover_loop()
+ check_boost()
+ if(driver.m_intent == MOVE_INTENT_WALK)
+ var/deceleration = max_deceleration
+ if(driver.in_throw_mode)
+ deceleration *= 1.5
+ friction(deceleration, TRUE)
+ else if(driver.in_throw_mode)
+ friction(max_deceleration*1.2, TRUE)
+ friction(max_deceleration/4)
+
+ if(trailer)
+ var/dir_to_move = get_dir(trailer.loc, loc)
+ var/did_move = move_car()
+ if(did_move)
+ step(trailer, dir_to_move)
+ trailer.pixel_x = tile_loc["x"]
+ trailer.pixel_y = tile_loc["y"]
+ after_move(did_move)
+ return did_move
+ else
+ var/direction = move_car()
+ after_move(direction)
+ return direction
+
+//I got over messy process procs
+/obj/vehicle/sealed/vectorcraft/process()
+ hover_loop()
+ dead_check()
+
+//////////////////////////////////////////////////////////////
+// Movement procs //
+//////////////////////////////////////////////////////////////
+
+/obj/vehicle/sealed/vectorcraft/proc/move_car()
+
+
+ if(GLOB.Debug2)
+ message_admins("Pre_ Tile_loc: [tile_loc["x"]], [tile_loc["y"]] Vector: [vector["x"]],[vector["y"]]")
+
+ var/cached_tile = tile_loc
+ tile_loc["x"] += vector["x"]/SPEED_MOD
+ tile_loc["y"] += vector["y"]/SPEED_MOD
+ //range = -16 to 16
+ var/x_move = 0
+ if(tile_loc["x"] > PX_OFFSET)
+ x_move = round((tile_loc["x"]+PX_OFFSET) / (PX_OFFSET*2), 1)
+ tile_loc["x"] = ((tile_loc["x"]+PX_OFFSET) % (PX_OFFSET*2))-PX_OFFSET
+ else if(tile_loc["x"] < -PX_OFFSET)
+ x_move = round((tile_loc["x"]-PX_OFFSET) / (PX_OFFSET*2), 1)
+ tile_loc["x"] = ((tile_loc["x"]-PX_OFFSET) % -(PX_OFFSET*2))+PX_OFFSET
+
+
+
+ var/y_move = 0
+ if(tile_loc["y"] > PX_OFFSET)
+ y_move = round((tile_loc["y"]+PX_OFFSET) / (PX_OFFSET*2), 1)
+ tile_loc["y"] = ((tile_loc["y"]+PX_OFFSET) % (PX_OFFSET*2))-PX_OFFSET
+ else if(tile_loc["y"] < -PX_OFFSET)
+ y_move = round((tile_loc["y"]-PX_OFFSET) / (PX_OFFSET*2), 1)
+ tile_loc["y"] = ((tile_loc["y"]-PX_OFFSET) % -(PX_OFFSET*2))+PX_OFFSET
+
+ if(!(x_move == 0 && y_move == 0))
+ var/turf/T = get_offset_target_turf(src, x_move, y_move)
+ for(var/atom/A in T.contents)
+ Bump(A)
+ if(A.density)
+ ricochet()
+ tile_loc = cached_tile
+ return FALSE
+ if(T.density)
+ ricochet()
+ tile_loc = cached_tile
+ return FALSE
+
+ x += x_move
+ y += y_move
+ pixel_x = round(tile_loc["x"], 1)
+ pixel_y = round(tile_loc["y"], 1)
+ if(driver && driver.client)
+ driver.client.pixel_x = pixel_x
+ driver.client.pixel_y = pixel_y
+
+
+ if(GLOB.Debug2)
+ message_admins("Post TileLoc:[tile_loc["x"]], [tile_loc["y"]] Movement: [x_move],[y_move]")
+ message_admins("Pix:[pixel_x],[pixel_y] TileLoc:[tile_loc["x"]], [tile_loc["y"]]. [round(tile_loc["x"])], [round(tile_loc["y"])]")
+ //no tile movement
+
+ if(x_move == 0 && y_move == 0)
+ return FALSE
+
+ //var/direction = calc_step_angle(x_move, y_move)
+ //if(direction) //If the movement is greater than 2
+ // step(src, direction)
+ // after_move(direction)
+
+
+
+
+ return TRUE
+
+//////////////////////////////////////////////////////////////
+// Check procs //
+//////////////////////////////////////////////////////////////
+
+//check the cooldown on the boost
+/obj/vehicle/sealed/vectorcraft/proc/check_boost()
+ if(enginesound_delay < world.time)
+ enginesound_delay = 0
+ if(!boost_cooldown)
+ return
+ if(boost_cooldown < world.time)
+ boost_cooldown = 0
+ playsound(src.loc,'sound/vehicles/boost_ready.ogg', 65, 0)
+ return
+
+//Make sure the clutch is on while changing gears!!
+/obj/vehicle/sealed/vectorcraft/proc/check_gears()
+ if(!driver)
+ for(var/i in contents)
+ if(iscarbon(i))
+ var/mob/living/carbon/C = i
+ driver = C
+ to_chat(driver, "You shuffle across to the driver's seat of the [src]")
+ start_engine()
+ break
+ if(!driver)
+ stop_engine()
+ return
+ if(!gear)
+ gear = driver.a_intent
+ if(gear == "auto")
+ return
+ //USE THE CCLUUUTCHHH
+ if(gear != driver.a_intent && SEND_SIGNAL(driver, COMSIG_COMBAT_MODE_CHECK, COMBAT_MODE_INACTIVE))
+ //playsound
+ to_chat(driver, "The gearbox gives out a horrific sound!")
+ playsound(src.loc,'sound/vehicles/clutch_fail.ogg', 70, 0)
+ apply_damage(5)
+ acceleration = acceleration/2
+ else if(gear != driver.a_intent && SEND_SIGNAL(driver, COMSIG_COMBAT_MODE_CHECK, COMBAT_MODE_ACTIVE))
+ playsound(src.loc,'sound/vehicles/clutch_win.ogg', 100, 0)
+ gear = driver.a_intent
+
+//Bounce the car off a wall
+/obj/vehicle/sealed/vectorcraft/proc/bounce()
+ vector["x"] = -vector["x"]/2
+ vector["y"] = -vector["y"]/2
+ acceleration /= 2
+
+/obj/vehicle/sealed/vectorcraft/proc/ricochet(x_move, y_move)
+ var/speed = calc_speed()
+ apply_damage(speed/10)
+ bounce()
+
+//////////////////////////////////////////////////////////////
+// Damage procs //
+//////////////////////////////////////////////////////////////
+//Repairing
+/obj/vehicle/sealed/vectorcraft/attackby(obj/item/O, mob/user, params)
+ .=..()
+ if(istype(O, /obj/item/weldingtool) && user.a_intent != INTENT_HARM)
+ if(obj_integrity < max_integrity)
+ if(!O.tool_start_check(user, amount=0))
+ return
+
+ user.visible_message("[user] begins repairing [src].", \
+ "You begin repairing [src]...", \
+ "You hear welding.")
+
+ if(O.use_tool(src, user, 40, volume=50))
+ to_chat(user, "You repair [src].")
+ apply_damage(-max_integrity)
+ else
+ to_chat(user, "[src] does not need repairs.")
+
+
+/obj/vehicle/sealed/vectorcraft/attack_hand(mob/user)
+ remove_key(driver)
+ ..()
+
+//Heals/damages the car
+/obj/vehicle/sealed/vectorcraft/proc/apply_damage(damage)
+ obj_integrity -= damage
+ var/healthratio = ((obj_integrity/max_integrity)/4) + 0.75
+ max_acceleration = initial(max_acceleration) * healthratio
+ max_deceleration = initial(max_deceleration) * healthratio
+ boost_power = initial(boost_power) * healthratio
+
+ if(obj_integrity <= 0)
+ mob_exit(driver)
+ var/datum/effect_system/reagents_explosion/e = new()
+ var/turf/T = get_turf(src)
+ e.set_up(1, T, 1, 3)
+ e.start()
+ visible_message("The [src] explodes from taking too much damage!")
+ qdel(src)
+ if(obj_integrity > max_integrity)
+ obj_integrity = max_integrity
+
+//
+/obj/vehicle/sealed/vectorcraft/Bump(atom/M)
+ var/speed = calc_speed()
+ if(isliving(M))
+ var/mob/living/C = M
+ if(!C.anchored)
+ var/atom/throw_target = get_edge_target_turf(C, calc_angle())
+ C.throw_at(throw_target, 10, 14)
+ to_chat(C, "You are hit by the [src]!")
+ to_chat(driver, "You just ran into [C] you crazy lunatic!")
+ C.adjustBruteLoss(speed/10)
+ return ..()
+ //playsound
+ if(istype(M, /obj/vehicle/sealed/vectorcraft))
+ var/obj/vehicle/sealed/vectorcraft/Vc = M
+ Vc.apply_damage(speed/5)
+ Vc.vector["x"] += vector["x"]/2
+ Vc.vector["y"] += vector["y"]/2
+ apply_damage(speed/10)
+ bounce()
+ return ..()
+ if(istype(M, /obj/))
+ var/obj/O = M
+ if(O.density)
+ O.take_damage(speed*2.5)
+ return ..()
+
+//////////////////////////////////////////////////////////////
+// Calc procs //
+//////////////////////////////////////////////////////////////
+/*Calc_step_angle calculates angle based off pixel x,y movement (x,y in)
+Calc angle calcus angle based off vectors
+calc_speed() returns the highest var of x or y relative
+calc accel calculates the acceleration to be added to vector
+calc vector updates the internal vector
+friction reduces the vector by an ammount to both axis*/
+
+//How fast the car is going atm
+/obj/vehicle/sealed/vectorcraft/proc/calc_velocity() //Depreciated.
+ var/speed = calc_speed()
+ switch(speed)
+ if(-INFINITY to 10)
+ movedelay = 5
+ inertia_move_delay = 5
+ if(10 to 20)
+ movedelay = 4
+ inertia_move_delay = 4
+ if(20 to 35)
+ movedelay = 3
+ inertia_move_delay = 3
+ if(35 to 60)
+ movedelay = 2
+ inertia_move_delay = 2
+ if(60 to 90)
+ movedelay = 1
+ inertia_move_delay = 1
+ if(90 to INFINITY)
+ movedelay = 0
+ inertia_move_delay = 0
+ return
+
+/*
+if(driver.sprinting && !(boost_cooldown))
+ acceleration += boost_power //You got boost power!
+ boost_cooldown = world.time + 150
+ playsound(src.loc,'sound/vehicles/boost.ogg', 50, 0)
+ //playsound
+*/
+
+/obj/vehicle/sealed/vectorcraft/proc/calc_step_angle(x, y)
+ if((sqrt(x**2))>1 || (sqrt(y**2))>1) //Too large a movement for a step
+ return FALSE
+ if(x == 1)
+ if (y == 1)
+ return NORTHEAST
+ else if (y == -1)
+ return SOUTHEAST
+ else if (y == 0)
+ return EAST
+ else
+ message_admins("something went wrong; y = [y]")
+ else if (x == -1)
+ if (y == 1)
+ return NORTHWEST
+ else if (y == -1)
+ return SOUTHWEST
+ else if (y == 0)
+ return WEST
+ else
+ message_admins("something went wrong; y = [y]")
+ else if (x != 0)
+ message_admins("something went wrong; x = [x]")
+
+ if (y == 1)
+ return NORTH
+ else if (y == -1)
+ return SOUTH
+ else if (x != 0)
+ message_admins("something went wrong; y = [y]")
+ return FALSE
+
+//Returns the angle to move towards
+/obj/vehicle/sealed/vectorcraft/proc/calc_angle()
+ var/x = round(vector["x"], 1)
+ var/y = round(vector["y"], 1)
+ if(y == 0)
+ if(x > 0)
+ return EAST
+ else if(x < 0)
+ return WEST
+ if(x == 0)
+ if(y > 0)
+ return NORTH
+ else if(y < 0)
+ return SOUTH
+ if(x == 0 || y == 0)
+ return FALSE
+ var/angle = (ATAN2(x,y))
+ //if(angle < 0)
+ // angle += 360
+ //message_admins("x:[x], y: [y], angle:[angle]")
+
+ //I WISH I HAD RADIANSSSSSSSSSS
+ if(angle > 0)
+ switch(angle)
+ if(0 to 22)
+ return EAST
+ if(22 to 67)
+ return NORTHEAST
+ if(67 to 112)
+ return NORTH
+ if(112 to 157)
+ return NORTHWEST
+ if(157 to 180)
+ return WEST
+ else
+ switch(angle)
+ if(0 to -22)
+ return EAST
+ if(-22 to -67)
+ return SOUTHEAST
+ if(-67 to -112)
+ return SOUTH
+ if(-112 to -157)
+ return SOUTHWEST
+ if(-157 to -180)
+ return WEST
+
+
+//updates the internal speed of the car (used for crashing)
+/obj/vehicle/sealed/vectorcraft/proc/calc_speed()
+ var/speed = max(sqrt((vector["x"]**2)), sqrt((vector["y"]**2)))
+ return speed
+
+//Converts "gear" from intent to numerics
+/obj/vehicle/sealed/vectorcraft/proc/convert_gear()
+ switch(gear)
+ if("help")
+ return 1
+ if("disarm")
+ return 2
+ if("grab")
+ return 3
+ if("harm")
+ return 4
+
+//Calculates the acceleration
+/obj/vehicle/sealed/vectorcraft/proc/calc_acceleration() //Make speed 0 - 100 regardless of gear here
+ if(SEND_SIGNAL(driver, COMSIG_COMBAT_MODE_CHECK, COMBAT_MODE_ACTIVE))//clutch is on
+ return FALSE
+ if(gear == "auto")
+ acceleration += accel_step
+ acceleration = clamp(acceleration, initial(acceleration), max_acceleration)
+ if(!enginesound_delay)
+ playsound(src.loc,'sound/vehicles/norm_eng.ogg', 25, 0)
+ enginesound_delay = world.time + 16
+ return
+
+ var/gear_val = convert_gear()
+ var/min_accel = max_acceleration*( (((gear_val-1) * 20) + ((gear_val-1)*5)) /100)
+ var/max_accel = max_acceleration*((gear_val * 25)/100) //1.25 - 5
+
+ if(acceleration < min_accel)
+ acceleration += accel_step/10
+ if(!enginesound_delay)
+ playsound(src.loc,'sound/vehicles/low_eng.ogg', 25, 0)
+ enginesound_delay = world.time + 16
+ else if (acceleration > max_accel)
+ acceleration -= accel_step
+ if(!enginesound_delay)
+ playsound(src.loc,'sound/vehicles/high_eng.ogg', 25, 0)
+ enginesound_delay = world.time + 16
+ else
+ if(gear_val == 1)
+ acceleration += accel_step*3.5
+ else
+ acceleration += accel_step
+ if(!enginesound_delay)
+ playsound(src.loc,'sound/vehicles/norm_eng.ogg', 25, 0)
+ enginesound_delay = world.time + 16
+
+ if(acceleration > ((max_acceleration*calc_speed())/90) && acceleration > max_acceleration/5)
+ acceleration -= accel_step*2
+ if(!enginesound_delay)
+ playsound(src.loc,'sound/vehicles/high_eng.ogg', 25, 0)
+ enginesound_delay = world.time + 16
+ return
+
+ acceleration = clamp(acceleration, initial(acceleration), max_acceleration)
+
+//calulate the vector change
+/obj/vehicle/sealed/vectorcraft/proc/calc_vector(direction)
+ if(SEND_SIGNAL(driver, COMSIG_COMBAT_MODE_CHECK, COMBAT_MODE_ACTIVE))//clutch is on
+ return FALSE
+ var/cached_acceleration = acceleration
+ var/boost_active = FALSE
+ if((driver.combat_flags & COMBAT_FLAG_SPRINT_ACTIVE) && !(boost_cooldown))
+ cached_acceleration += boost_power //You got boost power!
+ boost_cooldown = world.time + 80
+ playsound(src.loc,'sound/vehicles/boost.ogg', 100, 0)
+ boost_active = TRUE
+ //playsound
+
+ var/result_vector = vector
+ switch(direction)
+ if(NORTH)
+ result_vector["y"] += cached_acceleration
+ if(NORTHEAST)
+ result_vector["x"] += cached_acceleration/1.4
+ result_vector["y"] += cached_acceleration/1.4
+ if(EAST)
+ result_vector["x"] += cached_acceleration
+ if(SOUTHEAST)
+ result_vector["x"] += cached_acceleration/1.4
+ result_vector["y"] -= cached_acceleration/1.4
+ if(SOUTH)
+ result_vector["y"] -= cached_acceleration
+ if(SOUTHWEST)
+ result_vector["x"] -= cached_acceleration/1.4
+ result_vector["y"] -= cached_acceleration/1.4
+ if(WEST)
+ result_vector["x"] -= cached_acceleration
+ if(NORTHWEST)
+ result_vector["y"] += cached_acceleration/1.4
+ result_vector["x"] -= cached_acceleration/1.4
+
+ if(boost_active)
+ vector["x"] = result_vector["x"]
+ vector["y"] = result_vector["y"]
+ else
+ vector["x"] = clamp(result_vector["x"], -max_velocity, max_velocity)
+ vector["y"] = clamp(result_vector["y"], -max_velocity, max_velocity)
+
+ if(vector["x"] > max_velocity || vector["x"] < -max_velocity)
+ vector["x"] = vector["x"] - (vector["x"]/10)
+ vector["x"] = clamp(vector["x"], -250, 250)
+ if(vector["y"] > max_velocity || vector["y"] < -max_velocity)
+ vector["y"] = vector["y"] - (vector["y"]/10)
+ vector["y"] = clamp(vector["y"], -250, 250)
+
+ return
+
+//Reduces speed
+/obj/vehicle/sealed/vectorcraft/proc/friction(change, sfx = FALSE)
+ //decell X
+ if(vector["x"] == 0 && vector["y"] == 0)
+ return
+ if(vector["x"] <= -change)
+ vector["x"] += change
+ else if(vector["x"] >= change)
+ vector["x"] -= change
+ else
+ vector["x"] = 0
+ //decell Y
+ if(vector["y"] <= -change)
+ vector["y"] += change
+ else if(vector["y"] >= change)
+ vector["y"] -= change
+ else
+ vector["y"] = 0
+
+ if(sfx)
+ playsound(src.loc,'sound/vehicles/skid.ogg', 50, 0)
diff --git a/modular_citadel/code/modules/vectorcrafts/vectorvariants.dm b/modular_citadel/code/modules/vectorcrafts/vectorvariants.dm
new file mode 100644
index 0000000000..0fa1ec590d
--- /dev/null
+++ b/modular_citadel/code/modules/vectorcrafts/vectorvariants.dm
@@ -0,0 +1,57 @@
+/obj/vehicle/sealed/vectorcraft/cyber
+ name = "Cyberscuttle"
+ desc = "A robust hovercar that, until recently, could self drive. Unfortunately it was found that the AI was terrified of orbs and drove away from them at all costs. Overall a smashing hovercar."
+ max_acceleration = 4.5
+ accel_step = 0.4
+ acceleration = 0.5
+ max_deceleration = 3.5
+ max_velocity = 95
+ max_integrity = 150
+ icon_state = "cyber"
+
+/obj/vehicle/sealed/vectorcraft/clown
+ name = "Clowncraft"
+ icon_state = "clowncar"
+ max_acceleration = 4.7
+ accel_step = 0.4
+ acceleration = 0.5
+ max_deceleration = 4
+ max_velocity = 90
+ boost_power = 25
+ max_integrity = 80
+
+/obj/vehicle/sealed/vectorcraft/truck
+ name = "Hovertruck"
+ desc = "An all-terrain vehicle built for traversing rough terrain with ease."
+ gear = "auto"
+ icon_state = "truck"
+ max_acceleration = 4.25
+ accel_step = 0.4
+ acceleration = 0.5
+ max_deceleration = 5
+ max_velocity = 90
+ boost_power = 10
+ max_integrity = 200
+
+/obj/vehicle/sealed/vectorcraft/ambulance
+ name = "Ambulance"
+ icon_state = "ambutruck"
+ max_acceleration = 4.25
+ accel_step = 0.4
+ acceleration = 0.5
+ max_deceleration = 5
+ max_velocity = 90
+ boost_power = 40
+ max_integrity = 200
+
+/obj/vehicle/sealed/vectorcraft/auto
+ name = "Automatic hovercraft"
+ gear = "auto"
+ icon_state = "zoomscoot_auto"
+ max_acceleration = 4
+ accel_step = 0.22
+ acceleration = 0.30
+ max_deceleration = 2
+ max_velocity = 90
+ boost_power = 5
+ max_integrity = 100
diff --git a/sound/vehicles/boost.ogg b/sound/vehicles/boost.ogg
new file mode 100644
index 0000000000..92ff266b8c
Binary files /dev/null and b/sound/vehicles/boost.ogg differ
diff --git a/sound/vehicles/boost_ready.ogg b/sound/vehicles/boost_ready.ogg
new file mode 100644
index 0000000000..42030ee600
Binary files /dev/null and b/sound/vehicles/boost_ready.ogg differ
diff --git a/sound/vehicles/clutch_fail.ogg b/sound/vehicles/clutch_fail.ogg
new file mode 100644
index 0000000000..c8e07a6251
Binary files /dev/null and b/sound/vehicles/clutch_fail.ogg differ
diff --git a/sound/vehicles/clutch_win.ogg b/sound/vehicles/clutch_win.ogg
new file mode 100644
index 0000000000..0af36eed8e
Binary files /dev/null and b/sound/vehicles/clutch_win.ogg differ
diff --git a/sound/vehicles/high_eng.ogg b/sound/vehicles/high_eng.ogg
new file mode 100644
index 0000000000..7da7233c09
Binary files /dev/null and b/sound/vehicles/high_eng.ogg differ
diff --git a/sound/vehicles/low_eng.ogg b/sound/vehicles/low_eng.ogg
new file mode 100644
index 0000000000..d6843b87c5
Binary files /dev/null and b/sound/vehicles/low_eng.ogg differ
diff --git a/sound/vehicles/norm_eng.ogg b/sound/vehicles/norm_eng.ogg
new file mode 100644
index 0000000000..7fb70e6760
Binary files /dev/null and b/sound/vehicles/norm_eng.ogg differ
diff --git a/sound/vehicles/skid.ogg b/sound/vehicles/skid.ogg
new file mode 100644
index 0000000000..08ae4116ca
Binary files /dev/null and b/sound/vehicles/skid.ogg differ
diff --git a/tgstation.dme b/tgstation.dme
index 7a8a7a173e..7aca376ba7 100644
--- a/tgstation.dme
+++ b/tgstation.dme
@@ -3613,7 +3613,6 @@
#include "code\modules\tgui\tgui.dm"
#include "code\modules\tgui\tgui_alert.dm"
#include "code\modules\tgui\tgui_input_list.dm"
-#include "code\modules\tgui\tgui_input_text.dm"
#include "code\modules\tgui\tgui_window.dm"
#include "code\modules\tgui\states\admin.dm"
#include "code\modules\tgui\states\always.dm"
@@ -3753,6 +3752,8 @@
#include "modular_citadel\code\modules\custom_loadout\custom_items.dm"
#include "modular_citadel\code\modules\custom_loadout\load_to_mob.dm"
#include "modular_citadel\code\modules\custom_loadout\read_from_file.dm"
+#include "modular_citadel\code\modules\eventmaps\Spookystation\halloweenPersiWork.dm"
+#include "modular_citadel\code\modules\eventmaps\Spookystation\JTGSZwork.dm"
#include "modular_citadel\code\modules\mentor\dementor.dm"
#include "modular_citadel\code\modules\mentor\follow.dm"
#include "modular_citadel\code\modules\mentor\mentor.dm"
@@ -3791,4 +3792,8 @@
#include "modular_citadel\code\modules\reagents\chemistry\recipes\fermi.dm"
#include "modular_citadel\code\modules\reagents\objects\clothes.dm"
#include "modular_citadel\code\modules\reagents\objects\items.dm"
+#include "modular_citadel\code\modules\vectorcrafts\vector_process.dm"
+#include "modular_citadel\code\modules\vectorcrafts\vectorcar_heads.dm"
+#include "modular_citadel\code\modules\vectorcrafts\vectorcraft.dm"
+#include "modular_citadel\code\modules\vectorcrafts\vectorvariants.dm"
// END_INCLUDE
diff --git a/tgui/packages/tgui/interfaces/ClockworkSlab.js b/tgui/packages/tgui/interfaces/ClockworkSlab.js
index 3aab0d7617..56ac7b6f3a 100644
--- a/tgui/packages/tgui/interfaces/ClockworkSlab.js
+++ b/tgui/packages/tgui/interfaces/ClockworkSlab.js
@@ -6,12 +6,14 @@
* @license MIT
*/
-import { useBackend, useSharedState } from '../backend';
+import { useBackend, useLocalState, useSharedState } from '../backend';
+import { createSearch } from 'common/string';
import { map } from 'common/collections';
-import { Section, Tabs, Table, Button, Box, NoticeBox, Divider } from '../components';
+import { Section, Tabs, Table, Button, Box, NoticeBox, Divider, Input } from '../components';
import { Fragment } from 'inferno';
import { Window } from '../layouts';
+const MAX_SEARCH_RESULTS = 25;
let REC_RATVAR = "";
// You may ask "why is this not inside ClockworkSlab"
// It's because cslab gets called every time. Lag is bad.
@@ -31,13 +33,35 @@ export const ClockworkSlab = (props, context) => {
tab,
setTab,
] = useSharedState(context, 'tab', 'Application');
- const scriptInTab = scripture
- && scripture[tab]
- || [];
+
const tierInfo = tier_infos
&& tier_infos[tab]
|| {};
+ const [
+ searchText,
+ setSearchText,
+ ] = useLocalState(context, 'searchText', '');
+
+ const testSearch = createSearch(searchText, script => {
+ return script.name + script.descname;
+ });
+
+ let bucketOfScriptures = [];
+ // merge it, no need to throw a var.
+
+ const scriptInTab = (searchText.length > 0)
+ // Flatten all categories and apply search to it
+ // truthy because WE DO NOT WANT TO RETURN THIS!
+ && !!map((v, k) => {
+ bucketOfScriptures = bucketOfScriptures.concat(v);
+ })(scripture)
+ && bucketOfScriptures.filter(testSearch)
+ .filter((item, i) => i < MAX_SEARCH_RESULTS)
+ // Return the default one
+ || scripture[tab]
+ || null; // this is nullable, it's recommended that you null it.
+
return (
{
act('toggle')}>
- Recollection
-
+
+ Search
+ setSearchText(value)}
+ mx={1} />
+
+
)}>
{power} power is available for scripture
and other consumers.
@@ -67,13 +99,13 @@ export const ClockworkSlab = (props, context) => {
key={name}
selected={tab === name}
onClick={() => setTab(name)}>
- {name}
+ {name} ({scriptures?.length || 0})
))(scripture)}
{tierInfo.ready ? (
@@ -125,16 +157,16 @@ export const CSScripture = (props, context) => {
power_unformatted = 0,
} = data;
const {
- scriptInTab,
+ scriptInTab = [],
} = props;
return (
- scriptInTab?.map(script => (
+ scriptInTab?.length > 0 ? scriptInTab.map(script => (
{script.name}
@@ -176,7 +208,14 @@ export const CSScripture = (props, context) => {
- ))
+ )) : (
+
+ Nothing here!
+
+ )
);
};
@@ -209,7 +248,7 @@ export const CSTutorial = (props, context) => {
{REC_RATVAR}
) : (
-
+ <>
{
not let it confuse you! You are free to use the names
in pronoun form when speaking in normal languages.
-
+ >
)}
{recollection_categories?.map(cat => (
diff --git a/tgui/packages/tgui/interfaces/Crayon.js b/tgui/packages/tgui/interfaces/Crayon.js
index 05191f8c66..568e02667b 100644
--- a/tgui/packages/tgui/interfaces/Crayon.js
+++ b/tgui/packages/tgui/interfaces/Crayon.js
@@ -1,11 +1,18 @@
import { useBackend } from '../backend';
-import { Button, LabeledList, Section } from '../components';
+import { Button, LabeledList, Section, Slider } from '../components';
import { Window } from '../layouts';
export const Crayon = (props, context) => {
const { act, data } = useBackend(context);
const capOrChanges = data.has_cap || data.can_change_colour;
const drawables = data.drawables || [];
+ const {
+ precision_mode,
+ x,
+ y,
+ min_offset,
+ max_offset,
+ } = data;
return (
{
onClick={() => act('select_colour')} />
)}
+
+
+
+
+ {!!precision_mode && (
+ <>
+
+ act('set_precision_x', {
+ x: value,
+ })} />
+
+
+ act('set_precision_y', {
+ y: value,
+ })} />
+
+ >
+ )}
+
+
{drawables.map(drawable => {
diff --git a/tgui/packages/tgui/interfaces/InputModal.js b/tgui/packages/tgui/interfaces/InputModal.js
deleted file mode 100644
index 1818abccda..0000000000
--- a/tgui/packages/tgui/interfaces/InputModal.js
+++ /dev/null
@@ -1,119 +0,0 @@
-/**
- * @file
- * @copyright 2021 Leshana
- * @license MIT
- */
-
-import { clamp01 } from 'common/math';
-import { useBackend, useLocalState } from '../backend';
-import { Box, Button, Section, Input, Stack, TextArea } from '../components';
-import { KEY_ESCAPE } from 'common/keycodes';
-import { Window } from '../layouts';
-import { createLogger } from '../logging';
-
-const logger = createLogger('inputmodal');
-
-export const InputModal = (props, context) => {
- const { act, data } = useBackend(context);
- const { title, message, initial, input_type, timeout } = data;
-
- // Current Input Value
- const [curValue, setCurValue] = useLocalState(context, 'curValue', initial);
-
- const handleKeyDown = e => {
- if (e.keyCode === KEY_ESCAPE) {
- e.preventDefault();
- act("cancel");
- return;
- }
- };
-
- let initialHeight, initialWidth, canResize;
- let modalBody;
- switch (input_type) {
- case 'text':
- case 'num':
- initialWidth = 325;
- initialHeight = message ? Math.max(150, message.length) : 110;
- canResize = false;
- modalBody = (
- {
- setCurValue(val);
- }}
- onEnter={(_e, val) => {
- act('choose', { choice: val });
- }}
- />
- );
- break;
- case 'message':
- initialWidth = 450;
- initialHeight = 350;
- canResize = true;
- modalBody = (
-