#113296 - nornagon - Tue Dec 26, 2006 5:48 am
Hi all,
World of Sand (beta 1)
I hacked this up over the last couple of days and the folks on #dsdev seemed to enjoy it, so I thought I'd link it here for your pleasure.
Note that the idea for the game isn't original; the code is mostly from a clone I made of the game by Dofi (written in Java, eugh).
The performance isn't great yet, but it's acceptable. The code will be released when I get around to dropping it on a version control system, under the GPL. There are a bunch more features I plan to add, including:
- a title screen
- more materials/combinations (steam, ash, snow, ideas welcome)
- portrait view
- a hideable toolbox instead of the arrow-key-selected icons
- a way to stop/start the flow of individual sources
- different brush sizes
- timer and particle count on the top screen
- save/load to png
Thanks to: sgstair for answering my annoying questions, WinterMute and co. for libnds and devKitPro, the rest of the #dsdev guys for providing feedback :)
FAQ
Q. How do I clear the screen?
A. ???
#113303 - dantheman - Tue Dec 26, 2006 8:57 am
Heh, very addicting to play. Good job on the game.
#113313 - Mrshlee - Tue Dec 26, 2006 1:11 pm
Excellent release :)
The frames are smooth until you start to interact heavily with the falling sand eg Fire/Growth.
Release of the week :D
_________________
MrShlee.com
Projects
Dev-Scene
MyTechpedia
#113314 - nornagon - Tue Dec 26, 2006 1:27 pm
Yeah, the main operation is a pretty na?ve switch with loads of branches; I can't see an easy way out for optimisation. I'm hoping sgstair will have some tips when he wakes up :)
Glad you enjoy it! :D
#113333 - OOPMan - Tue Dec 26, 2006 8:26 pm
Very very cool. Just tested this.
Some things I think would be cool to see:
- Dual-screen flow, L/R to pan/flip screens :-)
- Rotation so you can play with fountains, etc
- Gravity control. Ties in with the rotation...
- More materials types :-)
At the moment it has a pretty cool "elementary" angle. You could also add "para-elementary" stuff for funky mixes :-)
World of Sand could be very cool...
I wonder...
It might also be possible to use the 3d hardware to help on this. I take it it's currently a framebuffer-style affair?
Anyway, I'll keep an eye on this :-)
_________________
"My boot, your face..." - Attributed to OOPMan, Emperor of Eroticon VI
You can find my NDS homebrew projects here...
#113335 - Veg - Tue Dec 26, 2006 9:11 pm
It's a lot of fun, but... is there something that I'm supposed to do with it? Or is it just a freeform 'play around' type of thing?
#113360 - nornagon - Wed Dec 27, 2006 12:08 am
@Veg: It's not a game so much as a toy. Think of it as a Zen garden.
@OOPMan: dual-screen flow would be rather unwieldy and would also deprive me of a place to put my miscellaneous gui elements :)
By 'rotation' do you mean a portrait view? Brain Training-style? If so, already in the todo ;)
No idea what you mean by gravity control.
More materials are definitely on the way!
Para-elements -- like how?
It uses a backbuffer array and blits it to an exrot bg every frame. I can't really see a way to bring the 3D into it... unless, say, you wanted to have multiple gardens -- you could flip between them with L/R and have a pretty 3D box effect or something, and pause the ones that aren't in view.
#113393 - OOPMan - Wed Dec 27, 2006 8:38 am
nornagon wrote: |
@OOPMan: dual-screen flow would be rather unwieldy and would also deprive me of a place to put my miscellaneous gui elements :) |
What I really meant by dual-screen flow was a kind of viewport system. In other words, the "world" is larger than the viewports (The DS' two screens). I would imagine it would be easiest if the "world" were longer vertically than the length of the two screens. This way you could pan up and down within the limits of the world, allowing for even more funky structures to be set up. Also, you could overlay the GUI on separate BG layer. The bottomost layer would be the viewport, while the top-most would be the GUI palette.
nornagon wrote: |
By 'rotation' do you mean a portrait view? Brain Training-style? If so, already in the todo ;) |
Not quite. I was thinking of free scale rotation. Let's say that the game's current view is rotated 0 degrees. Press D-Pad L or D-Pad R would allow you to increase or decrease the rotation in 1 degree increments. However, the rotation would not actually be of the view, but of the game world. The game's center of gravity would remain the same, though. Meaning that if you rotated the view 180 degrees the sand would be fountaining upwards and, if you've got a gravity system, eventually falling back down...
nornagon wrote: |
No idea what you mean by gravity control. |
Well, it's basically a particle system you've got here, right? A lot of particle systems use basic physical laws to handle the particle motion. Particles have x,y and z velocity and also x,y and z acceleration. The world itself has gravity that applies a constant acceleration to some of the values. For example, let's say the x-axis is the up/down vertical axis. Positive x is up, negative x is down. Your particle is moving upwards with a positive x velocity with no x acceleration. Your game world applies a constant negative x acceleration would. This causes the particle to slow down the longer it moves and eventually start moving in the opposite direction at increasing speed. So, basically, are you running a physics system of any kind? Do you plan to?
nornagon wrote: |
More materials are definitely on the way! |
Sweet :-)
nornagon wrote: |
Para-elements -- like how? |
Just silly role-playing jargon. For example, if Water + Earth = Mud. Therefore, Mud is the para-element of Water & Earth :-)
nornagon wrote: |
It uses a backbuffer array and blits it to an exrot bg every frame. I can't really see a way to bring the 3D into it... unless, say, you wanted to have multiple gardens -- you could flip between them with L/R and have a pretty 3D box effect or something, and pause the ones that aren't in view. |
Well, you could use very small triangles or something with a particle texture applied. But you might end up over-running the hardware's limits...
Bah, I'm not to hot on the 3d HW side of things, as you can guess :-)
_________________
"My boot, your face..." - Attributed to OOPMan, Emperor of Eroticon VI
You can find my NDS homebrew projects here...
#113398 - Lord Raptor - Wed Dec 27, 2006 10:03 am
Nice work nornagon !
I liked this game on PC, and always thought it should be ported on the DS !
Playing it with the stylus is a real pleasure.
Thanks !
#113402 - xtoc - Wed Dec 27, 2006 11:58 am
I think you could create a nice game with it
Starting like the first level : fill every box with the right type of sand... and so on
nice works
about the features , i agree with OOPMan
#113405 - nornagon - Wed Dec 27, 2006 12:14 pm
@OOPMan: No, there is no particle system as such. Each pixel is just that; a pixel. A calculation is run over every pixel such that it can react to the pixels in its immediate vicinity. No forces, no speeds, no accelerations, no gravity. Just sneaky use of rand() that makes it look like that.
The viewport idea I don't think would really work (though it's totally possible). One of the nice things about WoS is being able to see everything happening at once -- it's quite amazing how you can miss something happening only 20 pixels away. Bits that you actually *can't* see would make it a lot harder to manage, as the player.
With the para-elements, try mixing (say) salt and water. ;) I do my best to come up with as many combinations as possible, suggestions are welcome.
It's pretty much impossible to display that many particles in 3D, let alone do collision, combination, etc. It'd be a struggle even on a modern PC.
@xtoc: Interesting idea... I think having a progression kinda ruins the main point of the game, but there could always be a separate mode for playing the progression vs. 'sandbox' mode. Heh, sandbox.
#113453 - K-Duke - Wed Dec 27, 2006 10:36 pm
This playground really rocks! It somehow reminds me of the game Clonk which looks like WoS for the moving sand and water! thats some really neat stuff! I guess you should try it out. The older versions of it are freeware.
Keep up the good work.
PS: A nice new material would be Lava. Being fluid but flaming up everything in its way. Metal which doesn't burn by itself but can be heated up so bad that its other end incirnates wood.
Just cool! This is a nice break-filler :-D
#113465 - nornagon - Wed Dec 27, 2006 11:23 pm
Heh, I already have liquid fire (and a bunch of other funky stuff) on my TODO... lava is a better name, perhaps :)
#113938 - lolmasta - Mon Jan 01, 2007 2:06 pm
Whoohoo! Someone on the forums of the sand game made a port for this but this is more awesome.
Is there a way to stop the stuff from falling in the start of the game?
Will you add sizes in later versions?
Also, nornagon, you can try converting the whole Lynx's Mod to the DS.
#113941 - nornagon - Mon Jan 01, 2007 3:28 pm
There's no way to stop the materials flowing from the top yet, but there will be in future versions. Thick brushes have already been implemented in my local copy. What's a Lynx's Mod?
#113956 - laurens - Mon Jan 01, 2007 10:16 pm
It's a Physics file for the FallingSand program called wxSand
I guess he wants you to add most of the elements into your homebrew program
#113964 - lolmasta - Mon Jan 01, 2007 11:25 pm
It would be also possible to make a version that lets you use physics files of WXSand (without icons, just text)
#113984 - nornagon - Tue Jan 02, 2007 6:39 am
Hm, interesting.
The trouble with being able to load arbitrary physics stuff dynamically is that it would be very slow without enormous amounts of trickery (dynamic recompilation, basically). It *might* be possible to write a compiler from the crazy wxSand physics files, and maybe some sort of plugin system could be worked out. AFAIK, though, position independent (i.e, plugin) code tends to be slower than normal code (correct me if I'm wrong), and I also need the plugin code to run on both the arm7 and the arm9. Oh, and it has to fit into itcm, too (though that shouldn't be an issue for all but the most complicated physics sets).
I was thinking about creating some kind of abstract syntax for representing physics models, but I think that's probably quite a way down the line. In the mean time, there looks to be a fair few good ideas here that I could appropriate :) Thanks for linking me.
#113987 - Drood - Tue Jan 02, 2007 7:24 am
I spent 15 minutes playing with this last night... It's one of those things which when you describe, it sounds stupid. (Kinda like Harvest Moon:)) But in execution, it's compelling. I sat for 15 minutes, buggering around with sand.
The most fascinating bit of homebrew I've seen I think.
#113991 - lolmasta - Tue Jan 02, 2007 10:22 am
Well, Nornagon, if you don't feel ready to do that, just make your plans and make physics stuff if you want.
(lava is also included in Lynx's Mod, Hmm?)
#113997 - nornagon - Tue Jan 02, 2007 3:12 pm
Drood wrote: |
I spent 15 minutes playing with this last night... It's one of those things which when you describe, it sounds stupid. (Kinda like Harvest Moon:)) But in execution, it's compelling. I sat for 15 minutes, buggering around with sand.
The most fascinating bit of homebrew I've seen I think. |
:)
@lolmasta: Yep, at some point there might be a selection of different physics models; it's something i have indeed considered. For now I think I will just steal ideas from Lynx's mod :D
#114023 - Dood77 - Tue Jan 02, 2007 11:54 pm
I just discovered a whole community of falling sand games: http://fallingsandgame.com its got a whole bunch of different games wth tons of new materials and features, the main three different branches are: pyro sand 2, new sand game, and x sand. New sand game is probably the most bizzare, you should check it out ;)
#114038 - nornagon - Wed Jan 03, 2007 3:01 am
Looks interesting. I guess I'll have to install Java :(
#114269 - oman00339 - Sat Jan 06, 2007 12:17 am
Some of the things I would like to see would be some of the explosive elements in the Pyro Sand games. (Nitro, Napalm, Gunpowder, C-4, Owko)
Each is similar but has different characteristics in the way it explodes.
http://enigmasand.com/pyro2.html
#114289 - jdub2027 - Sat Jan 06, 2007 9:35 am
Will this work on the new R4DS or M3 Simply Slot-1 cards? I hope so!!
#114309 - lolmasta - Sat Jan 06, 2007 3:35 pm
nornagon wrote: |
@lolmasta: Yep, at some point there might be a selection of different physics models; it's something i have indeed considered. For now I think I will just steal ideas from Lynx's mod :D |
Huh, ok :D
jdub2027 wrote: |
Will this work on the new R4DS or M3 Simply Slot-1 cards? I hope so!! |
Well, it works on the DS-X, so I don't see any reason for it non working on other Slot-One's.
#114385 - nornagon - Sun Jan 07, 2007 12:53 pm
World of Sand currently has no libfat-requiring features, so it should work fine with any device that loads code.
Some of the Pyro Sand effects seem a bit hackish -- i.e, they break the principle of simplicity: that each pixel affects only the pixels immediately surrounding. IMO, the pyro sand materials aren't all that interesting, either (except, perhaps, for 'fuse').
#114442 - Dood77 - Sun Jan 07, 2007 11:48 pm
i thought the nitro was cool, and the torch is definately useful.
#114464 - Darkflame - Mon Jan 08, 2007 3:37 am
Isnt the whole point of the fun to maximise the potential for setting up chain reactions?
PyroSand seemed great for that, only the oil didnt float nearly as well as it should have imo.
(my idea was to have water dripping onto a box with oil, lifting the oil up, which when its high enough hits a torch, which makes the fire spread to the other side lighting a fuse.....)
_________________
Darkflames Reviews --
Make your own at;
Rateoholic:Reviews for anything, by anyone.
#114469 - nornagon - Mon Jan 08, 2007 4:01 am
Torch is definitely a candidate for inclusion, as are a few other pyromaniac-friendly materials I've dreamed up. I can't remember what Nitro does, but I remember that a lot of Pyro Sand materials seemed to violate the aforementioned principle of simplicity.
#114477 - Dood77 - Mon Jan 08, 2007 7:03 am
Nitro is the most violent explosive, its a liquid that sends flaming sparks in every direction, almost igniting everything on the screen. Its possible to start out with a torch, start drawing some nitro and let it ignite and hold the mouse button down to keep on laying down nitro and it keeps a steady explosion going, its lotsa fun :) but i can see some major slowdowns happening with this on the ds.
#114656 - nornagon - Tue Jan 09, 2007 9:22 pm
Ah, that. It's possible that could be implemented without breaking the principle of simplicity, but it would be tricky and quite possibly hackish.
#114691 - jdub2027 - Wed Jan 10, 2007 2:45 am
Just wanted to let you know that it does work on the R4DS. Very cool program. Do you think you could add the ability to turn off the constant streams?
EDIT: Actually its easy enough to just block them off...just keep updating this program, its awesome!!!
#114695 - HyperHacker - Wed Jan 10, 2007 5:36 am
I think the important part is keeping the game fun, rather than maintaining simplicity.
_________________
I'm a PSP hacker now, but I still <3 DS.
#114834 - Dood77 - Thu Jan 11, 2007 12:21 am
jdub2027 wrote: |
Actually its easy enough to just block them off...just keep updating this program, its awesome!!! |
It would be nice to beable to change what flows, and how much of it.
#115031 - nornagon - Fri Jan 12, 2007 10:22 am
@HyperHacker: There's also the problem that drawing circles breaks cache lines, and would be REALLY slow. Oh yeah, and it also would break the way I currently have the processing split across the ARM9/ARM7. So it's kind of important that it doesn't change.
That said, I think 'cheating' like that (drawing circles, thus breaking simplicity) also makes the game less fun -- more interesting effects are created without it, imo.
#115289 - jdub2027 - Sun Jan 14, 2007 7:06 pm
Hey, World of Sand was featured in a podcast on this site: http://homebrewcast.com/nds/
They talk about it about half way through and they really loved it.
#116036 - japala - Sun Jan 21, 2007 8:27 am
Our article that also features this "game".
http://www.metku.net/index.html?path=articles/nds/index_eng
btw. any news on the next version?
#116436 - oman00339 - Thu Jan 25, 2007 7:16 pm
I found a bug. When you use ???, it doesn't destroy plant.
#116545 - RavenWorks - Fri Jan 26, 2007 6:18 pm
Oh, man, fantastic :) I loved the original, and this is a top-quality port! :)
One tiny bug report... when I try and draw up and down the left side of the screen, I get streaks straight from the left side to the right side... this is probably a calibration issue, but I'm probably not the only person with a slightly-miscalibrated DS (and in fact, the calibration seemed spot-on to me)....
Anyway, thanks for a very enjoyable bit of homebrew! :D
#116552 - oman00339 - Fri Jan 26, 2007 8:04 pm
RavenWorks wrote: |
One tiny bug report... when I try and draw up and down the left side of the screen, I get streaks straight from the left side to the right side... this is probably a calibration issue, but I'm probably not the only person with a slightly-miscalibrated DS (and in fact, the calibration seemed spot-on to me)....
|
I have that same issue too. It's still a great app!
#116557 - NeX - Fri Jan 26, 2007 8:49 pm
No, I think that's a handy bug. It makes it easy to fill a scanline with one thing. Nothing escapes. NOTHING!
#116561 - oman00339 - Fri Jan 26, 2007 9:59 pm
NeX wrote: |
No, I think that's a handy bug. It makes it easy to fill a scanline with one thing. Nothing escapes. NOTHING! |
Of course that's true too. It does come in handy some times, like when you need to block off the spouts at the top.
#117085 - bugmenot! - Thu Feb 01, 2007 3:36 am
oman00339 wrote: |
Some of the things I would like to see would be some of the explosive elements in the Pyro Sand games. (Nitro, Napalm, Gunpowder, C-4, Owko)
Each is similar but has different characteristics in the way it explodes.
http://enigmasand.com/pyro2.html |
Yes, definitely add explosions, nothing is fun without explosions...
#117093 - Dood77 - Thu Feb 01, 2007 6:49 am
Oh wow, genious idea... although potentially memory hungry, i dont know:
Use the DS motion sensor to beable to tilt and change the direction of flow/shake up the sand!
#117169 - oman00339 - Fri Feb 02, 2007 1:23 am
Dood77 wrote: |
Use the DS motion sensor to beable to tilt and change the direction of flow/shake up the sand! |
I was thinking about that too! It would be cool to be able to shake up the sand or be able to tilt it and control the direction the stuff falls.
#117524 - nornagon - Mon Feb 05, 2007 10:46 am
RavenWorks wrote: |
One tiny bug report... when I try and draw up and down the left side of the screen, I get streaks straight from the left side to the right side... this is probably a calibration issue, but I'm probably not the only person with a slightly-miscalibrated DS (and in fact, the calibration seemed spot-on to me).... |
Odd... it's been yonks since I used that version (and it doesn't happen in my development version.) I guess that's what happens with betas!
Anyway, I've a smallish list of things I want to get done before I release beta 2. I'm not going to make promises on a release date, because I'm in the throes of my last year of school and there's no small amount of work, but I'll try to bring it out as soon as I can. Thanks to everyone for all the positive feedback!
Dood77 wrote: |
Oh wow, genious idea... although potentially memory hungry, i dont know:
Use the DS motion sensor to beable to tilt and change the direction of flow/shake up the sand! |
My friend had the exact same idea yesterday! How weird. Anyway, I'd love to see what I could do with a motion sensor card, but I don't have one. If anyone *really* wants to see motion stuff happening.... ;)
#119344 - oman00339 - Thu Feb 22, 2007 2:34 am
Any news on the next release?
#122425 - nornagon - Mon Mar 19, 2007 7:05 am
Hey all, sorry for not responding of late. I'm in my last year of high school (college, whatever you crazy foreigners call it -- after this I'll be at uni), so things have been a bit hectic and I've not been able to work on WoS.
There are a number of things I'd like to have rounded off a little better before the next release. I've added four new materials (concrete, acid, antimatter and liquid fire), and would like to maybe add another couple before release, and also to better define all the new possible interactions. My exams finish in a couple of weeks, so hopefully I'll be able to find a few hours around then to spend some time on it.
I'm not dead yet! :)
On a side note, there've been around a thousand downloads of World of Sand to date. Awesome!
#126952 - lolmasta - Sat Apr 28, 2007 10:56 am
nornagon wrote: |
Hey all, sorry for not responding of late. I'm in my last year of high school (college, whatever you crazy foreigners call it -- after this I'll be at uni), so things have been a bit hectic and I've not been able to work on WoS.
There are a number of things I'd like to have rounded off a little better before the next release. I've added four new materials (concrete, acid, antimatter and liquid fire), and would like to maybe add another couple before release, and also to better define all the new possible interactions. My exams finish in a couple of weeks, so hopefully I'll be able to find a few hours around then to spend some time on it.
I'm not dead yet! :)
On a side note, there've been around a thousand downloads of World of Sand to date. Awesome! |
Please add Glass. And the ability to boil water.
#126967 - chishm - Sat Apr 28, 2007 3:53 pm
#126968 - Lick - Sat Apr 28, 2007 4:03 pm
Paste? I prefer RAMEN.
_________________
http://licklick.wordpress.com
#126985 - Dood77 - Sat Apr 28, 2007 10:00 pm
lolmasta wrote: |
Please add Glass. And the ability to boil water. |
Has there been these in any sand game clones at all?
#127012 - Darkflame - Sun Apr 29, 2007 4:59 am
Dood77 wrote: |
lolmasta wrote: | Please add Glass. And the ability to boil water. |
Has there been these in any sand game clones at all? |
Boiling water certainly has been in many.
eg. Water + Lava = Steam.
After awhile , the steam condense's and drips back down.
Makes many interesting possibilitys.
Steam could be done with a reverseing of gravity, doing it with bouncey might get too complex.
_________________
Darkflames Reviews --
Make your own at;
Rateoholic:Reviews for anything, by anyone.
#127155 - lolmasta - Mon Apr 30, 2007 2:03 pm
New version's out! Saw it in GBATemp.