mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-20 19:44:09 +01:00
Additional constructable and upgradeable machines, adds soap to drones, updates teleporter
This commit is contained in:
@@ -395,6 +395,7 @@
|
||||
src.modules += new /obj/item/weapon/gripper(src)
|
||||
src.modules += new /obj/item/weapon/matter_decompiler(src)
|
||||
src.modules += new /obj/item/weapon/reagent_containers/spray/cleaner/drone(src)
|
||||
src.modules += new /obj/item/weapon/soap(src)
|
||||
|
||||
src.emag = new /obj/item/weapon/pickaxe/plasmacutter(src)
|
||||
src.emag.name = "Plasma Cutter"
|
||||
|
||||
@@ -56,6 +56,7 @@ display round(lastgen) and plasmatank amount
|
||||
var/open = 0
|
||||
var/recent_fault = 0
|
||||
var/power_output = 1
|
||||
var/consumption = 0
|
||||
|
||||
/obj/machinery/power/port_gen/proc/HasFuel() //Placeholder for fuel check.
|
||||
return 1
|
||||
@@ -101,7 +102,7 @@ display round(lastgen) and plasmatank amount
|
||||
var/sheet_path = /obj/item/stack/sheet/mineral/plasma
|
||||
var/board_path = "/obj/item/weapon/circuitboard/pacman"
|
||||
var/sheet_left = 0 // How much is left of the sheet
|
||||
var/time_per_sheet = 40
|
||||
var/time_per_sheet = 260
|
||||
var/heat = 0
|
||||
|
||||
/obj/machinery/power/port_gen/pacman/initialize()
|
||||
@@ -114,8 +115,8 @@ display round(lastgen) and plasmatank amount
|
||||
component_parts = list()
|
||||
component_parts += new /obj/item/weapon/stock_parts/matter_bin(src)
|
||||
component_parts += new /obj/item/weapon/stock_parts/micro_laser(src)
|
||||
component_parts += new /obj/item/stack/cable_coil(src)
|
||||
component_parts += new /obj/item/stack/cable_coil(src)
|
||||
component_parts += new /obj/item/stack/cable_coil(src, 1)
|
||||
component_parts += new /obj/item/stack/cable_coil(src, 1)
|
||||
component_parts += new /obj/item/weapon/stock_parts/capacitor(src)
|
||||
component_parts += new board_path(src)
|
||||
var/obj/sheet = new sheet_path(null)
|
||||
@@ -128,16 +129,16 @@ display round(lastgen) and plasmatank amount
|
||||
|
||||
/obj/machinery/power/port_gen/pacman/RefreshParts()
|
||||
var/temp_rating = 0
|
||||
var/temp_reliability = 0
|
||||
var/consumption_coeff = 0
|
||||
for(var/obj/item/weapon/stock_parts/SP in component_parts)
|
||||
if(istype(SP, /obj/item/weapon/stock_parts/matter_bin))
|
||||
max_sheets = SP.rating * SP.rating * 50
|
||||
else if(istype(SP, /obj/item/weapon/stock_parts/micro_laser) || istype(SP, /obj/item/weapon/stock_parts/capacitor))
|
||||
else if(istype(SP, /obj/item/weapon/stock_parts/capacitor))
|
||||
temp_rating += SP.rating
|
||||
for(var/obj/item/weapon/CP in component_parts)
|
||||
temp_reliability += CP.reliability
|
||||
reliability = min(round(temp_reliability / 4), 100)
|
||||
power_gen = round(initial(power_gen) * (max(2, temp_rating) / 2))
|
||||
else
|
||||
consumption_coeff += SP.rating
|
||||
power_gen = round(initial(power_gen) * temp_rating * 2)
|
||||
consumption = consumption_coeff
|
||||
|
||||
/obj/machinery/power/port_gen/pacman/examine()
|
||||
..()
|
||||
@@ -160,7 +161,7 @@ display round(lastgen) and plasmatank amount
|
||||
sheets -= amount
|
||||
|
||||
/obj/machinery/power/port_gen/pacman/UseFuel()
|
||||
var/needed_sheets = 1 / (time_per_sheet / power_output)
|
||||
var/needed_sheets = 1 / (time_per_sheet * consumption / power_output)
|
||||
var/temp = min(needed_sheets, sheet_left)
|
||||
needed_sheets -= temp
|
||||
sheet_left -= temp
|
||||
@@ -175,9 +176,9 @@ display round(lastgen) and plasmatank amount
|
||||
var/bias = 0
|
||||
if (power_output > 4)
|
||||
upper_limit = 400
|
||||
bias = power_output * 3
|
||||
bias = power_output - consumption * (4 - consumption)
|
||||
if (heat < lower_limit)
|
||||
heat += 3
|
||||
heat += 4 - consumption
|
||||
else
|
||||
heat += rand(-7 + bias, 7 + bias)
|
||||
if (heat < lower_limit)
|
||||
@@ -191,7 +192,6 @@ display round(lastgen) and plasmatank amount
|
||||
return
|
||||
|
||||
/obj/machinery/power/port_gen/pacman/handleInactive()
|
||||
|
||||
if (heat > 0)
|
||||
heat = max(heat - 2, 0)
|
||||
src.updateDialog()
|
||||
@@ -215,45 +215,29 @@ display round(lastgen) and plasmatank amount
|
||||
emagged = 1
|
||||
emp_act(1)
|
||||
else if(!active)
|
||||
|
||||
if(istype(O, /obj/item/weapon/wrench))
|
||||
|
||||
if(!anchored)
|
||||
if(!anchored && !isinspace())
|
||||
connect_to_network()
|
||||
user << "\blue You secure the generator to the floor."
|
||||
anchored = 1
|
||||
else
|
||||
disconnect_from_network()
|
||||
user << "\blue You unsecure the generator from the floor."
|
||||
anchored = 0
|
||||
|
||||
playsound(src.loc, 'sound/items/Deconstruct.ogg', 50, 1)
|
||||
anchored = !anchored
|
||||
|
||||
else if(istype(O, /obj/item/weapon/screwdriver))
|
||||
open = !open
|
||||
panel_open = !panel_open
|
||||
playsound(src.loc, 'sound/items/Screwdriver.ogg', 50, 1)
|
||||
if(open)
|
||||
user << "\blue You open the access panel."
|
||||
if(panel_open)
|
||||
user << "<span class='notice'>You open the access panel.</span>"
|
||||
else
|
||||
user << "\blue You close the access panel."
|
||||
else if(istype(O, /obj/item/weapon/crowbar) && open)
|
||||
var/obj/machinery/constructable_frame/machine_frame/new_frame = new /obj/machinery/constructable_frame/machine_frame(src.loc)
|
||||
for(var/obj/item/I in component_parts)
|
||||
if(I.reliability < 100)
|
||||
I.crit_fail = 1
|
||||
I.loc = src.loc
|
||||
while ( sheets > 0 )
|
||||
var/obj/item/stack/sheet/G = new sheet_path(src.loc)
|
||||
|
||||
if ( sheets > 50 )
|
||||
G.amount = 50
|
||||
else
|
||||
G.amount = sheets
|
||||
|
||||
sheets -= G.amount
|
||||
|
||||
new_frame.state = 2
|
||||
new_frame.icon_state = "box_1"
|
||||
del(src)
|
||||
user << "<span class='notice'>You close the access panel.</span>"
|
||||
else if(istype(O, /obj/item/weapon/storage/part_replacer) && panel_open)
|
||||
exchange_parts(user, O)
|
||||
return
|
||||
else if(istype(O, /obj/item/weapon/crowbar) && panel_open)
|
||||
default_deconstruction_crowbar(O)
|
||||
|
||||
/obj/machinery/power/port_gen/pacman/attack_hand(mob/user as mob)
|
||||
..()
|
||||
|
||||
@@ -260,9 +260,27 @@ datum/design/clonescanner
|
||||
materials = list("$glass" = 2000, "sacid" = 20)
|
||||
build_path = "/obj/item/weapon/circuitboard/clonescanner"
|
||||
|
||||
datum/design/teleport_station
|
||||
name = "Circuit Design (Teleportation Station Board)"
|
||||
desc = "Allows for the construction of circuit boards used to build a Teleporter Station."
|
||||
id = "tele_station"
|
||||
req_tech = list("programming" = 4, "bluespace" = 4, "engineering" = 4)
|
||||
build_type = IMPRINTER
|
||||
materials = list("$glass" = 1000, "sacid" = 20)
|
||||
build_path = /obj/item/weapon/circuitboard/teleporter_station
|
||||
|
||||
datum/design/teleport_hub
|
||||
name = "Circuit Design (Teleportation Hub Board)"
|
||||
desc = "Allows for the construction of circuit boards used to build a Teleportation Hub."
|
||||
id = "tele_hub"
|
||||
req_tech = list("programming" = 3, "bluespace" = 5, "materials" = 4, "engineering" = 5)
|
||||
build_type = IMPRINTER
|
||||
materials = list("$glass" = 1000, "sacid" = 20)
|
||||
build_path = /obj/item/weapon/circuitboard/teleporter_hub
|
||||
|
||||
datum/design/telepad
|
||||
name = "Circuit Design (Telepad Board)"
|
||||
desc = "The circuit board for a telescience telepad."
|
||||
desc = "Allows for the construction of circuit boards used to build a Telepad."
|
||||
id = "telepad"
|
||||
req_tech = list("programming" = 4, "bluespace" = 4, "materials" = 3, "engineering" = 3)
|
||||
build_type = IMPRINTER
|
||||
@@ -278,6 +296,33 @@ datum/design/sleeper
|
||||
materials = list("$glass" = 1000, "sacid" = 20)
|
||||
build_path = "/obj/item/weapon/circuitboard/sleeper"
|
||||
|
||||
datum/design/sleep_console
|
||||
name = "Circuit Design (Sleeper Console)"
|
||||
desc = "Allows for the construction of circuit boards used to build a Sleeper Console."
|
||||
id = "sleeper"
|
||||
req_tech = list("programming" = 3, "biotech" = 2, "materials" = 3, "engineering" = 3)
|
||||
build_type = IMPRINTER
|
||||
materials = list("$glass" = 1000, "sacid" = 20)
|
||||
build_path = "/obj/item/weapon/circuitboard/sleep_console"
|
||||
|
||||
datum/design/bodyscanner
|
||||
name = "Circuit Design (Body Scanner Board)"
|
||||
desc = "Allows for the construction of circuit boards used to build a Body Scanner."
|
||||
id = "sleeper"
|
||||
req_tech = list("programming" = 3, "biotech" = 2, "materials" = 3, "engineering" = 3)
|
||||
build_type = IMPRINTER
|
||||
materials = list("$glass" = 1000, "sacid" = 20)
|
||||
build_path = "/obj/item/weapon/circuitboard/bodyscanner"
|
||||
|
||||
datum/design/sleep_console
|
||||
name = "Circuit Design (Body Scanner Console)"
|
||||
desc = "Allows for the construction of circuit boards used to build a Body Scanner Console."
|
||||
id = "sleeper"
|
||||
req_tech = list("programming" = 3, "biotech" = 2, "materials" = 3, "engineering" = 3)
|
||||
build_type = IMPRINTER
|
||||
materials = list("$glass" = 1000, "sacid" = 20)
|
||||
build_path = "/obj/item/weapon/circuitboard/bodyscanner_console"
|
||||
|
||||
datum/design/cryotube
|
||||
name = "Circuit Design (Cryotube Board)"
|
||||
desc = "Allows for the construction of circuit boards used to build a Cryotube."
|
||||
@@ -414,7 +459,7 @@ datum/design/comm_traffic
|
||||
build_path = "/obj/item/weapon/circuitboard/comm_traffic"
|
||||
|
||||
datum/design/telesci_console
|
||||
name = "Computer Design (Telepad Control Console Board)"
|
||||
name = "Circuit Design (Telepad Control Console Board)"
|
||||
desc = "Allows for the construction of circuit boards used to build a telescience console."
|
||||
id = "telesci_console"
|
||||
req_tech = list("programming" = 3, "bluespace" = 2)
|
||||
@@ -1280,6 +1325,15 @@ datum/design/light_replacer
|
||||
////////////////////////////////////////
|
||||
//////////////MISC Boards///////////////
|
||||
////////////////////////////////////////
|
||||
datum/design/thermomachine
|
||||
name = "Machine Design (Freezer/Heater Board)"
|
||||
desc = "The circuit board for a freezer/heater."
|
||||
id = "thermomachine"
|
||||
req_tech = list("programming" = 3, "plasmatech" = 3)
|
||||
build_type = IMPRINTER
|
||||
materials = list("$glass" = 1000, "sacid" = 20)
|
||||
build_path = /obj/item/weapon/circuitboard/thermomachine
|
||||
|
||||
datum/design/biogenerator
|
||||
name = "Machine Design (Biogenerator Board)"
|
||||
desc = "The circuit board for a biogenerator."
|
||||
@@ -1388,6 +1442,15 @@ datum/design/cyborgrecharger
|
||||
materials = list("$glass" = 1000, "sacid" = 20)
|
||||
build_path = "/obj/item/weapon/circuitboard/cyborgrecharger"
|
||||
|
||||
datum/design/mech_recharger
|
||||
name = "Mechbay Recharger Board"
|
||||
desc = "The circuit board for a Mechbay Recharger."
|
||||
id = "mech_recharger"
|
||||
req_tech = list("programming" = 3, "powerstorage" = 4, "engineering" = 4)
|
||||
build_type = IMPRINTER
|
||||
materials = list("$glass" = 1000, "sacid" = 20)
|
||||
build_path = "/obj/item/weapon/circuitboard/mech_recharger"
|
||||
|
||||
/////////////////////////////////////////
|
||||
////////////Power Stuff//////////////////
|
||||
/////////////////////////////////////////
|
||||
@@ -1422,7 +1485,6 @@ datum/design/mrspacman
|
||||
materials = list("$glass" = 2000, "sacid" = 20)
|
||||
build_path = "/obj/item/weapon/circuitboard/pacman/mrs"
|
||||
|
||||
|
||||
/////////////////////////////////////////
|
||||
////////////Medical Tools////////////////
|
||||
/////////////////////////////////////////
|
||||
@@ -1974,14 +2036,14 @@ datum/design/bluespace_crystal
|
||||
reliability_base = 100
|
||||
build_path = "/obj/item/bluespace_crystal/artificial"
|
||||
|
||||
datum/design/telesci_gps
|
||||
name = "GPS Device"
|
||||
datum/design/telesci_sps
|
||||
name = "SPS Device"
|
||||
desc = "A device that can track its position at all times."
|
||||
id = "telesci_gps"
|
||||
id = "telesci_sps"
|
||||
req_tech = list("materials" = 2, "magnets" = 3, "bluespace" = 3)
|
||||
build_type = PROTOLATHE
|
||||
materials = list("$metal" = 500, "$glass" = 1000)
|
||||
build_path = /obj/item/device/gps
|
||||
build_path = /obj/item/device/sps
|
||||
|
||||
/////////////////////////////////////////
|
||||
/////////////////HUDs////////////////////
|
||||
|
||||
Reference in New Issue
Block a user