Two new collar types. All collars are now colorable a'la polychromic stuff.

This commit is contained in:
Useroth
2019-05-09 11:22:51 +02:00
parent 49a012ea87
commit 1efd7123f2
3 changed files with 59 additions and 1 deletions
+59 -1
View File
@@ -177,9 +177,12 @@
/obj/item/clothing/neck/petcollar
name = "pet collar"
desc = "It's for pets. Though you probably could wear it yourself, you'd doubtless be the subject of ridicule."
desc = "It's for pets. Though you probably could wear it yourself, you'd doubtless be the subject of ridicule. It seems to be made out of a polychromic material."
icon_state = "petcollar"
alternate_worn_icon = 'icons/mob/neck.dmi'
item_color = "petcollar"
hasprimary = TRUE
primary_color = "#00BBBB"
pocket_storage_component_path = /datum/component/storage/concrete/pockets/small/collar
var/tagname = null
@@ -187,6 +190,42 @@
tagname = copytext(sanitize(input(user, "Would you like to change the name on the tag?", "Name your new pet", "Spot") as null|text),1,MAX_NAME_LEN)
name = "[initial(name)] - [tagname]"
/obj/item/clothing/neck/petcollar/worn_overlays(isinhands, icon_file)
. = ..()
if(hasprimary | hassecondary | hastertiary)
if(!isinhands) //prevents the worn sprites from showing up if you're just holding them
if(hasprimary) //checks if overlays are enabled
var/mutable_appearance/primary_worn = mutable_appearance(alternate_worn_icon, "[item_color]-primary") //automagical sprite selection
primary_worn.color = primary_color //colors the overlay
. += primary_worn //adds the overlay onto the buffer list to draw on the mob sprite.
if(hassecondary)
var/mutable_appearance/secondary_worn = mutable_appearance(alternate_worn_icon, "[item_color]-secondary")
secondary_worn.color = secondary_color
. += secondary_worn
if(hastertiary)
var/mutable_appearance/tertiary_worn = mutable_appearance(alternate_worn_icon, "[item_color]-tertiary")
tertiary_worn.color = tertiary_color
. += tertiary_worn
/obj/item/clothing/neck/petcollar/leather
name = "leather pet collar"
icon_state = "leathercollar"
item_color = "leathercollar"
hasprimary = TRUE
hassecondary = TRUE
primary_color = "#000000"
secondary_color = "#888888"
/obj/item/clothing/neck/petcollar/choker
name = "choker"
icon_state = "choker"
item_color = "choker"
hasprimary = TRUE
hassecondary = TRUE
primary_color = "#000000"
/obj/item/clothing/neck/petcollar/locked
name = "locked collar"
desc = "A collar that has a small lock on it to keep it from being removed."
@@ -210,6 +249,25 @@
return
..()
/obj/item/clothing/neck/petcollar/locked/leather
name = "leather pet collar"
icon_state = "leathercollar"
item_color = "leathercollar"
hasprimary = TRUE
hassecondary = TRUE
primary_color = "#000000"
secondary_color = "#888888"
/obj/item/clothing/neck/petcollar/locked/choker
name = "choker"
icon_state = "choker"
item_color = "choker"
hasprimary = TRUE
hassecondary = TRUE
primary_color = "#000000"
/obj/item/key/collar
name = "Collar Key"
desc = "A key for a tiny lock on a collar or bag."