mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-11 23:23:28 +01:00
Sort of compiles
Time to fix xenoarch, and then the map.
This commit is contained in:
@@ -10,37 +10,19 @@
|
||||
input_dir = WEST
|
||||
output_dir = EAST
|
||||
|
||||
|
||||
/obj/machinery/mineral/unloading_machine/New()
|
||||
..()
|
||||
spawn( 5 )
|
||||
for (var/dir in cardinal)
|
||||
src.input = locate(/obj/machinery/mineral/input, get_step(src, dir))
|
||||
if(src.input) break
|
||||
for (var/dir in cardinal)
|
||||
src.output = locate(/obj/machinery/mineral/output, get_step(src, dir))
|
||||
if(src.output) break
|
||||
return
|
||||
return
|
||||
|
||||
/obj/machinery/mineral/unloading_machine/process()
|
||||
if (src.output && src.input)
|
||||
if (locate(/obj/structure/ore_box, input.loc))
|
||||
var/obj/structure/ore_box/BOX = locate(/obj/structure/ore_box, input.loc)
|
||||
var/i = 0
|
||||
for (var/obj/item/weapon/ore/O in BOX.contents)
|
||||
BOX.contents -= O
|
||||
O.loc = output.loc
|
||||
i++
|
||||
if (i>=10)
|
||||
var/turf/T = get_step(src,input_dir)
|
||||
if(T)
|
||||
var/limit
|
||||
for(var/obj/structure/ore_box/B in T)
|
||||
for (var/obj/item/weapon/ore/O in B)
|
||||
B.contents -= O
|
||||
unload_mineral(O)
|
||||
limit++
|
||||
if (limit>=10)
|
||||
return
|
||||
if (locate(/obj/item, input.loc))
|
||||
var/obj/item/O
|
||||
var/i
|
||||
for (i = 0; i<10; i++)
|
||||
O = locate(/obj/item, input.loc)
|
||||
if (O)
|
||||
O.loc = src.output.loc
|
||||
else
|
||||
return
|
||||
return
|
||||
for(var/obj/item/I in T)
|
||||
unload_mineral(I)
|
||||
limit++
|
||||
if (limit>=10)
|
||||
return
|
||||
Reference in New Issue
Block a user