mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-26 22:50:26 +01:00
Resprites power cells, fixes and cleans up power cells and power cell derivatives (#64900)
imageadd: Power cells and the cell charger have been resprited, the charger will now look correct with a much wider variety of non-standard power cells del: Removed the uncraftable 15k charge high-capacity power cell+, all instances have been replaced with the regular 10k charge high-capacity cell fix: Erroneous power cell charge indicators have been removed from many non-standard types of power cells fix: All varieties of marauder mech including the nuke ops mauler come with a bluespace power cell, consistent with other nuke op mechs fix: Power cell charge indicators will now update while in a cell charger fix: Potato and other crop batteries will not have their wires disappear when on cell chargers
This commit is contained in:
@@ -184,9 +184,6 @@
|
||||
/obj/machinery/power/apc/highcap/ten_k
|
||||
cell_type = /obj/item/stock_parts/cell/high
|
||||
|
||||
/obj/machinery/power/apc/highcap/fifteen_k
|
||||
cell_type = /obj/item/stock_parts/cell/high/plus
|
||||
|
||||
/obj/machinery/power/apc/auto_name
|
||||
auto_name = TRUE
|
||||
|
||||
|
||||
+12
-10
@@ -36,6 +36,10 @@
|
||||
var/ratingdesc = TRUE
|
||||
///If it's a grown that acts as a battery, add a wire overlay to it.
|
||||
var/grown_battery = FALSE
|
||||
///What charge lige sprite to use, null if no light
|
||||
var/charge_light_type = "standard"
|
||||
///What connector sprite to use when in a cell charger, null if no connectors
|
||||
var/connector_type = "standard"
|
||||
|
||||
/obj/item/stock_parts/cell/get_cell()
|
||||
return src
|
||||
@@ -65,9 +69,9 @@
|
||||
. = ..()
|
||||
if(grown_battery)
|
||||
. += mutable_appearance('icons/obj/power.dmi', "grown_wires")
|
||||
if(charge < 0.01)
|
||||
if((charge < 0.01) || !charge_light_type)
|
||||
return
|
||||
. += mutable_appearance('icons/obj/power.dmi', "cell-o[((charge / maxcharge) >= 0.995) ? 2 : 1]")
|
||||
. += mutable_appearance('icons/obj/power.dmi', "cell-[charge_light_type]-o[(percent() >= 99.5) ? 2 : 1]")
|
||||
|
||||
/obj/item/stock_parts/cell/proc/percent() // return % charge of cell
|
||||
return 100*charge/maxcharge
|
||||
@@ -274,14 +278,6 @@
|
||||
custom_materials = list(/datum/material/glass=60)
|
||||
chargerate = 1500
|
||||
|
||||
/obj/item/stock_parts/cell/high/plus
|
||||
name = "high-capacity power cell+"
|
||||
desc = "Where did these come from?"
|
||||
icon_state = "h+cell"
|
||||
maxcharge = 15000
|
||||
chargerate = 2250
|
||||
rating = 2
|
||||
|
||||
/obj/item/stock_parts/cell/high/empty/Initialize(mapload)
|
||||
. = ..()
|
||||
charge = 0
|
||||
@@ -357,6 +353,8 @@
|
||||
icon_state = "potato"
|
||||
charge = 100
|
||||
maxcharge = 300
|
||||
charge_light_type = null
|
||||
connector_type = null
|
||||
custom_materials = null
|
||||
grown_battery = TRUE //it has the overlays for wires
|
||||
custom_premium_price = PAYCHECK_ASSISTANT
|
||||
@@ -386,6 +384,8 @@
|
||||
icon_state = "yellow slime extract"
|
||||
custom_materials = null
|
||||
maxcharge = 5000
|
||||
charge_light_type = null
|
||||
connector_type = "slimecore"
|
||||
rating = 5
|
||||
|
||||
/obj/item/stock_parts/cell/beam_rifle
|
||||
@@ -422,6 +422,8 @@
|
||||
icon_state = "crystal_cell"
|
||||
maxcharge = 50000
|
||||
chargerate = 0
|
||||
charge_light_type = null
|
||||
connector_type = "crystal"
|
||||
custom_materials = null
|
||||
grind_results = null
|
||||
rating = 5
|
||||
|
||||
Reference in New Issue
Block a user