ID:143377
 
Code:
obj/Waterfall
Entered(mob/A)
if(istype(A,/mob))
A<<"ZOMG SECRET PASSAGE!"
A.loc=locate(1,1,1)
else del(A)


Problem description:

Problem is that this just doesnt work, I used Enter(mob/A) too, but neither works, whats the problem here?
Dragonn wrote:
Code:
> obj/Waterfall
> Entered(mob/A)
> if(istype(A,/mob))
> usr<<"ZOMG SECRET PASSAGE!"
> usr.loc=locate(1,1,1)
> else del(A)
>

Problem description:

Problem is that this just doesnt work, I used Enter(mob/A) too, but neither works, whats the problem here?


maybe try changing the two usr's to A? >.>
In response to Narmanb
Narmanb wrote:
Dragonn wrote:
Code:
> > obj/Waterfall
> > Entered(mob/A)
> > if(istype(A,/mob))
> > usr<<"ZOMG SECRET PASSAGE!"
> > usr.loc=locate(1,1,1)
> > else del(A)
> >

Problem description:

Problem is that this just doesnt work, I used Enter(mob/A) too, but neither works, whats the problem here?


maybe try changing the two usr's to A? >.>

Oh, thats a typo, it is A in the real code, I just posted this simplified example here. I'll modify my original post so people dont think thats the problem
Dragonn wrote:
Code:
> obj/Waterfall
> Entered(mob/A)
> if(istype(A,/mob))
> usr<<"ZOMG SECRET PASSAGE!"
> usr.loc=locate(1,1,1)
> else del(A)
>

Problem description:

Problem is that this just doesnt work, I used Enter(mob/A) too, but neither works, whats the problem here?

Doesnt sound like something you'd say, Couldn't you just copy your universal teleporter to the same thing then modify?
In response to Fusioneko
Doesnt sound like something you'd say, Couldn't you just copy your universal teleporter to the same thing then modify?

Nah this is for entering the Goku's CC Ship Neko... But for some reason it doesnt work
In response to Dragonn
Dragonn wrote:
Doesnt sound like something you'd say, Couldn't you just copy your universal teleporter to the same thing then modify?

Nah this is for entering the Goku's CC Ship Neko... But for some reason it doesnt work

Oh LOL! Well you surely got pwnt on the obvious, But Im sure alot of people make that mistake, forggeting to Tag the Object type putting usr instead of A or M or defined for the mob.
In response to Fusioneko
Actually I looked in the real code and its not using usr, it does use A, so thats not the actual problem I just checked...

I posted that simplified code here and accidently put usr just in that.

I want to make it so you can just bump into it to enter it, but if I cant get it solved Im gonna either have to make you enter it when you click it or right click and hit a verb, and thats pretty lame to me when you could just bump it
In response to Dragonn
Dragonn wrote:
Actually I looked in the real code and its not using usr, it does use A, so thats not the actual problem I just checked...

I posted that simplified code here and accidently put usr just in that.

LEt me have a look at it. ;)
In response to Fusioneko
Alright, here it is exactly...

obj/Gokus_CC_Ship
New()
var/image/A=image(icon='Goku Ship.dmi',icon_state="1")
var/image/B=image(icon='Goku Ship.dmi',icon_state="2")
var/image/C=image(icon='Goku Ship.dmi',icon_state="3")
var/image/D=image(icon='Goku Ship.dmi',icon_state="4")
A.pixel_y+=16
A.pixel_x-=16
B.pixel_y+=16
B.pixel_x+=16
C.pixel_y-=16
C.pixel_x-=16
D.pixel_y-=16
D.pixel_x+=16
overlays+=A
overlays+=B
overlays+=C
overlays+=D
Entered(mob/A)
if(istype(A,/mob))
A<<"Welcome Goku."
A.loc=locate(64,54,37)
else del(A)
In response to Dragonn

Err, try using Move() instead? >.>
In response to Narmanb
Narmanb wrote:
Err, try using Move() instead? >.>

I dont understand how to use Move() for this... You mean mob/Move()? I dont see what that has to do with it <_<?
In response to Dragonn

Move(locate(x, y, z))
In response to Narmanb
Narmanb wrote:
Move(locate(x, y, z))

Heh heh still not getting it... I looked up client.Move() and Move() (movable atom) but I dont get how to use it in this scenario...
In response to Dragonn
Have a simple proc

/mob/proc/teleport(X as num, Y as num, Z as num)
if (density)
density = 0
Move(locate(X, Y, Z))
density = 1
else
Move(locate(X, Y, Z))

and you would call it by putting
A.teleport(1,1,1)


Although this might be a waste of time, it might work for you
Dragonn wrote:
Code:
> obj/Waterfall
> Entered(mob/A)
> if(istype(A,/mob))
> A<<"ZOMG SECRET PASSAGE!"
> A.loc=locate(1,1,1)
> else del(A)
>

Problem description:

Problem is that this just doesnt work, I used Enter(mob/A) too, but neither works, whats the problem here?

Try a turf. Enter and Entered work for when something enters the contents list. Walking on top of it isn't the contents list. Walking over a turf puts you in its contents. There's the major difference between objs and turfs.
In response to Kaiochao2536
I'm not sure if this is 100% true, but I remember reading something about not using a specified atom as a parameter.
obj/Waterfall
Entered(atom/A)
if(istype(A,/mob))
var/mob/M=A //typecast
M<<"ZOMG SECRET PASSAGE!"
M.loc=locate(1,1,1)
else del(A)//you might want to change this since if a ki blast was used, it would be deleted when entering this area and it would look like something invisible is absorbing it. This is just a thought, you can ignore it.
Dragonn wrote:
Code:
> obj/Waterfall
> Entered(mob/A)
> if(istype(A,/mob))
> A<<"ZOMG SECRET PASSAGE!"
> A.loc=locate(1,1,1)
> else del(A)
>

Problem description:

Problem is that this just doesnt work, I used Enter(mob/A) too, but neither works, whats the problem here?

Correct me if I'm wrong but I do believe that you need a return in there to make it work. For example.
obj/Waterfall
Entered(mob/A)
if(istype(A,/mob))
A<<"ZOMG SECRET PASSAGE!"
A.loc=locate(1,1,1)
else del(A)
return 1


The same thing goes for Enter() if I'm not mistaken.
In response to The Naked Ninja
Oh yea I just remembered that when I didn't use ..(), the area doesn't let you in.
EDIT: I just noticed that it was an obj, why not make it dense and use the mob/Bump? If you want it to occur after steeping on, change the location to the teleporter and use sleep or spawn and then change the location.