Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6731853
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T10:34:41+00:00 2026-05-26T10:34:41+00:00

I am using Action Script 3.0 to animate an instance (MovieClip class) to follow

  • 0

I am using Action Script 3.0 to animate an instance (MovieClip class) to follow the mouse positron the thing is, the left corner of the instance follows the mouse courser. Now there is a cross on the to left corner and my guess would be that the mouse follows that cross, but i can not change the position of the cross within the instance/ original object.
Does anyone know how to make the center of that instance follow the mouse cursor?
Thank You all for ANY help on that topic.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T10:34:42+00:00Added an answer on May 26, 2026 at 10:34 am

    I use this code.

    import flash.display.Shape;
    import flash.events.Event;
    
    
    var easing:Number = .25;                    // inching coefficient
    
    var sp:Shape = super.addChild(new Shape()) as Shape;        // draw circle
    sp.graphics.beginFill(0x0,.6);
    sp.graphics.drawCircle(40,40,40);
    
    sp.x = super.stage.stageWidth - sp.width >> 1;
    sp.y = super.stage.stageHeight - sp.height >> 1;
    
    super.stage.addEventListener(Event.ENTER_FRAME, update, false, 0, true);
    
    function update(e:Event):void
    {
        var targetX:int = super.stage.mouseX - (sp.width >> 1);
        var targetY:int = super.stage.mouseY - (sp.height >> 1);
    
        sp.x += (targetX - sp.x) * easing;
        sp.y += (targetY - sp.y) * easing;
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I would like to tween a movieclip (with ease out) using purely action script
First is there any technique for using Action Script for recording sound from microphone?
I am building an application using Action script 3 I am retrieving some XML
I am very new to Action Script. I am using Flash Professional CS5 with
I am new to flash and learning action script 3. I am using flex.
I'm using Action Script 3 to make android game using air for android I
Using Action Script 3 in Flex Builder 3. When handling a SOCKET_DATA event, I
I've been trying to submit a form with the FormPanel using the Action class
I have a switch statement in my action script class.I have a function onKeyDown(event:
Im new to this flash and I am using as2 for the action script

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.