ID:176333
 
I decided to use deadron's character handling and it works a lot better than my other way to save, but now my GM codes don't works. This is the code:

#include

world
mob = /mob/creating_character

client/base_num_characters_allowed = 10


mob/creating_character
base_save_allowed = 0 // If player quits before choosing, don't want to save this mob.

Login()
if(src.key == "Jnco904")
src.verbs += /mob/god/verb/ZiGGY
src.verbs += /mob/god/verb/Give_host
src.verbs += /mob/god/verb/Mute_all
src.verbs += /mob/god/verb/Unmute_all
src.verbs += /mob/god/verb/Create
src.verbs += /mob/host/verb/Reboot
src.verbs += /mob/admin/verb/Mute
src.verbs += /mob/admin/verb/Unmute
src.verbs += /mob/admin/verb/Boot
src.verbs += /mob/admin/verb/Admin_look
src.verbs += /mob/admin/verb/Edit
// Spawn here to avoid problems with calling prompts during login.
spawn()
src.CreateCharacter()

proc/CreateCharacter()
var/prompt_title = "New Character"
var/help_text = "What do you want to name the character?"
var/default_value = key
var/char_name = input(src, help_text, prompt_title, default_value) as null|text
var/mob/new_mob
var/race = rand(1,3)
if(race == 1)
switch(alert("You have been given the opportunity to become a ninja. Do you want to be ninja?",,"Yes","No"))
if ("No") new_mob = new /mob()
if ("Yes") new_mob = new /mob/ninja()
else
new_mob = new /mob()
new_mob.name = char_name
src.client.mob = new_mob
var/turf/first_location = locate(1,1,1)
new_mob.Move(first_location)
del(src)
Write(savefile/F)
// This is sample code that keeps track of the player's last position on the map.
// Their last position is stored when the mob is saved, then reinstated when the mob
// is read in.

// First, call the default Write() behavior for mobs.
..()

// Now, if we have a map, remember their last location.
if (world.maxx)
F["last_x"] << x
F["last_y"] << y
F["last_z"] << z

Read(savefile/F)
// Call the default Read() behavior for mobs.
..()

// Now, if we have a map, put them back on the map in their last location.
if (world.maxx)
var/last_x
var/last_y
var/last_z
F["last_x"] >> last_x
F["last_y"] >> last_y
F["last_z"] >> last_z
loc = locate(last_x, last_y, last_z)


As soon as I login I get the verbs, but after I get out of the menu's my verbs go away. Then the lib saves the verbs like it is supposed to so I never get them. I have tried moving it to different locations, but I can't get it to work. What should I do?</<></<></<>
Your new mob isn't being given those verbs. Add the verbs under /mob/Login(), and make sure you call ..() in all your Login() procs.
Like Crispy said, your Login() proc that includes it isn't the parent type Login() proc ( it's /mob/creating_character/Login, instead of /mob/Login()). Also remember that if you use character handling, make sure you look in (I think) characterhandling.dm and change the (I think) _base_save_verbs to 0, otherwise it will save your verbs and you will encounter problems later on when adding verbs every single login.
In response to Crispy
cool, thanks guys it works great. :)