ID:158964
 
Just wanted to know the relation --
Crrect me if m wrong

client / New --> mob/Login --> Game Play -->mob/Logout --> client /Del

now client new returns a mob.
check this out
mob/Logout()
src.Save()
.() // this is logout proc
..() // this is client del proc

when one client is disconected from mob - it will get deleted bcz of the "..()" but if its ".()" it will only disconect the mob but the client stays alive ..
Am I correct ..?
what if i want to like switch savs / i should only use .()
right?
You don't understand how parent and child procs work, and so you don't understand ..(). ..() is used to call a parent proc; and a parent proc isn't an entirely different proc (i.e. it's always one with the same name). Logout()'s parent proc can never be Del()... Rather, it will be Logout(), or nothing:
mob
Logout()
src << "/mob/Logout()"
..() //this normally does nothing
player/Logout()
src << "/mob/player/Logout()"
..() //this calls /mob/Logout() above


You've also got .() very wrongly - that just calls the current proc, and is pretty much a shortcut. The following 2 procs are equivalent:
proc
Proc1()
.()
proc
Proc1()
Proc1()

And, of course, doing such a thing will cause a crippling infinite loop (until the proc crashes), and it's the same in your Logout() example.

Getenks wrote:
Just wanted to know the relation --
Crrect me if m wrong

You don't really understand how it precisely works, and the order for logging out is a little different. Here's how the procs are executed (they just end up being called by one another, pretty much, no parent proc calls involved):

When a player logs in: client/New() is called, which normally logs the player into a mob, which calls Login() on that mob.
When a player logs out: client/Del() is called, which normally calls Logout() on the player's mob. Afterward, the client is deleted.

(I said "normally" because it's of course possible for developer overrides to manipulate the behavior)
In response to Kaioken
thnx
In response to Kaioken
I Observed a Problem // While Single Player Mode (Ctrl + R) in DM or Run the Game using DM (I hope u understand)

When I log in - then after I logout
Then When again I login // I find my mob in the title screen; with the same icon , stats and everything!!
In response to Getenks
You're saving someone who's at the titlescreen. Which is baaaaad.
In response to Mysame
dude thats not it
.. I m not saving at title screen..
Cause i know i m not ; it got to do something else
Like Deleting the mob or something

Besides the mob comes to the title screen without clicking Load Button.
In response to Getenks
Well then, delete the mob on Logout().
In response to Getenks
This is essentially what happens if the world already contains a mob with your key when you join the game. Sometimes there's some wonkiness when restarting, but most likely it's an issue with saving your mob for some reason.
In response to Garthor
But Dude the world is delled/ killed
I mean after closing it ; then also it happens ; guess something to do with the .lk files. Bcz I dont give time for the .lk files to get deleted ; so it uses the same old expired lk files ; i guess ..