mirror of
https://github.com/CHOMPstation/CHOMPstation.git
synced 2026-08-22 03:26:21 +01:00
Merge pull request #658 from TheFurryFeline/TFF-QoL_Changes2
QoL Changes, Round 2
This commit is contained in:
@@ -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
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -873,6 +873,12 @@ FIRE ALARM
|
||||
/obj/machinery/firealarm/attackby(obj/item/W as obj, mob/user as mob)
|
||||
add_fingerprint(user)
|
||||
|
||||
//TFF 2/5/19: Port Polaris fix for deconstruction of fire alarms.
|
||||
if(alarm_deconstruction_screwdriver(user, W))
|
||||
return
|
||||
if(alarm_deconstruction_wirecutters(user, W))
|
||||
return
|
||||
|
||||
if(panel_open)
|
||||
if(istype(W, /obj/item/device/multitool))
|
||||
detecting = !(detecting)
|
||||
|
||||
@@ -215,24 +215,24 @@ var/list/obj/machinery/requests_console/allConsoles = list()
|
||||
if(computer_deconstruction_screwdriver(user, O))
|
||||
return
|
||||
if(istype(O, /obj/item/device/multitool))
|
||||
if(panel_open)
|
||||
var/input = sanitize(input(usr, "What Department ID would you like to give this request console?", "Multitool-Request Console Interface", department))
|
||||
if(!input)
|
||||
to_chat(usr, "No input found. Please hang up and try your call again.")
|
||||
return
|
||||
department = input
|
||||
announcement.title = "[department] announcement"
|
||||
announcement.newscast = 1
|
||||
|
||||
name = "[department] Requests Console"
|
||||
allConsoles += src
|
||||
if(departmentType & RC_ASSIST)
|
||||
req_console_assistance |= department
|
||||
if(departmentType & RC_SUPPLY)
|
||||
req_console_supplies |= department
|
||||
if(departmentType & RC_INFO)
|
||||
req_console_information |= department
|
||||
//TFF 2/5/19: Allow deconstruction to work correctly and enable setting the thing.
|
||||
var/input = sanitize(input(usr, "What Department ID would you like to give this request console?", "Multitool-Request Console Interface", department))
|
||||
if(!input)
|
||||
to_chat(usr, "No input found. Please hang up and try your call again.")
|
||||
return
|
||||
department = input
|
||||
announcement.title = "[department] announcement"
|
||||
announcement.newscast = 1
|
||||
|
||||
name = "[department] Requests Console"
|
||||
allConsoles += src
|
||||
if(departmentType & RC_ASSIST)
|
||||
req_console_assistance |= department
|
||||
if(departmentType & RC_SUPPLY)
|
||||
req_console_supplies |= department
|
||||
if(departmentType & RC_INFO)
|
||||
req_console_information |= department
|
||||
return
|
||||
|
||||
if(istype(O, /obj/item/weapon/card/id))
|
||||
if(inoperable(MAINT)) return
|
||||
|
||||
@@ -136,7 +136,7 @@
|
||||
|
||||
/obj/machinery/mecha_part_fabricator/attackby(var/obj/item/I, var/mob/user)
|
||||
if(busy)
|
||||
user << "<span class='notice'>\The [src] is busy. Please wait for completion of previous operation.</span>"
|
||||
to_chat(user, "<span class='notice'>\The [src] is busy. Please wait for completion of previous operation.</span>")
|
||||
return 1
|
||||
if(default_deconstruction_screwdriver(user, I))
|
||||
return
|
||||
@@ -148,25 +148,25 @@
|
||||
if(istype(I,/obj/item/stack/material))
|
||||
var/obj/item/stack/material/S = I
|
||||
if(!(S.material.name in materials))
|
||||
user << "<span class='warning'>The [src] doesn't accept [S.material]!</span>"
|
||||
to_chat(user, "<span class='warning'>The [src] doesn't accept [S.material]!</span>")
|
||||
return
|
||||
|
||||
var/sname = "[S.name]"
|
||||
var/amnt = S.perunit
|
||||
if(materials[S.material.name] + amnt <= res_max_amount)
|
||||
if(S && S.amount >= 1)
|
||||
if(S && S.get_amount() >= 1) //TFF 2/5/19: Polaris fix for Synthesisers inserting more than what is present
|
||||
var/count = 0
|
||||
overlays += "mechfab-load-metal"
|
||||
spawn(10)
|
||||
overlays -= "mechfab-load-metal"
|
||||
while(materials[S.material.name] + amnt <= res_max_amount && S.amount >= 1)
|
||||
while(materials[S.material.name] + amnt <= res_max_amount && S.get_amount() >= 1) //TFF 2/5/19: Polaris fix for Synthesisers inserting more than what is present
|
||||
materials[S.material.name] += amnt
|
||||
S.use(1)
|
||||
count++
|
||||
user << "You insert [count] [sname] into the fabricator."
|
||||
to_chat(user, "You insert [count] [sname] into the fabricator.")
|
||||
update_busy()
|
||||
else
|
||||
user << "The fabricator cannot hold more [sname]."
|
||||
to_chat(user, "The fabricator cannot hold more [sname].")
|
||||
|
||||
return
|
||||
|
||||
|
||||
@@ -175,25 +175,26 @@
|
||||
if(istype(I,/obj/item/stack/material))
|
||||
var/obj/item/stack/material/S = I
|
||||
if(!(S.material.name in materials))
|
||||
user << "<span class='warning'>The [src] doesn't accept [S.material]!</span>"
|
||||
to_chat(user, "<span class='warning'>The [src] doesn't accept [S.material]!</span>")
|
||||
return
|
||||
|
||||
//TFF 2/5/19: Polaris fix for Synthesisers inserting more than what is present
|
||||
var/sname = "[S.name]"
|
||||
var/amnt = S.perunit
|
||||
if(materials[S.material.name] + amnt <= res_max_amount)
|
||||
if(S && S.amount >= 1)
|
||||
if(S && S.get_amount() >= 1)
|
||||
var/count = 0
|
||||
overlays += "fab-load-metal"
|
||||
spawn(10)
|
||||
overlays -= "fab-load-metal"
|
||||
while(materials[S.material.name] + amnt <= res_max_amount && S.amount >= 1)
|
||||
while(materials[S.material.name] + amnt <= res_max_amount && S.get_amount() >= 1)
|
||||
materials[S.material.name] += amnt
|
||||
S.use(1)
|
||||
count++
|
||||
user << "You insert [count] [sname] into the fabricator."
|
||||
to_chat(user, "You insert [count] [sname] into the fabricator.")
|
||||
update_busy()
|
||||
else
|
||||
user << "The fabricator cannot hold more [sname]."
|
||||
to_chat(user, "The fabricator cannot hold more [sname].")
|
||||
|
||||
return
|
||||
|
||||
|
||||
@@ -49,22 +49,12 @@
|
||||
unbuckle_all_mobs()
|
||||
return ..()
|
||||
|
||||
|
||||
//TFF 2/5/19: Polaris port for buckling-related bugs - chair-related buckling disabled
|
||||
/atom/movable/proc/buckle_mob(mob/living/M, forced = FALSE, check_loc = TRUE)
|
||||
if(!buckled_mobs)
|
||||
buckled_mobs = list()
|
||||
|
||||
if(!istype(M))
|
||||
return FALSE
|
||||
|
||||
if(check_loc && M.loc != loc)
|
||||
return FALSE
|
||||
|
||||
if((!can_buckle && !forced) || M.buckled || M.pinned.len || (buckled_mobs.len >= max_buckled_mobs) || (buckle_require_restraints && !M.restrained()))
|
||||
return FALSE
|
||||
|
||||
if(has_buckled_mobs() && buckled_mobs.len >= max_buckled_mobs) //Handles trying to buckle yourself to the chair when someone is on it
|
||||
to_chat(M, "<span class='notice'>\The [src] can't buckle anymore people.</span>")
|
||||
if(!can_buckle_check(M, forced))
|
||||
return FALSE
|
||||
|
||||
M.buckled = src
|
||||
@@ -130,6 +120,9 @@
|
||||
if(M in buckled_mobs)
|
||||
to_chat(user, "<span class='warning'>\The [M] is already buckled to \the [src].</span>")
|
||||
return FALSE
|
||||
//TFF 2/5/19: Polaris port for buckling-related bugs - check for whether someone's buckled
|
||||
if(!can_buckle_check(M, forced))
|
||||
return FALSE
|
||||
|
||||
add_fingerprint(user)
|
||||
// unbuckle_mob()
|
||||
@@ -184,6 +177,23 @@
|
||||
L.set_dir(dir)
|
||||
return TRUE
|
||||
|
||||
//TFF 2/5/19: Polaris port for buckling-related bugs - check for whether someone's buckled
|
||||
/atom/movable/proc/can_buckle_check(mob/living/M, forced = FALSE)
|
||||
if(!buckled_mobs)
|
||||
buckled_mobs = list()
|
||||
|
||||
if(!istype(M))
|
||||
return FALSE
|
||||
|
||||
if((!can_buckle && !forced) || M.buckled || M.pinned.len || (buckled_mobs.len >= max_buckled_mobs) || (buckle_require_restraints && !M.restrained()))
|
||||
return FALSE
|
||||
|
||||
if(has_buckled_mobs() && buckled_mobs.len >= max_buckled_mobs) //Handles trying to buckle yourself to the chair when someone is on it
|
||||
to_chat(M, "<span class='notice'>\The [src] can't buckle anymore people.</span>")
|
||||
return FALSE
|
||||
|
||||
return TRUE
|
||||
|
||||
/atom/movable/Move(atom/newloc, direct = 0)
|
||||
. = ..()
|
||||
if(. && has_buckled_mobs() && !handle_buckled_mob_movement(newloc, direct)) //movement failed due to buckled mob(s)
|
||||
@@ -193,4 +203,4 @@
|
||||
riding_datum.handle_vehicle_layer()
|
||||
riding_datum.handle_vehicle_offsets()
|
||||
//VOREStation Add End
|
||||
|
||||
|
||||
|
||||
@@ -134,17 +134,18 @@ var/list/tape_roll_applications = list()
|
||||
update_icon()
|
||||
return ..()
|
||||
|
||||
//TFF 2/5/19: Polaris fix for taperolls not being usable on tiles with directional windows
|
||||
/obj/item/taperoll/attack_self(mob/user as mob)
|
||||
if(!start)
|
||||
start = get_turf(src)
|
||||
usr << "<span class='notice'>You place the first end of \the [src].</span>"
|
||||
to_chat(user, "<span class='notice'>You place the first end of \the [src].</span>")
|
||||
update_icon()
|
||||
else
|
||||
end = get_turf(src)
|
||||
if(start.y != end.y && start.x != end.x || start.z != end.z)
|
||||
start = null
|
||||
update_icon()
|
||||
usr << "<span class='notice'>\The [src] can only be laid horizontally or vertically.</span>"
|
||||
to_chat(user, "<span class='notice'>\The [src] can only be laid horizontally or vertically.</span>")
|
||||
return
|
||||
|
||||
if(start == end)
|
||||
@@ -154,15 +155,18 @@ var/list/tape_roll_applications = list()
|
||||
for(var/dir in cardinal)
|
||||
T = get_step(start, dir)
|
||||
if(T && T.density)
|
||||
possible_dirs += dir
|
||||
possible_dirs |= dir //TFF 2/5/19: Polaris fix for taperolls not being usable on tiles with directional windows
|
||||
else
|
||||
for(var/obj/structure/window/W in T)
|
||||
if(W.is_fulltile() || W.dir == reverse_dir[dir])
|
||||
possible_dirs += dir
|
||||
possible_dirs |= dir
|
||||
for(var/obj/structure/window/window in start)
|
||||
if(istype(window) && !window.is_fulltile())
|
||||
possible_dirs |= window.dir
|
||||
if(!possible_dirs)
|
||||
start = null
|
||||
update_icon()
|
||||
usr << "<span class='notice'>You can't place \the [src] here.</span>"
|
||||
to_chat(user, "<span class='notice'>You can't place \the [src] here.</span>")
|
||||
return
|
||||
if(possible_dirs & (NORTH|SOUTH))
|
||||
var/obj/item/tape/TP = new tape_type(start)
|
||||
@@ -178,7 +182,7 @@ var/list/tape_roll_applications = list()
|
||||
TP.update_icon()
|
||||
start = null
|
||||
update_icon()
|
||||
usr << "<span class='notice'>You finish placing \the [src].</span>"
|
||||
to_chat(user, "<span class='notice'>You finish placing \the [src].</span>")
|
||||
return
|
||||
|
||||
var/turf/cur = start
|
||||
@@ -196,6 +200,29 @@ var/list/tape_roll_applications = list()
|
||||
can_place = 0
|
||||
else
|
||||
for(var/obj/O in cur)
|
||||
//TFF 2/5/19: Handle places where you can't place down table (I think)
|
||||
if(istype(O, /obj/structure/window))
|
||||
var/obj/structure/window/window = O
|
||||
if(window.is_fulltile())
|
||||
can_place = 0
|
||||
break
|
||||
if(cur == start)
|
||||
if(window.dir == orientation)
|
||||
can_place = 0
|
||||
break
|
||||
else
|
||||
continue
|
||||
else if(cur == end)
|
||||
if(window.dir == reverse_dir[orientation])
|
||||
can_place = 0
|
||||
break
|
||||
else
|
||||
continue
|
||||
else if (window.dir == reverse_dir[orientation] || window.dir == orientation)
|
||||
can_place = 0
|
||||
break
|
||||
else
|
||||
continue
|
||||
if(O.density)
|
||||
can_place = 0
|
||||
break
|
||||
@@ -205,7 +232,7 @@ var/list/tape_roll_applications = list()
|
||||
if (!can_place)
|
||||
start = null
|
||||
update_icon()
|
||||
usr << "<span class='warning'>You can't run \the [src] through that!</span>"
|
||||
to_chat(user, "<span class='warning'>You can't run \the [src] through that!</span>")
|
||||
return
|
||||
|
||||
cur = start
|
||||
@@ -221,6 +248,10 @@ var/list/tape_roll_applications = list()
|
||||
for(var/obj/structure/window/W in T)
|
||||
if(W.is_fulltile() || W.dir == orientation)
|
||||
tape_dir = dir
|
||||
//TFF 2/5/19 - reverse orientation
|
||||
for(var/obj/structure/window/window in cur)
|
||||
if(istype(window) && !window.is_fulltile() && window.dir == reverse_dir[orientation])
|
||||
tape_dir = dir
|
||||
else if(cur == end)
|
||||
var/turf/T = get_step(end, orientation)
|
||||
if(T && !T.density)
|
||||
@@ -228,6 +259,10 @@ var/list/tape_roll_applications = list()
|
||||
for(var/obj/structure/window/W in T)
|
||||
if(W.is_fulltile() || W.dir == reverse_dir[orientation])
|
||||
tape_dir = dir
|
||||
//TFF 2/5/19 - regular orientation
|
||||
for(var/obj/structure/window/window in cur)
|
||||
if(istype(window) && !window.is_fulltile() && window.dir == orientation)
|
||||
tape_dir = dir
|
||||
for(var/obj/item/tape/T in cur)
|
||||
if((T.tape_dir == tape_dir) && (T.icon_base == icon_base))
|
||||
tapetest = 1
|
||||
@@ -243,7 +278,7 @@ var/list/tape_roll_applications = list()
|
||||
cur = get_step_towards(cur,end)
|
||||
start = null
|
||||
update_icon()
|
||||
usr << "<span class='notice'>You finish placing \the [src].</span>"
|
||||
to_chat(user, "<span class='notice'>You finish placing \the [src].</span>")
|
||||
return
|
||||
|
||||
/obj/item/taperoll/afterattack(var/atom/A, mob/user as mob, proximity)
|
||||
@@ -253,12 +288,12 @@ var/list/tape_roll_applications = list()
|
||||
if (istype(A, /obj/machinery/door))
|
||||
var/turf/T = get_turf(A)
|
||||
if(locate(/obj/item/tape, A.loc))
|
||||
user << "There's already tape over that door!"
|
||||
to_chat(user, "There's already tape over that door!")
|
||||
else
|
||||
var/obj/item/tape/P = new tape_type(T)
|
||||
P.update_icon()
|
||||
P.layer = WINDOW_LAYER
|
||||
user << "<span class='notice'>You finish placing \the [src].</span>"
|
||||
to_chat(user, "<span class='notice'>You finish placing \the [src].</span>")
|
||||
|
||||
if (istype(A, /turf/simulated/floor) ||istype(A, /turf/unsimulated/floor))
|
||||
var/turf/F = A
|
||||
|
||||
@@ -891,9 +891,14 @@ default behaviour is:
|
||||
to_chat(src, "<span class='warning'>You struggle free of \the [H.loc].</span>")
|
||||
H.forceMove(get_turf(H))
|
||||
|
||||
//TFF 2/5/19: Polaris fix for resisting out of vehicles
|
||||
/mob/living/proc/escape_buckle()
|
||||
if(buckled)
|
||||
buckled.user_unbuckle_mob(src, src)
|
||||
if(istype(buckled, /obj/vehicle))
|
||||
var/obj/vehicle/vehicle = buckled
|
||||
vehicle.unload()
|
||||
else
|
||||
buckled.user_unbuckle_mob(src, src)
|
||||
|
||||
/mob/living/proc/resist_grab()
|
||||
var/resisting = 0
|
||||
@@ -1277,4 +1282,4 @@ default behaviour is:
|
||||
|
||||
|
||||
/mob/living/proc/has_vision()
|
||||
return !(eye_blind || (disabilities & BLIND) || stat || blinded)
|
||||
return !(eye_blind || (disabilities & BLIND) || stat || blinded)
|
||||
|
||||
@@ -153,8 +153,10 @@
|
||||
icon_state = "gripper-mech"
|
||||
desc = "A large, heavy-duty grasping tool used in construction of mechs."
|
||||
|
||||
//TFF 2/5/19: Add ability to use micromech parts in constructing said micromech. Ported fix from VoreStation.
|
||||
can_hold = list(
|
||||
/obj/item/mecha_parts/part,
|
||||
/obj/item/mecha_parts/micro/part, //VOREStation Edit: Allow construction of micromechs,
|
||||
/obj/item/mecha_parts/mecha_equipment,
|
||||
/obj/item/mecha_parts/mecha_tracking
|
||||
)
|
||||
|
||||
@@ -1,3 +1,8 @@
|
||||
//TFF 2/5/19: Port Polaris's conveyor movement fixes - set define value from 2 to -1 for reverse direction in movement.
|
||||
#define OFF 0
|
||||
#define FORWARDS 1
|
||||
#define BACKWARDS -1
|
||||
|
||||
//conveyor2 is pretty much like the original, except it supports corners, but not diverters.
|
||||
//note that corner pieces transfer stuff clockwise when running forward, and anti-clockwise backwards.
|
||||
|
||||
@@ -10,7 +15,7 @@
|
||||
layer = ABOVE_TURF_LAYER
|
||||
anchored = 1
|
||||
circuit = /obj/item/weapon/circuitboard/conveyor
|
||||
var/operating = 0 // 1 if running forward, -1 if backwards, 0 if off
|
||||
var/operating = OFF // 1 if running forward, -1 if backwards, 0 if off
|
||||
var/operable = 1 // true if can operate (no broken segments in this belt run)
|
||||
var/forwards // this is the default (forward) direction, set by the map dir
|
||||
var/backwards // hopefully self-explanatory
|
||||
@@ -28,12 +33,7 @@
|
||||
if(newdir)
|
||||
set_dir(newdir)
|
||||
|
||||
if(dir & (dir-1)) // Diagonal. Forwards is *away* from dir, curving to the right.
|
||||
forwards = turn(dir, 135)
|
||||
backwards = turn(dir, 45)
|
||||
else
|
||||
forwards = dir
|
||||
backwards = turn(dir, 180)
|
||||
update_dir() //TFF 2/5/19: Port Polaris's conveyor movement fixes
|
||||
|
||||
if(on)
|
||||
operating = 1
|
||||
@@ -48,22 +48,36 @@
|
||||
RefreshParts()
|
||||
|
||||
/obj/machinery/conveyor/proc/setmove()
|
||||
if(operating == 1)
|
||||
if(operating == FORWARDS) //TFF: Port Polaris updoot.
|
||||
movedir = forwards
|
||||
else if(operating == -1)
|
||||
else if(operating == BACKWARDS) //TFF: Port Polaris updoot.
|
||||
movedir = backwards
|
||||
else operating = 0
|
||||
else
|
||||
operating = OFF
|
||||
update()
|
||||
|
||||
//TFF 2/5/19: Port Polaris's conveyor movement fixes - handle proper movement directions when conveyor is on.
|
||||
/obj/machinery/conveyor/set_dir()
|
||||
.=..()
|
||||
update_dir()
|
||||
|
||||
/obj/machinery/conveyor/proc/update_dir()
|
||||
if(!(dir in cardinal)) // Diagonal. Forwards is *away* from dir, curving to the right.
|
||||
forwards = turn(dir, 135)
|
||||
backwards = turn(dir, 45)
|
||||
else
|
||||
forwards = dir
|
||||
backwards = turn(dir, 180)
|
||||
|
||||
/obj/machinery/conveyor/proc/update()
|
||||
if(stat & BROKEN)
|
||||
icon_state = "conveyor-broken"
|
||||
operating = 0
|
||||
operating = OFF
|
||||
return
|
||||
if(!operable)
|
||||
operating = 0
|
||||
operating = OFF
|
||||
if(stat & NOPOWER)
|
||||
operating = 0
|
||||
operating = OFF
|
||||
icon_state = "conveyor[operating]"
|
||||
|
||||
// machine process
|
||||
|
||||
@@ -142,13 +142,14 @@ using metal and glass, it uses glass and reagents (usually sulphuric acid).
|
||||
for(var/mat in materials)
|
||||
max_res_amount -= materials[mat]
|
||||
|
||||
//TFF 2/5/19: Polaris fix for Synthesisers inserting more than what is present
|
||||
if(materials[S.material.name] + amnt <= max_res_amount)
|
||||
if(S && S.amount >= 1)
|
||||
if(S && S.get_amount() >= 1)
|
||||
var/count = 0
|
||||
overlays += "fab-load-metal"
|
||||
spawn(10)
|
||||
overlays -= "fab-load-metal"
|
||||
while(materials[S.material.name] + amnt <= max_res_amount && S.amount >= 1)
|
||||
while(materials[S.material.name] + amnt <= max_res_amount && S.get_amount() >= 1)
|
||||
materials[S.material.name] += amnt
|
||||
S.use(1)
|
||||
count++
|
||||
|
||||
@@ -130,13 +130,14 @@
|
||||
for(var/mat in materials)
|
||||
max_res_amount -= materials[mat]
|
||||
|
||||
//TFF 2/5/19: Polaris fix for Synthesisers inserting more than what is present
|
||||
if(materials[S.material.name] + amnt <= max_res_amount)
|
||||
if(S && S.amount >= 1)
|
||||
if(S && S.get_amount() >= 1)
|
||||
var/count = 0
|
||||
overlays += "fab-load-metal"
|
||||
spawn(10)
|
||||
overlays -= "fab-load-metal"
|
||||
while(materials[S.material.name] + amnt <= max_res_amount && S.amount >= 1)
|
||||
while(materials[S.material.name] + amnt <= max_res_amount && S.get_amount() >= 1)
|
||||
materials[S.material.name] += amnt
|
||||
S.use(1)
|
||||
count++
|
||||
|
||||
Reference in New Issue
Block a user