diff --git a/code/datums/components/melee/charged.dm b/code/datums/components/melee/charged.dm index 27ecac223930..2319977a4a0d 100644 --- a/code/datums/components/melee/charged.dm +++ b/code/datums/components/melee/charged.dm @@ -27,7 +27,7 @@ list/attack_verb_on, inhand_icon_change = TRUE, _allowed_cells = list(), - _preload_cell_type = /obj/item/stock_parts/cell/melee, + _preload_cell_type = /obj/item/stock_parts/cell, _cell_hit_cost = 1000, _can_remove_cell = FALSE, _no_cell_icon = FALSE diff --git a/code/game/objects/items/melee/charged.dm b/code/game/objects/items/melee/charged.dm deleted file mode 100644 index 32a536108a5d..000000000000 --- a/code/game/objects/items/melee/charged.dm +++ /dev/null @@ -1,87 +0,0 @@ -/obj/item/melee/charged - force = 0 - var/active_force = 10 - - var/obj/item/stock_parts/cell/cell - var/allowed_cells = list() - var/preload_cell_type = /obj/item/stock_parts/cell/melee //if not empty the sabre starts with this type of cell - var/cell_hit_cost = 1000 - var/activate_sound = "sparks" - -/obj/item/melee/charged/Initialize() - . = ..() - if(preload_cell_type) - if(preload_cell_type in allowed_cells) - cell = new preload_cell_type(src) - -/obj/item/melee/charged/ComponentInitialize() - AddComponent( \ - /datum/component/transforming, \ - force_on = active_force, \ - ) - RegisterSignal(src, COMSIG_TRANSFORMING_ON_TRANSFORM, PROC_REF(on_transform)) - -/obj/item/melee/charged/Destroy() - if(cell) - QDEL_NULL(cell) - return ..() - -/obj/item/melee/charged/proc/on_transform() - SIGNAL_HANDLER - - playsound(src, activate_sound, 75, TRUE, -1) - -/obj/item/melee/charged/proc/deductcharge(chrgdeductamt) - if(cell) - //Note this value returned is significant, as it will determine - //if a stun is applied or not - . = cell.use(chrgdeductamt) - if(turned_on && cell.charge < cell_hit_cost) - //we're below minimum, turn off - SEND_SIGNAL(src, COSMIG_ITEM_FORCE_TRANSFORM, src) - update_appearance() - playsound(src, activate_sound, 75, TRUE, -1) - -/obj/item/melee/charged/update_icon_state() - if(turned_on) - icon_state = "[initial(icon_state)]_on" - return ..() - if(!cell) - icon_state = "[initial(icon_state)]_nocell" - return ..() - icon_state = "[initial(icon_state)]" - return ..() - -/obj/item/melee/charged/examine(mob/user) - . = ..() - if(cell) - . += span_notice("\The [src] is [round(cell.percent())]% charged.") - else - . += span_warning("\The [src] does not have a power source installed.") - -/obj/item/melee/charged/attackby(obj/item/W, mob/user, params) - if(istype(W, /obj/item/stock_parts/cell)) - var/obj/item/stock_parts/cell/C = W - if(cell) - to_chat(user, span_notice("[src] already has a cell!")) - else - if(C.maxcharge < cell_hit_cost) - to_chat(user, span_notice("[src] requires a higher capacity cell.")) - return - if(!user.transferItemToLoc(W, src)) - return - cell = W - to_chat(user, span_notice("You install a cell in [src].")) - update_appearance() - else - return ..() - -/obj/item/melee/charged/screwdriver_act(mob/living/user, obj/item/I) - . = ..() - if(cell && can_remove_cell) - cell.update_appearance() - cell.forceMove(get_turf(src)) - cell = null - to_chat(user, span_notice("You remove the cell from [src].")) - turned_on = FALSE - update_appearance() diff --git a/code/game/objects/items/melee/dualenergy.dm b/code/game/objects/items/melee/dualenergy.dm index b53427503639..7776b078f13e 100644 --- a/code/game/objects/items/melee/dualenergy.dm +++ b/code/game/objects/items/melee/dualenergy.dm @@ -19,7 +19,7 @@ var/sword_color = "green" var/hacked = FALSE var/list/possible_colors = list("red", "blue", "green", "purple", "yellow") - var/impale_flavor_text "twirl" + var/impale_flavor_text = "twirl" var/hack_flavor_text = "" /obj/item/melee/duelenergy/Initialize() @@ -164,7 +164,7 @@ name = "energy halberd" desc = "For when a normal halberd just isnt enough." icon_state = "halberd" - base_icon_state = "halberd"' + base_icon_state = "halberd" lefthand_file = 'icons/mob/inhands/weapons/polearms_lefthand.dmi' righthand_file = 'icons/mob/inhands/weapons/polearms_righthand.dmi' w_class = WEIGHT_CLASS_BULKY diff --git a/code/game/objects/items/toys.dm b/code/game/objects/items/toys.dm index ff8146f3632d..6599b34d30e4 100644 --- a/code/game/objects/items/toys.dm +++ b/code/game/objects/items/toys.dm @@ -307,7 +307,7 @@ var/obj/item/melee/duelenergy/saber/toy/newSaber = new /obj/item/melee/duelenergy/saber/toy(user.loc) if(hacked) // That's right, we'll only check the "original" "sword". newSaber.hacked = TRUE - newSaber.saber_color = "rainbow" + newSaber.sword_color = "rainbow" qdel(W) qdel(src) else if(W.tool_behaviour == TOOL_MULTITOOL) diff --git a/shiptest.dme b/shiptest.dme index c137712a4aee..2d47741e5703 100644 --- a/shiptest.dme +++ b/shiptest.dme @@ -1318,6 +1318,9 @@ #include "code\game\objects\items\implants\implantchair.dm" #include "code\game\objects\items\implants\implanter.dm" #include "code\game\objects\items\implants\implantpad.dm" +#include "code\game\objects\items\implants\implantuplink.dm" +#include "code\game\objects\items\melee\axe.dm" +#include "code\game\objects\items\melee\chainsaw.dm" #include "code\game\objects\items\melee\dualenergy.dm" #include "code\game\objects\items\melee\energy.dm" #include "code\game\objects\items\melee\knife.dm"