ID:139608
 
Code:
New Player Code
mob
proc
np()
if(fexists("players/[src.key]"))
switch(alert(usr, "Are you sure you would like to remake?", "Character Creat", "Yes","No"))
if("Yes")
sleep(0)
fdel("players/[usr.key].sav")
if("No")
return
alert("Please Be original with your player names also include a first and last name.")
var/name = input("","What are you known by?") as text|null
if(!usr)
return
if(name == "")
return
if(name == " ")
return
if(name == " ")
return
usr.name="[name]"
usr.loc = locate(7,7,1)
usr.icon='Base.dmi'
switch(input("How would you like your hair Styled?", text) in list ("Style 1","Style 2"))
if("Style 1")
var/hairred = input("How much red do you want to put into your hair?") as num
var/hairblue = input("How much blue do you want to put into your hair?") as num
var/hairgreen = input("How much green do you want to put into your hair?") as num
var/hairover = 'Hair1.dmi'
hairover += rgb(hairred,hairgreen,hairblue)
usr.hair = hairover
usr.overlays += usr.hair
if("Style 2")
var/hairred = input("How much red do you want to put into your hair?") as num
var/hairblue = input("How much blue do you want to put into your hair?") as num
var/hairgreen = input("How much green do you want to put into your hair?") as num
var/hairover = 'Hair1.dmi'
hairover += rgb(hairred,hairgreen,hairblue)
usr.hair = hairover
usr.overlays += usr.hair
return
usr.loc=locate(7,7,1)
usr.loc = locate(7,7,1)
usr.cansave=1

Load Player Proc
mob
proc
LP()
if(fexists("players/[src.key].sav"))
var/savefile/F = new("players/[src.key].sav")
Read(F)
for(var/stuff in src.V)
src.verbs += stuff
world<<"<font size=1><font color=red><B>Info: <font color=white>[src]([src.key]) has logged in..."
src.loc = locate(xco,yco,zco)
client.view=6
src.OOC = 1
src.cansave=1
src.Frozen = 0
src.AutoSave()
src.np()

The button codes
mob/verb/NewP()
set category=null
var/S = winget(src, "Login", "is-visible")
if(S == "true")
winshow(src,"Login",0)
winshow(src,"Custom",1)
np()
mob/verb/ResP()
set category=null
var/S = winget(src, "Login", "is-visible")
if(S == "true")
winshow(src,"Login",0)

LP()

Problem description:
Ok whats happening is when I go to load my player it loads it, but also calls the new player proc so if someone can help me solve it it would be great but I am still gonna look for a solution on my own.

You're calling the src.np() proc inside the lp proc.
In response to Darker Legends
OMG im such a Idiot i cant believe i did not notice it thank u for the help
You can't fool me with your coding! All I have to do is enter THREE spaces as my name and it will blow right past your name checker!

Instead of entirely stopping the proc if they don't enter a name, instead continuously prompt them for a name until one is entered.

do
name = input("Name?") as text
while(!name)


...unless that isn't what you are going for.
In response to LordAndrew
honestly what i wanna do is set it up to where players have to enter a first and last name for their player but atm im just doin a normal bare bones setup