From 83eca75951ff276f5a1bcc87af2be5d5fa5b6fb1 Mon Sep 17 00:00:00 2001 From: MrStonedOne Date: Mon, 22 Aug 2016 08:56:53 -0700 Subject: [PATCH] Removes unneeded lighting checks. --- code/game/objects/items/devices/flashlight.dm | 3 --- code/modules/clothing/head/hardhat.dm | 3 --- code/modules/clothing/head/helmet.dm | 2 -- code/modules/clothing/spacesuits/hardsuit.dm | 3 --- code/modules/projectiles/gun.dm | 2 -- 5 files changed, 13 deletions(-) diff --git a/code/game/objects/items/devices/flashlight.dm b/code/game/objects/items/devices/flashlight.dm index 2cbe518d65d..b0be84a5209 100644 --- a/code/game/objects/items/devices/flashlight.dm +++ b/code/game/objects/items/devices/flashlight.dm @@ -36,9 +36,6 @@ SetLuminosity(0) /obj/item/device/flashlight/attack_self(mob/user) - if(!isturf(user.loc)) - user << "You cannot turn the light on while in this [user.loc]!" //To prevent some lighting anomalities. - return 0 on = !on update_brightness(user) for(var/X in actions) diff --git a/code/modules/clothing/head/hardhat.dm b/code/modules/clothing/head/hardhat.dm index 6f0487f4836..8751493b999 100644 --- a/code/modules/clothing/head/hardhat.dm +++ b/code/modules/clothing/head/hardhat.dm @@ -14,9 +14,6 @@ dog_fashion = /datum/dog_fashion/head /obj/item/clothing/head/hardhat/attack_self(mob/user) - if(!isturf(user.loc)) - user << "You cannot turn the light on while in this [user.loc]!" //To prevent some lighting anomalities. - return on = !on icon_state = "hardhat[on]_[item_color]" item_state = "hardhat[on]_[item_color]" diff --git a/code/modules/clothing/head/helmet.dm b/code/modules/clothing/head/helmet.dm index 0d49a915a2c..b4f057cacf5 100644 --- a/code/modules/clothing/head/helmet.dm +++ b/code/modules/clothing/head/helmet.dm @@ -290,8 +290,6 @@ var/mob/user = usr if(user.incapacitated()) return - if(!isturf(user.loc)) - user << "You cannot turn the light on while in this [user.loc]!" F.on = !F.on user << "You toggle the helmetlight [F.on ? "on":"off"]." diff --git a/code/modules/clothing/spacesuits/hardsuit.dm b/code/modules/clothing/spacesuits/hardsuit.dm index 29a12bb8700..b7e3680b66e 100644 --- a/code/modules/clothing/spacesuits/hardsuit.dm +++ b/code/modules/clothing/spacesuits/hardsuit.dm @@ -14,9 +14,6 @@ /obj/item/clothing/head/helmet/space/hardsuit/attack_self(mob/user) - if(!isturf(user.loc)) - user << "You cannot turn the light on while in this [user.loc]!" //To prevent some lighting anomalities. - return on = !on icon_state = "[basestate][on]-[item_color]" user.update_inv_head() //so our mob-overlays update diff --git a/code/modules/projectiles/gun.dm b/code/modules/projectiles/gun.dm index 079b00aa0c5..03df590ca0a 100644 --- a/code/modules/projectiles/gun.dm +++ b/code/modules/projectiles/gun.dm @@ -319,8 +319,6 @@ obj/item/weapon/gun/proc/newshot() return var/mob/living/carbon/human/user = usr - if(!isturf(user.loc)) - user << "You cannot turn the light on while in this [user.loc]!" F.on = !F.on user << "You toggle the gunlight [F.on ? "on":"off"]."