Moves reskinning items to /obj (#28558)

This commit is contained in:
Really-Good-Soda-Flavor
2017-06-21 14:19:17 -04:00
committed by Leo
parent 7155f5feb9
commit 40de86de35
4 changed files with 51 additions and 70 deletions
+9 -17
View File
@@ -82,25 +82,17 @@
materials = list(MAT_GOLD = 750)
sharpness = IS_SHARP
resistance_flags = FIRE_PROOF
var/unique_reskin = TRUE
var/list/skins = list("Oak" = "pen-fountain-o", "Gold" = "pen-fountain-g", "Rosewood" = "pen-fountain-r", "Black and Silver" = "pen-fountain-b","Command Blue" = "pen-fountain-cb")
unique_reskin = list("Oak" = "pen-fountain-o",
"Gold" = "pen-fountain-g",
"Rosewood" = "pen-fountain-r",
"Black and Silver" = "pen-fountain-b",
"Command Blue" = "pen-fountain-cb"
)
/obj/item/weapon/pen/fountain/captain/AltClick()
var/mob/living/carbon/user = usr
if(!istype(user))
return
if(unique_reskin)
var/choice = input(user,"Choose the finish for your pen.","Reskin Pen") as null|anything in skins
if(!QDELETED(src) && choice && !user.incapacitated() && in_range(user,src))
icon_state = skins[choice]
unique_reskin = FALSE
to_chat(user, "Your pen now has a [choice] finish.")
desc = "It's an expensive [choice] fountain pen. The nib is quite sharp."
/obj/item/weapon/pen/fountain/captain/examine(mob/user)
/obj/item/weapon/pen/fountain/captain/reskin_obj(mob/M)
..()
if(unique_reskin)
to_chat(user, "<span class='notice'>This item can be reskinned. Alt-click to select a skin.</span>")
if(current_skin)
desc = "It's an expensive [current_skin] fountain pen. The nib is quite sharp."
/obj/item/weapon/pen/attack_self(mob/living/carbon/user)
var/deg = input(user, "What angle would you like to rotate the pen head to? (1-360)", "Rotate Pen Head") as null|num