PDA

View Full Version : Clear dynamic text when click on anywhere that's not an object?


Heloed
08-05-2008, 09:58 PM
Basically I have whatever on the screen, and when you click on them the text box tells you a certain thing, and then what I want is so you can click on anywhere else, anything in the background that isn't an mc, and have it clear the textbox. The code I tried using is:stage.addEventListener(MouseEvent.CLICK, clickAnywhereElse);
function clickAnywhereElse(event:MouseEvent):void {
gametext.text = "";} but it makes things go wonky.

How might I code it so it does what I want?

theqman
08-06-2008, 03:45 AM
Well all I can see is make sure you have the closing }.
:P