I read them. I still don't get what I must do.
If the tutorials are unclear, talk to me in the tutorial threads and quote specifically the bits that you don't get. I wrote the tutorial because a number of people were having issues with saving systems just like you.

If I wrote it incorrectly, and it's just confusing people, I'd appreciate it if we could address it within the tutorial's thread so that we can clear up any confusion for future readers.
I am trying to fix my code. This still isn't working. I did this:

if(choose=="Load")
var/savefile/F=new("saves/[copytext(src.ckey,1,2)]/[src.ckey].sav")
F>>src

mob
player
Write(var/savefile/F,var/list/neversave=null)
. = ..(F,neversave)
var/ocd = F.cd
F.cd = "location"
F << src.x
F << src.y
F << src.z
F.cd = ocd
return .
Read(var/savefile/F,var/list/neversave=null)
. = ..(F,neversave)
var/ocd = F.cd
F.cd = "location"
F >> src.x
F >> src.y
F >> src.z
F.cd = ocd
return .

mob
logging
Login()
spawn()
if(fexists("saves/[copytext(src.ckey,1,2)]/[src.ckey].sav"))
var/savefile/F = new/savefile("saves/[copytext(src.ckey,1,2)]/[src.ckey].sav")
var/mob/player/p = null
F >> p
p.key = client.key
del src
else
client.mob = new/mob/player()
return 1
Okay... So you ignored my request and copied/pasted about 30 lines from my tutorial intended as an example. Great. Now what?

To be clear, I'm really not trying to be mean here, but each and every time we interact about a problem on this subforum, it becomes increasingly clear to me that you genuinely do not read what we type. Nor do you try to understand code before assuming it is a magic pill that will fix all your problems and pasting it into your project. I'm trying to help you. Give me the respect of making an effort, and we don't have to go through the entire military training instructor routine.

Did you read the bits about saving icon, overlay, and icon_state variables, and why you should never, ever, ever do it?

Of particular importance is in regard to the neversave bootstrap I laid into my system. Did you understand the underlying reason why I did all of that?
In response to Ter13
Yeah. I didn't get those yet. I must study these more.
In response to TheDarkChakra
TheDarkChakra wrote:
Yeah. I didn't get those yet. I must study these more.

There's no studying. The code is commented aggressively, and each step walks you through why I did it. If it's confusing, please quote the parts that are confusing so I can fix them, because these vague responses just make it harder for me to help you.
It seems now I got rid of some of the problems but when I load it keeps taking me to the Login() screen.
Your problem lay awash in a sea of missing context.
Here are the codes:

mob/player/proc/save()
if(usr.phase1||usr.phase2||usr.phase3||usr.phase4||usr.inturny)
usr << "You can't save here!"
return
var/savefile/F = new/savefile("saves/[src.ckey].sav")
F << src
F<<src.x
F<<src.y
F<<src.z

mob/var/numbericon
mob/player/Login()
world << sound('bell.ogg')
// if(src.key!="Dariuc" && src.key!="TheDarkChakra" && src.key!="Sers000" && src.key!="FallenPhenix" && src.key!="BBDragoon" && src.key!="Neimo" && src.key!="Konlet")
// src << "Sorry, the game is under testing right now so I can't have you play now."
// del src
updateScoreboard(src)
world << "[src.key] key has logged in"
src << "Hello. I am TheDarkChakra. I created this game. I would appreciate it if you told me on the forums or by emailing me at ssunlimitedssu@yahoo.com if I should make this into a full game or not. If you have any comments, suggestions, or complains please contact me through there. Please talk to Wing(the guy in white) to find out how to play."
src.invisibility=0
if(src.key=="TheDarkChakra"||src.key=="Sers000"||src.key=="Dariuc")
src.verbs+=typesof(/mob/admin/verb/)
src.verbs+=typesof(/mob/trainning/verb)
src<<"[src] you are an admin"
if(src.key=="Yut Put"||src.key=="EmpirezTeam" || src.key=="Vrocaan"||src.key=="Dr.Penguin"|| src.key=="Jeneric"||src.key=="Falcon lazorz")
alert("You trolls can't play this game")
del src
var/FileName="Players/[ckey(src.key)].sav"
if(fexists(FileName))
var/savefile/F=new(FileName)
F["Banned"]>>src.banned
if(src.banned)
alert("You are banned")
del src
// BEGIN
/* if(fexists("Players/[ckey(src.key)].sav"))
var/savefile/F =new("Players/[ckey(src.key)].sav")
F["played"] >> src.playedandsaved*/


