Flash Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsWeb DesignFlash Help

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 Dev Shed Forums Sponsor:
  #1  
Old February 17th, 2004, 01:47 AM
alt4ir alt4ir is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Dec 2003
Location: San Jose, CA
Posts: 65 alt4ir User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 5 h 33 m 55 sec
Reputation Power: 5
Send a message via AIM to alt4ir
Question dynamic bouncing ball within its own MC?

Well, I'm supposed to present this exercise before the class tomorrow in which we use actionscripting to create user defined incremental loops, as well as textfields to display data. Well, my idea was to create this bouncing ball that would bounce around the screen (taking reflective angles, random speed, random direction) with textfields to display its x/y coordinates, and then let the viewer choose how many they want on the screen.

Well, I got the ball bouncing perfectly, and the textfields display the x/y coordinates just the way I want, but it's all out in the scene. I want to put all of this into a movieclip, so that I can use duplicateMovieClip in a for loop. I've tried moving the content into a movieclip, but the paths must be changed. I went and made what I thought were the apropriate path changes, but it still won't work.

All the source and swf files are at my class project page. Here's the run down of the versions:

Exercise 2.3 is the last successful version, with the ball that bounces around perfectly.
Exercise 2.4 is screwed up because I tried to take out all the "Number()" statements, since I believe that's old code and isn't necessary in flash mx (am I wrong? please correct me).
Exercise 2.5 is version 2.3 that was moved into a single movie clip called "bounce", with modified paths to suit.

It would be really awesome if I just have some little thing screwed up and it can all work within one movie clip, cause that will make my life a lot easier. I'll be working on it tomorrow morning before class, so I'll definately check back before then.

PS: I know just saying "_root.bounce.whatever" will screw up my duplication of the MC "bounce". I'll need to name them incrementally (bounce + i), but am not sure how I will handle that within the seperate movie clips themselves... it's a bit of a logic fart.

Reply With Quote
  #2  
Old February 17th, 2004, 06:22 AM
Tann San Tann San is offline
Gotta get to the next screen..
Dev Shed Demi-God (4500 - 4999 posts)
 
Join Date: Nov 2003
Location: Legion of Dynamic Discord
Posts: 4,714 Tann San User rank is Colonel (50000 - 60000 Reputation Level)Tann San User rank is Colonel (50000 - 60000 Reputation Level)Tann San User rank is Colonel (50000 - 60000 Reputation Level)Tann San User rank is Colonel (50000 - 60000 Reputation Level)Tann San User rank is Colonel (50000 - 60000 Reputation Level)Tann San User rank is Colonel (50000 - 60000 Reputation Level)Tann San User rank is Colonel (50000 - 60000 Reputation Level)Tann San User rank is Colonel (50000 - 60000 Reputation Level)Tann San User rank is Colonel (50000 - 60000 Reputation Level)Tann San User rank is Colonel (50000 - 60000 Reputation Level)Tann San User rank is Colonel (50000 - 60000 Reputation Level)Tann San User rank is Colonel (50000 - 60000 Reputation Level)  Folding Points: 10093 Folding Title: Novice Folder
Time spent in forums: 3 Weeks 1 Day 11 h 8 m 12 sec
Reputation Power: 580
Facebook MySpace
Hi, I commented the code. So what's this supposed to demonstrate?
Attached Files
File Type: zip newBounce.zip (23.6 KB, 120 views)
__________________
-Tann

-Vote for your favorite ActionScript editor here.

Reply With Quote
  #3  
Old February 17th, 2004, 12:54 PM
alt4ir alt4ir is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Dec 2003
Location: San Jose, CA
Posts: 65 alt4ir User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 5 h 33 m 55 sec
Reputation Power: 5
Send a message via AIM to alt4ir
Talking

Holy crap dude. You did everything I wanted to. lol.

these are just preliminary exercises in the class to get used to working with concepts in flash (such as nested movieclips, random number generation, data display, etc). Then we'll take the knowledge gained from these little weekly exercises and apply them towards our larger projects.

Thank you very much for your help. I must now study your code to figure out how it works.

Reply With Quote
Reply

Viewing: Dev Shed ForumsWeb DesignFlash Help > dynamic bouncing ball within its own MC?


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 | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 4 hosted by Hostway
Stay green...Green IT