mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-18 18:44:48 +01:00
Lighting overhaul.
This commit overhauls the lighting system to Bay12 standards. It is better in pretty much every way.
This commit is contained in:
@@ -75,15 +75,15 @@
|
||||
set name = "Reset Computer"
|
||||
set category = "Object"
|
||||
set src in view(1)
|
||||
|
||||
|
||||
if(usr.stat || usr.restrained() || usr.lying || !istype(usr, /mob/living))
|
||||
usr << "\red You can't do that."
|
||||
return
|
||||
|
||||
|
||||
if(!Adjacent(usr))
|
||||
usr << "You can't reach it."
|
||||
return
|
||||
|
||||
|
||||
Reset()
|
||||
|
||||
New(var/L, var/built = 0)
|
||||
@@ -280,8 +280,8 @@
|
||||
chan = power_channel
|
||||
|
||||
var/area/A = get_area(loc)
|
||||
if(istype(A) && A.master && A.master.powered(chan))
|
||||
A.master.use_power(amount, chan)
|
||||
if(istype(A) && A.powered(chan))
|
||||
A.use_power(amount, chan)
|
||||
else if(battery && battery.charge > 0)
|
||||
battery.use(amount)
|
||||
|
||||
|
||||
@@ -143,10 +143,9 @@
|
||||
if(typekey == null)
|
||||
typekey = /obj/machinery
|
||||
var/list/machines = list()
|
||||
for(var/area/area in A.related)
|
||||
for(var/obj/O in area.contents)
|
||||
if(istype(O,typekey))
|
||||
machines |= O
|
||||
for(var/obj/O in A.contents)
|
||||
if(istype(O,typekey))
|
||||
machines |= O
|
||||
return machines
|
||||
verify_machine(var/obj/previous)
|
||||
if(!previous) return 0
|
||||
|
||||
Reference in New Issue
Block a user