// BEGINTWO
if(fexists(new/savefile("saves/[src.ckey].sav")))
var/savefile/F=new/savefile("saves/[src.ckey].sav")
F>>src
return ..()
else

// var/choose=input("New, Load or Delete Character") in list ("New", "Load", "Delete")
// if(choose=="New")
NAME
var/namee=input("Enter a name") as text
if(namee=="")
alert("Choose a name!")
goto NAME
else src.name=namee
// if(src.playedandsaved==1)
// alert("You already have a filename. Delete your save file.")
//goto BEGINTWO
//else
var/nen_typei=pick("Enhancement", "Transmutation", "Emission", "Conjuration", "Manipulation", "Specialization")
src.hp=rand(10,150)
if(src.hp<25)
src << "You were born with low hp"
else if(src.hp>=25 && src.hp<50)
src << "You were born with an average hp"
else if(src.hp>50 && src.hp<100)
src << "You were born with an above average hp"
else if(src.hp>100)
src << "You were born with an extraordinary amount of hp"
src.max_hp=src.hp//torso
src.nen_power=rand(100,1000)//power of aura(might change that)
src.max_nen_power=src.nen_power
nen_type=nen_typei
if(nen_type=="Enhancement")
nen_enhancer=100
nen_emitter=80
nen_transmuter=80
nen_conjurer=60
nen_specialization=0
nen_manipulator=60
else if(nen_type=="Transmutation")
nen_enhancer=80
nen_emitter=80
nen_transmuter=100
nen_conjurer=80
nen_specialization=0
nen_manipulator=40
else if(nen_type=="Emission")
nen_enhancer=80
nen_emitter=100
nen_transmuter=60
nen_conjurer=40
nen_specialization=0
nen_manipulator=80
else if(nen_type=="Conjuration")
nen_enhancer=60
nen_emitter=40
nen_transmuter=80
nen_conjurer=100
nen_specialization=0
nen_manipulator=60
else if(nen_type=="Manipulation")
nen_enhancer=60
nen_emitter=80
nen_transmuter=40
nen_conjurer=60
nen_specialization=0
nen_manipulator=100
else if(nen_type=="Specialization")
nen_enhancer=40
nen_emitter=60
nen_transmuter=60
nen_conjurer=80
nen_specialization=100
nen_manipulator=80
head=25 //might change as in in ten always
arms=25
torso=25
legs=25
str=rand(1, 150)//arms
if(str<=5)
src << "You were born really weak."
else if(str<=15 && str>5)
src << "You were born weak."
else if(str>15 && str<=30)
src << "You have a fair amount of strength."
else if(str>30 && str<=50)
src << "You have an average amount of strength."
else if(str>50 && str<=75)
src << "You have a good amount of strength."
else if(str>75 && str<=100)
src << "You were born strong."
else if(str>100 && str<=150)
src << "You were born very strong."
def=rand(1,150)//torso
if(def<=5)
src << "You were born with really weak defenses."
else if(def<=15 && def>5)
src << "You were born with weak defenses."
else if(def>15 && def<=30)
src << "You have a fair amount of defense."
else if(def>30 && def<=50)
src << "You have an average amount of defense."
else if(def>50 && def<=75)
src << "You have a good amount of defense."
else if(def>75 && def<=100)
src << "You were born with a very good defense."
else if(def>100 && def<=150)
src << "You were born with an extraordinary amount of defense."
inten=0
talent=1
src << "You were born with [usr.talent] out of 10 talent."
inzetsu=0
ingyo=0
vow=1
emotion=1
item_str=0
inken=0
armsnen=0
legsnen=0
torsonen=0
headnen=0
overallnen=0
caughtjail=0
stamina=rand(10,200)//run, legs
maxstamina=src.stamina
inen=0
equippeditem=null
equippediteminin=0
wearing_arms=0
wearing_legs=0
wearing_torso=0
didsquats=0
didpushups=0
didsitups=0
intrainning=0
talkedexam=0
papertest=FALSE
treadmill=FALSE
punchingbag=FALSE
passed=0
makingcharacter=1
ko=0
knownen=0
nonhuman=0
inren=0
lvlstr=0//arms
lvldef=0//torso
lvlsta=0//legs
lvlhp=0//torso
banned=0
src.loc=locate(45,32,6)
src << sound(null)
src << sound('waiting.wma',1)
speed=rand(10,100)
var/obj/weapon/randitem=pick("Shuriken","Dagger","Knife","Scythe","Bat", "Bow")
if(randitem=="Shuriken")
src.contents+=new/obj/weapon/shuriken
if(randitem=="Dagger")
src.contents+=new/obj/weapon/dagger
if(randitem=="Knife")
src.contents+=new/obj/weapon/knife
if(randitem=="Scythe")
src.contents+=new/obj/weapon/scythe
if(randitem=="Bat")
src.contents+=new/obj/weapon/bat
if(randitem=="Bow")
src.contents+=new/obj/weapon/bow
src << "You got [randitem]!"
var/obj/weapon/we=locate() in src.contents
src.s_atk=we.name
src.whichweapon=we.name
src.w=we
alert("Choose your icon")
By load, do you mean you call a procedure on some screen to load a character, or do you just kind of ... load into the character, when you login to the server?
I want it to automatically load the character when I login and I do it by testing if(fexist etc... but the test always fails so it makes me always create a new character. Then I try to load using a verb and it takes me to login screen again.
if(fexists(new/savefile("saves/[src.ckey].sav")))


Review part #1 section 1: Getting Started.

if(usr.phase1||usr.phase2||usr.phase3||usr.phase4||usr.inturny)


usr in proc.

if(src.key=="TheDarkChakra"...)
if(src.key=="Yut Put"...)


Redundant logic, integrated design.

if(fexists(FileName))
var/savefile/F=new(FileName)
F["Banned"]>>src.banned
if(src.banned)
alert("You are banned")
del src


Incorrectly embedded code.

    if(fexists(FileName))
if(fexists(new/savefile("saves/[src.ckey].sav")))


Redundant logic.

F<<src.x
F<<src.y
F<<src.z


Incorrectly embedded code.

        if(randitem=="Shuriken")
src.contents+=new/obj/weapon/shuriken
if(randitem=="Dagger")
src.contents+=new/obj/weapon/dagger
if(randitem=="Knife")
src.contents+=new/obj/weapon/knife
if(randitem=="Scythe")
src.contents+=new/obj/weapon/scythe
if(randitem=="Bat")
src.contents+=new/obj/weapon/bat
if(randitem=="Bow")
src.contents+=new/obj/weapon/bow


Redundant logic.

var/obj/weapon/we=locate() in src.contents
src.s_atk=we.name
src.whichweapon=we.name
src.w=we


redundant logic.

        inzetsu=0
ingyo=0
vow=1
emotion=1
item_str=0
inken=0
armsnen=0
legsnen=0
torsonen=0
headnen=0
overallnen=0
caughtjail=0
stamina=rand(10,200)//run, legs
maxstamina=src.stamina
inen=0
equippeditem=null
equippediteminin=0
wearing_arms=0
wearing_legs=0
wearing_torso=0
didsquats=0
didpushups=0
didsitups=0
intrainning=0
talkedexam=0
papertest=FALSE
treadmill=FALSE
punchingbag=FALSE
passed=0
makingcharacter=1
ko=0
knownen=0
nonhuman=0
inren=0
lvlstr=0//arms
lvldef=0//torso
lvlsta=0//legs
lvlhp=0//torso
banned=0


Redundant logic.

if(def<=5)
src << "You were born with really weak defenses."
else if(def<=15 && def>5)
src << "You were born with weak defenses."
else if(def>15 && def<=30)
src << "You have a fair amount of defense."
else if(def>30 && def<=50)
src << "You have an average amount of defense."
else if(def>50 && def<=75)
src << "You have a good amount of defense."
else if(def>75 && def<=100)
src << "You were born with a very good defense."
else if(def>100 && def<=150)
src << "You were born with an extraordinary amount of defense."


Redundant logic.

        if(str<=5)
src << "You were born really weak."
else if(str<=15 && str>5)
src << "You were born weak."
else if(str>15 && str<=30)
src << "You have a fair amount of strength."
else if(str>30 && str<=50)
src << "You have an average amount of strength."
else if(str>50 && str<=75)
src << "You have a good amount of strength."
else if(str>75 && str<=100)
src << "You were born strong."
else if(str>100 && str<=150)
src << "You were born very strong."


Redundant logic.

        if(nen_type=="Enhancement")
nen_enhancer=100
nen_emitter=80
nen_transmuter=80
nen_conjurer=60
nen_specialization=0
nen_manipulator=60
else if(nen_type=="Transmutation")
nen_enhancer=80
nen_emitter=80
nen_transmuter=100
nen_conjurer=80
nen_specialization=0
nen_manipulator=40
else if(nen_type=="Emission")
nen_enhancer=80
nen_emitter=100
nen_transmuter=60
nen_conjurer=40
nen_specialization=0
nen_manipulator=80
else if(nen_type=="Conjuration")
nen_enhancer=60
nen_emitter=40
nen_transmuter=80
nen_conjurer=100
nen_specialization=0
nen_manipulator=60
else if(nen_type=="Manipulation")
nen_enhancer=60
nen_emitter=80
nen_transmuter=40
nen_conjurer=60
nen_specialization=0
nen_manipulator=100
else if(nen_type=="Specialization")
nen_enhancer=40
nen_emitter=60
nen_transmuter=60
nen_conjurer=80
nen_specialization=100
nen_manipulator=80


Redundant logic.

goto NAME

goto albeit not that bad of one.

        if(src.hp<25)
src << "You were born with low hp"
else if(src.hp>=25 && src.hp<50)
src << "You were born with an average hp"
else if(src.hp>50 && src.hp<100)
src << "You were born with an above average hp"
else if(src.hp>100)
src << "You were born with an extraordinary amount of hp"


Redundant logic.


In the interest of time, I'm going to rehash this for you quickly so we can at least address the core issue, and ignore the rest of the stuff here. Give me a bit with another reply.
Hmm...
This is not intended to compile, much less actually work. It's meant to show you the way you should be moving toward.

You are going to have to adjust significant portions of your code to comply with basic rules of sanity, but I've cleaned up the majority of your major flaws and made it at least a *little* easier on the stomach.

Pay attention to my comments. They will explain why I did what I did, and be very wary of what they warn against.

Per usual, specific questions will be answered with specific answers. Vague questions without context will not get either of us anywhere we want to go.

//you should never have to touch any of this:

//modify standard saving/loading behavior a bit for all objects
datum
//set up the new save behavior.
Write(var/savefile/F,var/list/neversave=null)
//make sure neversave has been initialized as a list with contents
if(neversave!=null&&istype(neversave,/list)&&neversave.len>=1)
//define i for storing initial variables
var/i
//run through neversave one time
for(var/v in neversave)
//if the variable is not savable (tmp/const/global/static) just remove it,
//as it will never save anyway.
if(!issaved(src.vars[v]))
neversave.Remove(v)
else
//get the initial value of the variable.
i = initial(src.vars[v])
//now, check if the variable would normally save.
if(i!=src.vars[v])
//if it has been changed since runtime, store the current value in neversave.
neversave[v] = src.vars[v]
//and set the variable to default so it won't save.
src.vars[v] = i
else
//remove the variable as it won't save because it's the default value.
neversave.Remove(v)
//call the default behavior.
. = ..(F)
//go back through everything and set it to whatever it should be.
for(var/v in neversave)
src.vars[v] = neversave[v]
//return whatever default would have returned.
return.
else
//fall back to normal behavior if neversave is not set up.
return ..(F)

//set up the new load behavior.
Read(var/savefile/F,var/list/neversave=null)
//check if neversave has been initialized as a list with contents
if(neversave!=null&&istype(neversave,/list)&&neversave.len>=1)
//run through neversave once
for(var/v in neversave)
//if the variable shouldn't be saved (tmp/const/global/static)
if(!issaved(src.vars[v]))
//remove the variable
neversave.Remove(v)
else
//store the current value.
neversave[v] = src.vars[v]
//call the default behavior.
. = ..(F)
//run back through the list
for(var/v in neversave)
//reset the values that may have been overwritten
src.vars[v] = neversave[v]
//return the default return.
return .
else
//fall back to normal behavior if neversave is not set up.
return ..(F)
proc
NeverSave(var/list/L)
return L
atom
NeverSave(var/list/L)
//add what we don't want to save
L.Add("icon","icon_state","overlays","underlays")
return ..(L) //return whatever the parent type does.
Write(var/savefile/F,var/list/neversave=null)
//if we don't have any defined nonsavables yet.
if(neversave==null)
neversave = src.NeverSave(list())

//we want to get a local copy of the overlays and underlays
//because you can't just assign a list to overlays or underlays
//at runtime. Things get messy.
var/list/ol
var/list/ul

if(src.overlays!=initial(src.overlays)&&neversave.Find("overlays"))
ol = src.overlays.Copy(1,0)
src.overlays = initial(src.overlays)
neversave.Remove("overlays")
if(src.underlays!=initial(src.underlays)&&neversave.Find("underlays"))
ul = src.underlays.Copy(1,0)
src.underlays = initial(src.underlays)
neversave.Remove("underlays")

. = ..(F,neversave)

if(ol!=null&&ol.len)
src.overlays.Add(ol)
if(ul!=null&&ul.len)
src.underlays.Add(ul)
Read(var/savefile/F,var/list/neversave=null)
if(neversave==null)
neversave = src.NeverSave(list())
return ..(F,neversave)
movable
NeverSave(var/list/L)
L.Add("screen_loc")
return ..(L)
mob
player
Write(var/savefile/F,var/list/neversave=null)
. = ..(F,neversave)
var/ocd = F.cd
F.cd = "location"
F << src.x
F << src.y
F << src.z
F.cd = ocd
return .
Read(var/savefile/F,var/list/neversave=null)
. = ..(F,neversave)
var/ocd = F.cd
F.cd = "location"
F >> src.x
F >> src.y
F >> src.z
F.cd = ocd
return .



//this is all there is to saving:

mob/player/proc/save()
if(src.phase1||src.phase2||src.phase3||src.phase4||src.inturny)
src << "You can't save here!"
return
var/savefile/F = new/savefile("saves/[src.ckey].sav")
F << src

world
mob = /mob/logging //separate your character creation behavior so you can body-switch without additional effort.
New()
. = ..()
load_testers()

var
testing_mode = 0
list
testers = list()
admins = list("TheDarkChakra","Sers000","Dariuc")
bans = list("Yut Put","EmpirezTeam","Vrocaan","Dr.Penguin","Jeneric","Falcon lazorz")

//a way to abstract code without slowing down your code.
//probably best to not actually make your own versions of these, because overuse of this can make debugging code problematic to the uninitiated.

#define is_tester(x) ((x.ckey) in testers)
#define is_admin(x) ((x.key) in admins)
#define is_banned(x) ((x.key) in bans)

//a more robust way to handle testing mode:
//code bans and admins should be handled this way as well, ideally, but you can leave hard-coded bans, testers, and admins in if you'd like, just to keep control of things.

proc
load_testers()
var/savefile/f = new/savefile("testers.sav")
while(!f.eof)
f >> .
testers += f
save_testers()
if(fexists("testers.sav"))
fdel("testers.sav")
var/savefile/f = new/savefile("testers.sav")
for(var/v in testers)
f << v

add_tester(var/new_person)
testers += ckey(new_person)
save_testers()

remove_tester(var/person)
testers -= person
if(testing_mode)
for(var/client/c in world)
if(c.ckey==person)
del c
save_testers()

enter_testmode()
testing_mode = 1
for(var/client/c in world)
if(!is_tester(c))
del c

exit_testmode()
testing_mode = 0

propername(var/name)
if(length(name)>2)
return 0
return 1

client/New()
//checking key status should only be done on key connect or admin suspension/ban add.
if(is_banned(src))
alert("You trolls can't play this game")
del src
else if(is_admin(src))
//admin verbs should belong to the client. Not the mob.
src.verbs+=typesof(/mob/admin/verb/)
src.verbs+=typesof(/mob/trainning/verb)
src<<"[src] you are an admin"
else if(testing_mode&&!is_tester(src))
del src
. = ..()


//as long as all of these variables are not const, tmp or global, they will be saved automatically by DM's internal saving system.
//These variables should NOT be under /mob, though if you have NPCs, you may wish for a /mob/combatant type that NPCs share combat stats with.
//DO NOT define all root behavior under /mob. This will help you avoid usr abuse. Do not simply replace usr. with usr:. It's slower. Do it right.

mob/player/var
head=25
arms=25
torso=25
legs=25
inten = 0
talent = 1
inzetsu = 0
ingyo = 0
vow = 1
emotion = 1
item_str = 0
inken = 0
armsnen = 0
legsnen = 0
torsonen = 0
headnen = 0
overallnen = 0
caughtjail = 0
inen=0
equippeditem=null
equippediteminin=0
wearing_arms=0
wearing_legs=0
wearing_torso=0
didsquats=0
didpushups=0
didsitups=0
intrainning=0
talkedexam=0
papertest=FALSE
treadmill=FALSE
punchingbag=FALSE
passed=0
makingcharacter=1
ko=0
knownen=0
nonhuman=0
inren=0
lvlstr=0//arms
lvldef=0//torso
lvlsta=0//legs
lvlhp=0//torso
banned=0





//fixed multiple issues, including redundancy and possible spam by banned users triggering the bell sound repeatedly to DDoS annoy your game.
mob/logging/Login()
world << sound('bell.ogg')
updateScoreboard(src)
world << "[src.key] key has logged in"
src << "Hello. I am TheDarkChakra. I created this game. I would appreciate it if you told me on the forums or by emailing me at ssunlimitedssu@yahoo.com if I should make this into a full game or not. If you have any comments, suggestions, or complains please contact me through there. Please talk to Wing(the guy in white) to find out how to play."
src.invisibility=0

var/FileName="Players/[ckey(src.key)].sav"
if(fexists(FileName))
var/savefile/F=new(FileName)
var/mob/player/p = null
F>>p
return ..()
else
src.CharCreation()

mob/logging/proc/CharCreation()
//the character should never initialize itself. Best to leave the client out of the character until the character is prepared.
var/mob/player/p = new/mob/player()

//removed goto. Included possible dummy while loop instead, much cleaner. Easier to understand.
//abstracted what is an proper character name to a function for ease of reading and later expansion of forbidden names, etc.
p.name = input("Enter a name") as text
while(!propername(p.name))
alert("Name was invalid!")
p.name = input("Enter a name") as text

p.nen_type = pick("Enhancement", "Transmutation", "Emission", "Conjuration", "Manipulation", "Specialization")

p.hp=rand(10,150)
//better way of comparing the value to an outcome.
if(p.hp>100)
src << "You were born with an extraordinary amount of hp"
else if(p.hp>50)
src << "You were born with an above average hp"
else if(p.hp>=25)
src << "You were born with an average hp"
else
src << "You were born with low hp"

p.max_hp = p.hp
p.nen_power = rand(100,1000)
p.max_nen_power = p.nen_power

//removed redundant if-chain, using switch. Much faster.
//this could be cleaner, but this is the fastest way to handle it, thus is ideal.
switch(p.nen_type)
if("Enhancement")
p.nen_enhancer=100
p.nen_emitter=80
p.nen_transmuter=80
p.nen_conjurer=60
p.nen_specialization=0
p.nen_manipulator=60
if("Transmutation")
p.nen_enhancer=80
p.nen_emitter=80
p.nen_transmuter=100
p.nen_conjurer=80
p.nen_specialization=0
p.nen_manipulator=40
if("Emission")
p.nen_enhancer=80
p.nen_emitter=100
p.nen_transmuter=60
p.nen_conjurer=40
p.nen_specialization=0
p.nen_manipulator=80
if("Conjuration")
p.nen_enhancer=60
p.nen_emitter=40
p.nen_transmuter=80
p.nen_conjurer=100
p.nen_specialization=0
p.nen_manipulator=60
if("Manipulation")
p.nen_enhancer=60
p.nen_emitter=80
p.nen_transmuter=40
p.nen_conjurer=60
p.nen_specialization=0
p.nen_manipulator=100
if("Specialization")
p.nen_enhancer=40
p.nen_emitter=60
p.nen_transmuter=60
p.nen_conjurer=80
p.nen_specialization=100
p.nen_manipulator=80

p.str=rand(1, 150)
//reversed the logic
if(p.str>100)
src << "You were born very strong."
else if(p.str>75)
src << "You were born strong."
else if(p.str>50)
src << "You have a good amount of strength."
else if(p.str>30)
src << "You have an average amount of strength."
else if(p.str>15)
src << "You have a fair amount of strength."
else if(p.str>5)
src << "You were born weak."
else
src << "You were born really weak."

p.def=rand(1,150)//torso
//reversed the logic
if(p.def>100)
src << "You were born with an extraordinary amount of defense."
else if(p.def>75)
src << "You were born with a very good defense."
else if(p.def>50)
src << "You have a good amount of defense."
else if(p.def>30)
src << "You have an average amount of defense."
else if(p.def>15)
src << "You have a fair amount of defense."
else if(p.def>5)
src << "You were born with weak defenses."
else
src << "You were born with really weak defenses."

//removed redundant variables that should be default-initialized in the prototype definition.

p.stamina = rand(10,200)
p.maxstamina = p.stamina

p.speed=rand(10,100)

p.loc = locate(45,32,6) //you should probably avoid doing this. Call Move() where you can, in order to take advantage of a more event-oriented structure.

src << sound(null) //pretty sure this is redundant.
src << sound('waiting.wma',1)

//better way of handling picking between types and adding them to the inventory.
var/obj/item/weapon/w = new pick(/obj/weapon/shuriken,/obj/weapon/dagger,/obj/weapon/knife,/obj/weapon/scythe,/obj/weapon/bat,/obj/weapon/bow)
src << "You got [w.name]!"
p.contents += w
//forcing an item to be equipped should all be located in the item's code, not in the login code.
w.equip(p)

//switch to the newly created character.
p.key = src.client.key
del src
So I can't just use what you wrote for me here?
In response to TheDarkChakra
TheDarkChakra wrote:
So I can't just use what you wrote for me here?

It's not going to compile because it's not intended to. It's meant to be an example that you are supposed to learn from.

Parts of it will work fine without modification. The Read/Write overrides should be just fine as they are. You don't need to tell it to save anything else as long as you mark your variables as tmp/global/const correctly.

Most of the login code will work fine as well, provided you restructure your project a bit for some of the changes it necessitates. Lastly, I've stripped out some bits of code that I found offensive, like the input() based menu system for New/Load/Delete... Which is a trend that needed to die in 2003.

Then there's the issue of your admin commands being defined entirely wrong. Admin commands should belong to the client, not the mob. This prevents mob-switching/saving from accidentally granting powers to people that shouldn't have them.

You should know me by now, TDC: I don't tend to hand out copypasta code, because I actually want you to learn something. I'd actually like to see you, and everybody else around here improve. It's why I'm still here. That, and BYOND's limitations are quite fun to try to circumvent.
But I can't understand this yet.
In response to TheDarkChakra
TheDarkChakra wrote:
But I can't understand this yet.

Don't/won't. Can't is defeatist.


Don't try to digest it all at once. The saving bit is done for you. Pick out a specific detail that you don't understand, and I'll be more than willing to discuss it with you. Until you do that, there's nothing I can do to help you further.

Just saying: "I don't get it." isn't going to help you. You're in your mid-twenties. I'm in my mid-twenties. I'm not especially gifted. You know how I learned? Lexy, Lummox, and Skysaw. Among others, but those three were tough teachers.

Don't throw your hands up in defeat. You want to do this. You want to get it. Take a few lines at a time and try to understand it. If you have questions, ask them, but be specific. If you can write code, you can read it. Just because you don't understand my patterns or my reasoning doesn't mean you don't get the code. Why is a valid question. How is sitting right in front of you.
OMG! I plugged in that code and once AGAIN my icon is blank invisible! Maybe the error is somewhere else...
In response to TheDarkChakra
TheDarkChakra wrote:
OMG! I plugged in that code and once AGAIN my icon is blank invisible! Maybe the error is somewhere else...

You do realize that my code prevents the icon and icon_state from saving, right? (And I really strongly doubt you managed to plug that code in less than 19 minutes after you said you couldn't, and still get it to compile, much less run without potential errors.)

I explicitly outlined that in three separate posts in this thread, in both of my tutorials' parts, and the code blatantly lists icon and icon_state as parts of NeverSave, right? And you realize there's a good reason it does that, right?

You are setting the icon during character creation, am I right? In a part of your login proc you never actually showed us?

I promise you I know exactly what you are doing wrong, but you completely refuse to ask me actual questions, and instead insist on beating your head against a wall of your own construction.
Page: 1 2 3