Another bunch of fixes for TGUI inputs (I'll be cursed...) (#25009)

* Oh god, oh fuck, WHY DIDN'T I USE isnull()???

* More correct checks

* That's all

* That's all x2

* Flavor fix
This commit is contained in:
Aylong
2024-04-12 18:51:36 +00:00
committed by GitHub
parent bc4cd8bceb
commit 6fe23a6a20
28 changed files with 87 additions and 88 deletions
+4 -4
View File
@@ -546,16 +546,16 @@ GLOBAL_LIST_INIT(view_runtimes_verbs, list(
explosion(epicenter, 3, 5, 7, 5)
if("Custom Bomb")
var/devastation_range = tgui_input_number(src, "Devastation range (in tiles):", "Custom Bomb", max_value = 255)
if(devastation_range == null)
if(isnull(devastation_range))
return
var/heavy_impact_range = tgui_input_number(src, "Heavy impact range (in tiles):", "Custom Bomb", max_value = 255)
if(heavy_impact_range == null)
if(isnull(heavy_impact_range))
return
var/light_impact_range = tgui_input_number(src, "Light impact range (in tiles):", "Custom Bomb", max_value = 255)
if(light_impact_range == null)
if(isnull(light_impact_range))
return
var/flash_range = tgui_input_number(src, "Flash range (in tiles):", "Custom Bomb", max_value = 255)
if(flash_range == null)
if(isnull(flash_range))
return
explosion(epicenter, devastation_range, heavy_impact_range, light_impact_range, flash_range, 1, 1)
log_admin("[key_name(usr)] created an admin explosion at [epicenter.loc]")