256
edits
(→Function Reference: Added div, length, and random) |
|||
Line 78: | Line 78: | ||
=== Variables === | === Variables === | ||
SigMath have support for variables. It supports both [[SigServer:Variables|AniDB variables]] and | SigMath have support for variables. It supports both [[SigServer:Variables|AniDB variables]] and user defined. AniDB variables are prefixed with $ and user defined variables with @. | ||
'''Example''' | '''Example''' | ||
<nowiki>{{ $example }}</nowiki> | <nowiki>{{ $example }}</nowiki> | ||
<nowiki>{{ @example }}</nowiki> | <nowiki>{{ @example }}</nowiki> | ||
The first block outputs the AniDB variable named ''example''. The second block outputs the user defined variable named ''example''. A user defined variable may have the same name as an AniDB variable. The variables are only | The first block outputs the AniDB variable named ''example''. The second block outputs the user defined variable named ''example''. A user defined variable may have the same name as an AniDB variable. The variables are only alphanumeric and may contain _ as well. | ||
Setting a variable is quite straight-forward. | |||
'''Example''' | |||
<nowiki>{{ @example = "Where's the money Lebowski?" }}</nowiki> | |||
This will set the variable ''@example'' to ''Where's the money Lebowski?''. | |||
=== Functions === | === Functions === |
edits