Spinning object and moving it faster with mouse down

I am using AS2 (CS3 Flash) and know how to do a simple motion
tween to create a spinning object (which is just a color wheel). I
was wondering how to take it to the next level and have it
interactive. I'd like it to be able to rotate faster with a mouse
down and drag if possible. Any suggestions? I don't really know AS,
but can do what I'm told to do - I'm more designer than
programmer.

sure - well instead of using a motion tween, you should
directly manipulate the objects spin using the _rotation property
within an onEnterFrame loop - in this way you can then adjust the
value of the step in the rotation (by degrees) when the user
presses the mouse button - then reset it to the orginal value on
release. as for dragging an Object, you would use the startDrag()
and stopDrag() methods of the MovieClip class. you would end up
with something like this:

Similar Messages

  • Help displaying Instructional Objectives 1-at-a-time using mouse down on a button on one screen.

    I am brand new to Captivate 6 and have encountered my first coding problem. I have six instructional objectives and would like to display them one at a time with a mouse click on a button. I would like some guidance either with making what I a trying to do work or in the alternative telling me what I should be doing instead. Here is what I tried to do.
    1. I created 6 instructional objectives on a single screen.
    2. Then I created a user variable "increment_objectives." It's starting value was set to 0.
    3. Next, I built an advanced conditional action. It contained seven conditional  statements, each built the same way. The purpose of the seventh was to move to the next slide after all instructional objectives were viewed.
    The advanced conditional action IF statement was:  If increment_objectives = x  then (where x varied from 0 to 7)
    The ACTION statements contained the names of the six instruction objectives (objective_1 through objective_6) and these were either shown or hidden, based upon the increment_objectives value.
    4. This advanced conditional action was attached to the enter frame on the slide and "no action" was on the exit frame on the slide.
    5. On a Button I attached an increment value that added 1 to increment_objectives variable.
    6. I set all frame objects to "duration of slide" turning off all timing increments.
    I had expected that this would increment the increment_objectives variable when the mouse was clicked and that the advanced actions conditional statements would be interpreted and display the objectives one at a time. How wrong I was. Not only did they not display, but after a few seconds, the screen would flip to the next slide.
    Can you offer me some help?
    Rod Wolford

    Hi Rod
    What did you use to trigger calling the Advanced Action? From what you just described, there is nothing to trigger the action. At least beyond the initial triggering upon entering the slide.
    Normally you want a Button or Click Box or other trigger to call the Advanced Action after each interaction.
    Hope this helps a smidge... Rick
    Helpful and Handy Links
    Captivate Wish Form/Bug Reporting Form
    Adobe Certified Captivate Training
    SorcerStone Blog
    Captivate eBooks

  • Problems with Mouse Down event for a picture control embedded in tab.

    I noticed that when trying to get a Mouse Down event for a picture control that the Mouse Down will not be 'fired' if the picture is embedded in a tab control. It also appears that this problem exists for other controls (I only tested a slider in addition to the picture). It isn't much of an issue for me now as I can just poll the mouse property of the picture control, but the Mouse Down event has information that I may want access to in my next software revision (button pressed, and Alt mod). I could do that by handling the Mouse Down event for the tab itself and checking to see if the the mouse property isn't -1, -1 for the picture, but that seems a little bit too kludgy (sp?) to me and wouldn
    't address the issue with other control types. Any chance of this being addressed by a patch sometime in the next couple of months???
    Attachments:
    TabProblem.vi ‏69 KB

    The problem I reported above was in LV 6.1.
    As a work-around, I used the mouse down on the tab control and did the math to decide if the picture was clicked.
    I have been told that this was fixed in LV 7.0. I can not confirm.
    You could call NI and ask about the service request number I cited above.
    I hope this helps,
    Ben
    Ben Rayner
    I am currently active on.. MainStream Preppers
    Rayner's Ridge is under construction

  • Read group membership for a user object and populate every group with matching user from another domain

    I have LON\JSmith in LON domain and DEL\JimSmith in DEL domain
    I would like to extract group memberships of LON\JSmith in LON domain and append matching by email (i.e. DEL\JimSmith) user object in every group in LON domain.
    for instance
    LON\JSmith and DEL\JimSmith is the same person and has same email address [email protected]
    LON\JSmith belongs to 3 groups - LON\localadmingroup;LON\univdesktop;LON\globalsurvey
    The outcome of the script should be
    LON\JSmith; DEL\JimSmith    should be in 3 groups - LON\localadmingroup;LON\univdesktop;LON\globalsurvey.
    How can i do it?
    Navgup

    Hi Navgup,
    Please refer to the script below, to query users in other domain by specifying the parameter "-Server" in the cmdlet "get-aduser", and also note I haven't tested the script below:
    import-module activedirectory
    get-adgroupmember "group"|foreach{
    $email=(get-aduser $_.samaccountname -properties *).EmailAddress#get the user email
    Get-ADUser -filter {EmailAddress -eq $email} -properties * -server DomainB.company.com|select samaccountname, memberof}#filter user name and group with the email in other domain
    To get users across domain, please also refer this blog:
    Adding/removing members from another forest or domain to groups in Active Directory:
    http://blogs.msdn.com/b/adpowershell/archive/2010/01/20/adding-removing-members-from-another-forest-or-domain-to-groups-in-active-directory.aspx?Redirected=true
    I hope this helps.

  • Cannot slide back and forth to pages with mouse since Maverick install, anyone else??

    Cannot slide back and forth (page to page) with the mouse since Mavericks install. Anyone else??

    Hi,
    Please do not type in all caps,its considered shouting and we can hear you just fine.
    I believe you are asking a question regarding Pages, I would recommend re-posting in the Pages forum. This forum is a general iMac forum, while someone may know I believe the Pages forum is a better bet.
    Good luck.

  • Cannot scroll drop downs, or drag and drop files/folders with mouse

    I cannot scroll drop downs (I can click them, but I can't choose anything) or drag files or folders with the mouse or touch pad, but it works fine when I use my Wacom tablet. It's super frustrating. Help!

    P.S. I've narrowed the problem down to being related to the game Diablo III. If I restart my machine, it works fine again. Until I play Diablo. Totally lame.

  • Spin object and move it at the same time...

    I am trying to have two polaroid pictures slide across the screen into position, I've used keyframes to accomplish this. But I want to add a little spin as the move but when I apply change the rotation at the keyframe it changes the rotation for the entire timeline not just at that keyframe. So I tried to apply spin and it cancelled out the keyframe movement. I couldn't even drag it on the screen it was stuck in position. How can i fix this. Thank you for your help.

    The record button merely tells Motion to begin applying keyframes to changes in a parameter different from it's starting values. If you don't tell Motion where you want it to begin the changes from, it'll assume you want the animation to begin from the start of the clip.
    Go to the place where you want the spin to start. OPT+click the rotation parameter to add a keyframe. Turn on the record button (A). Go to where you want the spin to end. Adjust the value to the rotation parameter.
    Andy

  • Trying to create a surface  with multiple images with mouse events

    novice programmer (for a applet program)
    hi trying to create a surface i.e jpanel, canvas, that allows multiple images to be created.
    Each object is to contain a image(icon) and a name associated with that particular image. Then each image+label has a mouse event that allows the item to be dragged around the screen.
    I have tried creating own class that contains a image and string but I having problems.
    I know i can create a labels with icons but having major problems adding mouse events to allow each newly created label object to moved by the users mouse?
    if any one has any tips of how to acheive this it would be much appreciated. Thanks in advance.
    fraser.

    This should set you on the right track:- import java.awt.*;
        import java.awt.event.*;
        import javax.swing.*;
        public class DragTwoSquares extends JApplet implements MouseListener, MouseMotionListener {  
           int x1, y1;   // Coords of top-left corner of the red square.
           int x2, y2;   // Coords of top-left corner of the blue square.
           /* Some variables used during dragging */
           boolean dragging;      // Set to true when a drag is in progress.
           boolean dragRedSquare; // True if red square is being dragged, false                              //    if blue square is being dragged.                            
           int offsetX, offsetY;  // Offset of mouse-click coordinates from
                                  //   top-left corner of the square that was                           //   clicked.
           JPanel drawSurface;    // This is the panel on which the actual
                                  // drawing is done.  It is used as the
                                  // content pane of the applet.  It actually                      // belongs to an anonymous class which is
                                  // defined in place in the init() method.
            public void init() {
                 // Initialize the applet by putting the squares in a
                 // starting position and creating the drawing surface
                 // and installing it as the content pane of the applet.
              x1 = 10;  // Set up initial positions of the squares.
              y1 = 10;
              x2 = 50;
              y2 = 10;
              drawSurface = new JPanel() {
                        // This anonymous inner class defines the drawing
                        // surface for the applet.
                    public void paintComponent(Graphics g) {
                           // Draw the two squares and a black frame
                           // around the panel.
                       super.paintComponent(g);  // Fill with background color.
                       g.setColor(Color.red);
                       g.fillRect(x1, y1, 30, 30);
                       g.setColor(Color.blue);
                       g.fillRect(x2, y2, 30, 30);
                       g.setColor(Color.black);
                       g.drawRect(0,0,getSize().width-1,getSize().height-1);
              drawSurface.setBackground(Color.white);
              drawSurface.addMouseListener(this);
              drawSurface.addMouseMotionListener(this);
              setContentPane(drawSurface);
           } // end init();
           public void mousePressed(MouseEvent evt) {
                  // Respond when the user presses the mouse on the panel.
                  // Check which square the user clicked, if any, and start
                  // dragging that square.
              if (dragging)  // Exit if a drag is already in progress.
                 return;           
              int x = evt.getX();  // Location where user clicked.
              int y = evt.getY();        
              if (x >= x2 && x < x2+30 && y >= y2 && y < y2+30) {
                     // It's the blue square (which should be checked first,
                     // since it's in front of the red square.)
                 dragging = true;
                 dragRedSquare = false;
                 offsetX = x - x2;  // Distance from corner of square to (x,y).
                 offsetY = y - y2;
              else if (x >= x1 && x < x1+30 && y >= y1 && y < y1+30) {
                     // It's the red square.
                 dragging = true;
                 dragRedSquare = true;
                 offsetX = x - x1;  // Distance from corner of square to (x,y).
                 offsetY = y - y1;
           public void mouseReleased(MouseEvent evt) {
                  // Dragging stops when user releases the mouse button.
               dragging = false;
           public void mouseDragged(MouseEvent evt) {
                   // Respond when the user drags the mouse.  If a square is
                   // not being dragged, then exit. Otherwise, change the position
                   // of the square that is being dragged to match the position
                   // of the mouse.  Note that the corner of the square is placed
                   // in the same position with respect to the mouse that it had
                   // when the user started dragging it.
               if (dragging == false)
                 return;
               int x = evt.getX();
               int y = evt.getY();
               if (dragRedSquare) {  // Move the red square.
                  x1 = x - offsetX;
                  y1 = y - offsetY;
               else {   // Move the blue square.
                  x2 = x - offsetX;
                  y2 = y - offsetY;
               drawSurface.repaint();
           public void mouseMoved(MouseEvent evt) { }
           public void mouseClicked(MouseEvent evt) { }
           public void mouseEntered(MouseEvent evt) { }
           public void mouseExited(MouseEvent evt) { }  
        } // end class

  • CONNECTION OBJECT AND POD

    hi experts,
    can any one of you explain what is connection object and point of delivery with any example.

    Hello
    Connection object is the place where the Utility service is provided. It can be a building, or a transformation center in the street or a fountain. It is just where you provide the service.
    PoD is an object for the de regulated market. It is a universal coordinate on where the service is provided. Imagine you switch  from UItility company A to company B. When both companies exchange your data, the only data that both companies know for sure is your PoD.
    PoD number is created via an algorithm which is unique for your whole country.
    Hope it helps
    Joaquin

  • Loading 3D objects and their animations

    Hi all:
    I want to load some 3D objects (humanoid) with different animations(walk, jump...) which depend on the situation in the game. Objects and animations are made with 3dStudio max 5.0.
    I have found a lot of documents and loaders for several types of objects 3D (particullary .3DS, .wrl ), but I have some problems:
         * With an 3D object .3ds, I can load and show an humanoid with textures, but I don't know how load and attach an animation (.bvh, .cvm or .bip). I haven't got any documents about this.
         * I have tried to load a vrml97 file with Xj3D, but it seems that the vrml97 produced by 3dStudio can't be loaded by the Xj3D, whereas with the other vrml97 files there is no problem. But a solution with vrml is not very good because objects and animations are not separated.
    Can anyone help me?
    Thanks,
    Tamica.

    I remember reading somewhere that some dude successfully loaded up neverwinter nights models in a java3D canvas, and one of them had active fire animation.
    So loading an animation should be feasible :)

  • How do I place an image and insert a different photo for the "mouse down" state?

    I have placed an image within an accordian widget and when I select the "mouse down" area in the states dialog box, i click "fill" in the toolbar and insert the photo i want to display when the image is clicked but this image is "covered up" by the originally placed image and is not seen in my states dialog box.
    I have done this before when i made rectangles and placed images in rectangles. But i soon realized that you cannot add alternative text to images in rectangles for some frustrating reason.
    How do I place and image and have a different image for the mouse down state?

    Hello,
    This effect can only be achieved when you use the images as a Rectangle Fill. And as you mentioned it above, you cannot add alternative text to images because it is added as a fill and not as a image.
    I would suggest you to post this as a feature request on our "Ideas for features in Adobe Muse" section of the forums : http://forums.adobe.com/community/muse/ideas
    Regards,
    Sachin

  • When I open aperture it opens then after a minute I get the spinning ball and the program freezes

    When I open  aperture it opens, after a minute I get a spinning ball and the program freezes.

    Try holding down the Option and Command keys while opening Aperture. Click Rebuild Database. Dumping preferences couldn't hurt.

  • How to code 2 buttons with mouse events

    I am trying to code two buttons, both with mouse down events, but perform different functions. When I coded the script, I received the following error message:
    1021: Duplicate function definition.

    use different function names.

  • MacBook slow; results in a freeze and inability to boot after shutting down

    From time to time my MacBook starts getting slow. This always results in a total freeze, to which my (as far as I can tell only available) reaction is always powering it off with the P-button.
    However, after I shut it down it always gets stuck at the loading screen when trying to boot again. I've experienced both a grey screen with spinning gear and a white screen with spinning gear. Usually a Pram-reset allows me to boot, but lately it has taken days and countless different fixes to get past the starting sequence.
    This morning I spent 3 hours resetting every concieveable thing, booted in safe mode, did a disk repair, but to no effect.
    Initially I couldn't even do a Pram-reset (it would just boot regularly without a second chime).
    Later I was able to, but again to no effect (it would just get stuck at the grey screen).
    I ended up leaving my MacBook for a few hours to 'rest'. Upon returning home I did another Pram-reset, and this time it booted normally - it just seems so random that it would suddenly work.
    My question is: what can I do to prevent this in the future? The sudden drop in performance resulting in a freeze?
    Thanks in advance,
    Kris

    If your MacBook is a 2008 model see this
    [Solved] Beachballs on late 2008 15" MacBook Pro MacBookPro5,1 with SATA II HD

  • I have an iMac with Mavericks that is experiencing a lot of "spinning balls" from particularly Mail, Google Chrome, and Word. I took it to the Apple store and it was fast there, at home slow. I have been having internet speed issues, could it be that?

    I have a pretty new iMac with LOTS of storage (about 4TB with externals) that is experiencing a lot of "spinning balls of death" from time to time in almost any program that I might have open, but particularly MacMail, Google Chrome browsers, and Word. I took it to the Apple store to be checked out and it was really fast with no issues there. I brought it home and it was better at first but then it started happening again.
    I have been having a lot of issues with Time Warner where my download speeds will dip really low, and all I can think of is that MacMail goes and tries to check for email and can't get out to the internet and it locks all the other resources up while it is doing it. It will also take a REALLY long time to even let you look at mail. The folder size is over 13GB (down from 22GB that I just cleared out from - I have a lot of MP3s etc in there) and I will try to get this down to under 10GB which might help, and the mail is on an external drive. I have been told that Verizon is not a shared network but a direct connection to their server, and if I can't fix this then I will try switching to them. If anyone has any direct knowledge on this stuff, I am all ears.

    We need to know more about your system, please download EtreCheck and run the report and please post it on your next reply. Then we can see how your system is configured, what apps are on it and look for anything obvious. We will look forward to seeing your report.

Maybe you are looking for