Basic Cubescript: Variables
#18
(28 Nov 11, 10:38AM)V-Man Wrote: Documentation using "docident" requires more arguments. Look at the default docs for a good example of the proper structure.
Or, if you'd like, you can see how I documented the tools.cfg commands -- based on the pattern visible in the default docs.

I see the script needs to be "installed" via execution rather than inside the autoexec itself. I copied the following anyway and didn't get any documentation to show up. Looks like some useful stuff in there :)
[cubescript]alias kickbots [
loop o $numargs [
kickbot (findpn (getalias (concatword "arg" (+ $o 1)))) ]]

docident [kickbots] [Kicks multiple bots out of a bot game.];
docargument [C] [Bot's client number];
docargument [...] [Up to 24 at a time.]
docexample [kickbots 2 4 6 8] [kicks bots with client number 2, 4, 6, and 8.];
docremark [For duplicate client numbers, will only kick one bot each.];[/cubescript]

Where in the tools.cfg does it call docsection.cfg?

(28 Nov 11, 10:38AM)V-Man Wrote: A word of wisdom: You'll want to avoid the quotes as much as possible, since they aren't "sided" -- meaning the engine will not nest them in a predictable way like it does with square brackets and parentheses.

Good advice. I didn't know the brackets could handle strings.
Thanks given by:


Messages In This Thread
RE: Basic Cubescript: Variables - by V-Man - 28 Nov 11, 10:38AM
RE: Basic Cubescript: Variables - by Felix-The-Ghost - 28 Nov 11, 08:52PM
RE: Basic Cubescript: Variables - by V-Man - 28 Nov 11, 09:06PM
RE: Basic Cubescript: Variables - by V-Man - 29 Nov 11, 12:44AM
RE: Basic Cubescript: Variables - by V-Man - 29 Nov 11, 05:41AM
RE: Basic Cubescript: Variables - by V-Man - 30 Nov 11, 05:30PM
RE: Basic Cubescript: Variables - by V-Man - 01 Dec 11, 03:50AM
RE: Basic Cubescript: Variables - by tempest - 01 Dec 11, 03:17PM
RE: Basic Cubescript: Variables - by V-Man - 02 Dec 11, 12:55PM
RE: Basic Cubescript: Variables - by V-Man - 03 Dec 11, 07:37AM
RE: Basic Cubescript: Variables - by Bukz - 03 Dec 11, 01:11PM
RE: Basic Cubescript: Variables - by V-Man - 04 Dec 11, 06:43AM
RE: Basic Cubescript: Variables - by V-Man - 04 Dec 11, 11:21PM
RE: Basic Cubescript: Variables - by V-Man - 05 Dec 11, 10:37AM
RE: Basic Cubescript: Variables - by V-Man - 12 Dec 11, 10:27PM