• Stars
    star
    324
  • Rank 129,708 (Top 3 %)
  • Language
    JavaScript
  • License
    MIT License
  • Created almost 5 years ago
  • Updated over 2 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Papercraft videogame cartridges you can print and pirate with a copy machine.

Rewtro



Rewtro is a weird retro game engine inspired by fantasy consoles and code golfing that runs games encoded in a very small amount of data (2kB/3kB). This way is possible to share games using exoteric and usually data inefficient ways: i.e. sticking some PWA magic and a QR-Code reader to the engine I've made a fake gaming console for mobile devices...

...that loads games from papercraft game cartridges...

...or animated GIFs...

...simply framing them!

All the game data (graphic, sound, music, and code) is encoded into the QR-Codes and no data is stored online - and the same goes for the game console code too, once installed on your device - so scrap the paper cartridge and the game is gone. But hey... you can produce your game cartridges using just a plain printer and you can still pirate games using a copy machine like we used to do with cassette duplicators in the 80s. I hope it will bring back that retro vibes.

The game engine

The game engine implements:

  • A super simple physics engine
  • A sprites renderer that supports rotation and scaling
  • A text renderer based on pixel fonts
  • A simple event manager
  • A scene loader and manager
  • A sound synthesizer and basic music sequencer
  • Some commands for doing the math and basic logic
  • Some tilemap handling commands
  • Several custom graphics encoder/decoders
  • Some data packers, from old good zipping to custom algorithms suited for small data

And that's all. No game-specific code has been coded inside the engine. Making an actual game with these few things it's up to you.

The development tools

Games are coded using JSON structures and I've built some (pretty raw) tools you can use to code your games - together with some sample games. You can find them in the carts/ subfolder: there is a viewer for built-in color palettes, screen resolutions, controls and fonts you can use in your games.

To avoid cheating or being influenced by specific games, all presets are based on actual gaming systems form the past (Gameboy, ZX-Spectrum and Commodore 64) and most of them can be overridden by custom ones encoding them into your game code. You can also find a noise generator you can use to create sound effects that feature a pretty simple piano keyboard for sketching some music for your games.

But what you are going to use the most is the game debugger...

...and the game compiler and packager, that generates a foldable cartridge in SVG format to be customized and printed or an animated GIF you can show anywhere you want. Sorry for the thin toolchain: I survived with that but I'm going to improve it if there is some kind of interest.

While both the game console and the SDK tools run client-side, I've added a pinch of PHP for reading the games file list to be displayed on SDK main screen. Feel free to replace that PHP with any alternative you can think about (or suggest one).

You can have a look at a read-only version of the SDK here. Hit random buttons, test games, generate SVGs, etc. To play games in debugger use arrow keys and Z/X/C/V as action buttons.

The developer manual

There is a developer manual with explanations and a lot of code examples that cover everything Rewtro! See you there!

Released games

In the carts/ folder, you'll find the SDK and all the games I've developed for Rewtro till now. I've made 2 series of games, split by its initial:

  • The V- series contains customizable greeting card games: they include a title screen, a briefing screen, a short and relatively easy gameplay, and a debriefing screen displayed once the game is cleared. Games are customizable in text, gameplay parameters, graphics and - if you feel brave - music and sounds. You can make your cartridges making a copy and renaming a V- series JSON file into the same folder, changing the data as you want with any text editor and testing and printing the games within the SDK. That's what I did in November/December 2019.
  • The K- series contains short but more complete games, mostly inspired by classics. They are harder to change but you can print them as-is and customize the printed cartridge writing a dedication or a silly doodle on the front, more like a classic greeting card.

Remember that a QR-Cart contains the whole game code, music, graphics, AND customizations so, once the game is printed, you can't change anything. If you want to update your game, fixing a bug or a typo, you've to print the cartridge again. The previous one will be a rare bugged version of your game to be collected jealously. Welcome to the 80s!

Why?

It's Christmas time, I needed some greeting cards and decided to make some original ones this year. I liked the idea of hiding the actual greetings at the end of a customized videogame but implementing a browser game lacked the perishability of a greeting card: you want to keep them because it contains the whole experience, that is the stock message and the handwritten message. Moreover, the game itself is part of the message so why keeping that outside the greeting card?

Then, building physical retro games for specific persons and hiding messages in them gives you that Petscop's Rainer chills that's both cool and frightening.

You can also use these paper cartridges as hints in treasure hunts, put them in geocaches, spread its parts as collectible stickers, on video advertising, for fancy business cards, etc.

Rewtro QR-Carts are cheap to print and contain the whole game data, are physically shareable, fun to copy and can be easily unique. Take the best of that.

FAQs

Q: I want to make a Rewtro game too!

A: Have a look to the developer manual to learn how to setup your development environment and start developing!

Q: Which browser I can use for running Rewtro games?

A: On mobile, you can use Safari on iOS and Firefox or Chrome on Android. I just have an old iMac and a Windows 10 laptop and everything seems working on both Firefox and Chrome...

Q: Can I run a QR-Cart on a desktop computer?

A: While it's quite hard to frame a tiny QR-Code printed on paper or displayed on a mobile with a desktop cam, I managed to load a game easily running the Datasette on a tablet and displaying the code full screen (hit the buttons on top of the Datasette screen).

Q: I've created an SVG cartridge but it looks like I'm missing a font...

A: I've used the Jost free font (Jost-500-Medium.otf). Download, install, restart your favorite vector editor and open the SVG again.

Q: I received a QR-Cart from a friend but I've lost/ruined it. Can I reprint that exact copy using these source files?

