An open API service indexing awesome lists of open source software.

https://github.com/exposedcat/world.js

Are we living in simulation? what if our world written in JavaScript ? 😆
https://github.com/exposedcat/world.js

Last synced: 27 days ago
JSON representation

Are we living in simulation? what if our world written in JavaScript ? 😆

Awesome Lists containing this project

README

          

# World.JS
Are we living in simulation? What if our world written in JavaScript ? 😆

To run World, import `Universe` class from `universe.mjs`, one of initialization types from `initTypes.mjs` and make anything you want 😜
Exmaple `index.js`:
```js
import { Universe } from './universe.mjs'
import { bigBang } from './initTypes.mjs'

const myUniverse = new Universe()
myUniverse.init(bigBang)
myUniverse.makeGalaxy()
myUniverse.galaxies[0].makePlanet()
myUniverse.galaxies[0].makeStar()
myUniverse.galaxies[0].makeStar()

console.dir(myUniverse)
```