Project 130 Computational Fluid Dynamics posted as free Resource
by PhoenixGames on Dec.20, 2013, under Software and Games, Tutorials
I have decided to release my Computational Fluid Dynamics code as a free resource for users of the Torque 3D game engine.
My resource can be found here:
http://www.garagegames.com/community/blogs/view/22519
I have duplicated the text of the resource below.
This resource adds support for “metablobs” to T3D. This can allow for very realistic fluid simulations, much more so than can be achieved with particle effects.
Included are a realistic Water material, a Lava Material, A Tar material, and a Mud material. I have also included a ported version of the renderMonkey glitter shader.
Tutorial:
First, download the resource from here: (4.2MB’s, .RAR archive)
http://www.phoenixgamedevelopment.com/downloads/FluidDynamics.rar
Copy the “Fluid Dynamics” folder to:
“game/art/shapes/FluidDynamics”
Inside the archive is a folder called “SHADERS”. All files in this folder should be copied to:
game/shaders/common/
Drop the files directly in that folder, do not include the “SHADERS” directory itself.
There should also be a folder called “CODE”. All files in this directory should be added to:
“engine/source/T3D/examples/metaBlobs”
In your compiler, you will then need to add these files to the build.
In order to add MetaBlob based objects to the world using the editor, add the following line to:
“game/tools/worldeditor/scripts/editors/creator.ed.cs
Around line 100, under:
%this.registerMissionObject( “RenderShapeExample” );
add:
%this.registerMissionObject( “metaBlobExample” );
The resource folder also contains a sample mission file showing how to create a metablob object from code.
Finally, execute the file “fluiddynamics.cs” by adding the line:
exec(“art/shapes/FluidDynamics/fluiddynamics.cs”);
to:
“game/scripts/server/scriptExec.cs”
Any questions, comments, etc, can be directed to:
jackstone@phoenixgamedevelopment.com