send gEgo:onControl()

Wilco23 Hey guys I need some help! I've followed the tutorial, and I'm currently scripting my own game but I'm stuck. I can't seem to be able to get the control colour to work so that my character will transport to the next room when he is on the control colour. I've used green as my control colour, and I'm sure there's nothing wrong with my picture. It must be in my script.
Any help muchly appreciated.
Thankees

(instance RoomScript of Script
(properties)
(method (doit)
(if(== (send gEgo:onControl()) ctlGREEN)
(send gRoom:newRoom(2))
)
)

   (method (handleEvent pEvent)
(super:handleEvent(pEvent))

This is just the first part of my roomscript instance.
Eigen I tried your code and it works here. Are you sure you draw the green color on the Control screen not Priority screen. And make sure it is dark green not light green.




-Eigen
Wilco23 Yeppers, I used dark green, and I've definitely been drawing on the control screen. Perhaps there is something wrong with another area of my code?
I'm not entirely sure how the:
north
south
east
west
section of the public instance is supposed to fit into the big picture, (but this probably has nothing to do with my code not working right?)
I can't figure out why it won't do anything, I've spent hours on this. :-\
Brian_Provinciano Have a look at my Gnome Quest source for examples. You should look in the class reference/help file and check out the methods ignoreControl and observeControl. If you do ignoreControl, it will ignore the control and not return TRUE. observeControl does the opposite.
Wilco23 Thanks, I'll read up the examples more thoroughly. :)
Wilco23 Well it's five days later and I'm still having no luck with this gosh-darned command. For some reason, which I really can't figure out why, my control line doesn't seem to have any effect. I've tried importing Brian's ego into my room, I've tried using one of Brian's rooms with my coding (just in case, to narrow down the possiblity of what was going wrong)
- Still it didn't work. I'm thinking there has to be something wrong with my code.
* I know the tutorial like the back of my hand by now
* I've referred to the help file, but it doesn't seem to be in English ;)

Oh yeah, I did the tutorial and my control lines worked then - though as you know in the tutorial there's a door and an entranceTo command, so I'm not sure if this is different.

I'm just trying to get my ego to walk through an empty door (but not touch the edge of the screen) to the next room.
Hmmm, it's probably something small and silly! :-\
Eigen Could you send me the whole script/game?


-Eigen
Wilco23 That would be fab Eigen, I'll post tomorrow (not on this computer) :)
cloudee1 ok don't leave me hanging i'm having same problem i have scripted two instances; look and control But it only does the script which comes first. Similar problem? Help me now Please!
Wilco23 Never mind, I've scrapped the whole lot and I'm starting again - it worked in the tutorial so I think I'll just follow the example more closely.