-
Notifications
You must be signed in to change notification settings - Fork 71
The Money Is Calling And I Am Cutting To Get It: Adds Fully Player Buildable Shipbreaking For Fun, Profit, And Liveleak Tier Industrial Accidents #938
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Changes from all commits
e0dc8e9
cf73921
9017ae6
fbe7700
5fd1584
5be9e15
b36ad35
deeecaa
7a00346
2da23f3
b6967f1
2c5b0a3
b81a9f7
10e5700
f67ddab
e289726
308d338
69e6b3f
ff21655
c01f9b7
43d9213
8038449
c34ea53
8f1ebdf
ee9ece4
bce8a7c
41e34c7
c52f3a5
1217c7c
69a6615
8f14632
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,16 @@ | ||
| /// Ship contains electrical hazards | ||
| #define SALVAGE_HAZARD_ELECTRICAL "Electrical Hazards" | ||
| /// Ship contains explosive fuels | ||
| #define SALVAGE_HAZARD_FUEL "Explosive Fuels" | ||
| /// Ship contains radioactive things | ||
| #define SALVAGE_HAZARD_RADIATION "Above-Background Radioactivity" | ||
| /// Ship contains a shipmind or equivalent | ||
| #define SALVAGE_HAZARD_SHIPMIND "Potentially Active Shipmind" | ||
| /// Ship contains coolant canisters | ||
| #define SALVAGE_HAZARD_COOLANT "Superketone Coolant" | ||
| /// Ship contains a reactor | ||
| #define SALVAGE_HAZARD_REACTOR "Active Bloom Reactor" | ||
| /// Ship has nonspecific cargo that might be dangerous | ||
| #define SALVAGE_HAZARD_CARGO "Potentially Volatile Cargo" | ||
| /// Ship has munitions on board | ||
| #define SALVAGE_HAZARD_WEAPONS "Uncleared Weaponry" |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,151 @@ | ||
| /obj/effect/temp_visual/telegraphing/long_duration | ||
| duration = 15 SECONDS | ||
|
|
||
| // Circuit and RND | ||
|
|
||
| /obj/item/circuitboard/machine/docking_clamp | ||
| name = "Salvage Clamp" | ||
| greyscale_colors = CIRCUIT_COLOR_ENGINEERING | ||
| build_path = /obj/machinery/docking_clamp | ||
|
|
||
| /datum/design/board/salvage_docking_clamp | ||
| name = "Salvage Clamp" | ||
| desc = "A large clamp for holding shuttles in place without using their own power." | ||
| id = "salvage_docking_clamp" | ||
| build_path = /obj/item/circuitboard/machine/docking_clamp | ||
| category = list( | ||
| RND_CATEGORY_COMPUTER + RND_SUBCATEGORY_COMPUTER_ENGINEERING | ||
| ) | ||
| departmental_flags = DEPARTMENT_BITFLAG_ENGINEERING | ||
|
|
||
| /datum/techweb_node/mining/New() | ||
| design_ids += list( | ||
| "salvage_docking_clamp", | ||
| ) | ||
| return ..() | ||
|
|
||
| // Everything else | ||
|
|
||
| /obj/machinery/docking_clamp | ||
| name = "salvage clamp" | ||
| desc = "A large clamp for holding shuttles in place without using their own power." | ||
| icon = 'icons/obj/machines/floor.dmi' | ||
| icon_state = "mass_driver" | ||
| use_power = NO_POWER_USE | ||
| circuit = /obj/item/circuitboard/machine/docking_clamp | ||
| /// The docking port we use to connect ships with | ||
| var/obj/docking_port/stationary/salvage_dock/docking_port | ||
| /// The computer the clamp is linked to | ||
| var/obj/machinery/computer/salvage_bay_controller/controller | ||
|
|
||
| /obj/machinery/docking_clamp/Initialize(mapload) | ||
| . = ..() | ||
| AddComponent(/datum/component/simple_rotation) | ||
|
|
||
| /obj/machinery/docking_clamp/Destroy(force) | ||
| if(controller) | ||
| controller.delink_clamp() | ||
| if(docking_port) | ||
| QDEL_NULL(docking_port) | ||
| return ..() | ||
|
|
||
| /obj/machinery/docking_clamp/examine(mob/user) | ||
| . = ..() | ||
| if(!controller) | ||
| . += span_notice("Use a [EXAMINE_HINT("multitool")] to connect this to a [EXAMINE_HINT("salvage bay control console")] before use.") | ||
| if(!docking_port) | ||
| . += span_notice("Interact with the clamp to set it up for docking, otherwise it will not function.") | ||
| . += span_notice("The clamp requires a large space in front of it, indicated by holograms on setup.") | ||
| . += span_notice("This space is [EXAMINE_HINT("[floor(/obj/docking_port/stationary/salvage_dock::width / 2)]")] tiles to either side of the clamp, and [EXAMINE_HINT("[/obj/docking_port/stationary/salvage_dock::height]")] tiles straight out.") | ||
|
|
||
| /obj/machinery/docking_clamp/multitool_act(mob/living/user, obj/item/multitool/the_tool) | ||
| if(!panel_open) | ||
| balloon_alert(user, "panel closed!") | ||
| return ITEM_INTERACT_BLOCKING | ||
| the_tool.set_buffer(src) | ||
| balloon_alert(user, "saved to multitool buffer") | ||
| return ITEM_INTERACT_SUCCESS | ||
|
|
||
| /obj/machinery/docking_clamp/wrench_act(mob/living/user, obj/item/tool) | ||
| if(!panel_open) | ||
| balloon_alert(user, "panel closed!") | ||
| return ITEM_INTERACT_BLOCKING | ||
| if(!default_unfasten_wrench(user, tool, 4 SECONDS)) | ||
| return ITEM_INTERACT_BLOCKING | ||
| if(!anchored) | ||
| QDEL_NULL(docking_port) | ||
| return ITEM_INTERACT_SUCCESS | ||
|
|
||
| /obj/machinery/docking_clamp/screwdriver_act(mob/user, obj/item/tool) | ||
| if(!default_deconstruction_screwdriver(user, icon_state, icon_state, tool)) | ||
| return ITEM_INTERACT_BLOCKING | ||
| update_appearance() | ||
| return ITEM_INTERACT_SUCCESS | ||
|
|
||
| /obj/machinery/docking_clamp/crowbar_act(mob/user, obj/item/tool) | ||
| if(!default_deconstruction_crowbar(tool)) | ||
| return ITEM_INTERACT_BLOCKING | ||
| return ITEM_INTERACT_SUCCESS | ||
|
|
||
| /obj/machinery/docking_clamp/interact(mob/user) | ||
| if(!can_interact(user)) | ||
| return | ||
| if(!anchored) | ||
| balloon_alert(user, "not secured!") | ||
| return ..() | ||
| if(docking_port) | ||
| balloon_alert(user, "unsetting...") | ||
| if(!do_after(user, 3 SECONDS, src)) | ||
| return ..() | ||
| QDEL_NULL(docking_port) | ||
| return ..() | ||
| balloon_alert(user, "setting clamp") | ||
| if(!do_after(user, 2 SECONDS, src)) | ||
| return ..() | ||
| var/turf/dock_location = get_step(src, dir) | ||
| var/obj/docking_port/stationary/salvage_dock/temp_docking_port = new(dock_location, dir) | ||
| var/list/docking_turfs = temp_docking_port.return_turfs() | ||
| var/list/dock_bounds = temp_docking_port.return_coords() | ||
| var/list/overlappers = SSshuttle.get_dock_overlap(dock_bounds[1], dock_bounds[2], dock_bounds[3], dock_bounds[4], z) | ||
| if(length(overlappers)) // Overlappers list contains ourself as well | ||
| for(var/dock as anything in overlappers) | ||
| if(dock == temp_docking_port) | ||
| continue | ||
| balloon_alert(user, "intersecting nearby dock") | ||
| temp_docking_port.Destroy(TRUE) | ||
| return ..() | ||
| for(var/turf/checked_turf as anything in docking_turfs) | ||
| if(checked_turf.x <= 10 || checked_turf.y <= 10 || checked_turf.x >= world.maxx - 10 || checked_turf.y >= world.maxy - 10) | ||
| balloon_alert(user, "cannot place here") | ||
| new /obj/effect/temp_visual/telegraphing/long_duration(checked_turf) | ||
| temp_docking_port.Destroy(TRUE) | ||
| return ..() | ||
| var/area/turf_area = get_area(checked_turf) | ||
| if(!is_space_or_openspace(checked_turf) || checked_turf.is_blocked_turf(TRUE) || !is_area_nearby_station(turf_area)) | ||
| balloon_alert(user, "dock not clear") | ||
| new /obj/effect/temp_visual/telegraphing/long_duration(checked_turf) | ||
| temp_docking_port.Destroy(TRUE) | ||
| return ..() | ||
| new /obj/effect/temp_visual/medical_holosign(checked_turf) | ||
| docking_port = temp_docking_port | ||
| return ..() | ||
|
|
||
| /// Scans the docking port area for if living mobs are present inside, TRUE means a mob is in the way (or we have no port?) | ||
| /obj/machinery/docking_clamp/proc/check_for_clear_bay() | ||
| if(!docking_port) | ||
| return TRUE // what ?? No | ||
| var/list/docking_turfs = docking_port.return_turfs() | ||
| for(var/turf/checked_turf as anything in docking_turfs) | ||
| for(var/mob/living/living_mob in checked_turf.contents) | ||
| return TRUE | ||
| return FALSE | ||
|
|
||
| /obj/docking_port/stationary/salvage_dock | ||
| name = "Salvage Dock" | ||
| width = 31 | ||
| height = 19 | ||
| dwidth = 15 | ||
|
|
||
| /obj/docking_port/stationary/salvage_dock/Initialize(mapload, dock_direction) | ||
| setDir(dock_direction) | ||
| . = ..() |
Uh oh!
There was an error while loading. Please reload this page.