Alice Community  

Go Back   Alice Community > Alice 2 > How do I...?

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
How Do I DISABLE AN Event?
Old
lanceA
Guest
 
Status:
Posts: n/a
Default How Do I DISABLE AN Event? - 05-11-2008, 09:19 PM

Given this scenerio:
Person walks forward while up-arrow is pressed.

Now:
The person disappears and I no longer wish the up-arrow to trigger an event for the 'person'

How do I stop the event-listener from monitoring the up-arrow key-press?

I think I just solved it:
The up-arrow event calls a method such as MoveObj(Object obj). Then the code within the method does something like:

while Obj.isShowing == true
move the object.

Now, might I include within that method an if/else statement so that I can transfer the event handler to move a second or third object??? In otherwords, based upon some condition, I can force the event handler to control multiple objects?
if obj1 isShowing
...do this
else if obj2 isShowing
...do this
etc., etc.

A 2nd question, does Alice recognize the instanceOf command? And if so how do I invoke it?

Any speculation on why any of the above would not work?

Thanks.

Last edited by lanceA; 05-11-2008 at 09:43 PM. Reason: added question about instanceOf
   
Reply With Quote
 


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump



Copyright ©2024, Carnegie Mellon University
Alice 2.x © 1999-2012, Alice 3.x © 2008-2012, Carnegie Mellon University. All rights reserved.