ID:850558
 
(See the best response by Raimo.)
Code:


Problem description:

Hey it's me again and I'm having problems with getting someone to teleport to the Title screen.
I'm using a code like this

mob/Login()
src.loc = locate(1,9,9)
src.client.view=8
It's not working well at all, could someone help me?
Best response
Are you sure you didn't overwrite the Login() proc somewhere else? Because then you would need to place the parent. Like this:
mob/Login()
src.loc = locate(1,9,9)
src.client.view = 8
..()
What do you mean? Overwrite as in duplicate it or...idk
The Login() proc is built-in. Means that when you code it again, you overwrite it. You can do this in several files, meaning several times in your environment. But if you do that, you need to call the parent which is '..()', to make all of those parts of the Login() proc work together.
So you're saying, that I should go through and see if I have anymore then Re write it?
No, what I mean is, do you have anywhere else, in all of your code files, overwritten the built-in Login() proc like you did above?
I only have it in one place, and no where else
I would write the parent like I showed at my top most post, it's a good habit and will prevent hassle in the future. Try the parent and tell me if it's fixed.
No it's still putting me on 0,0,0
You have to include ..() at the end of a proc you call multiple times to create a chain.

Login()
world << some code here
..()

//goes to

Login()
world << some other code
//..()
/*Code goes down all the files in the same order they
are in the folder listing. If a proc in the middle of
this group doesn't have one of these- yet it is
called later on your proc-chain won't work.*/


//goes to

Login()
world << other code again
..()


TL;DR: ..()



Not to mention you don't have anything indented so you could just be doing that wrong.
That makes no sense
Post your login proc in code tags as is - straight from your code. If Raimo's code didn't work you're doing something wrong and not giving enough information.

mob/Login()
src.loc = locate(1,9,9)
src.client.view = 8
..()

Ok, this is how i'm puutting it, nothing works.
The Z coordinate on your map probably isn't 9... Just a guess
Just curious, does your snippet have any indentions?
Maybe put ..() as the very first line just after Login()? It's worth a shot.
In response to Killalongjohns (#13)
Killalongjohns wrote:
The Z coordinate on your map probably isn't 9... Just a guess

LB :D, and I tried that doesn't work
In response to Killalongjohns (#13)
Snippet? And I tried that stoneman, no luck
Are you getting a DM error, a runtime error or does it just not work?
It's just not working, what If I tried a pop up instead of a screen?
Page: 1 2