Flash

 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me



Go Back   Tutorialized Forums2D GraphicsFlash

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Tutorialized Forums Sponsor:
  #1  
Old February 3rd, 2012, 08:51 PM
aruna_juice aruna_juice is offline
Registered User
Tutorialized Newbie (0 - 499 posts)
 
Join Date: Feb 2012
Posts: 1 aruna_juice User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 28 m 54 sec
Reputation Power: 0
Smile how spin the wheel on movie load without mouse click

Hello all, I am new to flash and seem to be stuck with this problem. Any

guidance would be extremely appreciated.

I am trying to spin the wheel automatically with out mouse click. i am

trying harder. here is the code:

Code:
import fl.transitions.Tween;
import fl.transitions.TweenEvent;
import fl.transitions.easing.*;


txtCount.background=true;


var randomnumber:Number; 


var tw:Tween  = new Tween(mcArrow,"rotation",Strong.easeOut, 10, 360, 

20, true); 


tw.stop();


tw.addEventListener(TweenEvent.MOTION_FINISH, spinStopped);


function spinStopped(twevt:TweenEvent):void {
    txtCount.backgroundColor = 0xFFFFFF;
    txtCount.text = String(randomnumber);
    mcArrow.addEventListener(MouseEvent.CLICK, spin);
}


mcArrow.addEventListener(MouseEvent.CLICK, spin);


function spin(mevt:MouseEvent):void {
    var numturns:int = Math.ceil(2*Math.random());
    randomnumber = Math.ceil(100*Math.random());
    
    mcArrow.removeEventListener(MouseEvent.CLICK, spin);
    
    txtCount.text = "Spinning...";
    txtCount.backgroundColor = 0xFF9999;
    
    tw.begin = mcArrow.rotation;
    tw.finish = numturns*1080 + randomnumber*3.6;
    tw.start();
}

here is the sample file http://www.mediafire.com/?q988b9nse43zbdg
how to get the specified number which is available in mysql database

instead of random no.

advance thanks for the help...

Reply With Quote
Reply

Viewing: Tutorialized Forums2D GraphicsFlash > how spin the wheel on movie load without mouse click


Developer Shed Advertisers and Affiliates


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 

Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.

© 2003-2017 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap