| Welcome to Brackenwood. We hope you enjoy your visit. You're currently viewing our forum as a guest. This means you are limited to certain areas of the board and there are some features you can't use. If you join our community, you'll be able to access member-only sections, and use many member-only features such as customizing your profile, sending personal messages, and voting in polls. Registration is simple, fast, and completely free. Join our community! If you're already a member please log in to your account to access all of our features: |
| Why? Why Why Why Why?...........!; *shoots self in the head* | |
|---|---|
| Tweet Topic Started: Apr 11 2005, 11:18 AM (173 Views) | |
| Mr. Jiggmin | Apr 11 2005, 11:18 AM Post #1 |
|
made of tulips
|
errrrrr...... ok, so I'm making the sequel to red earth. Its goin pretty well except for this blasted flame thrower! When you use it the game starts slowing down as if the movie clips aren't being unloaded. But as far as I can tell they are..... I set up a trace action that displayes how many flame movie clips are on the stage and it always goes back to zero after there all gone. So then I thought that maybe it was something else that was slowing it down so I striped out everything but the flamethrower. But guess what! its still slowing down.
I have no idea whats causing the slowdown after you use the flamethrower for a while..... I'm posting up the striped swf and fla, so if anyone can figure out whats going so horribly wrong i'd kiss you. errr.. maby not. swf fla |
![]() |
|
| Markham Carroll | Apr 11 2005, 02:55 PM Post #2 |
|
Custom member title
|
The only time I get lag is when I'm usingthe flame thrower. This is most likely caused by the alpha transparencies. The current Flash player can't handle too many transparent movie clips. |
![]() |
|
| Squidclops | Apr 11 2005, 03:01 PM Post #3 |
|
Guy with a hat.
|
Looked at your fla... Not sure exactly why it would slow down even AFTER the flame clips are unloaded. All that math and onEnterFrame handlers for each flame would probably have a bit to do with it though. Especially the onEnterFrame handlers. That tends to make things grind to a halt. Other than that...??? Sorry. |
![]() |
|
| Markham Carroll | Apr 11 2005, 04:05 PM Post #4 |
|
Custom member title
|
Flash 8's supposed to come out this year, and that's supposed to be able to handle much, much more than the current version of Flash. Maybe it would be worth your wait for the next version of Flash player to come out? |
![]() |
|
| Mr. Jiggmin | Apr 12 2005, 04:12 AM Post #5 |
|
made of tulips
|
Thanks guys, I sorta-kinda have it figured out. I ended up setting a function that loaded the new fire clips to the same level as older ones. Thus forcing things to unload. Ha! I still don't know what the problem was, but oh well. <_< Plus, I now have the added bonus of being able to put a cap on how many flame clips are loaded.
I'll post it up when I get home.-edit here's what I have so far: click upon me You move around with the wasd keys and shoot with the mouse. The three squares on the side are the buttons that switch between your weapons. |
![]() |
|
| Mr. Jiggmin | Apr 21 2005, 12:25 PM Post #6 |
|
made of tulips
|
Sorry about the double post, but it couldn’t be helped. Now that I test this thing more, the slowdown is still happening. Not only with the flamethrower, but with all the weapons. After you've shot about a million times, things just start lagging. I'm pretty sure I'm unloading the movie clips and even if I'm not, I'm re-using the levels. I think there must be some fundamental thing I'm missing.... Most of the code is on the buttons on the side and in the movie clips that those buttons call.the swf: here the fla: here Just because I don't want the only smiley in my post to be the sad one: :lol: edit: Haha, never mind. I went and got some cereal and when I came back I found the problem immediately. :rolleyes: I forgot to clear the interval that determines how often it checks where the mouse is. So after a couple of minutes, its doing like 300 hitTests per frame.... haha. Now I feel dumb. It only took me 9 days to find that problem.
|
![]() |
|
| 1 user reading this topic (1 Guest and 0 Anonymous) | |
| « Previous Topic · Actionscript · Next Topic » |



I have no idea whats causing the slowdown after you use the flamethrower for a while..... I'm posting up the striped swf and fla, so if anyone can figure out whats going so horribly wrong i'd kiss you.
errr.. maby not.



I'll post it up when I get home.
12:31 AM Jul 12