Skip to content

malachyfernandez/GerrymanderTheGame

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

17 Commits
ย 
ย 
ย 
ย 

Repository files navigation

Gerrymander: The Puzzle Game ๐Ÿ—บ๏ธ๐Ÿงฉ

A browser-based strategy puzzle game where you redraw district lines to win elections with a minority. Learn the mechanics of gerrymandering by trying to create a red majority from fewer red precincts โ€” all in a clean, responsive interface.

๐ŸŽฏ Objective

Your goal is to:

  • Divide a grid of red and blue tiles into a given number of districts.
  • Make a majority of the districts red, even though red is the minority overall.

๐Ÿš€ Getting Started

Option 1: Local Use

  1. Clone or download the repository.
  2. Open index.html in any modern web browser.
  3. Start drawing district lines!

OR

Option 2: Online Version

  1. Visit: https://malachyfernandez.github.io/GerrymanderTheGame
  2. The game will load instantly in your browser.
  3. Begin experimenting with electoral outcomes!

What is a GitHub Page? GitHub Pages is a free hosting service that allows you to serve static HTML, CSS, and JS directly from a GitHub repository. It makes it easy to publish and share web apps without any server-side code or hosting setup.

๐ŸŽฎ Gameplay Features

  • ๐ŸŸฅ๐ŸŸฆ Color-Coded Tiles โ€” Red and blue tiles represent voter precincts.
  • โœ๏ธ Draw Districts โ€” Click and drag to assign tiles to districts.
  • ๐Ÿง  Strategic Logic โ€” Must follow legal-like constraints: red-majority districts can have just one more red than blue, blue-majority must be entirely blue.
  • โš ๏ธ Imperfect Alerts โ€” Visual warning if a district violates the rules.
  • ๐Ÿ” Auto-checks & Win Condition โ€” When enough red districts are created, you win (and "kill democracy")!

โš™๏ธ Tech Stack

  • HTML5/CSS3 โ€” Responsive interface, mobile-friendly.
  • JavaScript โ€” Handles game logic, user interaction, animation, and color assignment.

๐Ÿงฉ Learning Outcome

This game serves as an educational tool to demonstrate how district manipulation can affect election results โ€” even when it appears mathematically unfair.

๐Ÿ“œ License

Open-source and free to use. Modify or expand upon it as you like!

About

A browser-based strategy puzzle game where you redraw district lines to win elections with a minority

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages