Skip to content

Commit

Permalink
Merge branch 'main' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
EternoSeeker authored May 16, 2024
2 parents e5b3a55 + 0647c9f commit 3015adc
Show file tree
Hide file tree
Showing 6 changed files with 257 additions and 215 deletions.
16 changes: 16 additions & 0 deletions .github/workflows/greetings.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
name: Greetings

on: [pull_request_target, issues]

jobs:
greeting:
runs-on: ubuntu-latest
permissions:
issues: write
pull-requests: write
steps:
- uses: actions/first-interaction@v1
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
issue-message: "Hi there! Thanks for opening this issue. We appreciate your contribution to this open-source project. We aim to respond or assign your issue as soon as possible."
pr-message: "Welcome to Our repository.🎊 Thank you so much for taking the time to point this out."
20 changes: 15 additions & 5 deletions LEARN.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@

Welcome to the Conway's Game of Life project! This document will guide you on how to run the project and provide additional resources to learn more about the game.

## Running the Project
---
## 🚀 Running the Project

### Using a Live Server Extension

Expand All @@ -18,7 +19,8 @@ Welcome to the Conway's Game of Life project! This document will guide you on ho

5. Your default web browser should automatically open, displaying the Conway's Game of Life project.

### Guide to playing the game

### Guide to Playing the Game

1. Click on the cells to toggle them between alive and dead states.

Expand All @@ -28,13 +30,17 @@ Welcome to the Conway's Game of Life project! This document will guide you on ho
- **Clear**: Clear the board.
- **Random**: Randomly set cells to alive or dead.

#### You can also check the [Step by Step Guide](https://scribehow.com/shared/Customize_Game_of_Life_Simulation_Visuals_and_Patterns__n1LPE5YdTHSDSydMI76yfQ)
#### For a detailed walkthrough, check the [Step by Step Guide](https://scribehow.com/shared/Customize_Game_of_Life_Simulation_Visuals_and_Patterns__n1LPE5YdTHSDSydMI76yfQ)

---

## Commit Conventions
## 📜 Commit Conventions

