mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-20 19:44:09 +01:00
Rechargers can be built now
Rechargers now use capacitors as their stock parts and recharge faster depending on the quality of the recharger(may need balancing) Can now also place smaller machinery on tables by clicking on the table while pulling them(microwaves and soda dispensers are some examples)
This commit is contained in:
@@ -8,6 +8,7 @@
|
||||
idle_power_usage = 5
|
||||
active_power_usage = 60
|
||||
power_channel = EQUIP
|
||||
pass_flags = PASSTABLE
|
||||
var/obj/item/stock_parts/cell/charging = null
|
||||
var/chargelevel = -1
|
||||
|
||||
|
||||
@@ -330,6 +330,14 @@ to destroy them and players will be able to make replacements.
|
||||
name = "circuit board (Freezer)"
|
||||
to_chat(user, "<span class='notice'>You set the board to cooling.</span>")
|
||||
|
||||
/obj/item/circuitboard/recharger
|
||||
name = "circuit board (Recharger)"
|
||||
build_path = /obj/machinery/recharger
|
||||
board_type = "machine"
|
||||
origin_tech = "powerstorage=3;materials=2"
|
||||
frame_desc = "Requires 1 Capacitor"
|
||||
req_components = list(/obj/item/stock_parts/capacitor = 1)
|
||||
|
||||
/obj/item/circuitboard/snow_machine
|
||||
name = "circuit board (snow machine)"
|
||||
build_path = /obj/machinery/snow_machine
|
||||
|
||||
@@ -6,13 +6,26 @@
|
||||
anchored = 1
|
||||
use_power = IDLE_POWER_USE
|
||||
idle_power_usage = 4
|
||||
active_power_usage = 250
|
||||
active_power_usage = 200
|
||||
pass_flags = PASSTABLE
|
||||
var/obj/item/charging = null
|
||||
var/list/allowed_devices = list(/obj/item/gun/energy, /obj/item/melee/baton, /obj/item/modular_computer, /obj/item/rcs, /obj/item/bodyanalyzer)
|
||||
var/icon_state_off = "rechargeroff"
|
||||
var/icon_state_charged = "recharger2"
|
||||
var/icon_state_charging = "recharger1"
|
||||
var/icon_state_idle = "recharger0"
|
||||
var/recharge_coeff = 1
|
||||
|
||||
/obj/machinery/recharger/New()
|
||||
..()
|
||||
component_parts = list()
|
||||
component_parts += new /obj/item/circuitboard/recharger(null)
|
||||
component_parts += new /obj/item/stock_parts/capacitor(null)
|
||||
RefreshParts()
|
||||
|
||||
/obj/machinery/recharger/RefreshParts()
|
||||
for(var/obj/item/stock_parts/capacitor/C in component_parts)
|
||||
recharge_coeff = C.rating
|
||||
|
||||
/obj/machinery/recharger/attackby(obj/item/G, mob/user, params)
|
||||
if(iswrench(G))
|
||||
@@ -53,8 +66,16 @@
|
||||
else
|
||||
to_chat(user, "<span class='notice'>[src] isn't connected to anything!</span>")
|
||||
return 1
|
||||
else
|
||||
return ..()
|
||||
|
||||
if(anchored && !charging)
|
||||
if(default_deconstruction_screwdriver(user, "rechargeropen", "recharger0", G))
|
||||
return
|
||||
|
||||
if(panel_open && istype(G, /obj/item/crowbar))
|
||||
default_deconstruction_crowbar(G)
|
||||
return
|
||||
|
||||
return ..()
|
||||
|
||||
/obj/machinery/recharger/attack_hand(mob/user)
|
||||
if(issilicon(user))
|
||||
@@ -87,7 +108,7 @@
|
||||
var/obj/item/gun/energy/E = charging
|
||||
if(E.power_supply.charge < E.power_supply.maxcharge)
|
||||
E.power_supply.give(E.power_supply.chargerate)
|
||||
use_power(250)
|
||||
use_power(200 * recharge_coeff)
|
||||
using_power = 1
|
||||
|
||||
|
||||
|
||||
@@ -91,6 +91,12 @@
|
||||
if(climber)
|
||||
climber.Weaken(2)
|
||||
climber.visible_message("<span class='warning'>[climber.name] has been knocked off the table", "You've been knocked off the table", "You see [climber.name] get knocked off the table</span>")
|
||||
else if(user.pulling.pass_flags & PASSTABLE)
|
||||
user.Move_Pulled(src)
|
||||
if (user.pulling.loc == loc)
|
||||
user.visible_message("<span class='notice'>[user] places [user.pulling] onto [src].</span>",
|
||||
"<span class='notice'>You place [user.pulling] onto [src].</span>")
|
||||
user.stop_pulling()
|
||||
|
||||
/obj/structure/table/attack_tk() // no telehulk sorry
|
||||
return
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
broken_icon = "mwb"
|
||||
dirty_icon = "mwbloody"
|
||||
open_icon = "mw-o"
|
||||
pass_flags = PASSTABLE
|
||||
|
||||
// see code/modules/food/recipes_microwave.dm for recipes
|
||||
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
name = "plant DNA manipulator"
|
||||
desc = "An advanced device designed to manipulate plant genetic makeup."
|
||||
icon = 'icons/obj/hydroponics/equipment.dmi'
|
||||
pass_flags = PASSTABLE
|
||||
icon_state = "dnamod"
|
||||
density = 1
|
||||
anchored = 1
|
||||
|
||||
@@ -9,6 +9,7 @@ var/global/list/fax_blacklist = list()
|
||||
icon = 'icons/obj/library.dmi'
|
||||
icon_state = "fax"
|
||||
insert_anim = "faxsend"
|
||||
pass_flags = PASSTABLE
|
||||
var/fax_network = "Local Fax Network"
|
||||
|
||||
var/long_range_enabled = 0 // Can we send messages off the station?
|
||||
|
||||
@@ -12,6 +12,16 @@
|
||||
build_path = /obj/item/circuitboard/thermomachine
|
||||
category = list ("Engineering Machinery")
|
||||
|
||||
/datum/design/recharger
|
||||
name = "Machine Board(Weapon Recharger)"
|
||||
desc = "The circuit board for a weapon recharger"
|
||||
id = "recharger"
|
||||
build_path = /obj/item/circuitboard/recharger
|
||||
materials = list(MAT_GLASS = 1000)
|
||||
build_type = IMPRINTER
|
||||
req_tech = list("powerstorage" = 3, "materials" = 3)
|
||||
category = list("Misc. Machinery")
|
||||
|
||||
/datum/design/smes
|
||||
name = "Machine Board (SMES)"
|
||||
desc = "The circuit board for a SMES."
|
||||
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 79 KiB After Width: | Height: | Size: 80 KiB |
Reference in New Issue
Block a user