aerth/rpg 是一个托管在 GitHub 上的开源项目,主要使用 Go 编写,采用 MIT License 许可证,目前获得 30 个 Star、4 次 Fork。
仓库全名
aerth/rpg
README 摘要
lets make a game 2D, top-down, pixelized magic action RPG contributions very welcome (see roadmap) AERPG demo INCLUDED TOOLS aerpg - play the demo rpg: explore map, kill skeletons, pick up loot, gain xp, collect magic items mapmaker - create/edit a map: read source code for keymap mapgen - generate a map: run mapgen to use specific seed such as mapgen mycoolseed FETCHING DEPENDENCIES install Go: go install C…
fetch this source code and dependencies: go get -v -d -u github.com/aerth/rpg/cmd/...
INSTALLING AERPG GAME
Requirements
If you’re using Windows and having trouble building Pixel, please check this
guide on the
wiki.
PixelGL backend uses OpenGL to render
graphics. Because of that, OpenGL development libraries are needed for compilation. The dependencies
are same as for GLFW.
The OpenGL version used is OpenGL 3.3.
On macOS, you need Xcode or Command Line Tools for Xcode (xcode-select --install) for required
headers and libraries.
On Ubuntu/Debian-like Linux distributions, you need libgl1-mesa-dev and xorg-dev packages.
On CentOS/Fedora-like Linux distributions, you need libX11-devel libXcursor-devel libXrandr-devel libXinerama-devel mesa-libGL-devel libXi-devel packages.
The combination of Go 1.8, macOS and latest XCode seems to be problematic as mentioned in issue
#7. This issue is probably not related to Pixel.
Upgrading to Go 1.8.1 fixes the issue.
Compiling
go get -v -d github.com/aerth/rpgGOBIN=$PWD go install github.com/aerth/rpg/cmd/...
keymap:
Pause, Inventory, Char Stats: i
Movement: arrows, asdw, hjkl, hold right mouse
Zoom: mouse wheel
Identify tile: left click
Pick up loot: left click
Attack (manastorm): spacemiddle click
Attack (magic bullet): Bleft click (point/shoot)
Quit: ctrl+Q
CHEATS
Toggle show enemy paths: =
Toggle fly mode: caps lock
Mana potion: 1
Health potion: 2
XP potion: 3
Speed up time: LSHIFT
Slow motion: TAB
Random Loot: ctrl+L (random location), ctrl+K (under mouse)
Spawn fresh mob: M (watch FPS go down)
ROADMAP
Regions (separated by doors)
Doors/Portals connect regions
Spawn tiles (instead of random tile) (should be Rectangle)
评论