Skip to content

tterrasson/liquid-simulator-godot

Repository files navigation

Hello, welcome to AJ-Wi the space where we learn together

LiquidSim

2D Liquid simulator with cellular automaton in Godot Engine (GDNative / C++) - NativeScript 1.1

prerequisites

  • Godot 3.x executable

  • C++ compiler

  • SCons as a build tool

  • emcc compiler


API

$LiquidSim.start() : Start the simulation (started by default)

$LiquidSim.stop() : Stop the simulation

$LiquidSim.update_simulation() : Force an update

$LiquidSim.cleanup_empty_cells() : Cleanup all empty cell (automatic)

$LiquidSim.add_liquid(int x, int y, float amount) : Add some liquid to the cell

$LiquidSim.del_liquid(int x, int y) : Empty a cell

$LiquidSim.set_liquid(int x, int y, float amount) : Set a fixed amount of liquid to the cell

$LiquidSim.get_liquid(int x, int y) float : Return the amount of liquid for the cell




Original repository

$ git clone --recurse-submodules https://github.com/tterrasson/liquid-simulator-godot

For more details, see "Using the Guide"



Remember We can all code, but together we can learn

About

2D Liquid simulator with cellular automaton in Godot (GDNative / C++) - Godot 3.2

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published