For managing commits in this project, we follow the conventional commit specification. You can find more information about the conventions at [Conventional Commits](https://www.conventionalcommits.org/en/v1.0.0/). Following these conventions helps maintain a clean and structured commit history.

## Other Resources
---

## 🌐 Other Resources

### Try Playing It Online

Expand All @@ -47,3 +53,7 @@ For managing commits in this project, we follow the conventional commit specific
- [Conway's Game of Life - Wikipedia](https://en.wikipedia.org/wiki/Conway%27s_Game_of_Life)

Explore these resources to dive deeper into Conway's Game of Life and enhance your understanding of the game's principles, patterns, and applications.

<div align="center">
<h2>Enjoy exploring the intricate world of Conway's Game of Life!</h2>
</div>
95 changes: 53 additions & 42 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,32 +1,36 @@
# Conway's Game of Life
## What is it?
<div align="center">
<h1>Conway's Game of Life</h1>
<p>A cellular automaton devised by British mathematician John Horton Conway in 1970.</p>
</div>

Conway's Game of Life, or simply "Life," is a cellular automaton devised by British mathematician John Horton Conway in 1970. It is a zero-player game, meaning its evolution is determined by its initial state, requiring no further input. Players interact with the game by creating an initial configuration and observing how it evolves. The game is Turing complete and can simulate a universal constructor or any other Turing machine.
---
## ✨ What is it?

### The Universe
Conway's Game of Life, or simply "Life," is a cellular automaton devised by British mathematician John Horton Conway in 1970. It is a zero-player game, meaning its evolution is determined by its initial state, requiring no further input. Players interact with the game by creating an initial configuration and observing how it evolves. The game is Turing complete and can simulate a universal constructor or any other Turing machine.

The universe of the Game of Life is an infinite, two-dimensional orthogonal grid of square cells,
---

Each cell is in one of two possible states, `ALIVE` or `DEAD`.
## 🌌 The Universe

Every cell interacts with its eight neighbors, which are the cells that are horizontally, vertically, or diagonally adjacent.
The universe of the Game of Life is an infinite, two-dimensional orthogonal grid of square cells. Each cell is in one of two possible states: `ALIVE` or `DEAD`. Every cell interacts with its eight neighbors, which are the cells that are horizontally, vertically, or diagonally adjacent.

## The Rules
---
## 📜 The Rules

1. Any live cell with fewer than two live neighbors dies, as if by **underpopulation**.
2. Any live cell with two or three live neighbors lives on to the next generation.
3. Any live cell with more than three live neighbors dies, as if by **overpopulation**.
4. Any dead cell with exactly three live neighbors becomes a live cell, as if by **reproduction**.

The first generation is created by applying the above rules simultaneously to every cell in the seed, alive or dead;
births and deaths occur simultaneously, and the discrete moment at which this happens is sometimes called a tick. Each generation is a pure function of the preceding one.
The first generation is created by applying the above rules simultaneously to every cell in the seed, alive or dead; births and deaths occur simultaneously, and the discrete moment at which this happens is sometimes called a tick. Each generation is a pure function of the preceding one.

## The Game
---

## 🎮 The Game

### The Canvas / Grid
### 🖼️ The Canvas / Grid

<img src="data/game-images/Game-Grid.png" height="300">
![Game Grid](data/game-images/Game-Grid.png)

| Buttons | What they do |
| --- | --- |
Expand All @@ -37,17 +41,19 @@ births and deaths occur simultaneously, and the discrete moment at which this ha
| `Clear` | Clears the grid on click, only if the game is not animating at that moment |
| `Random` | Randomly initializes the grid with initial randomness as 20% |

### The Settings

<img src="data/game-images/Game-Sidebar.png" height="350">
### ⚙️ The Settings

![Game Sidebar](data/game-images/Game-Sidebar.png)

| Settings | What are they for? |
| --- | --- |
| `Gridlines` | Toggles visibility of the gridlines |
| `Warp on Edges` | Warps the patterns across the edges - Initially set as true |
| `Randomness` | Allows you to set custom randomness percent for random initialization |

### The Themes

### 🎨 The Themes

| Themes | The Colors |
| --- | --- |
Expand All @@ -58,18 +64,22 @@ births and deaths occur simultaneously, and the discrete moment at which this ha
| Dark Cyan | ![#045a5a](https://placehold.co/15x15/045a5a/045a5a.png) ![#75B2B2](https://placehold.co/15x15/75B2B2/75B2B2.png) ![#039696](https://placehold.co/15x15/039696/039696.png) ![#EBFFFF](https://placehold.co/15x15/EBFFFF/EBFFFF.png) ![#2A7E7E](https://placehold.co/15x15/2A7E7E/2A7E7E.png) ![#103636](https://placehold.co/15x15/103636/103636.png) ![#012626](https://placehold.co/15x15/012626/012626.png) ![#C6DEDE](https://placehold.co/15x15/C6DEDE/C6DEDE.png) ![#006b6b](https://placehold.co/15x15/006b6b/006b6b.png) ![#cafcfc](https://placehold.co/15x15/cafcfc/cafcfc.png) |
| Dark Neon | ![#d0ff00](https://placehold.co/15x15/d0ff00/d0ff00.png) ![#00cc26](https://placehold.co/15x15/00cc26/00cc26.png) ![#00b81b](https://placehold.co/15x15/00b81b/00b81b.png) ![#004640](https://placehold.co/15x15/004640/004640.png) ![#fc0101](https://placehold.co/15x15/fc0101/fc0101.png) ![#000000](https://placehold.co/15x15/000000/000000.png) ![#002628](https://placehold.co/15x15/002628/002628.png) ![#000525](https://placehold.co/15x15/000525/000525.png) ![#9800f5](https://placehold.co/15x15/9800f5/9800f5.png) ![#80ffff](https://placehold.co/15x15/80ffff/80ffff.png) |

### History

> Also stores history of patterns that user has played with, up to 5 recent patterns
### ⏳ History

Stores history of patterns that user has played with, up to 5 recent patterns.

---

## 🔮 The Presets

## The Presets
### Glider

The glider is the smallest, most common, and first-discovered spaceship in Game of Life. It travels diagonally across the grid, Gliders are important because they are easily produced (by glider guns and rakes) can be collided with each other to form more complicated patterns, and can be used to transmit information over long distances.
The glider is the smallest, most common, and first-discovered spaceship in Game of Life. It travels diagonally across the grid. Gliders are important because they are easily produced, can be collided with each other to form more complicated patterns, and can be used to transmit information over long distances.

<div>
<img src="data/game-images/Small-Glider.png" alt="Small Glider" height="150">
<img src="https://conwaylife.com/w/images/8/81/Glider.gif" height="150">
<img src="data/game-images/Small-Glider.png" alt="Small Glider" height="150">
<img src="https://conwaylife.com/w/images/8/81/Glider.gif" height="150">
</div>

### Big Glider
Expand All @@ -85,35 +95,36 @@ The big glider was found by Dean Hickerson in December 1989 and was the first kn

The Gosper glider gun is the first known gun, and indeed the first known finite pattern with unbounded growth, found by Bill Gosper in November 1970. It consists of two queen bee shuttles stabilized by two blocks.

<img src="data/game-images/Gosper-Glider-Gun.png" alt="Gosper Glider Gun" height="150">
<img src="https://conwaylife.com/w/images/b/b6/Gosperglidergun.gif" height="150">


#### More Configurations

https://conwaylife.com/wiki/Category:Patterns
<div>
<img src="data/game-images/Gosper-Glider-Gun.png" alt="Gosper Glider Gun" height="150">
<img src="https://conwaylife.com/w/images/b/b6/Gosperglidergun.gif" height="150">
</div>

## The Resources
### More Configurations

#### Spark your interest
Explore more patterns at [ConwayLife Patterns](https://conwaylife.com/wiki/Category:Patterns).

https://www.youtube.com/watch?v=R9Plq-D1gEk
---

https://youtu.be/C2vgICfQawE?si=yWqN0BOSBOMaujkI
## 📚 Resources

#### Also try playing it here
### Spark your interest

https://playgameoflife.com/
- [The Game of Life | John Conway | TEDxDanubia](https://www.youtube.com/watch?v=R9Plq-D1gEk)
- [Conway's Game of Life Explained](https://youtu.be/C2vgICfQawE?si=yWqN0BOSBOMaujkI)

https://conwaylife.com/
### Try playing it here

#### Further Reading
- [Play Game of Life](https://playgameoflife.com/)
- [Conway Life](https://conwaylife.com/)

https://conwaylife.com/wiki/
### Further Reading

https://en.wikipedia.org/wiki/Conway%27s_Game_of_Life
- [Conway's Game of Life Wiki](https://conwaylife.com/wiki/)
- [Wikipedia: Conway's Game of Life](https://en.wikipedia.org/wiki/Conway%27s_Game_of_Life)

## Footnote
Conway's Game of Life is a fascinating exploration of life, death, and the rules that govern them. Despite its simplicity, it can lead to complex and beautiful patterns.
---

Game of Life offers a unique way to explore the unpredictable beauty of life itself.
<div align="center">
<h2>Conway's Game of Life offers a unique way to explore the unpredictable beauty of life itself.</h2>
</div>
137 changes: 74 additions & 63 deletions data/themes.json
Original file line number Diff line number Diff line change
@@ -1,65 +1,65 @@
{
"blue": {
"--primary-color": "#0f045a",
"--theme-color1": "#7582b2",
"--theme-color2": "#036c96",
"--theme-color3": "#ebf2ff",
"--shadow-color1": "#352a7e",
"--shadow-color2": "#101536",
"--border-color1": "#080126",
"--background-col": "#c6cede",
"ALIVE_COLOR": "#00246B",
"DEAD_COLOR": "#CADCFC"
},
"green": {
"--primary-color": "#045a1e",
"--theme-color1": "#75B289",
"--theme-color2": "#03962f",
"--theme-color3": "#EBFFEF",
"--shadow-color1": "#2A7E4D",
"--shadow-color2": "#10361C",
"--border-color1": "#01260B",
"--background-col": "#C6DECC",
"ALIVE_COLOR": "#006b2b",
"DEAD_COLOR": "#cafcdd"
},
"red": {
"--primary-color": "#5a0404",
"--theme-color1": "#B27575",
"--theme-color2": "#960320",
"--theme-color3": "#FFEBEB",
"--shadow-color1": "#7E2A37",
"--shadow-color2": "#361015",
"--border-color1": "#260106",
"--background-col": "#DEC6C6",
"ALIVE_COLOR": "#6b0000",
"DEAD_COLOR": "#fccaca"
},
"purple":{
"--primary-color": "#5a045a",
"--theme-color1": "#B275B2",
"--theme-color2": "#960396",
"--theme-color3": "#FFEBFF",
"--shadow-color1": "#7E2A7E",
"--shadow-color2": "#361036",
"--border-color1": "#260126",
"--background-col": "#DEC6DE",
"ALIVE_COLOR": "#6b006b",
"DEAD_COLOR": "#fcafcf"
},
"darkCyan":{
"--primary-color": "#045a5a",
"--theme-color1": "#75B2B2",
"--theme-color2": "#039696",
"--theme-color3": "#EBFFFF",
"--shadow-color1": "#2A7E7E",
"--shadow-color2": "#103636",
"--border-color1": "#012626",
"--background-col": "#C6DEDE",
"ALIVE_COLOR": "#006b6b",
"DEAD_COLOR": "#cafcfc"
},
"neon": {
"blue": {
"--primary-color": "#0f045a",
"--theme-color1": "#7582b2",
"--theme-color2": "#036c96",
"--theme-color3": "#ebf2ff",
"--shadow-color1": "#352a7e",
"--shadow-color2": "#101536",
"--border-color1": "#080126",
"--background-col": "#c6cede",
"ALIVE_COLOR": "#00246B",
"DEAD_COLOR": "#CADCFC"
},
"green": {
"--primary-color": "#045a1e",
"--theme-color1": "#75B289",
"--theme-color2": "#03962f",
"--theme-color3": "#EBFFEF",
"--shadow-color1": "#2A7E4D",
"--shadow-color2": "#10361C",
"--border-color1": "#01260B",
"--background-col": "#C6DECC",
"ALIVE_COLOR": "#006b2b",
"DEAD_COLOR": "#cafcdd"
},
"red": {
"--primary-color": "#5a0404",
"--theme-color1": "#B27575",
"--theme-color2": "#960320",
"--theme-color3": "#FFEBEB",
"--shadow-color1": "#7E2A37",
"--shadow-color2": "#361015",
"--border-color1": "#260106",
"--background-col": "#DEC6C6",
"ALIVE_COLOR": "#6b0000",
"DEAD_COLOR": "#fccaca"
},
"purple": {
"--primary-color": "#5a045a",
"--theme-color1": "#B275B2",
"--theme-color2": "#960396",
"--theme-color3": "#FFEBFF",
"--shadow-color1": "#7E2A7E",
"--shadow-color2": "#361036",
"--border-color1": "#260126",
"--background-col": "#DEC6DE",
"ALIVE_COLOR": "#6b006b",
"DEAD_COLOR": "#fcafcf"
},
"darkCyan": {
"--primary-color": "#045a5a",
"--theme-color1": "#75B2B2",
"--theme-color2": "#039696",
"--theme-color3": "#EBFFFF",
"--shadow-color1": "#2A7E7E",
"--shadow-color2": "#103636",
"--border-color1": "#012626",
"--background-col": "#C6DEDE",
"ALIVE_COLOR": "#006b6b",
"DEAD_COLOR": "#cafcfc"
},
"neon": {
"--primary-color": "#d0ff00",
"--theme-color1": "#00cc26",
"--theme-color2": "#00b81b",
Expand All @@ -70,6 +70,17 @@
"--background-col": "#000525",
"ALIVE_COLOR": "#9800f5",
"DEAD_COLOR": "#80ffff"
}

},
"black": {
"--primary-color": "#505050",
"--theme-color1": "#FFFFFF",
"--theme-color2": "#808080",
"--theme-color3": "#FFFFFF",
"--shadow-color1": "#808080",
"--shadow-color2": "#000000",
"--border-color1": "#000000",
"--background-col": "#FFFFFF",
"ALIVE_COLOR": "#000000",
"DEAD_COLOR": "#FFFFFF"
}
}
Loading

0 comments on commit 3015adc

Please sign in to comment.