Bye-Bye, Double Zappy!

Fixes the double-zapping from shocked vendors.
This commit is contained in:
TheFurryFeline
2019-05-02 22:25:13 -04:00
committed by GitHub
parent b98f1125ed
commit 3331ffe5a9
3 changed files with 4 additions and 13 deletions
+1 -4
View File
@@ -8,12 +8,9 @@
wire_count = 4
random = 1
//TFF 2/5/19: Port Polaris double-zap fix - remove forcing all non-silicons to get zapped twice.
/datum/wires/seedstorage/CanUse(var/mob/living/L)
var/obj/machinery/seed_storage/V = holder
if(!istype(L, /mob/living/silicon))
if(V.seconds_electrified)
if(V.shock(L, 100))
return 0
if(V.panel_open)
return 1
return 0
+1 -4
View File
@@ -10,12 +10,9 @@ var/const/SMARTFRIDGE_WIRE_ELECTRIFY = 1
var/const/SMARTFRIDGE_WIRE_THROW = 2
var/const/SMARTFRIDGE_WIRE_IDSCAN = 4
//TFF 2/5/19: Port Polaris double-zap fix - remove forcing all non-silicons to get zapped twice.
/datum/wires/smartfridge/CanUse(var/mob/living/L)
var/obj/machinery/smartfridge/S = holder
if(!istype(L, /mob/living/silicon))
if(S.seconds_electrified)
if(S.shock(L, 100))
return 0
if(S.panel_open)
return 1
return 0
+2 -5
View File
@@ -7,12 +7,9 @@ var/const/VENDING_WIRE_CONTRABAND = 2
var/const/VENDING_WIRE_ELECTRIFY = 4
var/const/VENDING_WIRE_IDSCAN = 8
//TFF 2/5/19: Port Polaris double-zap fix - remove forcing all non-silicons to get zapped twice.
/datum/wires/vending/CanUse(var/mob/living/L)
var/obj/machinery/vending/V = holder
if(!istype(L, /mob/living/silicon))
if(V.seconds_electrified)
if(V.shock(L, 100))
return 0
if(V.panel_open)
return 1
return 0
@@ -43,7 +40,7 @@ var/const/VENDING_WIRE_IDSCAN = 8
if(VENDING_WIRE_THROW)
V.shoot_inventory = !mended
if(VENDING_WIRE_CONTRABAND)
V.categories &= ~CAT_HIDDEN
V.categories &= ~CAT_HIDDEN
if(VENDING_WIRE_ELECTRIFY)
if(mended)
V.seconds_electrified = 0