Noita-Inspired Sand/Water Simulation

Introduction

Welcome to my Noita-inspired sand and water simulation project! Inspired by the physics-based roguelike game Noita, this simulation uses the Pygame library to create a dynamic, grid-based environment where different types of cells interact in fascinating ways. In this simulation, you can spawn and observe the behavior of various cells, such as sand and water, as they respond to their environment according to predefined rules. This project serves as a great introduction to both the Pygame library and the principles of cellular automata.

Why Noita?

Noita is renowned for its innovative use of physics and cellular automata to create a highly interactive and destructible environment. By drawing inspiration from Noita, I aim to explore the potential of simulating complex systems using simple rules, a concept that is not only entertaining but also educational. Whether you're a game developer, a hobbyist, or a student, this project offers valuable insights into the mechanics of simulating realistic interactions between different materials.

Project Overview

In this simulation, each cell type behaves according to specific rules:

The interaction between these cells creates an engaging and visually appealing simulation that can be endlessly tinkered with and expanded upon.

Installation

Ready to dive into the world of sand and water simulation? Follow these simple steps to install and run the project on your machine.

Prerequisites

Before you begin, ensure you have Python and Pygame installed. If you don't have them installed, you can download Python from the official Python website and install Pygame using pip.

Step-by-Step Guide

  1. Clone the Repository Begin by cloning the project's repository from GitHub. Open your terminal and run:

    git clone https://github.com/skudunter/noita-sand-sim
    
  2. Navigate to the Project Directory Change your current directory to the project's folder:

    cd noita-sand-sim
    
  3. Install Dependencies Use pip to install Pygame, the only external library required for this project:

    pip install pygame
    
  4. Run the Simulation Finally, start the simulation by running the main script:

    python main.py
    

Enjoy the Simulation!

Once the setup is complete, the simulation will launch, and you can start experimenting with spawning and interacting with different cell types. Watch as sand and water particles behave according to their programmed rules, and feel free to modify the code to explore new behaviors and interactions.

This project is a perfect blend of fun and learning, offering a glimpse into the exciting world of cellular automata and physics simulations. I hope you enjoy building and experimenting with your Noita-inspired sand and water simulation!

Links