ID:1441018
 
(See the best response by Nadrew.)
Ok so i made my game where I have title screen and the creation screen on panes and when ure done with the creation you goto the map pane but question im wondering is where is the character you control while its being created?

I don't want it to be sitting on some map while its being made to be killed or something do I use the login() thing to spawn it on the map when im done creating cause atm there isn't any sort of login code since its all just panes

As long as you don't move your mob to a map, it won't be on the map. Also, you can set the mobs loc to null if you want to be certain.
what happens if i set it to null what will it do?
In response to Mastergamerxxx
Mastergamerxxx wrote:
what happens if i set it to null what will it do?

The mob will not have a location on the map.
well atm i got

world
mob = /mob/player

and of course the whole mob/player icon thingy so how should i go about that should i remove it from the world thing or what?
In response to Mastergamerxxx
Consider when the mob or client is initialized...

client/New() {
. = ..();
mob.loc = null;
}


This is assuming your mob viewpoint is not necessary in regards to your title screen, which it sounds like it's not. Technically, this just sets the mob's x, y, and z variables to 0, which is an unreachable spot on the map.
Best response
Definitely not the way to handle that, you should be using a mob type just for the loading process, which will handle everything before the player is loaded.

world/mob = /mob/loading

mob/loading
Login()
// Create your loading screen and whatnot here.
// Don't call ..() if you don't want it placed on the map.


Then, inside of your loading process you transfer the loading mob to the loaded /mob/player by setting client.mob

// When loading the mob, load it into a variable reference.
// This example assumes your savefile contains a straight file["player"] << src type save.

var/mob/player/loaded_player
mysave["player"] >> loaded_player
if(loaded_player) // Successful load.
var/mob/loading/old_mob = src
client.mob = loaded_player
del(old_mob) // The garbage collector might not catch this, so delete it yourself.


Example, of course. Doing it this way gives you a lot greater control over how things are processed during player login and pre-loading. It also makes it possible to type-check for /mob/loading in sanity checks to prevent actions from happening to non-loaded mobs in some strange event that it happens to appear on the map. Type checking is going to be a lot more efficient than checking a bunch of variables to see if they've been loaded or not.