Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 4 of 4
  1. #1
    New to the CF scene
    Join Date
    Jan 2008
    Posts
    9
    Thanks
    1
    Thanked 0 Times in 0 Posts

    linking .fla's and collision problems

    I am painfully new to actionscript and have been given an assignment to make my own flash game for college. The game is simple, move a duck through a maze without touching the lava. I got the duck to move and everything else to work but I've hit two snags I was wondering people can help with.


    1) When it comes to collision, I can only find tuts that tell me when the collision happens. What I cant get to happen is when my first movieclip (the duck) comes into contact with another movieclip (the lava) the graphic changes from that of a duck to that of fire. I just don't know what to write!


    2) Can you link from one flash movie to another? I want to make a splash screen with a play button to pop up when you start the application and when you hit play it will start the game. The only information on linking I've found online is linking from flash to a webpage. Would it be better to use another program?


    3) A decent tutorial site for actionscript since I wasn't able to find the answer to any of my questions on my own :P

    Thank you for your attention.
    Last edited by Estellio; 03-28-2008 at 12:47 PM.

  • #2
    Senior Coder gnomeontherun's Avatar
    Join Date
    Sep 2007
    Location
    Houston
    Posts
    2,846
    Thanks
    10
    Thanked 238 Times in 229 Posts
    College means this is homework which means it violates the rules to ask for help.

    1) Most of the time when you find a tutorial it doesn't give you EXACTLY what you need. Hence the purpose of tutorials, to give you a headstart but not to do all of the work for you. So logically when you find a tutorial that allows you to detect a collision, then make a function that runs then.

    2) Why link Flash to Flash when you could make just one file for this?

    3) http://www.codingforums.com/showthread.php?t=126424

    Good luck, but please read the rules before posting about homework.
    jeremy - gnomeontherun
    Educated questions often get educated answers, and simple questions often get simple answers.

  • #3
    Supreme Master coder! _Aerospace_Eng_'s Avatar
    Join Date
    Dec 2004
    Location
    In a place far, far away...
    Posts
    19,291
    Thanks
    2
    Thanked 1,043 Times in 1,019 Posts
    You can ask for help but don't expect us to do the work for you.
    Quote Originally Posted by CodingForums.com Rules
    1.5) No homework assignments - Do not post your entire homework assignment and request that other members do it for you. This is considered cheating, and your thread may even be used by your school to prove your guilt. Now, you may ask for advice or help on a specific aspect of your assignment that you're having trouble with. Use common sense as far as what's acceptable in terms of soliciting help with homework assignments.
    ||||If you are getting paid to do a job, don't ask for help on it!||||

  • #4
    New to the CF scene
    Join Date
    Jan 2008
    Posts
    9
    Thanks
    1
    Thanked 0 Times in 0 Posts
    Now, you may ask for advice or help on a specific aspect of your assignment that you're having trouble with.
    I didn't post up the specifics of my brief or ask anyone to do it for me. I asked

    1) How do you change a graphic on collision
    2) Can you use Flash to link a splash page to the game itself or would it be better to use a different program.

    I even asked for tutorials to help me find this out, not straight answers and
    I have searched the internet for a decent tutorial, even the ones you linked me but it's mostly teaching you to use Flash, which I can do, it's Actionscript I have trouble with. I'm here to learn Actionscript afterall.

    In any case, back to the code. If you want more detail with the trouble I'm having, what I was trying to achieve was that when the duck hit the lava the graphic changed from a duck to fire. I've tried a few ways to do this but none work.


    onClipEvent(enterFrame){
    if (ball.hitTest (puddle)) {
    (what do I put here?)<- I can't figure out how to change the graphic
    }
    }
    If there is a 'get graphic' command please, just let me know and I'll figure it out on my own from there.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •