Open main menu
Home
Random
Log in
Settings
About the CreationKit Wiki
Disclaimers
the CreationKit Wiki
Search
Editing
Script File Structure
(section)
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
== Comments == Comments in Papyrus come in three forms: Single line, multi-line, and documentation === Single-line Comments === <single line comment> ::= ';' <any text> <end of line> Single line comments start with ";" and go until the end of the line. They consume all text after the semicolon, including any backslash characters that would otherwise let you continue onto the following line. ==== Examples ==== <syntaxhighlight lang="papyrus"> ; A simple single line comment </syntaxhighlight> === Multi-line Comments === <multi-line comment> ::= ';/' <any text> '/;' Multi-line comments start with ";/" and consume any text (including newlines) until it finds "/;" ==== Examples ==== <syntaxhighlight lang="papyrus"> ;/ A simple Multi-line comment /; ;/ You can also have code in here, if you want to comment it out: x = 2 * 1 y.DoCoolStuff() /; </syntaxhighlight> === Documentation Comments === <documentation comment> ::= '{' <any text> '}' Documentation comments are special and can only appear on the line following a script header, property definition, or function definition. Documentation comments start at a "{" character and go until the terminating "}" character, including eating newlines and such. These comments show up as tooltips in the editor when you mouse over the script in the script picker, or when mousing over a property in the property editor. ==== Examples ==== <syntaxhighlight lang="papyrus"> ScriptName MyCoolScript {Documentation for my cool script here! I can even use more than one line...} </syntaxhighlight> <br> <syntaxhighlight lang="papyrus"> int Property MyProperty Auto {This property is fun, if you set it to 1, watch cool stuff happen!} </syntaxhighlight> [[Category:Scripting]] [[Category:Papyrus]] [[Category:Papyrus Language Reference]]
Summary:
Please note that all contributions to the CreationKit Wiki are considered to be released under the Creative Commons Attribution-ShareAlike (see
CreationKit:Copyrights
for details). If you do not want your writing to be edited mercilessly and redistributed at will, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource.
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)