We are about to switch to a new forum software. Until then we have removed the registration on this forum.
I recently created this universe simulation after school at mcdonald's where it works as such: Matter isn't clumped into 1 3 dimensional area but is it's own dimension. In it particles don't move rather they copy a state of one location to another on that same matter dimension. Therefore the void can move to occupy matter. (its confusing but neet) It took about an hour and is 147 lines of code.
Comments
Very nice simulation Alex! Tried my luck at trying to speed it up & trim it down a bit more. :P
In my PC it still crawls a lot though. It can also be run even slower online below:
http://studio.ProcessingTogether.com/sp/pad/export/ro.9cEyzu18dPQIG/latest
And here's the tweaked version: :-\"
very nice! I will share your update on my channel!
UPDATE: I shared your code in my video here: I credited you for your nice work!
Wow, cool YouTube comparison review video, thx! <:-P
Though you had some little problems finding out where the 2 implementations matched each other! ;)
thanks very much!
byte
.boolean[][][][]
we've gotbyte[][][]
! \m/byte
via bitwise operators.http://studio.ProcessingTogether.com/sp/pad/export/ro.9cEyzu18dPQIG/latest
P.S.: In the end, those
else if ((mk & (G|B)) == (G|B)) mj[k] = R;
check statements proved useless! :O)Since we've never needed any bitwise checks b/c matters[][][] are never more than 1 color state at a single time, we can have a more direct approach, where a
byte
either represents an INKS[]'s index or-1
: *-:)That update improved performance on my machine significantly! Thanks for the shared code! As well I found that changing DIM to 50 or 75 performance increases. I also like how your mod prevents clumping of particles to the edge of the universe, it makes it look much cleaner. :)