Git Product home page Git Product logo

worldlinesim's Introduction

World Line Simulator

A BIG overhaul on the way... ab is duniya me bolne, sun ne, dekhne, sochne wale log honge... :D


As of now, it can be said that it simulates a simple 3D multiverse

And... it currently doesn't have 3D rendering, since that wasn't of importance earlier, the theoretical implementation was the goal, but it's interesting, think of the very basic idea as this ->

Think about a world, in which some snakes keep moving automatically to get food, any `time*` the universe has some state; You go back in time, change anything, that then changes the state then, and hence the present and the future

ie. Time Travel following the WorldLine theory, stated in the Anime Steins Gate

It has a 3D auto expanding space, like a simple form of our universe Now the project offers much more, since you can now have as many entities as memory allows, and can CREATE your own entities too.

This project generalises the idea to entities and actions, in different worlds and worldlines, all independently on different threads, as well theoretically different verses too, other than this ->

It also features a constantly growing matrix (the world_plot), using another project GraphMat3D that was actually a part of this one itself

Building

First do a recursive clone, then

cd build   # if doesn't exist, then create
cmake ..
cmake --build .

You may set CMAKE_Build_Type as Release

Creating your own Custom ENTITIES (for example, horses)

  • Inherit from the Entity class, override/implement the startSimulation and pauseSimulation virtual member functions, and others that are pure virtuals, and need to be overloaded in Entity class

  • In World constructors, make sure your push your new entities to the entities vector with entities.push_back(new Horse(this));

Constructor - An entities constructor takes in the World*, so that it has access to the worldplot (consider it the space fabric here, just a matrix), for eg, calling world->getRandomCoord() to get a position in the world See the constructor of other entity, for eg. Human, Rock, Snake for reference

Current State

Note: Currently the focus is that internally the simulation happens, but maybe the display won't be very great now, so it just logs on console (Since, I don't have a ground in rendering things currently, if you have ideas, or suggestions do put in that pinned issue)

NOTE: The time is integral now

Current State

Class Diagram

Many entities have been added after this, leaving it so, as it clarifies the base things

Made with draw.io

Class Diagram

Future Ideas

There have been lots of ideas, all just in code, from now on, adding here, what i think...

  • 3D Rendering -> Currently, EVERYTHING happens, and is correctly simulating, devs working on this maybe satisfied, though actually being able see them moving will absolutely be a great thing

  • Sparse Matrix for space -> Currently it uses the graphMat library for the 3D matrix, ie, the space here, in current scenario a sparse data structure will be more beneficial

3D Rendering wasn't the aim at beginning; Developed graphMat as dense matrix as per the eariler needs, they have slightly changed with the current ways entities exist

Source of Idea

Steins Gate (Anime)

and...

My Interest, and thinking ๐Ÿ˜Ž๐Ÿ˜Ž

ยฉ๏ธ Aditya Gupta 2020

worldlinesim's People

Contributors

adi-g15 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.