Giter Site home page Giter Site logo

gol's Introduction

Conway's Game of Life implemented in C and SDL2

You MUST install the SDL2 library and cmake before going any further.

Automated Installation via cmake (Linux possibly Mac)

Note that if install.sh is not marked executable by default you mut run chmod +x install.sh.

Manual Installation via cmake (Linux possibly Mac)

To install manually make sure you have requisite SDL2 libraries and cmake. You MUST use the recursive flag to pull in the FindSDL2.cmake submodules. (Or git submodule update --init after the fact).

Note that by default, the binary is targeted at the originating folder. The build folder can be discarded; rm -rf build

Installation via Makefile (for FreeBSD/Dragonfly especially)

It's the damndest thing but I cannot figure out why my original makefile works here yet the cmake build does not. No matter, I've added a branch so that installation via the traditional Makefile is possible. Dragonfly/gcc users remember to change CC flag of Makefile to gcc.

Notes

Space will run/pause the time evolution and allow you to populate the grid. Escape to exit. Backspace will clear the screen. Window should be resizable now. Please report any bugs and I'll try to fix them immediately.

For more advanced usage such as changing cell size and rate of time evolution see ./conway -h:

Usage: conway [-t ticks] [-c cell_size]

-t Set number of ticks in microseconds. Enter extremely low values at own peril. Recommended to stay in 30000-100000 range. Defaults to 50000.

-c Set cell size to small, medium or large. Defaults to small.

The inclusion of the FindSDL2.cmake modules should make this port to just about anything. If you have an issue on your system, please let me know.

gol's People

Contributors

9ziggy9 avatar

Stargazers

 avatar  avatar  avatar

Watchers

 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.