mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-01-24 00:12:07 +00:00
* refactor: Movement cross/uncross implementation.
* wrong var name
* fix unit tests dropping PDAs into nowhere
* Add documentation.
* remove unused constants
* say which procs are off limits
* fix simpleanimal z change runtime
* helps not to leave merge conflicts
* kill me
* fix typecast
* fix projectile/table collision
* treadmills don't cause MC to crash anymore
* connect_loc is appropriate here
* fix windoors and teleporters
* fix bonfires and clarify docs
* fix proximity sensors
Tested with sensors in crates, sensors in modsuits
Tested new proximity component with firing projectiles at singularity
Tested new proximity component with portable flashes
Tested new proximity component with facehuggers
* lint
* fix: polarized access helper false positives
* Revert "fix: polarized access helper false positives"
This reverts commit 9814f98cf6.
* hopefully the right change for mindflayer steam
* Changes following cameras
* fix glass table collision
* appears to fix doorspam
* fix ore bags not picking up ore
* fix signatures of /Exited
* remove debug log
* remove duplicate signal registrar
* fix emptying bags into locations
* I don't trust these nested Move calls
* use connect_loc for upgraded resonator fields
* use moveToNullspace
* fix spiderweb crossing
* fix pass checking for windows from a tile off
* fix bluespace closet/transparency issues
* fix mechs not interacting with doors and probably other things
* fix debug
* fix telepete
* add some docs
* stop trying to shoehorn prox monitor into cards
* I should make sure things build
* kill override signal warning
* undef signal
* not many prox monitors survive going off like this
* small fixes to storage
* make moving wormholes respect signals
* use correct signals for pulse demon
* fix pulse heart too
* fix smoke signals
* may have fucked singulo projectile swerve
* fix singulo projectile arcing
* remove duplicate define
* just look at it
* hopefully last cleanups of incorrect signal usage
* fix squeaking
* may god have mercy on my soul
* Apply suggestions from code review
Co-authored-by: Luc <89928798+lewcc@users.noreply.github.com>
Signed-off-by: warriorstar-orion <orion@snowfrost.garden>
* lewc review
* Apply suggestions from code review
Co-authored-by: Burzah <116982774+Burzah@users.noreply.github.com>
Signed-off-by: warriorstar-orion <orion@snowfrost.garden>
* burza review
* fix bad args for grenade assemblies
* Update code/__DEFINES/is_helpers.dm
Co-authored-by: Luc <89928798+lewcc@users.noreply.github.com>
Signed-off-by: warriorstar-orion <orion@snowfrost.garden>
---------
Signed-off-by: warriorstar-orion <orion@snowfrost.garden>
Co-authored-by: DGamerL <daan.lyklema@gmail.com>
Co-authored-by: Luc <89928798+lewcc@users.noreply.github.com>
Co-authored-by: Burzah <116982774+Burzah@users.noreply.github.com>
103 lines
3.1 KiB
Plaintext
103 lines
3.1 KiB
Plaintext
|
|
/**********************Ore box**************************/
|
|
|
|
/obj/structure/ore_box
|
|
icon = 'icons/obj/mining.dmi'
|
|
icon_state = "orebox"
|
|
name = "ore box"
|
|
desc = "A heavy wooden box, which can be filled with a lot of ores."
|
|
density = TRUE
|
|
pressure_resistance = 5 * ONE_ATMOSPHERE
|
|
|
|
/obj/structure/ore_box/attackby__legacy__attackchain(obj/item/W, mob/user, params)
|
|
if(istype(W, /obj/item/stack/ore))
|
|
if(!user.drop_item())
|
|
return
|
|
W.forceMove(src)
|
|
else if(isstorage(W))
|
|
var/obj/item/storage/S = W
|
|
S.hide_from(user)
|
|
if(length(S.contents))
|
|
for(var/obj/item/stack/ore/O in S.contents)
|
|
S.remove_from_storage(O, src) //This will move the item to this item's contents
|
|
to_chat(user, "<span class='notice'>You empty the satchel into the box.</span>")
|
|
else
|
|
return ..()
|
|
|
|
/obj/structure/ore_box/crowbar_act(mob/living/user, obj/item/I)
|
|
. = TRUE
|
|
if(!I.use_tool(src, user, 5 SECONDS, volume = I.tool_volume))
|
|
return
|
|
user.visible_message("<span class='notice'>[user] pries [src] apart.</span>", "<span class='notice'>You pry apart [src].</span>", "<span class='italics'>You hear splitting wood.</span>")
|
|
deconstruct(TRUE, user)
|
|
|
|
/obj/structure/ore_box/attack_hand(mob/user)
|
|
if(Adjacent(user))
|
|
show_contents(user)
|
|
|
|
/obj/structure/ore_box/attack_robot(mob/user)
|
|
if(Adjacent(user))
|
|
show_contents(user)
|
|
|
|
/obj/structure/ore_box/proc/show_contents(mob/user)
|
|
var/dat = "<b>The contents of the ore box reveal...</b><br>"
|
|
var/list/assembled = list()
|
|
for(var/obj/item/stack/ore/O in src)
|
|
assembled[O.type] += O.amount
|
|
for(var/type in assembled)
|
|
var/obj/item/stack/ore/O = type
|
|
dat += "[initial(O.name)] - [assembled[type]]<br>"
|
|
|
|
dat += "<br><br><A href='byond://?src=[UID()];removeall=1'>Empty box</A>"
|
|
var/datum/browser/popup = new(user, "orebox", name, 400, 400)
|
|
popup.set_content(dat)
|
|
popup.open(0)
|
|
|
|
/obj/structure/ore_box/Topic(href, href_list)
|
|
if(..())
|
|
return
|
|
usr.set_machine(src)
|
|
add_fingerprint(usr)
|
|
if(href_list["removeall"])
|
|
dump_box_contents()
|
|
to_chat(usr, "<span class='notice'>You empty the box.</span>")
|
|
updateUsrDialog()
|
|
|
|
/obj/structure/ore_box/deconstruct(disassembled = TRUE, mob/user)
|
|
var/obj/item/stack/sheet/wood/W = new (loc, 4)
|
|
if(user)
|
|
W.add_fingerprint(user)
|
|
dump_box_contents()
|
|
qdel(src)
|
|
|
|
/obj/structure/ore_box/proc/dump_box_contents()
|
|
for(var/obj/item/stack/ore/O in src)
|
|
if(QDELETED(O))
|
|
continue
|
|
if(QDELETED(src))
|
|
break
|
|
O.forceMove(loc)
|
|
CHECK_TICK
|
|
|
|
/obj/structure/ore_box/examine(mob/user)
|
|
. = ..()
|
|
if(Adjacent(user))
|
|
. += "<span class='notice'>You can <b>Alt-Shift-Click</b> to empty the ore box.</span>"
|
|
|
|
/obj/structure/ore_box/on_changed_z_level(turf/old_turf, turf/new_turf, notify_contents = FALSE)
|
|
return ..()
|
|
|
|
/obj/structure/ore_box/AltShiftClick(mob/user)
|
|
if(!Adjacent(user) || !ishuman(user) || HAS_TRAIT(user, TRAIT_HANDS_BLOCKED))
|
|
to_chat(user, "You cannot interact with the ore box.")
|
|
return
|
|
|
|
add_fingerprint(user)
|
|
|
|
if(length(contents) < 1)
|
|
to_chat(user, "<span class='warning'>The ore box is empty.</span>")
|
|
return
|
|
|
|
dump_box_contents()
|
|
to_chat(user, "<span class='notice'>You empty the ore box.</span>")
|