Listener+gotoAndPlay 2004-03-11 - By Andreas Weber
Back Oops...
Forget about that - this solution will work very nicely if the user behaves as expected. The problem is: if he doesn't have a clue what the password is and just guesses (trial and error) the last charcter/number he/she is taken to the 'treasure' (the 'get' frame) as well.
Jim's solution is definitely the way to go!
-- ---- ------ Andreas Weber motiondraw.com
-- --Original Message-- -- From: Andreas Weber [mailto:webweber@(protected)] Sent: Thursday, March 11, 2004 6:26 AM To: flashnewbie@(protected) Subject: RE: [Flashnewbie] Listener+gotoAndPlay
Jim's solution is very elegant and perfectly generic - very easy to change the codeword to whatever you want.
Not so nice, but closer to what you've already got:
stop(); keyList1 = {}; keyList1.onKeyDown = function(){ switch(Key.getCode()){ case 73: // i gotoAndStop("s"); break; case 83: // s gotoAndStop("k"); break; case 75: // k gotoAndStop("7"); break; case 55: // 7 gotoAndPlay("get"); break; } } Key.addListener(keyList1);
HTH -- ---- ------ Andreas Weber motiondraw.com
-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ------ Supported by Fig Leaf Software -- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ------ Lower Prices for Certified Training! Check out new lower prices for Certified Macromedia Training from Fig Leaf Software. Expand your skill set with courses in ColdFusion, Flash, Rich Internet Applications and .NET in the new year. Fig Leaf Software provides the highest caliber instruction at our training centers in Washington D.C., Atlanta, Chicago, Baltimore, Northern Virginia, or on-site at your location.
Get the details at http://training.figleaf.com/ -- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- -- To unsubscribe, e-mail: flashnewbie-unsubscribe@(protected) For additional commands, e-mail: flashnewbie-help@(protected)
-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ------ Supported by Fig Leaf Software -- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ------ Lower Prices for Certified Training! Check out new lower prices for Certified Macromedia Training from Fig Leaf Software. Expand your skill set with courses in ColdFusion, Flash, Rich Internet Applications and .NET in the new year. Fig Leaf Software provides the highest caliber instruction at our training centers in Washington D.C., Atlanta, Chicago, Baltimore, Northern Virginia, or on-site at your location.
Get the details at http://training.figleaf.com/ -- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- -- To unsubscribe, e-mail: flashnewbie-unsubscribe@(protected) For additional commands, e-mail: flashnewbie-help@(protected)
|
|