From f2a27ade31a442bc44e36056d2b6b78be9e7b475 Mon Sep 17 00:00:00 2001 From: xxalpha Date: Sun, 22 Feb 2015 02:49:56 +0000 Subject: [PATCH 1/2] Add initialize for crayons and fix runtime error. --- code/game/objects/items/toys.dm | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/code/game/objects/items/toys.dm b/code/game/objects/items/toys.dm index 104cf19eff3..4781ff2dc74 100644 --- a/code/game/objects/items/toys.dm +++ b/code/game/objects/items/toys.dm @@ -449,6 +449,12 @@ ..() name = "[colourName] crayon" //Makes crayons identifiable in things like grinders drawtype = pick(pick(graffiti), pick(letters), "rune[rand(1,6)]") + if(config != null) + if(config.mutant_races == 1) + graffiti += "antilizard" + graffiti += "prolizard" + +/obj/item/toy/crayon/initialize() if(config.mutant_races == 1) graffiti += "antilizard" graffiti += "prolizard" From cf05a587f90b1f6def9e8ef32072744717424d92 Mon Sep 17 00:00:00 2001 From: xxalpha Date: Sun, 22 Feb 2015 13:58:15 +0000 Subject: [PATCH 2/2] Code tweak. --- code/game/objects/items/toys.dm | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/code/game/objects/items/toys.dm b/code/game/objects/items/toys.dm index 4781ff2dc74..12c3e59e172 100644 --- a/code/game/objects/items/toys.dm +++ b/code/game/objects/items/toys.dm @@ -449,15 +449,15 @@ ..() name = "[colourName] crayon" //Makes crayons identifiable in things like grinders drawtype = pick(pick(graffiti), pick(letters), "rune[rand(1,6)]") - if(config != null) + if(config) if(config.mutant_races == 1) - graffiti += "antilizard" - graffiti += "prolizard" + graffiti |= "antilizard" + graffiti |= "prolizard" /obj/item/toy/crayon/initialize() if(config.mutant_races == 1) - graffiti += "antilizard" - graffiti += "prolizard" + graffiti |= "antilizard" + graffiti |= "prolizard" /obj/item/toy/crayon/attack_self(mob/living/user as mob) update_window(user)