A: Probably not, sorry. QR-Carts are not a reference to a database of games or customizations: they contain the full game data so, if they are lost, they can't be recovered anymore. You may try asking your friend if he can print the cartridge again... it's a great reason to meet him again!

Q: Can Rewtro load games just from a binary file?

A: Yes, it's doable, game files should be very small and this way you could make larger games but no, I don't think that the feature fits the project. Rewtro tries to store tiny games in the smallest amount of data possible (at least, that's what I tried to do) and, for that very reason, it has a limited number of commands that are thought to be easy to be encoded instead of being easy to use. This self-limitation was key to make something that loads games fast from offline low-storage systems, like QR-Codes and - maybe in the future - audio. Other fantasy consoles and game engines don't have such limitations and, for this reason, are easier to code, they can load larger games from the internet or files. For these reasons, they can handle more complex games. So: if you have a reason to share tiny games using files, feel free to tell me your idea. Otherwise, if you want something that shares larger games in a digital way, there are several easier alternatives out there!

Q: Why the V-PESCOP-Basic game looks glitched, features quite disturbing graphics and has cryptic gameplay?

A: If you know what Petscop is, you already have your answer.

Disclaimer

Consider Rewtro in beta right now. I've not so much time to work on pet projects but I'll try to evolve the game engine a little more without breaking it. There is some kind of engine version tracking in the Rewtro code and encoded in cartridges but, If you want to be extra cautious, make a snapshot of the engine and host it elsewhere - there is no URL encoded in game cartridges so you're safe.

News and contacts

I use Twitter as my main social. It's probably the best place to be updated about Rewtro and to contact me.

Credits

Rewtro exists thanks to these techs:

...and the great support of these people:

More Repositories

1

akihabara

A game engine for making classic arcade style games using Javascript and HTML5. We're starting moving on a re-organized repo here: https://github.com/akihabara
JavaScript
530
star
2

magaka

A digital magazine framework in HTML/Javascript.
JavaScript
62
star
3

stampadia

A daily print-and-play roguelike adventure you can play offline.
JavaScript
44
star
4

Wright

A thoughtful full-stack reimplementation of gaming in 80's and 90's.
HTML
36
star
5

pvp

An opensource web browser 1-4 Players arena shooter you can play offline in split-screen and networked (experimental).
JavaScript
26
star
6

kuroshimu

Kuroshimu is a procedural black box investigation game: guess what happened to 6 persons trapped by a cute journalist dog in an endlessly resetting simulated world.
JavaScript
8
star
7

StripThis

Web. Comic. For real.
JavaScript
6
star
8

programmino

An implementation of the machine I've seen in my dreams.
JavaScript
5
star
9

stampadia-travelers

The Chronicles of Stampadia card game spin-off! A daily print-and-play roguelike adventure card game you can play offline.
JavaScript
5
star
10

jsjsj

A no-fat JS implementation of the famous Die Gute Fabrik's Johann Sebastian Joust
HTML
4
star
11

massive-randomness-2

A Massive Darkness 2 one-shot quest random generator.
JavaScript
4
star
12

beastparty

A code golfed JavaScript tiny deckbuilding card game
HTML
3
star
13

stampadia-generals

The third chapter of the Stampadia series! An open-source print-and-play single-player Expandable Card Game.
JavaScript
3
star
14

roguecairn

An opensource random generator of small worlds designed to be explored following Yochai Gal's Cairn adventure game rules.
CSS
3
star
15

JSTV

The internet player. (and the procedural gaming TV Gamecora)
JavaScript
2
star
16

cardcade

A collection of classic arcade games turned into card games.
HTML
2
star
17

metroidvania

Explore, fight, improve, repeat! A printable 1kb JavaScript metroidvania.
HTML
2
star
18

elixirexplosive

A codegolfed printable and potion-shaped puzzle game inspired by the super fun "Potion Explosion" board game
HTML
1
star
19

mmry

The classic memory game in a tweet of JS. (280 bytes)
JavaScript
1
star
20

wc

World Changers is Cabal, Contra, Gears of War, OutRun, roguelike and mobile gaming shuffled together.
HTML
1
star
21

dealan

Dealan is an advanced HTML5 opensource gesture-based sound board made to break free.
Shell
1
star
22

WordBoy

A tiny real-life puzzle game you can customize and print for your on-the-go Nonary games. Or parties. Or deadly weddings.
JavaScript
1
star
23

metame

METAME is a Multiple ExtraTerrestrial Arcade Machine Emulator and it's probably the first opensource earthling attempt on emulating extraterrestrial videogame systems.
JavaScript
1
star
24

razorthought

Razorthought: A battle of ideas and men - A card battler
JavaScript
1
star
25

Atwenture

An open-sourced surreal social-collaborative Twitter-based text adventure that changes unpredictably.
HTML
1
star
26

wizardsurvivors

A 500-characters codegolfed tribute to the infectious game Vampire Survivors.
HTML
1
star
27

TinyHAL

A MegaHAL-like chatterbot in 600 (or ~440) bytes of JS
JavaScript
1
star
28

TheLastOfAt

A Fanfictional Tribute Survival Roguelike in 1K of JS.
JavaScript
1
star
29

tightydeadline

Easy is hard to design. A puzzle/action game about level design.
HTML
1
star
30

lcdgame

A simulator of a never existed physical LCD handheld conversion of World Changers (https://github.com/kesiev/wc), an action game inspired by old classics, like Cabal, Contra, and OutRun, and modern games like Gears Of War and mobile casual gaming.
JavaScript
1
star
31

roguerogue

A secrets-packed roguelite single-screen platformer arcade game for 1-2 players heavily inspired by the 1986 Taito masterpiece Bubble Bobble and other great games from the past.
JavaScript
1
star