Difference between revisions of "User:Strife Onizuka/Sandbox/Switch/Template:Test"
< User:Strife Onizuka | Sandbox | Switch
Jump to navigation
Jump to search
Line 323: | Line 323: | ||
{{!}} valign="top" {{!}} <div id="box"> | {{!}} valign="top" {{!}} <div id="box"> | ||
<h2>Function: {{#if:{{{return_type|}}}|[[{{{return_type|}}}]]||}} [[{{{func}}}]]( {{#if:{{{p1_name|}}}{{{p1_type|}}}| [[{{{p1_type|}}}]] {{LSL Param|{{{p1_name|}}}}}{{#if:{{{p2_name|}}}{{{p2_type|}}}|, [[{{{p2_type|}}}]] {{LSL Param|{{{p2_name|}}}}}{{#if:{{{p3_name|}}}{{{p3_type|}}}|, [[{{{p3_type|}}}]] {{LSL Param|{{{p3_name|}}}}}{{#if:{{{p4_name|}}}{{{p4_type|}}}|, [[{{{p4_type|}}}]] {{LSL Param|{{{p4_name|}}}}}{{#if:{{{p5_name|}}}{{{p5_type|}}}|, [[{{{p5_type|}}}]] {{LSL Param|{{{p5_name|}}}}}{{#if:{{{p6_name|}}}{{{p6_type|}}}|, [[{{{p6_type|}}}]] {{LSL Param|{{{p6_name|}}}}}{{#if:{{{p7_name|}}}{{{p7_type|}}}|, [[{{{p7_type|}}}]] {{LSL Param|{{{p7_name|}}}}}{{#if:{{{p8_name|}}}{{{p8_type|}}}|, [[{{{p8_type|}}}]] {{LSL Param|{{{p8_name|}}}}}{{#if:{{{p9_name|}}}{{{p9_type|}}}|, [[{{{p9_type|}}}]] {{LSL Param|{{{p9_name|}}}}}{{#if:{{{p10_name|}}}{{{p10_type|}}}|, [[{{{p10_type|}}}]] {{LSL Param|{{{p10_name|}}}}}{{#if:{{{p11_name|}}}{{{p11_type|}}}|, [[{{{p11_type|}}}]] {{LSL Param|{{{p11_name|}}}}}{{#if:{{{p12_name|}}}{{{p12_type|}}}|, [[{{{p12_type|}}}]] {{LSL Param|{{{p12_name|}}}}}}}}}}}}}}}}}}}}}}}}}}}}} )<nowiki>;</nowiki></h2> | <h2>Function: {{#if:{{{return_type|}}}|[[{{{return_type|}}}]]||}} [[{{{func}}}]]( {{#if:{{{p1_name|}}}{{{p1_type|}}}| [[{{{p1_type|}}}]] {{LSL Param|{{{p1_name|}}}}}{{#if:{{{p2_name|}}}{{{p2_type|}}}|, [[{{{p2_type|}}}]] {{LSL Param|{{{p2_name|}}}}}{{#if:{{{p3_name|}}}{{{p3_type|}}}|, [[{{{p3_type|}}}]] {{LSL Param|{{{p3_name|}}}}}{{#if:{{{p4_name|}}}{{{p4_type|}}}|, [[{{{p4_type|}}}]] {{LSL Param|{{{p4_name|}}}}}{{#if:{{{p5_name|}}}{{{p5_type|}}}|, [[{{{p5_type|}}}]] {{LSL Param|{{{p5_name|}}}}}{{#if:{{{p6_name|}}}{{{p6_type|}}}|, [[{{{p6_type|}}}]] {{LSL Param|{{{p6_name|}}}}}{{#if:{{{p7_name|}}}{{{p7_type|}}}|, [[{{{p7_type|}}}]] {{LSL Param|{{{p7_name|}}}}}{{#if:{{{p8_name|}}}{{{p8_type|}}}|, [[{{{p8_type|}}}]] {{LSL Param|{{{p8_name|}}}}}{{#if:{{{p9_name|}}}{{{p9_type|}}}|, [[{{{p9_type|}}}]] {{LSL Param|{{{p9_name|}}}}}{{#if:{{{p10_name|}}}{{{p10_type|}}}|, [[{{{p10_type|}}}]] {{LSL Param|{{{p10_name|}}}}}{{#if:{{{p11_name|}}}{{{p11_type|}}}|, [[{{{p11_type|}}}]] {{LSL Param|{{{p11_name|}}}}}{{#if:{{{p12_name|}}}{{{p12_type|}}}|, [[{{{p12_type|}}}]] {{LSL Param|{{{p12_name|}}}}}}}}}}}}}}}}}}}}}}}}}}}}} )<nowiki>;</nowiki></h2> | ||
<div style="padding: 0.5em"><div id="box" style="float:right;"><table class="collapsible" style="font-size:50%;" | <div style="padding: 0.5em"><div id="box" style="float:right;"><table class="collapsible"><tr style="font-size:50%;"><th colspan="2"></tr><tr> | ||
<td> {{HoverText|{{#var:func_id}}|The function index number.}} | <td> {{HoverText|{{#var:func_id}}|The function index number.}} | ||
<td> [[LSL Function ID|Function ID]] | <td> [[LSL Function ID|Function ID]] |
Revision as of 18:25, 20 July 2007
LSL Portal | Functions | Events | Types | Operators | Constants | Flow Control | Script Library | Categorized Library | Tutorials |
See User:Strife Onizuka/Sandbox/Switch/Template:Test/docs for additional documentation.
{{LSL_Function |func |func_id |func_sleep |func_energy |func_desc |func_footnote |return_type |return_text |p1_type|p1_name|p1_desc|p1_hover |p2_type|p2_name|p2_desc|p2_hover |p3_type|p3_name|p3_desc|p3_hover |p4_type|p4_name|p4_desc|p4_hover |p5_type|p5_name|p5_desc|p5_hover |p6_type|p6_name|p6_desc|p6_hover |p7_type|p7_name|p7_desc|p7_hover |p8_type|p8_name|p8_desc|p8_hover |p9_type|p9_name|p9_desc|p9_hover |p10_type|p10_name|p10_desc|p10_hover |p11_type|p11_name|p11_desc|p11_hover |p12_type|p12_name|p12_desc|p12_hover |constants |spec |caveats |examples |helpers |also_header |also_functions |also_tests |also_events |also_articles |also_footer |notes |mode |deprecated |location |cat1 |cat2 |cat3 |cat4 |cat5 |cat6 }}
The LSL_Function template is a intermediate template for LSL_Generic, which handles the formating for both functions and events (LSL_Event is also an intermediate template). The main job of this template is to change the parameter, names & setup the right-side floater. Also makes permission requirements a part of the template.
parameter | desc | example |
---|---|---|
func | Function name | |
func_id | Function ID | 1.0 |
func_sleep | Delay | 0.0 |
func_energy | Energy | 10.0 |
func_desc | Function description text. | Gives the monkey a banana |
func_footnote | Function footnote (appears after the parameters text). | Has the side effect of causing the avatar to run in circles shouting like on fire. |
return_type | return type | integer |
return_text | "Returns a return_type return_text" in most cases return_text can be used instead of func_desc. | that is a monkey |
p1_type | first parameter type | |
p1_name | first parameter name | |
p1_desc | first parameter desc | |
p1_hover | first parameter hover, if not included it defaults to p1_desc | |
p2_type | second parameter type | |
p2_name | second parameter name | |
p2_desc | second parameter desc | |
p2_hover | second parameter hover, if not included it defaults to p2_desc | |
... | ||
p12_type | twelfth parameter type | |
p12_name | twelfth parameter name | |
p12_desc | twelfth parameter desc | |
p12_hover | twelfth parameter hover, if not included it defaults to p12_desc | |
constants | constants area, no box, please use a table for this section. | |
spec | spec box | |
caveats | caveats box | |
examples | examples box | |
helpers | helper functions box | |
also_header | also header | |
also_functions | also functions indent | |
also_events | also events indent | |
also_articles | also articles indent | |
also_tests | also tests indent | |
also_footer | also footer | |
notes | notes box | |
mode | if mode equals 'god' then it is tagged as requiring godmode. if set to 'request' marks the page as a feature request. | |
deprecated | Marks the function as deprecated. Set the value to the replacement functions name or 'none'. If it is not set to none and it is infact set, it will include a link to the replacement function. | |
self | Special field that you only set if you don't want the function to be included in any categories. | |
cat1 | An LSL specific category and sets the proper sort. (example would add the function to the "LSL Stub" category) | Stub |
cat2 | " | |
cat3 | " | |
cat4 | " | |
cat5 | " | |
cat6 | " | |
sort | not required but used to specify the sort order, if excluded the wiki will calculate this value for you. | |
location | optional: location box, used to say which source file it is defined in. | |
history | a box for function history |
LSL Portal | Functions | Events | Types | Operators | Constants | Flow Control | Script Library | Categorized Library | Tutorials |
Specificationspec | ||||
constants | ||||
Caveats
caveats | ||||
Examplesexamples | ||||
Useful Snippetshelpers | ||||
Notesnotes | ||||
See Also
also_header Events
Functions
Tests
Articles
| ||||
Source Locationlocation | ||||
Historyhistory |