Giter Site home page Giter Site logo

magikal-lands's Introduction

Magikal-Lands

This is a woking concept for a game I have in mind.

Currently, the game loads the player and a randomly generated tile map onto the screen.

There are elemental orbs located at specific positions in the world. These orbs modify the environmental conditions(temperature and humidity) of its surroundings. As time passes, these physical properties diffuse to its suroundings until an equilibrium is achieved.

Different environmental conditions can lead to different tile types. Currently they are the plains(lightgreen), swampy(darkgreen), snow(white), desert(orange) and cursed(brown).

For efficiency during runtime, the entire world map has been divided into chunks and each chunk has particular environmental conditions(temperature and humidity). The environmental conditions of any tile is then calculated from the chunk it is in and the surrounding chunks, with a weight function dependant on the distance of that tile from the center of the chunks.

Also, the temperature and humidity are measured in a scale of 1 to 100.
Temperature of 1: Very cold.
Temperature of 100: Very hot.
Humidity of 1: Very dry.
Humidity of 100: Very humid.

Screenshots

Plains. Plains

Plains to snow transition. Snow transition

Plains to swamp transition. Swamp transition

Plains to desert transition. Desert transition

Plains to wasteland transition. Wasteland transition

Cold orb. Reduces temperature of surroundings. Cold orb

Map view. Map view

Map during start of diffusion. Diffusion start

Map after diffusion reaches equilibrium. Diffusion end

Running the program

To run the program, first clone this repository to a local directory.

Then run the following command in a terminal opened from this directory to install all required dependencies:

pip install -r requirements.txt

Finally run main.py from the same terminal.

python main.py

Interaction with the game

Use arrow keys to move around the world.

The following keys are mapped to the following actions:

1 -> Diffuses physical properties.

2 -> Updates entities.

3 -> Toggles live diffusion.

4 -> Runs diffusion and updation for 100 frames.

 Caution: I do not recommend leaving DEBUG = True for the below two actions.

5 -> Runs diffusion and updation for 1000 frames.

6 -> Runs diffusion and updation for 10000 frames.

7 -> Slows down player movement speed.

8 -> Speeds up player movement speed.

m -> Toggles world map.

q -> Closes the game.

Known issues

Credits

Brainstorming for ideas: Agamdeep Singh(https://github.com/jnash10)

Assets(images): Pixel-Boy(https://pixel-boy.itch.io/ninja-adventure-asset-pack)(https://www.patreon.com/pixelarchipel)

magikal-lands's People

Contributors

monopolize-all avatar

Watchers

 avatar Akshat Singh 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.