參考教學:
Complete roguelike tutorial using C++ and libtcod - part 1: setting up。
原文教學系列係以 libtcod 函式庫 為 RougeLike 核心開心的引擎。原文即說明了 libtcod 的主要功能:
libtcod is a free, fast, portable and uncomplicated API for roguelike developpers providing an advanced true color console, input, and lots of other utilities frequently used in roguelikes.
有個開源的即時戰略遊戲:ASCIIWar,竟然就是以 libtcod 所開發的 ASCII 字符純文字遊戲,但卻又能展現出即時戰略的效果。
首要安裝套件 (pre-requisite):
Ubuntu 14.04 需安裝 libsdl1.2debian 套件;Raspbian 則已預先安裝。
$ sudo apt-get install libsdl1.2debian |
** 另外兩者尚須安裝 libsdl1.2-dev 套件 (如此編譯 libtcod 才不會有問題):
$ sudo apt-get install libsdl1.2-dev |
SDL (Simple DirectMedia Layer) is a cross-platform development library designed to provide low level access to audio, keyboard, mouse, joystick, and graphics hardware via OpenGL and Direct3D.