mob
proc
yes()
switch(usr.class)
if("Soldier")
var/mob/newmob=new/mob/player/Soldier
newmob.gender=newgender
newmob.name=newname
newmob.class=newclass
usr.client.mob=newmob
del src
if("Royalty")
switch(src.key)
if("Satans Spawn")
var/mob/newmob=new/mob/player/Satans_Spawn
newmob.gender=newgender //line 451
newmob.name=newname
newmob.class=newclass
usr.client.mob=newmob
del src
Problem description:
Now on to the problem. Up until now that has been the code that decides whether or not to make a character Royalty. (It is a DW styled game where you choose your class via on screen display, using a variable to store which class you choose.) When I choose to make a Royalty class, I get a runtime error reading:
runtime error: Cannot modify null.gender.
proc name: yes (/mob/proc/yes)
source file: char creation.dm,451
usr: Satans Spawn (/mob/choosing)
src: Satans Spawn (/mob/choosing)
call stack:
AAA (/mob/choosing): yes()
Satans Spawn (/client): Center()
However, when I choose to create a Soldier classed Character, everything goes through normally.
Can anyone see what may be causing this error to appear out of no where?
§atans§pawn