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 4534338
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 21, 20262026-05-21T14:16:06+00:00 2026-05-21T14:16:06+00:00

Ok i have a mc called dracoplay and inside is another mc called Drakep

  • 0

Ok i have a mc called dracoplay and inside is another mc called Drakep and inside that there is another mc called wing and head as you may have guessed they make up a dragon. So dracoplay is the character that gets coded. Drakp is the body and the head and wing have animations. Now my problem is making it breath fire so that it will keep firing until i let go of the left click (I already found a way for it fire when i click but i have to click again for it to stop). I would also like for it to shoot towards the mouse.

  • 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-21T14:16:07+00:00Added an answer on May 21, 2026 at 2:16 pm

    from what i’m seeing, you should use two eventListeners, a mouseDown and mouseUp-event 🙂 I’ll write some basic code that should help you.

    public function constructor():void
    {
         stage.addEventListener(MouseEvent.MOUSE_DOWN, toggleFire);
         stage.addEventListener(MouseEvent.MOUSE_UP, toggleFire);
    }
    

    these two eventListeners should be added in the constructor of your code. Then, the toggleFire-method will look like this:

    private function toggleFire(e:MouseEvent):void
    {
         if(e.type == MouseEvent.MOUSE_DOWN)
              stage.addEventListener(Event.ENTER_FRAME, breatheFire);
         else
              stage.removeEventListener(Event.ENTER_FRAME, breatheFire);
    }
    

    the last function you need is the breatheFire-function.

    private function breatheFire(e:Event):void
    {
         //Write your code for the fire breathing here
    }
    

    and this should do the trick.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Ok i have a mc called dracoplay and inside is another mc called Drakep
Is there a convention for naming the private method that I have called _Add
I have a java script function that i have called on body load mousemove()
I have some jQuery code. I have called an Ajax function file, file.php, that
I have called a view from another with Html.Action method. I want to call
I've got a function called updateTheValue() that I have called using [self updateTheValue] for
I have called a method using a secondary thread. From inside the method i
Inside the google maps infowindow object I have called the showHotel() function but it
I have a .NET webmethod that I have called from jQuery. The method returns
I have a stored procedure in which I have called another stored procedure [Let

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.