piyo: Haskell game engine like fantasy console.

[ game, library, mit, program ] [ Propose Tags ] [ Report a vulnerability ]

Please see the README on GitHub at https://github.com/opyapeus/piyo#readme


[Skip to Readme]

Modules

  • Piyo
    • Piyo.Asset
    • Piyo.Draw
    • Piyo.Game
    • Piyo.Sound
    • Piyo.Types

Downloads

Maintainer's Corner

Package maintainers

For package maintainers and hackage trustees

Candidates

  • No Candidates
Versions [RSS] 0.1.0.0
Change log ChangeLog.md
Dependencies base (>=4.7 && <5), extra, piyo, sdl2, sdl2-gfx, sdl2-image, sdl2-mixer, sdl2-ttf, text [details]
License MIT
Copyright 2018 peus
Author peus
Maintainer opyapeus@gmail.com
Category Game
Home page https://github.com/opyapeus/piyo#readme
Bug tracker https://github.com/opyapeus/piyo/issues
Source repo head: git clone https://github.com/opyapeus/piyo
Uploaded by opyapeus at 2018-08-08T17:06:01Z
Distributions
Executables piyo-exe
Downloads 958 total (14 in the last 30 days)
Rating (no votes yet) [estimated by Bayesian average]
Your Rating
  • λ
  • λ
  • λ
Status Docs not available [build log]
All reported builds failed as of 2018-08-08 [all 3 reports]

Readme for piyo-0.1.0.0

[back to package description]

Piyo🐤

Haskell game engine like fantasy console. Inspired by PICO-8.

NOTE: UNDER DEVELOPMENT

Feature

  • minimum but simple api
  • pure update funciton
  • japanease bitmap font support

It supports PICO-8 like drawing api.

Assuming Specification

For now below.

  • display: 192x192
  • sprite size: 12x12
  • map size: 16x16

Requirements

SDL2 needed.

For OS X

Install middle wares with homebrew.

brew install sdl2 sdl2_gfx sdl2_image sdl2_mixer sdl2_ttf

For others

It may work ..!

Minimal code

import Piyo

instance Game () where
    draw _ =
        [ cls Yellow
        , txt Black "Hello, World!" 48 48
        ]

main :: IO ()
main = piyo () Nothing

Data Flow Schematic

Functions are called in order update, draw, sound every frame.

Indexing

Index number starts with 0. Not 1.

Examples

Sample working code at Examples

Development in the future

  • Redesign assets format
  • Enrich sound api
  • Add useful state update functions
  • FPS management
  • Support ore key action
  • Sprite and map editor
  • Export function for distribution
  • etc...