Difference between revisions of "Template:SourceMod API"

From AlliedModders Wiki
Jump to: navigation, search
(Update template with docs)
m (Avoid breaking lines after the end of the template)
Line 1: Line 1:
<code>[https://sm.alliedmods.net/new-api/{{{file}}}/{{#if:{{{class|}}}|{{{class}}}/|}}{{{function}}} {{#if:{{{class|}}}|{{{class}}}.|}}{{{function}}}]</code>
+
<code>[https://sm.alliedmods.net/new-api/{{{file}}}/{{#if:{{{class|}}}|{{{class}}}/|}}{{{function}}} {{#if:{{{class|}}}|{{{class}}}.|}}{{{function}}}]</code><noinclude>
  
<noinclude>
 
 
This generates a link to the [https://sm.alliedmods.net/new-api/ SourceMod Scripting API reference] entry.
 
This generates a link to the [https://sm.alliedmods.net/new-api/ SourceMod Scripting API reference] entry.
  

Revision as of 10:16, 15 October 2020

{{{function}}}

This generates a link to the SourceMod Scripting API reference entry.

Usage

{{SourceMod API|file=datapack|class=DataPack|function=Reset}}

produces

DataPack.Reset

Parameters

file
the source file that contains the function.
class
optional. The methodmap class associated with a method. If this is present, the link will be displayed as Class.Method.
function
the function / method / other identifier.