Skip to content

❗ This is a read-only mirror of the CRAN R package repository. pixelpuzzle — Puzzle Game for the R Console. Homepage: https://github.com/rolkra/pixelpuzzle

Notifications You must be signed in to change notification settings

cran/pixelpuzzle

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

pixelpuzzle

Puzzle game for the R console. Restore the pixel art by shifting rows!

example pixel art

Installation

CRAN

install.packages("pixelpuzzle")

Github

# install from github
if (!require(devtools)) install.packages("devtools")
devtools::install_github("rolkra/pixelpuzzle")

Start Game

library(pixelpuzzle)
pixelpuzzle()

Pixel Art

{pixelpuzzle} comes with predefined pixel art you can play with. Just start the game with pixelpuzzle() to select one.

In case you want to define your own pixel art you can use the following color codes for each pixel:

  • R = Red
  • M = Magenta
  • B = Blue
  • C = Cyan
  • G = Green
  • Y = Yellow
  • W = White
  • S = Silver
  • X = Black
  • . = No color (transparent)
library(pixelpuzzle)

sprite <- c(
  "RRRRRRRRR",
  "MMMMMMMMR",
  "BBBBBBBMR",
  "CCCCCCBMR",
  "GGGGGCBMR",
  "YYYYGCBMR",
  "WWWYGCBMR",
  "SSWYGCBMR",
  "XSWYGCBMR"
)

show_sprite(sprite)

define pixel art

You can use this pixel art by passing it as parameter to pixelpuzzle()

pixelpuzzle(sprite)

About

❗ This is a read-only mirror of the CRAN R package repository. pixelpuzzle — Puzzle Game for the R Console. Homepage: https://github.com/rolkra/pixelpuzzle

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages