A delightfully simple and lightweight 2D game engine for the D programming language, offering a solid foundation for creating 2D games.
import parin;
void ready() {
(320, 180);
lockResolution}
bool update(float dt) {
("Hello world!", Vec2(8));
drawDebugTextreturn false;
}
void finish() { }
mixin runGame!(ready, update, finish);
Parin is packed with powerful features to get you started quickly:
Parin lets you to build games for multiple platforms with ease:
Parin is MIT-licensed and free to use forever.
A list of projects made with Parin is available in the projects page.
This guide shows how to install Parin and its dependencies using DUB. Create a new folder and run inside the following commands:
-n
dub init
dub run parin:setup dub run
If everything is set up correctly, a window will appear showing the message “Hello world!”.
Some libraries for sound, graphics, and input handling are required before using Parin on Linux. Below are installation commands for some Linux distributions.
Ubuntu:
-dev libx11-dev libxrandr-dev libxi-dev libgl1-mesa-dev libglu1-mesa-dev libxcursor-dev libxinerama-dev libwayland-dev libxkbcommon-dev sudo apt install libasound2
Fedora:
-lib-devel mesa-libGL-devel libX11-devel libXrandr-devel libXi-devel libXcursor-devel libXinerama-devel libatomic sudo dnf install alsa
Arch:
-S alsa-lib mesa libx11 libxrandr libxi libxcursor libxinerama sudo pacman
Start with the examples folder for a quick overview. For more details, check the tour page.