This is my attempt to simplify CS2D's Lua API. It was inspired by Livia's API mentioned here Extending native functions, but that project appears to be dead.
The wrapper allows you to treat players like objects (similar to classes or structures) by using tables and metatables. It also overrides a few CS2D functions to make them easier to use, while maintaining compatibility with existing code.
I'm not going to give a lot of details here because I've already written a large readme, available on github and in the file archive.
The archive also includes samples which are also available on github. These are based on the samples in sys/lua/samples and include gungame.lua and utsfx.lua.
A snippet from gungame.lua
The wrapper will detect if EngiN33R's [EngiN33R] UTF-8 Wrapper Library (11) is loaded and update the colorcode symbol (©) accordingly. A function is provided to get the correct color code or create a color string given RGB, C (see section 4 of the readme).
edited 2×, last 16.12.17 11:44:31 pm
Approved by SQ
Download
13 kb, 433 Downloads