mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-24 04:27:35 +01:00
Crayons and Gloves
This commit is contained in:
@@ -1,100 +1,84 @@
|
||||
/obj/item/toy/crayon/red
|
||||
icon_state = "crayonred"
|
||||
colour = "#DA0000"
|
||||
shadeColour = "#810C0C"
|
||||
colourName = "red"
|
||||
|
||||
/obj/item/toy/crayon/orange
|
||||
icon_state = "crayonorange"
|
||||
colour = "#FF9300"
|
||||
shadeColour = "#A55403"
|
||||
colourName = "orange"
|
||||
|
||||
/obj/item/toy/crayon/yellow
|
||||
icon_state = "crayonyellow"
|
||||
colour = "#FFF200"
|
||||
shadeColour = "#886422"
|
||||
colourName = "yellow"
|
||||
|
||||
/obj/item/toy/crayon/green
|
||||
icon_state = "crayongreen"
|
||||
colour = "#A8E61D"
|
||||
shadeColour = "#61840F"
|
||||
colourName = "green"
|
||||
|
||||
/obj/item/toy/crayon/blue
|
||||
icon_state = "crayonblue"
|
||||
colour = "#00B7EF"
|
||||
shadeColour = "#0082A8"
|
||||
colourName = "blue"
|
||||
|
||||
/obj/item/toy/crayon/purple
|
||||
icon_state = "crayonpurple"
|
||||
colour = "#DA00FF"
|
||||
shadeColour = "#810CFF"
|
||||
colourName = "purple"
|
||||
|
||||
/obj/item/toy/crayon/white
|
||||
icon_state = "crayonwhite"
|
||||
colour = "#FFFFFF"
|
||||
colourName = "white"
|
||||
|
||||
/obj/item/toy/crayon/mime
|
||||
icon_state = "crayonmime"
|
||||
desc = "A very sad-looking crayon."
|
||||
colour = "#FFFFFF"
|
||||
shadeColour = "#000000"
|
||||
colourName = "mime"
|
||||
uses = 0
|
||||
|
||||
/obj/item/toy/crayon/mime/attack_self(mob/living/user as mob) //inversion
|
||||
if(colour != "#FFFFFF" && shadeColour != "#000000")
|
||||
colour = "#FFFFFF"
|
||||
shadeColour = "#000000"
|
||||
user << "You will now draw in white and black with this crayon."
|
||||
/obj/item/toy/crayon/mime/attack_self(mob/living/user as mob)
|
||||
update_window(user)
|
||||
|
||||
/obj/item/toy/crayon/mime/update_window(mob/living/user as mob)
|
||||
dat += "<center><span style='border:1px solid #161616; background-color: [colour];'> </span><a href='?src=\ref[src];color=1'>Change color</a></center>"
|
||||
..()
|
||||
|
||||
/obj/item/toy/crayon/mime/Topic(href,href_list)
|
||||
if ((usr.restrained() || usr.stat || usr.get_active_hand() != src))
|
||||
return
|
||||
if(href_list["color"])
|
||||
if(colour != "#FFFFFF")
|
||||
colour = "#FFFFFF"
|
||||
else
|
||||
colour = "#000000"
|
||||
update_window(usr)
|
||||
else
|
||||
colour = "#000000"
|
||||
shadeColour = "#FFFFFF"
|
||||
user << "You will now draw in black and white with this crayon."
|
||||
return
|
||||
..()
|
||||
|
||||
/obj/item/toy/crayon/rainbow
|
||||
icon_state = "crayonrainbow"
|
||||
colour = "#FFF000"
|
||||
shadeColour = "#000FFF"
|
||||
colourName = "rainbow"
|
||||
uses = 0
|
||||
|
||||
/obj/item/toy/crayon/rainbow/attack_self(mob/living/user as mob)
|
||||
colour = input(user, "Please select the main colour.", "Crayon colour") as color
|
||||
shadeColour = input(user, "Please select the shade colour.", "Crayon colour") as color
|
||||
return
|
||||
update_window(user)
|
||||
|
||||
/obj/item/toy/crayon/afterattack(atom/target, mob/user as mob, proximity)
|
||||
if(!proximity) return
|
||||
if(istype(target,/turf/simulated/floor))
|
||||
var/drawtype = input("Choose what you'd like to draw.", "Crayon scribbles") in list("graffiti","rune","letter")
|
||||
switch(drawtype)
|
||||
if("letter")
|
||||
drawtype = input("Choose the letter.", "Crayon scribbles") in list("a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z")
|
||||
user << "You start drawing a letter on the [target.name]."
|
||||
if("graffiti")
|
||||
user << "You start drawing graffiti on the [target.name]."
|
||||
if("rune")
|
||||
user << "You start drawing a rune on the [target.name]."
|
||||
if(instant || do_after(user, 50))
|
||||
new /obj/effect/decal/cleanable/crayon(target,colour,shadeColour,drawtype)
|
||||
user << "You finish drawing."
|
||||
if(uses)
|
||||
uses--
|
||||
if(!uses)
|
||||
user << "\red You used up your crayon!"
|
||||
del(src)
|
||||
return
|
||||
/obj/item/toy/crayon/rainbow/update_window(mob/living/user as mob)
|
||||
dat += "<center><span style='border:1px solid #161616; background-color: [colour];'> </span><a href='?src=\ref[src];color=1'>Change color</a></center>"
|
||||
..()
|
||||
|
||||
/obj/item/toy/crayon/attack(mob/M as mob, mob/user as mob)
|
||||
if(M == user)
|
||||
user << "You take a bite of the crayon. Delicious!"
|
||||
user.nutrition += 5
|
||||
if(uses)
|
||||
uses -= 5
|
||||
if(uses <= 0)
|
||||
user << "\red You ate your crayon!"
|
||||
del(src)
|
||||
/obj/item/toy/crayon/rainbow/Topic(href,href_list[])
|
||||
|
||||
if(href_list["color"])
|
||||
var/temp = input(usr, "Please select colour.", "Crayon colour") as color
|
||||
if ((usr.restrained() || usr.stat || usr.get_active_hand() != src))
|
||||
return
|
||||
colour = temp
|
||||
update_window(usr)
|
||||
else
|
||||
..()
|
||||
Reference in New Issue
Block a user