forked from CorsixTH/CorsixTH
-
Notifications
You must be signed in to change notification settings - Fork 0
LDocGen
Tim Diels edited this page Mar 6, 2014
·
8 revisions
LDocGen is a documentation generator for lua written for CorsixTH.
- luafilesystem (LFS)
- LPeg (Pattern matching library for lua)
Dependencies can be installed with (on linux, at least):
luarocks install luafilesystem
luarocks install lpeg
Install luarocks for lua 5.2 as LDocGen will be ran with lua v5.2
pacman -S lua luarocks
LDocGen is similar to DoxyGen, though more limited. (DoxyGen doesn't support lua.)
Syntax explained by example:
--! Description of func3 (There's no distinction between short/long description)
--! Continuation of description
function func3();
--! Supports the class construct used in CorsixTH
class "GameUI" (UI);
//! Describe func4
//!param x (integer) X coord. When negative
//! the function will also peel a banana.
//! This is still more info about param x.
//!param y (integer) Y coord
//!return (integer) A glorious number derived from x, y
//!example
//! retval = func(1, 3)
function func4(x, y);
Back to the Home page