Skip to content

RyanRizzoGithub/Hexabine

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

2 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

Hexabine

Hexabine is a hexagonal twist on the classic 2048 game, built using JavaScript and the HTML5 Canvas API. Players slide and merge numbered hex tiles across a honeycomb-shaped board to reach higher values. Strategic movement is key, as diagonal directions are included for more complex gameplay.



๐ŸŽฎ Gameplay

The game begins with 2 randomly spawned tiles.

Players use the arrow keys (and diagonal combinations) to slide tiles across the board.

When two tiles of the same value collide, they merge into a single tile with double the value.

Each move spawns a new tile in an empty cell.

The game ends when no more moves are possible.

โœจ Features

๐Ÿ Unique hexagonal board layout

โžก๏ธ Six movement directions (L, R, UL, UR, DL, DR)

๐Ÿ”„ Smooth tile animations and merging

๐ŸŽฏ Score tracking with every merge

๐ŸŽจ Vibrant tile colors for each value

โŒ Game over detection with restart option



๐Ÿ–ฅ๏ธ Controls

  • Arrow Keys โ†’ Move tiles left, right, up, or down
  • Arrow Key Combos โ†’ Move tiles diagonally:
  • Left + Up โ†’ Up-Left
  • Right + Up โ†’ Up-Right
  • Left + Down โ†’ Down-Left
  • Right + Down โ†’ Down-Right
  • Restart Button โ†’ Start a new game
  • Help Button โ†’ View controls and objective

๐Ÿš€ Getting Started

Clone or download this repository

Open hexabine.html in a web browser

Start sliding and merging tiles!

Or

Go to this link: Coming Soon

๐Ÿ› ๏ธ Technologies Used

JavaScript (ES6)

HTML5 Canvas API

CSS3

๐Ÿ“Œ Notes

The board is a fixed hexagonal grid of configurable size.

New tiles spawn with values of 2 or 4.

Movement and merges are animated for clarity.

The highest tile created is recorded in score tracking.

๐Ÿ† Future Enhancements

Mobile/touch input support

High score persistence (local storage)

Custom board sizes and difficulties

Themed color palettes

About

A hexagonal take on the classic shifting number game 2048.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published