ProcessForm()
/*
This is called when the player submits the form.
Make sure everything is valid; if not, send them back to the
form with an error message.
If everything is okay, create their character and log them
into it, then blank out the web page.
This checks the ckey() version of the name they chose, to make
sure it has actual letters and isn't just punctuation.
*/
var/mob/creating_character/player = usr
var/ckey_name = ckey(name)
if (!ckey_name || ckey_name == "")
player.error_text = "Your name must have alpha-numeric characters in it!"
DisplayForm()
return
// Everything is okay, so create the new mob based on the class they chose.
var/mob/new_mob
switch(class)
if ("Warrior") new_mob = new /mob/Warrior()
if ("Priest") new_mob = new /mob/Priest()
if ("Paladin") new_mob = new /mob/Paladin()
switch(hair)
if ("Warrior")
usr.overlays+= "WarriorHair.dmi"
if ("Mage")
usr.overlays+= "MageHair.dmi"
if ("Bald")
..()
Problem description:Im having a problem with the demo, i reconfigured everything perfectly except this won't work. Somehow it doesn't overlay the hair on the base icon, i don't see what i did wrong.
usr.overlays+= "WarriorHair.dmi"
should be like this
not the ' ' around them instead of the " "
[edit]
Note: also since it is defining the user in the character creation, u should do it like this.
src.overlays+= 'WarriorHair.dmi'
with the src. instead of usr.