Making 2D Arrays, Fast!
Im in a bit of trouble as I am making this effect using a massive 2D array. I have used Array Painter 1.1 to draw it and import it into flash. However, this programe SUCKS! I don't know the exact size of my array and I want to shift bits round quickly and easily. Array Painter is impossible to work with and is slow and painful. Before I go of and just make my own Flash Based Array Painter (Which I dont have time for) I would like to know if anyone else has a better progame?!
I have searched loads but these kinds of random things are hard to find. So please I you know any better programes, please share them!
Thanks,
Dan
HOWEVER! This sounds like a plan! I could effect each pixel individually but it would probably kill my FPS.
Thanks for the help,
Dan
Well, the only way make arrays faster is to use them less or not too lengthy, as not the arrays, but the for loops are being slow. You can either come up with array-less algorithm or lower the number of indexes in the line by optimizing it and skipping redundant and insignificant points.
Thanks
Schm
You can download it to to suit your needs, quite easy to change to what I needed it to do and it is a flash program which I think you said you wanted, but didn't have the time to make one.
All I need is a programe like Array Painter (where you can paint a 2D array!) but a better programe, as Array Painter is awful.
Thanks for your help,
Dan
However puppy intregged me (spelling :crazy: ) and I learnt how to use the bitmapdata object in flash. Its AWSEM now. I can do anything I want. Save as a jpg or png, then import, linkage to p0,1,2, w/e then BANG it makes a massive thingy which is well fun!
Its so fast and effective and lets me use colour :D
www.dan0.com/pixel.html - just a crappy testy thing to give you and idea
At the moments its fine with a small number of pixels, but too many and the fps dies on me. Im not sure if/how I can increase the FPS. I made the onEnterFrame function with the most CPU frendly code I could muster.
Thanks for all the help,
Dan
Im not sure how to increase the speed in AS2 though. At the moment it checks through ever single bloody square. I don't know how I can get it to just check the sqaures I want it to check. The only thing I have thought of is by making an array which holds all of the currently checking MCs and when they are finished moving they are removed from the array. Its overly complex and would proabably not make my code go any faster because it would still need to check which MCs were added to the array.
:stare: scripting...
Thanks for your help,
Dan
Thanks :)
What would I need to add/change? I don't use attached MCs everything is created there and then with code etc..
Thanks for the help,
Dan
schmichael I will put the final .fla on my site after jun. Sorry its just because its for my exams and I don't want any one to nick it. I will PM you if you like.
If you know how to make arrays, attach MCs, loop through the BitmapData and send the MCs to a function everyframe, you will easily be able to make them scale. I only have 4 variables attached to the MCs, they are:
_x
_y
sx (starting _x)
sy (starting _y)
using these you can make loads of cool stuffsz!
clicky me (http://www.actionscriptcheatsheet.com/downloads/as3cs_migration.pdf)
#If you have any other info about this subject , Please add it free.# |

