diff --git a/api/actor/State.md b/api/actor/State.md index 81e727a..bac947c 100644 --- a/api/actor/State.md +++ b/api/actor/State.md @@ -33,90 +33,87 @@ struct State } ``` -- `Frame` +### `Frame` - The sprite frame of this state. +The sprite frame of this state. -- `NextState` +### `NextState` - A pointer to the next state in the global state table. +A pointer to the next state in the global state table. -- `Sprite` +### `Sprite` - The sprite ID of this state. +The sprite ID of this state. -- `Tics` +### `Tics` - The number of game ticks this state lasts. +The number of game ticks this state lasts. -- `Misc1` -- `Misc2` +### `Misc1`, `Misc2` - Primarily used in DeHackEd compatibility. Don't use this. +Primarily used in DeHackEd compatibility. Don't use this. -- `TicRange` +### `TicRange` - The maximum amount of tics to add for random tic durations, or `0` if the - duration is not random. For example, `TNT1 A random(5, 7)` would have a - `Tics` value of `5` and a `TicRange` of `2`. +The maximum amount of tics to add for random tic durations, or `0` if the +duration is not random. For example, `TNT1 A random(5, 7)` would have a `Tics` +value of `5` and a `TicRange` of `2`. -- `UseFlags` +### `UseFlags` - The scope of this state. See *Action Scoping*. Can have any of the - `DefaultStateUsage` flags. +The scope of this state. See *Action Scoping*. Can have any of the +`DefaultStateUsage` flags. -- `bCanRaise` +### `bCanRaise` - State has the `CanRaise` flag, allowing `A_VileChase` to target this actor - for healing without entering an infinitely long state. +State has the `CanRaise` flag, allowing `A_VileChase` to target this actor for +healing without entering an infinitely long state. -- `bDeHackEd` +### `bDeHackEd` - `true` if the state has been modified by DeHackEd. +`true` if the state has been modified by DeHackEd. -- `bFast` +### `bFast` - State has the `Fast` flag, halving the duration when fast monsters is - enabled. +State has the `Fast` flag, halving the duration when fast monsters is enabled. -- `bFullBright` +### `bFullBright` - State has the `Bright` flag, making it fully bright regardless of other - lighting conditions. +State has the `Bright` flag, making it fully bright regardless of other +lighting conditions. -- `bNoDelay` +### `bNoDelay` - State has the `NoDelay` flag, forcing the associated action function to be - run if the actor is in its first tic. +State has the `NoDelay` flag, forcing the associated action function to be run +if the actor is in its first tic. -- `bSameFrame` +### `bSameFrame` - `true` if the state's frame is to be kept from the last frame used, i.e., is - `#`. +`true` if the state's frame is to be kept from the last frame used, i.e., is +`#`. -- `bSlow` +### `bSlow` - State has the `Slow` flag, doubling the duration when slow monsters is - enabled. +State has the `Slow` flag, doubling the duration when slow monsters is enabled. -- `DistanceTo` +### `DistanceTo` - Returns the offset between this state and `other` in the global frame table. - Only works if both states are owned by the same actor. +Returns the offset between this state and `other` in the global frame table. +Only works if both states are owned by the same actor. -- `InStateSequence` +### `InStateSequence` - Returns `true` if this state is within a contiguous state sequence beginning - with `base`. +Returns `true` if this state is within a contiguous state sequence beginning +with `base`. -- `ValidateSpriteFrame` +### `ValidateSpriteFrame` - Returns `true` if the sprite frame actually exists. +Returns `true` if the sprite frame actually exists. -- `GetSpriteTexture` +### `GetSpriteTexture` - Returns the texture, if the texture should be flipped horizontally, and - scaling of this state's sprite. Scaling will return `scale` unless `skin` is - nonzero. `skin` determines the player skin used. +Returns the texture, if the texture should be flipped horizontally, and scaling +of this state's sprite. Scaling will return `scale` unless `skin` is nonzero. +`skin` determines the player skin used. diff --git a/api/base/Array.md b/api/base/Array.md index ea128f7..dff0e71 100644 --- a/api/base/Array.md +++ b/api/base/Array.md @@ -30,75 +30,75 @@ struct Array } ``` -- `Max` +### `Max` - Returns the amount of allocated objects in the array. +Returns the amount of allocated objects in the array. -- `Size` +### `Size` - Returns the amount of constructed objects in the array. +Returns the amount of constructed objects in the array. -- `Clear` +### `Clear` - Clears out the entire array, possibly destroying all objects in it. +Clears out the entire array, possibly destroying all objects in it. -- `Delete` +### `Delete` - Removes `count` objects starting at `index`, possibly destroying them. Moves - objects after `index + count` to the left. +Removes `count` objects starting at `index`, possibly destroying them. Moves +objects after `index + count` to the left. -- `Pop` +### `Pop` - Removes the last item in the array, possibly destroying it. Returns `false` - if there are no items in the array to begin with. +Removes the last item in the array, possibly destroying it. Returns `false` if +there are no items in the array to begin with. -- `Append` +### `Append` - Value-copies another array's contents and places them into this array at the - end. +Value-copies another array's contents and places them into this array at the +end. -- `Copy` +### `Copy` - Value-copies another array's contents into this array. The contents of - `other` are preserved. This operation can be extremely taxing in some cases. +Value-copies another array's contents into this array. The contents of `other` +are preserved. This operation can be extremely taxing in some cases. -- `Move` +### `Move` - Moves another array's contents into this array. The contents of `other` are - left indeterminate and shall not be used. This operation is extremely fast - as it only copies pointers but must be used carefully to avoid error. +Moves another array's contents into this array. The contents of `other` are +left indeterminate and shall not be used. This operation is extremely fast +as it only copies pointers but must be used carefully to avoid error. -- `Find` +### `Find` - Finds the index of `item` in the array, or `Size` if it couldn't be found. +Finds the index of `item` in the array, or `Size` if it couldn't be found. -- `Grow` +### `Grow` - Ensures the array can hold at least `amount` new members, growing the - allocated object amount if necessary. +Ensures the array can hold at least `amount` new members, growing the allocated +object amount if necessary. -- `Insert` +### `Insert` - Inserts `item` at `index`. Moves objects after `index` to the right. +Inserts `item` at `index`. Moves objects after `index` to the right. -- `Push` +### `Push` - Places `item` at the end of the array, calling `Grow` if necessary. +Places `item` at the end of the array, calling `Grow` if necessary. -- `Reserve` +### `Reserve` - Adds `amount` new empty-constructed objects at the end of the array, - increasing `Size` and calling `Grow` if necessary. Value types are - initialized to zero and reference types to `null`. +Adds `amount` new empty-constructed objects at the end of the array, increasing +`Size` and calling `Grow` if necessary. Value types are initialized to zero and +reference types to `null`. -- `Resize` +### `Resize` - Adds or removes objects based on `amount`. If it is less than `Size` then - objects are destroyed, if it is more then objects are empty-constructed. New - objects follow the same initialization rules as `Reserve`. +Adds or removes objects based on `amount`. If it is less than `Size` then +objects are destroyed, if it is more then objects are empty-constructed. New +objects follow the same initialization rules as `Reserve`. -- `ShrinkToFit` +### `ShrinkToFit` - Shrinks `Max` to `Size`. Does not mutate any objects in the array. +Shrinks `Max` to `Size`. Does not mutate any objects in the array. diff --git a/api/base/CVar.md b/api/base/CVar.md index 9a37f3d..175695b 100644 --- a/api/base/CVar.md +++ b/api/base/CVar.md @@ -27,59 +27,56 @@ struct CVar } ``` -- `FindCVar` +### `FindCVar` - Returns a server CVar by name, or `null` if none is found. +Returns a server CVar by name, or `null` if none is found. -- `GetCVar` +### `GetCVar` - Returns a user or server CVar by name, with `player` as the user if - applicable, or `null` if none is found. +Returns a user or server CVar by name, with `player` as the user if applicable, +or `null` if none is found. -- `GetBool` +### `GetBool` - Returns a boolean representing the value of the CVar, or `false` if it - cannot be represented. +Returns a boolean representing the value of the CVar, or `false` if it +cannot be represented. -- `GetFloat` +### `GetFloat` - Returns a float representing the value of the CVar, or `0.0` if it cannot be - represented. +Returns a float representing the value of the CVar, or `0.0` if it cannot be +represented. -- `GetInt` +### `GetInt` - Returns an integer representing the value of the CVar, or `0` if it cannot - be represented. +Returns an integer representing the value of the CVar, or `0` if it cannot be +represented. -- `GetString` +### `GetString` - Returns a string representing the value of the CVar. CVars can always be - represented as strings. +Returns a string representing the value of the CVar. CVars can always be +represented as strings. -- `SetBool` -- `SetFloat` -- `SetInt` -- `SetString` +### `SetBool`, `SetFloat`, `SetInt`, `SetString` - Sets the representation of the CVar to `v`. May only be used on mod-defined - CVars. +Sets the representation of the CVar to `v`. May only be used on mod-defined +CVars. -- `GetRealType` +### `GetRealType` - Returns the type of the CVar as it was defined, which may be one of the - following: +Returns the type of the CVar as it was defined, which may be one of the +following: - | Name | - | ---- | - | `CVar.CVAR_BOOL` | - | `CVar.CVAR_COLOR | - | `CVar.CVAR_FLOAT` | - | `CVar.CVAR_INT` | - | `CVar.CVAR_STRING` | +| Name | +| ---- | +| `CVar.CVAR_BOOL` | +| `CVar.CVAR_COLOR` | +| `CVar.CVAR_FLOAT` | +| `CVar.CVAR_INT` | +| `CVar.CVAR_STRING` | -- `ResetToDefault` +### `ResetToDefault` - Resets the CVar to its default value and returns 0. The purpose of the - return is unknown. May only be used on mod-defined CVars. +Resets the CVar to its default value and returns 0. The purpose of the +return is unknown. May only be used on mod-defined CVars. diff --git a/api/base/FixedArray.md b/api/base/FixedArray.md index 75855e5..5a5629b 100644 --- a/api/base/FixedArray.md +++ b/api/base/FixedArray.md @@ -9,8 +9,8 @@ struct Type[N] } ``` -- `Size` +### `Size` - Returns the size of the array. This is a compile-time constant. +Returns the size of the array. This is a compile-time constant. diff --git a/api/base/Object.md b/api/base/Object.md index 9b780bc..bc277ef 100644 --- a/api/base/Object.md +++ b/api/base/Object.md @@ -17,33 +17,33 @@ class Object } ``` -- `bDestroyed` +### `bDestroyed` - This object wants to be destroyed but has not yet been garbage collected. +This object wants to be destroyed but has not yet been garbage collected. -- `GetClass` +### `GetClass` - Returns the class type of this object. +Returns the class type of this object. -- `GetClassName` +### `GetClassName` - Returns a string representation of the class type of this object. +Returns a string representation of the class type of this object. -- `GetParentClass` +### `GetParentClass` - Returns the class type of this object's parent class. +Returns the class type of this object's parent class. -- `Destroy` +### `Destroy` - Destroys this object. Do not use the object after calling this. References - to it will be invalidated. +Destroys this object. Do not use the object after calling this. References to +it will be invalidated. -- `OnDestroy` +### `OnDestroy` - Called just before the object is collected by the garbage collector. **Not - deterministic** unless the object is linked into the thinker list, in which - case it is destroyed earlier in a deterministic setting. Not all `Thinker`s - are linked into this list, so be careful when overriding this. Any `Actor` - will generally be safe. +Called just before the object is collected by the garbage collector. **Not +deterministic** unless the object is linked into the thinker list, in which +case it is destroyed earlier in a deterministic setting. Not all `Thinker`s are +linked into this list, so be careful when overriding this. Any `Actor` will +generally be safe. diff --git a/api/base/String.md b/api/base/String.md index c975ee1..8f591f2 100644 --- a/api/base/String.md +++ b/api/base/String.md @@ -30,84 +30,82 @@ struct String } ``` -- `Format` +### `Format` - Creates a string using a format string and any amount of arguments. +Creates a string using a format string and any amount of arguments. -- `AppendFormat` +### `AppendFormat` - Works like `Format`, but appends the result to the string. +Works like `Format`, but appends the result to the string. -- `CharAt` +### `CharAt` - Returns the character at `pos` as a new string. +Returns the character at `pos` as a new string. -- `CharCodeAt` +### `CharCodeAt` - Returns the character at `pos` as an integer. +Returns the character at `pos` as an integer. -- `Filter` +### `Filter` - Replaces escape sequences in a string with escaped characters as a new - string. +Replaces escape sequences in a string with escaped characters as a new string. -- `IndexOf` +### `IndexOf` - Returns the first index of `substr` starting from the left at `start`. +Returns the first index of `substr` starting from the left at `start`. -- `Left` +### `Left` - Returns the first `len` characters as a new string. +Returns the first `len` characters as a new string. -- `Length` +### `Length` - Returns the number of characters in this string. +Returns the number of characters in this string. -- `Mid` +### `Mid` - Returns `len` characters starting at `pos` as a new string. +Returns `len` characters starting at `pos` as a new string. -- `Remove` +### `Remove` - Removes `amount` characters starting at `index` in place. +Removes `amount` characters starting at `index` in place. -- `Replace` +### `Replace` - Replaces all instances of `pattern` with `replacement` in place. +Replaces all instances of `pattern` with `replacement` in place. -- `RightIndexOf` +### `RightIndexOf` - Returns the first index of `substr` starting from the right at `end`. +Returns the first index of `substr` starting from the right at `end`. -- `Split` +### `Split` - Splits the string by each `delimiter` into `tokens`. `keepEmpty` may be - either `TOK_SKIPEMPTY` (the default) or `TOK_KEEPEMPTY`, which will keep or - discard empty strings found while splitting. +Splits the string by each `delimiter` into `tokens`. `keepEmpty` may be either +`TOK_SKIPEMPTY` (the default) or `TOK_KEEPEMPTY`, which will keep or discard +empty strings found while splitting. -- `ToDouble` +### `ToDouble` - Interprets the string as a double precision floating point number. +Interprets the string as a double precision floating point number. -- `ToInt` +### `ToInt` - Interprets the string as a base `base` integer, guessing the base if it is - `0`. +Interprets the string as a base `base` integer, guessing the base if it is `0`. -- `ToLower` +### `ToLower` - Converts all characters in the string to lowercase in place. +Converts all characters in the string to lowercase in place. -- `ToUpper` +### `ToUpper` - Converts all characters in the string to uppercase in place. +Converts all characters in the string to uppercase in place. -- `Truncate` +### `Truncate` - Truncates the string to `len` characters in place. +Truncates the string to `len` characters in place. -- `LastIndexOf` +### `LastIndexOf` - Broken. Use `RightIndexOf` instead. +Broken. Use `RightIndexOf` instead. diff --git a/api/base/StringTable.md b/api/base/StringTable.md index 48f25d3..6d49ac5 100644 --- a/api/base/StringTable.md +++ b/api/base/StringTable.md @@ -9,12 +9,11 @@ struct StringTable } ``` -- `Localize` +### `Localize` - Returns the localized variant of `val`. If `prefixed` is `true`, the string - is returned as-is unless it is prefixed with `$` where the `$` character - itself is ignored. **Not deterministic** unless there is only one variant of - `val`. This is generally fine because this should only be used for visual - strings anyway. +Returns the localized variant of `val`. If `prefixed` is `true`, the string is +returned as-is unless it is prefixed with `$` where the `$` character itself is +ignored. **Not deterministic** unless there is only one variant of `val`. This +is generally fine because this should only be used for visual strings anyway. diff --git a/api/base/Thinker.md b/api/base/Thinker.md index 63ee935..e9e88ac 100644 --- a/api/base/Thinker.md +++ b/api/base/Thinker.md @@ -13,8 +13,8 @@ The user-defined stat numbers begin at `Thinker.STAT_USER` and end at except as relative to these two. Thinkers which do not think and are elided from many checks: @@ -65,30 +65,30 @@ class Thinker : Object play } ``` -- `TICRATE` +### `TICRATE` - The number of game ticks in a second. This value is always `int(35)`. +The number of game ticks in a second. This value is always `int(35)`. -- `Level` +### `Level` - The level this `Thinker` is in, which may differ from another one's. +The level this `Thinker` is in, which may differ from another one's. -- `ChangeStatNum` +### `ChangeStatNum` - Changes the statnum of this `Thinker`. +Changes the statnum of this `Thinker`. -- `PostBeginPlay` +### `PostBeginPlay` - Called at the very end of this Thinker's initialization. +Called at the very end of this Thinker's initialization. -- `Tick` +### `Tick` - Called every game tick. The order between this thinker's `Tick` and every - other thinker in the same statnum is unspecified. +Called every game tick. The order between this thinker's `Tick` and every other +thinker in the same statnum is unspecified. -- `Tics2Seconds` +### `Tics2Seconds` - Roughly converts a number of tics to an integral amount of seconds. - Equivalent to `tics / TICRATE`. +Roughly converts a number of tics to an integral amount of seconds. Equivalent +to `tics / TICRATE`. diff --git a/api/base/Vector.md b/api/base/Vector.md index 395b7d4..e6641b5 100644 --- a/api/base/Vector.md +++ b/api/base/Vector.md @@ -22,12 +22,12 @@ struct Vector3 } ``` -- `Length` +### `Length` - Returns the length (magnitude) of the vector. +Returns the length (magnitude) of the vector. -- `Unit` +### `Unit` - Returns a normalized vector. Equivalent to `vec / vec.Length()`. +Returns a normalized vector. Equivalent to `vec / vec.Length()`. diff --git a/api/drawing/BrokenLines.md b/api/drawing/BrokenLines.md index f57e2da..31d81d7 100644 --- a/api/drawing/BrokenLines.md +++ b/api/drawing/BrokenLines.md @@ -12,16 +12,16 @@ class BrokenLines : Object } ``` -- `Count` +### `Count` - Returns the amount of lines in this container. +Returns the amount of lines in this container. -- `StringAt` +### `StringAt` - Returns the text of line `line`. +Returns the text of line `line`. -- `StringWidth` +### `StringWidth` - Returns the width (in pixels) of line `line`. +Returns the width (in pixels) of line `line`. diff --git a/api/drawing/Console.md b/api/drawing/Console.md index 627fcfc..dc27978 100644 --- a/api/drawing/Console.md +++ b/api/drawing/Console.md @@ -11,22 +11,21 @@ struct Console } ``` -- `HideConsole` +### `HideConsole` - Hides the console if it is open and `GameState` is not `GS_FULLCONSOLE`. +Hides the console if it is open and `GameState` is not `GS_FULLCONSOLE`. -- `MidPrint` +### `MidPrint` - Prints `text` (possibly a `LANGUAGE` string if prefixed with `$`) in `font` - to the middle of the screen for 1½ seconds. Will print even if the player is - a spectator if `bold` is `true`. Uses the `msgmidcolor` CVar for non-bold - messages and `msgmidcolor2` for bold messages. +Prints `text` (possibly a `LANGUAGE` string if prefixed with `$`) in `font` to +the middle of the screen for 1½ seconds. Will print even if the player is a +spectator if `bold` is `true`. Uses the `msgmidcolor` CVar for non-bold +messages and `msgmidcolor2` for bold messages. - This is the function used internally by ACS' `Print` and `PrintBold` - functions. +This is the function used internally by ACS' `Print` and `PrintBold` functions. -- `PrintF` +### `PrintF` - Prints a formatted string to the console. +Prints a formatted string to the console. diff --git a/api/drawing/Font.md b/api/drawing/Font.md index 2370bfb..52fddc6 100644 --- a/api/drawing/Font.md +++ b/api/drawing/Font.md @@ -20,42 +20,42 @@ struct Font } ``` -- `FindFont` +### `FindFont` - Gets a font as defined in `FONTDEFS`. +Gets a font as defined in `FONTDEFS`. -- `FindFontColor` +### `FindFontColor` - Returns the color range enumeration for a named color. +Returns the color range enumeration for a named color. -- `GetFont` +### `GetFont` - Gets a font either as defined in `FONTDEFS` or a ZDoom/bitmap font. +Gets a font either as defined in `FONTDEFS` or a ZDoom/bitmap font. -- `GetBottomAlignOffset` +### `GetBottomAlignOffset` - Returns the baseline for the character `code`. +Returns the baseline for the character `code`. -- `GetCharWidth` +### `GetCharWidth` - Returns the width in pixels of a character code. +Returns the width in pixels of a character code. -- `GetCursor` +### `GetCursor` - Returns the string used as a blinking cursor graphic for this font. +Returns the string used as a blinking cursor graphic for this font. -- `GetHeight` +### `GetHeight` - Returns the line height of the font. +Returns the line height of the font. -- `StringWidth` +### `StringWidth` - Returns the width in pixels of the string. +Returns the width in pixels of the string. -- `BreakLines` +### `BreakLines` - Breaks `text` up into a `BrokenLines` structure according to the screen and - clip region, as well as appropriately accounting for a maximum width in - pixels of `maxlen`. +Breaks `text` up into a `BrokenLines` structure according to the screen and +clip region, as well as appropriately accounting for a maximum width in pixels +of `maxlen`. diff --git a/api/drawing/GIFont.md b/api/drawing/GIFont.md index 378fc08..a7a2072 100644 --- a/api/drawing/GIFont.md +++ b/api/drawing/GIFont.md @@ -10,12 +10,12 @@ struct GIFont } ``` -- `Color` +### `Color` - The color of the font. +The color of the font. -- `FontName` +### `FontName` - The name of the font. +The name of the font. diff --git a/api/drawing/Screen.md b/api/drawing/Screen.md index 864c200..04553a3 100644 --- a/api/drawing/Screen.md +++ b/api/drawing/Screen.md @@ -32,145 +32,144 @@ struct Screen } ``` -- `DrawChar` +### `DrawChar` - The same as `DrawTexture`, but draws the texture of character code - `character` from `font`. The output color may be modified by the font color - `cr`. +The same as `DrawTexture`, but draws the texture of character code `character` +from `font`. The output color may be modified by the font color `cr`. -- `DrawShape` +### `DrawShape` - TODO +TODO -- `DrawText` +### `DrawText` - TODO +TODO -- `DrawTexture` +### `DrawTexture` - Draws texture `tex`, possibly animated by the animation ticker if `animate` - is `true`, at horizontal position `x` and vertical position `y`. +Draws texture `tex`, possibly animated by the animation ticker if `animate` is +`true`, at horizontal position `x` and vertical position `y`. - Various properties of this drawing process can be changed by passing extra - arguments to this function. After all arguments are parsed, the - "`CleanMode`" internal variable is used along with the specified virtual - width/height to determine how to finally transform positions. `CleanMode` - may be one of the following: +Various properties of this drawing process can be changed by passing extra +arguments to this function. After all arguments are parsed, the "`CleanMode`" +internal variable is used along with the specified virtual width/height to +determine how to finally transform positions. `CleanMode` may be one of the +following: - | Name | Description | - | ---- | ----------- | - | `DTA_BASE` | No position scaling is performed. | - | `DTA_CLEAN` | Scales all positions by `Clean*Fac`. See the documentation for those variables for more information. | - | `DTA_CLEANNOMOVE` | Scales the destination width and height by `Clean*Fac`. | - | `DTA_CLEANNOMOVE_1` | Scales the destination width and height by `Clean*Fac_1`. | - | `DTA_FULLSCREEN` | Sets the X and Y positions to `0`. (Yes, really, this is all it does.) | - | `DTA_HUDRULES` | Scales all positions by the current status bar's scaling rules. | - | `DTA_HUDRULESC` | Scales all positions by the current status bar's scaling rules and centers the X position. | +| Name | Description | +| ---- | ----------- | +| `DTA_BASE` | No position scaling is performed. | +| `DTA_CLEAN` | Scales all positions by `Clean*Fac`. See the documentation for those variables for more information. | +| `DTA_CLEANNOMOVE` | Scales the destination width and height by `Clean*Fac`. | +| `DTA_CLEANNOMOVE_1` | Scales the destination width and height by `Clean*Fac_1`. | +| `DTA_FULLSCREEN` | Sets the X and Y positions to `0`. (Yes, really, this is all it does.) | +| `DTA_HUDRULES` | Scales all positions by the current status bar's scaling rules. | +| `DTA_HUDRULESC` | Scales all positions by the current status bar's scaling rules and centers the X position. | - Here is a list of tags and their respective arguments which may be used: +Here is a list of tags and their respective arguments which may be used: - | Name | Arguments | Description | - | ---- | --------- | ----------- | - | `DTA_320X200` | `bool use` | Sets `CleanMode` to `DTA_BASE` and the virtual width/height to `320`/`200` if `use` is `true`. Note that 320x200 does not scale properly to the screen as it must be 320x240 to do so. | - | `DTA_ALPHACHANNEL` | `bool use` | Does nothing unless `DTA_FILLCOLOR` is used and the render style is unspecified, in which case it will set the render style to "shaded" if `use` is `true`. | - | `DTA_ALPHA` | `double alpha` | Sets the alpha of the drawn texture to `alpha`. | - | `DTA_BOTTOM320X200` | `bool use` | Same as `DTA_320X200`, but also enables position transformation as if a call to `VirtualToRealCoords` with `vbottom` to `true`. Note that this is the only way to actually set this, but it may be overridden by following arguments to effectively toggle only this flag. | - | `DTA_CENTERBOTTOMOFFSET` | `bool use` | Same as `DTA_CENTERBOTTOMOFFSET`, but the Y offset is aligned to the bottom instead of the center. | - | `DTA_CENTEROFFSET` | `bool use` | Overrides the texture's X and Y offsets, centering them between the texture's height and width if `use` is `true`. | - | `DTA_CLEANNOMOVE1` | `bool use` | Sets `CleanMode` to `DTA_CLEANNOMOVE1` if `use` is `true`. | - | `DTA_CLEANNOMOVE` | `bool use` | Sets `CleanMode` to `DTA_CLEANNOMOVE` if `use` is `true`. | - | `DTA_CLEAN` | `bool use` | Sets `CleanMode` to `DTA_CLEAN` if `use` is `true`. | - | `DTA_CLIPBOTTOM`, `DTA_CLIPTOP` | `int length` | Sets the vertical clipping for the texture. | - | `DTA_CLIPLEFT`, `DTA_CLIPRIGHT` | `int length` | Sets the horizontal clipping for the texture. | - | `DTA_COLOROVERLAY` | `color cr` | Multiplies `cr` with the texture. Alpha determines the intensity of this overlay. Applied before render styles. | - | `DTA_COLOR` | `color cr` | Multiplies `cr` with the texture. Applied after render styles change the color. | - | `DTA_DESATURATE` | `int amount` | Desaturates the texture by `amount` (range 0-255.) | - | `DTA_DESTHEIGHTF`, `DTA_DESTWIDTHF` | `double size` | Same as `DTA_DESTHEIGHT`/`DTA_DESTWIDTH`, but with decimal arguments. | - | `DTA_DESTHEIGHT`, `DTA_DESTWIDTH` | `int size` | Sets the resulting width or height on screen of the texture and sets `CleanMode` to `DTA_BASE`. | - | `DTA_FILLCOLOR` | `color cr` | Sets the render style to "stencil" if one is not specified and the fill color to `cr`. | - | `DTA_FLIPX`, `DTA_FLIPY` | `bool use` | Flips the X or Y position if `use` is `true`. - | `DTA_FULLSCREEN` | `bool use` | Sets `CleanMode` to `DTA_FULLSCREEN` and the virtual width and height to the display size of the texture. | - | `DTA_HUDRULES` | `int type` | Sets `CleanMode` to `DTA_HUDRULESC` if `type` is `BaseStatusBar.HUD_HORIZCENTER`, or `DTA_HUDRULES` if it is `BaseStatusBar.HUD_NORMAL`. | - | `DTA_KEEPRATIO` | `bool on` | Enables aspect ratio correction if `on` is `true`. | - | `DTA_LEFTOFFSETF`, `DTA_TOPOFFSETF` | `double ofs` | Same as `DTA_LEFTOFFSET`/`DTA_TOPOFFSETF`, but with decimal arguments. | - | `DTA_LEFTOFFSET`, `DTA_TOPOFFSET` | `int ofs` | Overrides the texture's X or Y offset. | - | `DTA_LEGACYRENDERSTYLE` | `int style` | Overrides the render style. Note that there is also a `DTA_RENDERSTYLE` which cannot be used because the engine does not expose `FRenderStyle` yet. | - | `DTA_MASKED` | `bool on` | Turns the texture fully opaque (no alpha mask) if `on` is `false`. Default value is on. | - | `DTA_SRCHEIGHT`, `DTA_SRCWIDTH` | `int size` | Sets the width or height of the source image. Will cut the texture if lower than the original size. If the size is larger than the original, it will cause UV clamping, repeating the pixels at the image borders. | - | `DTA_SRCX`, `DTA_SRCY` | `int pos` | Sets the X or Y on the source image to start the texture at. Texture wrapping will cause a UV clamping effect, repeating the pixels at the image borders. | - | `DTA_TRANSLATIONINDEX` | `int index` | Remaps colors in the destination texture with translation table `index`. | - | `DTA_VIRTUALHEIGHTF`, `DTA_VIRTUALWIDTHF` | `double size` | Same as `DTA_VIRTUALHEIGHT`/`DTA_VIRTUALWIDTH`, but with decimal arguments. | - | `DTA_VIRTUALHEIGHT`, `DTA_VIRTUALWIDTH` | `int size` | Sets the virtual width or height to `size`. | - | `DTA_WINDOWLEFTF`, `DTA_WINDOWRIGHTF` | `double size` | Same as `DTA_WINDOWLEFT`/`DTA_WINDOWRIGHT`, but with decimal arguments. | - | `DTA_WINDOWLEFT`, `DTA_WINDOWRIGHT` | `int size` | Crops `size` pixels from the left or right. | +| Name | Arguments | Description | +| ---- | --------- | ----------- | +| `DTA_320X200` | `bool use` | Sets `CleanMode` to `DTA_BASE` and the virtual width/height to `320`/`200` if `use` is `true`. Note that 320x200 does not scale properly to the screen as it must be 320x240 to do so. | +| `DTA_ALPHACHANNEL` | `bool use` | Does nothing unless `DTA_FILLCOLOR` is used and the render style is unspecified, in which case it will set the render style to "shaded" if `use` is `true`. | +| `DTA_ALPHA` | `double alpha` | Sets the alpha of the drawn texture to `alpha`. | +| `DTA_BOTTOM320X200` | `bool use` | Same as `DTA_320X200`, but also enables position transformation as if a call to `VirtualToRealCoords` with `vbottom` to `true`. Note that this is the only way to actually set this, but it may be overridden by following arguments to effectively toggle only this flag. | +| `DTA_CENTERBOTTOMOFFSET` | `bool use` | Same as `DTA_CENTERBOTTOMOFFSET`, but the Y offset is aligned to the bottom instead of the center. | +| `DTA_CENTEROFFSET` | `bool use` | Overrides the texture's X and Y offsets, centering them between the texture's height and width if `use` is `true`. | +| `DTA_CLEANNOMOVE1` | `bool use` | Sets `CleanMode` to `DTA_CLEANNOMOVE1` if `use` is `true`. | +| `DTA_CLEANNOMOVE` | `bool use` | Sets `CleanMode` to `DTA_CLEANNOMOVE` if `use` is `true`. | +| `DTA_CLEAN` | `bool use` | Sets `CleanMode` to `DTA_CLEAN` if `use` is `true`. | +| `DTA_CLIPBOTTOM`, `DTA_CLIPTOP` | `int length` | Sets the vertical clipping for the texture. | +| `DTA_CLIPLEFT`, `DTA_CLIPRIGHT` | `int length` | Sets the horizontal clipping for the texture. | +| `DTA_COLOROVERLAY` | `color cr` | Multiplies `cr` with the texture. Alpha determines the intensity of this overlay. Applied before render styles. | +| `DTA_COLOR` | `color cr` | Multiplies `cr` with the texture. Applied after render styles change the color. | +| `DTA_DESATURATE` | `int amount` | Desaturates the texture by `amount` (range 0-255.) | +| `DTA_DESTHEIGHTF`, `DTA_DESTWIDTHF` | `double size` | Same as `DTA_DESTHEIGHT`/`DTA_DESTWIDTH`, but with decimal arguments. | +| `DTA_DESTHEIGHT`, `DTA_DESTWIDTH` | `int size` | Sets the resulting width or height on screen of the texture and sets `CleanMode` to `DTA_BASE`. | +| `DTA_FILLCOLOR` | `color cr` | Sets the render style to "stencil" if one is not specified and the fill color to `cr`. | +| `DTA_FLIPX`, `DTA_FLIPY` | `bool use` | Flips the X or Y position if `use` is `true`. +| `DTA_FULLSCREEN` | `bool use` | Sets `CleanMode` to `DTA_FULLSCREEN` and the virtual width and height to the display size of the texture. | +| `DTA_HUDRULES` | `int type` | Sets `CleanMode` to `DTA_HUDRULESC` if `type` is `BaseStatusBar.HUD_HORIZCENTER`, or `DTA_HUDRULES` if it is `BaseStatusBar.HUD_NORMAL`. | +| `DTA_KEEPRATIO` | `bool on` | Enables aspect ratio correction if `on` is `true`. | +| `DTA_LEFTOFFSETF`, `DTA_TOPOFFSETF` | `double ofs` | Same as `DTA_LEFTOFFSET`/`DTA_TOPOFFSETF`, but with decimal arguments. | +| `DTA_LEFTOFFSET`, `DTA_TOPOFFSET` | `int ofs` | Overrides the texture's X or Y offset. | +| `DTA_LEGACYRENDERSTYLE` | `int style` | Overrides the render style. Note that there is also a `DTA_RENDERSTYLE` which cannot be used because the engine does not expose `FRenderStyle` yet. | +| `DTA_MASKED` | `bool on` | Turns the texture fully opaque (no alpha mask) if `on` is `false`. Default value is on. | +| `DTA_SRCHEIGHT`, `DTA_SRCWIDTH` | `int size` | Sets the width or height of the source image. Will cut the texture if lower than the original size. If the size is larger than the original, it will cause UV clamping, repeating the pixels at the image borders. | +| `DTA_SRCX`, `DTA_SRCY` | `int pos` | Sets the X or Y on the source image to start the texture at. Texture wrapping will cause a UV clamping effect, repeating the pixels at the image borders. | +| `DTA_TRANSLATIONINDEX` | `int index` | Remaps colors in the destination texture with translation table `index`. | +| `DTA_VIRTUALHEIGHTF`, `DTA_VIRTUALWIDTHF` | `double size` | Same as `DTA_VIRTUALHEIGHT`/`DTA_VIRTUALWIDTH`, but with decimal arguments. | +| `DTA_VIRTUALHEIGHT`, `DTA_VIRTUALWIDTH` | `int size` | Sets the virtual width or height to `size`. | +| `DTA_WINDOWLEFTF`, `DTA_WINDOWRIGHTF` | `double size` | Same as `DTA_WINDOWLEFT`/`DTA_WINDOWRIGHT`, but with decimal arguments. | +| `DTA_WINDOWLEFT`, `DTA_WINDOWRIGHT` | `int size` | Crops `size` pixels from the left or right. | -- `Clear` +### `Clear` - Draws a rectangle from `top left` to `bottom right` in screen coordinates of - `cr` color. Does not support translucent colors. `palcolor` is a palette - index to use as a color in paletted renderers or `-1` for automatic - conversion from the given RGB color. +Draws a rectangle from `top left` to `bottom right` in screen coordinates of +`cr` color. Does not support translucent colors. `palcolor` is a palette index +to use as a color in paletted renderers or `-1` for automatic conversion from +the given RGB color. -- `Dim` +### `Dim` - Draws a rectangle at `x y` of `w h` size in screen coordinates of `cr` - color. Does not support translucent colors, but `amount` may be used to - specify the translucency in a range of 0-1 inclusive. +Draws a rectangle at `x y` of `w h` size in screen coordinates of `cr` color. +Does not support translucent colors, but `amount` may be used to specify the +translucency in a range of 0-1 inclusive. -- `DrawFrame` +### `DrawFrame` - Draws a frame around a rectangle at `x y` of `w h` size in screen - coordinates, using the border graphics as defined in `MAPINFO`/GameInfo. +Draws a frame around a rectangle at `x y` of `w h` size in screen coordinates, +using the border graphics as defined in `MAPINFO`/GameInfo. -- `DrawLine` +### `DrawLine` - Draws a one pixel wide line from `x0 y0` to `x1 y1` in screen coordinates of - color `cr` with alpha `alpha` (range 0-255.) +Draws a one pixel wide line from `x0 y0` to `x1 y1` in screen coordinates of +color `cr` with alpha `alpha` (range 0-255.) -- `DrawThickLine` +### `DrawThickLine` - Draws a `thickness` pixel wide line from `x0 y0` to `x1 y1` in screen - coordinates of color `cr` with alpha `alpha` (range 0-255.) +Draws a `thickness` pixel wide line from `x0 y0` to `x1 y1` in screen +coordinates of color `cr` with alpha `alpha` (range 0-255.) -- `GetAspectRatio` +### `GetAspectRatio` - Returns the aspect ratio of the screen. +Returns the aspect ratio of the screen. -- `GetHeight` +### `GetHeight` - Returns the height of the screen. +Returns the height of the screen. -- `GetWidth` +### `GetWidth` - Returns the width of the screen. +Returns the width of the screen. -- `PaletteColor` +### `PaletteColor` - Returns a `color` for a given palette index. +Returns a `color` for a given palette index. -- `VirtualToRealCoords` +### `VirtualToRealCoords` - Converts virtual coordinates `pos` from virtual coordinate space `vsize` to - screen coordinate space `size`, possibly accounting for aspect ratio - differences if `handleaspect` is true. If the ratio is 5:4, `vbottom` will - account for the higher-than-wide conversion by repositioning vertically. +Converts virtual coordinates `pos` from virtual coordinate space `vsize` to +screen coordinate space `size`, possibly accounting for aspect ratio +differences if `handleaspect` is true. If the ratio is 5:4, `vbottom` will +account for the higher-than-wide conversion by repositioning vertically. -- `ClearClipRect` +### `ClearClipRect` - Clears the clipping rectangle if there is one. +Clears the clipping rectangle if there is one. -- `GetClipRect` +### `GetClipRect` - Returns the clipping rectangle's `x`/`y`/`w`/`h`. +Returns the clipping rectangle's `x`/`y`/`w`/`h`. -- `GetViewWindow` +### `GetViewWindow` - Returns the 3D viewing window, which may be smaller than the screen size - with any given `screenblocks` setting. +Returns the 3D viewing window, which may be smaller than the screen size with +any given `screenblocks` setting. -- `SetClipRect` +### `SetClipRect` - Sets the clipping rectangle to restrict further drawing to the region - starting at `x y` of size `w h` in screen coordinates. +Sets the clipping rectangle to restrict further drawing to the region starting +at `x y` of size `w h` in screen coordinates. diff --git a/api/drawing/Shape2D.md b/api/drawing/Shape2D.md index 9de9cd8..f0353c9 100644 --- a/api/drawing/Shape2D.md +++ b/api/drawing/Shape2D.md @@ -12,26 +12,26 @@ class Shape2D : Object } ``` -- `Clear` +### `Clear` - Clears data out of a shape. Uses these as a bit flag: +Clears data out of a shape. Uses these as a bit flag: - | Name | Description | - | ---- | ----------- | - | `Shape2D.C_Coords` | Clears texture coordinates. | - | `Shape2D.C_Indices` | Clears vertex indices. | - | `Shape2D.C_Verts` | Clears vertices. | +| Name | Description | +| ---- | ----------- | +| `Shape2D.C_Coords` | Clears texture coordinates. | +| `Shape2D.C_Indices` | Clears vertex indices. | +| `Shape2D.C_Verts` | Clears vertices. | -- `PushCoord` +### `PushCoord` - Pushes a texture coordinate into the shape buffer. +Pushes a texture coordinate into the shape buffer. -- `PushTriangle` +### `PushTriangle` - Pushes the indices of a triangle into the shape buffer. +Pushes the indices of a triangle into the shape buffer. -- `PushVertex` +### `PushVertex` - Pushes a vertex into the shape buffer. +Pushes a vertex into the shape buffer. diff --git a/api/drawing/TexMan.md b/api/drawing/TexMan.md index 1523567..5a414d2 100644 --- a/api/drawing/TexMan.md +++ b/api/drawing/TexMan.md @@ -19,91 +19,90 @@ struct TexMan } ``` -- `CheckForTexture` +### `CheckForTexture` - Returns a `textureid` for the texture named `name`. `usetype` may be one of - the following, which selects what kind of texture to find: +Returns a `textureid` for the texture named `name`. `usetype` may be one of the +following, which selects what kind of texture to find: - | Name | Description | - | ---- | ----------- | - | `TexMan.TYPE_ANY` | Any kind of texture. | - | `TexMan.TYPE_AUTOPAGE` | Unused. | - | `TexMan.TYPE_BUILD` | Unused. | - | `TexMan.TYPE_DECAL` | A decal pic defined in `DECALDEF`. | - | `TexMan.TYPE_FIRSTDEFINED` | The first composite texture defined by the IWad. | - | `TexMan.TYPE_FLAT` | A flat (ceiling/floor texture,) i.e. `FLOOR0_1`. | - | `TexMan.TYPE_FONTCHAR` | Unused. | - | `TexMan.TYPE_MISCPATCH` | A loose graphic, i.e. `M_DOOM`. | - | `TexMan.TYPE_NULL` | Reserved for the null graphic. Ignores `name`. | - | `TexMan.TYPE_OVERRIDE` | Overridable generalized textures, for instance textures defined in `TX_START` or BUILD ART tiles. | - | `TexMan.TYPE_SKINGRAPHIC` | Any loose graphic defined in `S_SKIN` i.e. statusbar faces. | - | `TexMan.TYPE_SKINSPRITE` | Any sprite defined in `S_SKIN`. | - | `TexMan.TYPE_SPRITE` | A sprite in `S_START`, i.e. `MEDIA0`. | - | `TexMan.TYPE_WALLPATCH` | An uncomposited patch, i.e. `DOOR2_1`. | - | `TexMan.TYPE_WALL` | Any composited wall texture, i.e. `STARTAN2`. | +| Name | Description | +| ---- | ----------- | +| `TexMan.TYPE_ANY` | Any kind of texture. | +| `TexMan.TYPE_AUTOPAGE` | Unused. | +| `TexMan.TYPE_BUILD` | Unused. | +| `TexMan.TYPE_DECAL` | A decal pic defined in `DECALDEF`. | +| `TexMan.TYPE_FIRSTDEFINED` | The first composite texture defined by the IWad. | +| `TexMan.TYPE_FLAT` | A flat (ceiling/floor texture,) i.e. `FLOOR0_1`. | +| `TexMan.TYPE_FONTCHAR` | Unused. | +| `TexMan.TYPE_MISCPATCH` | A loose graphic, i.e. `M_DOOM`. | +| `TexMan.TYPE_NULL` | Reserved for the null graphic. Ignores `name`. | +| `TexMan.TYPE_OVERRIDE` | Overridable generalized textures, for instance textures defined in `TX_START` or BUILD ART tiles. | +| `TexMan.TYPE_SKINGRAPHIC` | Any loose graphic defined in `S_SKIN` i.e. statusbar faces. | +| `TexMan.TYPE_SKINSPRITE` | Any sprite defined in `S_SKIN`. | +| `TexMan.TYPE_SPRITE` | A sprite in `S_START`, i.e. `MEDIA0`. | +| `TexMan.TYPE_WALLPATCH` | An uncomposited patch, i.e. `DOOR2_1`. | +| `TexMan.TYPE_WALL` | Any composited wall texture, i.e. `STARTAN2`. | - `flags` may be any of the following combined (with the bitwise OR operator - `|`:) +`flags` may be any of the following combined (with the bitwise OR operator +`|`:) - | Name | Description | - | ---- | ----------- | - | `TexMan.ALLOWSKINS` | Allows `SkinGraphic`s to be returned under normal circumstances. | - | `TexMan.DONTCREATE` | Will never create a new texture when searching. | - | `TexMan.LOCALIZE` | TODO . | - | `TexMan.OVERRIDABLE` | Allows overriding of this texture by for instance `TEXTURES`. | - | `TexMan.RETURNFIRST` | Allows returning the `FirstDefined` "null" texture under normal circumstances. | - | `TexMan.SHORTNAMEONLY` | Will force use of a short name when searching. | - | `TexMan.TRYANY` | Returns any other type of texture if one is not found in the specified use type. Default. | +| Name | Description | +| ---- | ----------- | +| `TexMan.ALLOWSKINS` | Allows `SkinGraphic`s to be returned under normal circumstances. | +| `TexMan.DONTCREATE` | Will never create a new texture when searching. | +| `TexMan.LOCALIZE` | TODO . | +| `TexMan.OVERRIDABLE` | Allows overriding of this texture by for instance `TEXTURES`. | +| `TexMan.RETURNFIRST` | Allows returning the `FirstDefined` "null" texture under normal circumstances. | +| `TexMan.SHORTNAMEONLY` | Will force use of a short name when searching. | +| `TexMan.TRYANY` | Returns any other type of texture if one is not found in the specified use type. Default. | -- `CheckRealHeight` +### `CheckRealHeight` - Returns the height in pixels of the texture down to the last scanline which - has actual pixel data. Note that this operation is extremely slow and should - be used sparingly. +Returns the height in pixels of the texture down to the last scanline which has +actual pixel data. Note that this operation is extremely slow and should be +used sparingly. -- `GetName` +### `GetName` - Returns the original name of a `textureid`. +Returns the original name of a `textureid`. -- `GetScaledOffset` +### `GetScaledOffset` - Returns the offsets for this texture used to display it (rather than the - original offsets.) +Returns the offsets for this texture used to display it (rather than the +original offsets.) -- `GetScaledSize` +### `GetScaledSize` - Returns the size used to display this texture (rather than the physical - size.) +Returns the size used to display this texture (rather than the physical size.) -- `GetSize` +### `GetSize` - Returns the width and height of a `textureid`. +Returns the width and height of a `textureid`. -- `SetCameraToTexture` +### `SetCameraToTexture` - Sets the camera texture (as defined in `ANIMDEFS`) `texture` to the - viewpoint of `viewpoint` with a fov of `fov`. +Sets the camera texture (as defined in `ANIMDEFS`) `texture` to the viewpoint +of `viewpoint` with a fov of `fov`. -- `OkForLocalization` +### `OkForLocalization` - TODO +TODO -- `ReplaceTextures` +### `ReplaceTextures` - Note: This function is deprecated and `LevelLocals::ReplaceTextures` should - be used instead. +Note: This function is deprecated and `LevelLocals::ReplaceTextures` should be +used instead. - Replaces textures named `from` with `to` within the map. `flags` may be used - to filter out certain textures from being replaced: +Replaces textures named `from` with `to` within the map. `flags` may be used to +filter out certain textures from being replaced: - | Name | Description | - | ---- | ----------- | - | `TexMan.NOT_BOTTOM` | Filters out linedef bottom textures. | - | `TexMan.NOT_CEILING` | Filters out ceiling flats. | - | `TexMan.NOT_FLAT` | Filters out any flat texture. | - | `TexMan.NOT_FLOOR` | Filters out floor flats. | - | `TexMan.NOT_MIDDLE` | Filters out linedef middle textures. | - | `TexMan.NOT_TOP` | Filters out linedef upper textures. | - | `TexMan.NOT_WALL` | Filters out any linedef texture. | +| Name | Description | +| ---- | ----------- | +| `TexMan.NOT_BOTTOM` | Filters out linedef bottom textures. | +| `TexMan.NOT_CEILING` | Filters out ceiling flats. | +| `TexMan.NOT_FLAT` | Filters out any flat texture. | +| `TexMan.NOT_FLOOR` | Filters out floor flats. | +| `TexMan.NOT_MIDDLE` | Filters out linedef middle textures. | +| `TexMan.NOT_TOP` | Filters out linedef upper textures. | +| `TexMan.NOT_WALL` | Filters out any linedef texture. | diff --git a/api/drawing/TextureID.md b/api/drawing/TextureID.md index 1b70851..7599f69 100644 --- a/api/drawing/TextureID.md +++ b/api/drawing/TextureID.md @@ -15,31 +15,31 @@ struct TextureID } ``` -- `Exists` +### `Exists` - Checks if the texture exists within the texture manager at all. +Checks if the texture exists within the texture manager at all. -- `IsNull` +### `IsNull` - Checks if the texture is the null index (`0`.) +Checks if the texture is the null index (`0`.) -- `IsValid` +### `IsValid` - Checks if the texture index is not the invalid index (`-1`.) +Checks if the texture index is not the invalid index (`-1`.) -- `SetInvalid` +### `SetInvalid` - Sets the texture index to `-1`. +Sets the texture index to `-1`. -- `SetNull` +### `SetNull` - Sets the texture index to `0`. +Sets the texture index to `0`. - The proper way to zero-initialize a `textureid` is: +The proper way to zero-initialize a `textureid` is: - ``` - textureid tex; - tex.SetNull(); - ``` +``` +textureid tex; +tex.SetNull(); +``` diff --git a/api/events/ConsoleEvent.md b/api/events/ConsoleEvent.md index 0184133..4706629 100644 --- a/api/events/ConsoleEvent.md +++ b/api/events/ConsoleEvent.md @@ -12,25 +12,25 @@ struct ConsoleEvent } ``` -- `Player` +### `Player` - The player who created this event, or `-1` if there was no activator. This - will always be positive for `NetworkProcess` events and always `-1` for - `ConsoleProcess` events. +The player who created this event, or `-1` if there was no activator. This will +always be positive for `NetworkProcess` events and always `-1` for +`ConsoleProcess` events. -- `Name` +### `Name` - The name as provided to `SendNetworkEvent`. Use this to distinguish between - event types. It is favorable to prefix names with the name of your mod or - game so that it will not potentially conflict with other mods. +The name as provided to `SendNetworkEvent`. Use this to distinguish between +event types. It is favorable to prefix names with the name of your mod or game +so that it will not potentially conflict with other mods. -- `Args` +### `Args` - The arguments as provided to `SendNetworkEvent`. +The arguments as provided to `SendNetworkEvent`. -- `IsManual` +### `IsManual` - `true` if this event was created manually, for instance through a console - command. +`true` if this event was created manually, for instance through a console +command. diff --git a/api/events/EventHandler.md b/api/events/EventHandler.md index 06f4e2f..d2bc594 100644 --- a/api/events/EventHandler.md +++ b/api/events/EventHandler.md @@ -20,15 +20,15 @@ class EventHandler : StaticEventHandler } ``` -- `Find` +### `Find` - Finds and returns the `StaticEventHandler` type `type` if it is registered, - or `null` if it does not exist. It should be noted that this is exactly the - same as `StaticEventHandler`'s, and does not actually check for - `EventHandlers`, although due to inheritance will return them correctly. +Finds and returns the `StaticEventHandler` type `type` if it is registered, or +`null` if it does not exist. It should be noted that this is exactly the same +as `StaticEventHandler`'s, and does not actually check for `EventHandlers`, +although due to inheritance will return them correctly. -- `SendNetworkEvent` +### `SendNetworkEvent` - Sends a network event with no activator. +Sends a network event with no activator. diff --git a/api/events/RenderEvent.md b/api/events/RenderEvent.md index b85f44f..1848a4d 100644 --- a/api/events/RenderEvent.md +++ b/api/events/RenderEvent.md @@ -14,31 +14,31 @@ struct RenderEvent } ``` -- `ViewPos` +### `ViewPos` - The position at which the camera is at. +The position at which the camera is at. -- `ViewAngle` +### `ViewAngle` - The yaw angle of the camera. +The yaw angle of the camera. -- `ViewPitch` +### `ViewPitch` - The pitch angle of the camera. +The pitch angle of the camera. -- `ViewRoll` +### `ViewRoll` - The roll angle of the camera. +The roll angle of the camera. -- `FracTic` +### `FracTic` - A value between 0 and 1 (exclusive) representing the time between the last - game tick and the next game tick. This is most useful for interpolation, and - you can add it to the current game tick to get the real time at which this - event has been called. Precision is not specified. +A value between 0 and 1 (exclusive) representing the time between the last game +tick and the next game tick. This is most useful for interpolation, and you can +add it to the current game tick to get the real time at which this event has +been called. Precision is not specified. -- `Camera` +### `Camera` - The actor which is acting as the camera for the player's view. +The actor which is acting as the camera for the player's view. diff --git a/api/events/ReplaceEvent.md b/api/events/ReplaceEvent.md index 6494795..1f5cf11 100644 --- a/api/events/ReplaceEvent.md +++ b/api/events/ReplaceEvent.md @@ -12,19 +12,19 @@ struct ReplaceEvent } ``` -- `Replacee` +### `Replacee` - The actor class which is being replaced. +The actor class which is being replaced. -- `Replacement` +### `Replacement` - What to replace it with. This class type is already effected by skill and - actor definition replacements, so it may be useful to read it. Modify this - to change what the resulting replacement class ends up being. +What to replace it with. This class type is already effected by skill and actor +definition replacements, so it may be useful to read it. Modify this to change +what the resulting replacement class ends up being. -- `IsFinal` +### `IsFinal` - If `true`, the engine will not attempt to continue going down the - replacement chain, and will directly replace the actor with `Replacement`. +If `true`, the engine will not attempt to continue going down the replacement +chain, and will directly replace the actor with `Replacement`. diff --git a/api/events/StaticEventHandler.md b/api/events/StaticEventHandler.md index 68e588d..ad352c4 100644 --- a/api/events/StaticEventHandler.md +++ b/api/events/StaticEventHandler.md @@ -64,186 +64,185 @@ class StaticEventHandler : Object play } ``` -- `Find` +### `Find` - Finds and returns the `StaticEventHandler` type `type` if it is registered, - or `null` if it does not exist. +Finds and returns the `StaticEventHandler` type `type` if it is registered, or +`null` if it does not exist. -- `OnRegister` +### `OnRegister` - Called when this type is registered. This is where you should set `Order`, - `IsUiProcessor` and `RequireMouse`. +Called when this type is registered. This is where you should set `Order`, +`IsUiProcessor` and `RequireMouse`. -- `OnUnregister` +### `OnUnregister` - Called when this type is un-registered. With `StaticEventHandler`s this is - called when the engine shuts down, so it isn't particularly useful. +Called when this type is un-registered. With `StaticEventHandler`s this is +called when the engine shuts down, so it isn't particularly useful. -- `WorldLoaded` +### `WorldLoaded` - Called directly after the status bar is attached to the player and after - `REOPEN` ACS scripts are called, just before the display is flushed and - auto-save is done. +Called directly after the status bar is attached to the player and after +`REOPEN` ACS scripts are called, just before the display is flushed and +auto-save is done. -- `WorldUnloaded` +### `WorldUnloaded` - Called directly after `UNLOADING` ACS scripts, just before the level is - changed. +Called directly after `UNLOADING` ACS scripts, just before the level is +changed. -- `WorldThingSpawned` +### `WorldThingSpawned` - Called directly after an actor's `PostBeginPlay` function. +Called directly after an actor's `PostBeginPlay` function. -- `WorldThingDied` +### `WorldThingDied` - Called after `MorphedDeath`, inventory items have called `OwnerDied`, and - the target is set to the damage source, just before `KILL` ACS scripts are - called and the rest of the death handling is done. +Called after `MorphedDeath`, inventory items have called `OwnerDied`, and the +target is set to the damage source, just before `KILL` ACS scripts are called +and the rest of the death handling is done. -- `WorldThingRevived` +### `WorldThingRevived` - Called when an actor is revived, after everything is finished. +Called when an actor is revived, after everything is finished. -- `WorldThingDamaged` +### `WorldThingDamaged` - Called directly before `Die`, or directly after after `DamageMobj` finishes. +Called directly before `Die`, or directly after after `DamageMobj` finishes. -- `WorldThingDestroyed` +### `WorldThingDestroyed` - Called at the beginning of an actor's `OnDestroy` function. +Called at the beginning of an actor's `OnDestroy` function. -- `WorldLinePreActivated` +### `WorldLinePreActivated` - Called directly after a line is tested for activation, before any other - activation specials are called (such as checking for keys, executing the - line special, etc.) +Called directly after a line is tested for activation, before any other +activation specials are called (such as checking for keys, executing the line +special, etc.) -- `WorldLineActivated` +### `WorldLineActivated` - Called directly after a line's special is executed, if it succeeded, before - any other handling (such as changing a switch's texture) is completed. +Called directly after a line's special is executed, if it succeeded, before any +other handling (such as changing a switch's texture) is completed. -- `WorldSectorDamaged` +### `WorldSectorDamaged` - Called when a sector is damaged if it has any health groups, before any - other handling is done. +Called when a sector is damaged if it has any health groups, before any other +handling is done. -- `WorldLineDamaged` +### `WorldLineDamaged` - Called when a line is damaged if it has any health groups, before any other - handling is done. +Called when a line is damaged if it has any health groups, before any other +handling is done. -- `WorldLightning` +### `WorldLightning` - Called when lightning strikes, directly after the sound is played, just - before `LIGHTNING` ACS scripts are called. +Called when lightning strikes, directly after the sound is played, just before +`LIGHTNING` ACS scripts are called. -- `WorldTick` +### `WorldTick` - Called on every world tick, after interpolators are updated, world freeze is - updated, sight counters are reset, particles have run their thinkers, and - players have run their thinkers, just before the status bar is ticked, the - level ticks, thinkers are ticked, and the level time is updated. This is not - called when the game is paused, and its execution is entirely deterministic - regardless of how this event handler is applied. +Called on every world tick, after interpolators are updated, world freeze is +updated, sight counters are reset, particles have run their thinkers, and +players have run their thinkers, just before the status bar is ticked, the +level ticks, thinkers are ticked, and the level time is updated. This is not +called when the game is paused, and its execution is entirely deterministic +regardless of how this event handler is applied. -- `RenderOverlay` +### `RenderOverlay` - Despite the name, this is actually run on the status bar, specifically in - `BaseStatusBar::DrawTopStuff`. It is run after `HudMessage`s are drawn and - power-ups are drawn, just before ゴゴゴ「The Log」ゴゴゴ is drawn. You may - use `Screen` functions in this function. +Despite the name, this is actually run on the status bar, specifically in +`BaseStatusBar::DrawTopStuff`. It is run after `HudMessage`s are drawn and +power-ups are drawn, just before ゴゴゴ「The Log」ゴゴゴ is drawn. You may use +`Screen` functions in this function. -- `PlayerEntered` +### `PlayerEntered` - Called during level load when each player enters the game, after the camera - is set but just before `RETURN` ACS scripts are called. +Called during level load when each player enters the game, after the camera is +set but just before `RETURN` ACS scripts are called. -- `PlayerRespawned` +### `PlayerRespawned` - Called when a player spawns, directly after the teleport fog is spanwed and - just before `RESPAWN` ACS scripts are called. Also called similarly at the - end of the `Respawn` function, for example when the `resurrect` cheat is - used. +Called when a player spawns, directly after the teleport fog is spanwed and +just before `RESPAWN` ACS scripts are called. Also called similarly at the end +of the `Respawn` function, for example when the `resurrect` cheat is used. -- `PlayerDied` +### `PlayerDied` - Called after `WorldThingDied` and `GetDeathHeight`, and after the actor's - thing special is activated, when the obituary has been displayed, just - before `DEATH` ACS scripts have been called. +Called after `WorldThingDied` and `GetDeathHeight`, and after the actor's thing +special is activated, when the obituary has been displayed, just before `DEATH` +ACS scripts have been called. -- `PlayerDisconnected` +### `PlayerDisconnected` - Called when a bot is removed and when a player disconnects from the game, - just before `DISCONNECT` ACS scripts are called. +Called when a bot is removed and when a player disconnects from the game, just +before `DISCONNECT` ACS scripts are called. -- `UiProcess` +### `UiProcess` - Called only if `IsUiProcessor` is `true`. Called when a GUI event is - dispatched by the engine, for example when the UI is active and the player - has pressed a key or moved the mouse. Mouse movements will only be captured - if `RequireMouse` is `true`. Because this interacts directly with the OS it - is not part of the game simulation, therefore has `ui` scope and must - dispatch commands to the game as networked events. If the return value is - `true`, the function will block any further handlers from processing this - event, essentially "eating" it. If the return value is `false`, other - handlers will continue to be called as normal. +Called only if `IsUiProcessor` is `true`. Called when a GUI event is dispatched +by the engine, for example when the UI is active and the player has pressed a +key or moved the mouse. Mouse movements will only be captured if `RequireMouse` +is `true`. Because this interacts directly with the OS it is not part of the +game simulation, therefore has `ui` scope and must dispatch commands to the +game as networked events. If the return value is `true`, the function will +block any further handlers from processing this event, essentially "eating" +it. If the return value is `false`, other handlers will continue to be called +as normal. -- `UiTick` +### `UiTick` - Despite what it may seem, this function is actually called deterministically - within the game loop, just before the level is ticked and after the player's - network commands are created. Albeit this, it is `ui` scope, so it should - be used to process UI code. +Despite what it may seem, this function is actually called deterministically +within the game loop, just before the level is ticked and after the player's +network commands are created. Albeit this, it is `ui` scope, so it should be +used to process UI code. -- `PostUiTick` +### `PostUiTick` - Similar to `UiTick`, this is also deterministic, but called after all other - tickers. +Similar to `UiTick`, this is also deterministic, but called after all other +tickers. -- `InputProcess` +### `InputProcess` - The same as `UiProcess`, but this is only called when inputs are being - directed to the game, rather than to the GUI. All of the same restrictions - apply to this as they do to `UiProcess`, and the return value acts the same. +The same as `UiProcess`, but this is only called when inputs are being directed +to the game, rather than to the GUI. All of the same restrictions apply to this +as they do to `UiProcess`, and the return value acts the same. -- `ConsoleProcess` +### `ConsoleProcess` - Called when network events which have no player activator are received. +Called when network events which have no player activator are received. -- `NetworkProcess` +### `NetworkProcess` - Called when network events which have a player activator are received. +Called when network events which have a player activator are received. -- `CheckReplacement` +### `CheckReplacement` - Called during actor replacement, after skill replacement is done, but before - any other replacement (such as actor replacements done in ZScript actor - definitions.) +Called during actor replacement, after skill replacement is done, but before +any other replacement (such as actor replacements done in ZScript actor +definitions.) -- `NewGame` +### `NewGame` - Called on a new game, directly after level data is reset and right before - the level is set up. +Called on a new game, directly after level data is reset and right before the +level is set up. -- `SetOrder` +### `SetOrder` - Sets the ordering of this event handler, which can be read from `Order`. +Sets the ordering of this event handler, which can be read from `Order`. -- `Order` +### `Order` - The arbitrary ordering of this event handler relative to other ones. Event - handlers with lower ordering numbers have their functions executed first. - You can set this variable with `SetOrder`. +The arbitrary ordering of this event handler relative to other ones. Event +handlers with lower ordering numbers have their functions executed first. You +can set this variable with `SetOrder`. -- `IsUiProcessor` +### `IsUiProcessor` - If `true`, GUI events will be sent to this event handler through - `UiProcess`. This is mainly for optimization purposes. +If `true`, GUI events will be sent to this event handler through `UiProcess`. +This is mainly for optimization purposes. -- `RequireMouse` +### `RequireMouse` - If `true`, mouse events will be sent to this event handler through - `InputProcess` and/or `UiProcess`. This is mainly for optimization purposes. +If `true`, mouse events will be sent to this event handler through +`InputProcess` and/or `UiProcess`. This is mainly for optimization purposes. diff --git a/api/files/Wads.md b/api/files/Wads.md index 8456f6e..913787c 100644 --- a/api/files/Wads.md +++ b/api/files/Wads.md @@ -22,11 +22,11 @@ Single files can also be loaded as archives, containing only themselves. In short: -- *Lump* refers to an object from any archive type with an 8 character filename (extension removed.) -- *File* refers to fully qualified object from a resource archive, which can also be used as a lump through its truncated name. -- *Archives* are real files or folders which hold *lumps*. -- *Resource archives* are archives with a folder structure for determining lump namespaces, and also store fully qualified paths for files. -- *Wad files* are archives which hold only lumps, and use markers for determining lump namespaces. +* *Lump* refers to an object from any archive type with an 8 character filename (extension removed.) +* *File* refers to fully qualified object from a resource archive, which can also be used as a lump through its truncated name. +* *Archives* are real files or folders which hold *lumps*. +* *Resource archives* are archives with a folder structure for determining lump namespaces, and also store fully qualified paths for files. +* *Wad files* are archives which hold only lumps, and use markers for determining lump namespaces. | Name | Description | Resource path | Wad file marker | | ---- | ----------- | ------------- | --------------- | @@ -61,37 +61,37 @@ struct Wads } ``` -- `CheckNumForFullName` +### `CheckNumForFullName` - Returns the handle of the first file named `name`, matching only the full - path to it, including the extension, or `-1` if the file was not found. Only - works with files defined in resource archives. +Returns the handle of the first file named `name`, matching only the full path +to it, including the extension, or `-1` if the file was not found. Only works +with files defined in resource archives. -- `CheckNumForName` +### `CheckNumForName` - Returns the handle of the first lump named `name` within namespace `ns`. If - `wadnum` is not `-1`, then it signifies, if `exact` is false, the number of - the last archive to search in, or the only archive to search in if `exact` - is `true`. +Returns the handle of the first lump named `name` within namespace `ns`. If +`wadnum` is not `-1`, then it signifies, if `exact` is false, the number of the +last archive to search in, or the only archive to search in if `exact` is +`true`. - Note there is currently no way to actually *get* the number of an archive, - even the current one. The only guarantee is that archive `0` will be the - base archive (`gzdoom.pk3`.) +Note there is currently no way to actually *get* the number of an archive, even +the current one. The only guarantee is that archive `0` will be the base +archive (`gzdoom.pk3`.) -- `FindLump` +### `FindLump` - Returns the handle of the first lump named `name` starting at `startlump` - (zero indicates the first lump) in either the global namespace or any - namespace. `ns` can be either `Wads.GLOBALNAMESPACE` or `Wads.ANYNAMESPACE` - to specify this. Returns `-1` if there are no lumps with that name left. +Returns the handle of the first lump named `name` starting at `startlump` (zero +indicates the first lump) in either the global namespace or any namespace. `ns` +can be either `Wads.GLOBALNAMESPACE` or `Wads.ANYNAMESPACE` to specify this. +Returns `-1` if there are no lumps with that name left. - This function can be used in a loop to find all lumps with a specified name. +This function can be used in a loop to find all lumps with a specified name. -- `ReadLump` +### `ReadLump` - Reads the whole contents of `lump` into a string and returns the result. If - `lump` is not valid, returns an empty string. Note that binary lumps can be - loaded this way and the string's length will be correct according to the - lump's size even if null characters are present in the lump. +Reads the whole contents of `lump` into a string and returns the result. If +`lump` is not valid, returns an empty string. Note that binary lumps can be +loaded this way and the string's length will be correct according to the lump's +size even if null characters are present in the lump. diff --git a/api/global/data/Client.md b/api/global/data/Client.md index 1979738..b1e52ad 100644 --- a/api/global/data/Client.md +++ b/api/global/data/Client.md @@ -32,109 +32,109 @@ readonly ui bool NetGame; int LocalViewPitch; ``` -- `AutomapBindings` +### `AutomapBindings` - TODO +TODO -- `Bindings` +### `Bindings` - TODO +TODO -- `BigFont` +### `BigFont` - The `bigfont` for the current game. +The `bigfont` for the current game. -- `CleanHeight` +### `CleanHeight` - The current screen height divided by `CleanYFac`. **Not deterministic.** +The current screen height divided by `CleanYFac`. **Not deterministic.** -- `CleanHeight_1` +### `CleanHeight_1` - The current screen height divided by `CleanYFac_1`. **Not deterministic.** +The current screen height divided by `CleanYFac_1`. **Not deterministic.** -- `CleanWidth` +### `CleanWidth` - The current screen width divided by `CleanXFac`. **Not deterministic.** +The current screen width divided by `CleanXFac`. **Not deterministic.** -- `CleanWidth_1` +### `CleanWidth_1` - The current screen width divided by `CleanYFac_1`. **Not deterministic.** +The current screen width divided by `CleanYFac_1`. **Not deterministic.** -- `CleanXFac` +### `CleanXFac` - Integral scaling factor for horizontal positions to scale from 320x200 to - the current virtual resolution. **Not deterministic.** +Integral scaling factor for horizontal positions to scale from 320x200 to the +current virtual resolution. **Not deterministic.** -- `CleanXFac_1` +### `CleanXFac_1` - Integral scaling factor for horizontal positions to scale from 320x200 to - the current virtual resolution, accounting for aspect ratio differences. - **Not deterministic.** +Integral scaling factor for horizontal positions to scale from 320x200 to the +current virtual resolution, accounting for aspect ratio differences. **Not +deterministic.** -- `CleanYFac` +### `CleanYFac` - Integral scaling factor for vertical positions to scale from 320x200 to the - current virtual resolution. **Not deterministic.** +Integral scaling factor for vertical positions to scale from 320x200 to the +current virtual resolution. **Not deterministic.** -- `CleanYFac_1` +### `CleanYFac_1` - Integral scaling factor for vertical positions to scale from 320x200 to the - current virtual resolution, accounting for aspect ratio differences. **Not - deterministic.** +Integral scaling factor for vertical positions to scale from 320x200 to the +current virtual resolution, accounting for aspect ratio differences. **Not +deterministic.** -- `ConFont` +### `ConFont` - The console font. +The console font. -- `IntermissionFont` +### `IntermissionFont` - The font used in intermission screens. +The font used in intermission screens. -- `SmallFont` +### `SmallFont` - The `smallfnt` for the current game. +The `smallfnt` for the current game. -- `SmallFont2` +### `SmallFont2` - The alternate `smallfnt`. +The alternate `smallfnt`. -- `NewConsoleFont` +### `NewConsoleFont` - TODO +TODO -- `NewSmallFont` +### `NewSmallFont` - TODO +TODO -- `BackbuttonAlpha` +### `BackbuttonAlpha` - Alpha of the back button in menus. +Alpha of the back button in menus. -- `BackbuttonTime` +### `BackbuttonTime` - The time until the back button starts fading out in menus. +The time until the back button starts fading out in menus. -- `MenuActive` +### `MenuActive` - The current active menu state. One of: +The current active menu state. One of: - | Name | Description | - | ---- | ----------- | - | `Menu.Off` | No active menu. | - | `Menu.OnNoPause` | Menu is opened, but the game is not paused. | - | `Menu.On` | Menu is open, game is paused. | - | `Menu.WaitKey` | Menu is opened, waiting for a key for a controls menu binding. | +| Name | Description | +| ---- | ----------- | +| `Menu.Off` | No active menu. | +| `Menu.OnNoPause` | Menu is opened, but the game is not paused. | +| `Menu.On` | Menu is open, game is paused. | +| `Menu.WaitKey` | Menu is opened, waiting for a key for a controls menu binding. | -- `StatusBar` +### `StatusBar` - TODO +TODO -- `NetGame` +### `NetGame` - Whether this is a networked game or not. +Whether this is a networked game or not. -- `LocalViewPitch` +### `LocalViewPitch` - The pitch angle (in degrees) of `ConsolePlayer`'s view. **Not deterministic.** +The pitch angle (in degrees) of `ConsolePlayer`'s view. **Not deterministic.** diff --git a/api/global/data/Constants.md b/api/global/data/Constants.md index f7579f5..2ce83af 100644 --- a/api/global/data/Constants.md +++ b/api/global/data/Constants.md @@ -12,29 +12,29 @@ const PLAYERMISSILERANGE; const SAWRANGE; ``` -- `MAXPLAYERNAME` +### `MAXPLAYERNAME` - The maximum length of a player name. +The maximum length of a player name. -- `MAXPLAYERS` +### `MAXPLAYERS` - The maximum amount of players in game. +The maximum amount of players in game. -- `DEFMELEERANGE` +### `DEFMELEERANGE` - The range where melee will be used for monsters, and the range for the - player's melee attacks. +The range where melee will be used for monsters, and the range for the player's +melee attacks. -- `MISSILERANGE` +### `MISSILERANGE` - The maximum range for monster missile/hit-scan attacks. +The maximum range for monster missile/hit-scan attacks. -- `PLAYERMISSILERANGE` +### `PLAYERMISSILERANGE` - The maximum range for player missile/hit-scan attacks. +The maximum range for player missile/hit-scan attacks. -- `SAWRANGE` +### `SAWRANGE` - The range of Doom's Chainsaw weapon. +The range of Doom's Chainsaw weapon. diff --git a/api/global/data/Game.md b/api/global/data/Game.md index 0abb23b..64a534b 100644 --- a/api/global/data/Game.md +++ b/api/global/data/Game.md @@ -15,72 +15,72 @@ deprecated("3.8") readonly bool GlobalFreeze; int ValidCount; ``` -- `AutomapActive` +### `AutomapActive` - `true` if the auto-map is currently open on the client. **Not deterministic.** +`true` if the auto-map is currently open on the client. **Not deterministic.** -- `DemoPlayback` +### `DemoPlayback` - User is watching a demo. +User is watching a demo. -- `GameAction` +### `GameAction` - Current global game action. May be one of: +Current global game action. May be one of: - | Name | Description | - | ---- | ----------- | - | `ga_autoloadgame` | Don't use this. | - | `ga_autosave` | Creates an autosave. | - | `ga_completed` | Don't use this. | - | `ga_fullconsole` | Don't use this. | - | `ga_loadgamehideicon` | Don't use this. | - | `ga_loadgameplaydemo` | Don't use this. | - | `ga_loadgame` | Don't use this. | - | `ga_loadlevel` | Don't use this. | - | `ga_newgame2` | Don't use this. | - | `ga_newgame` | Don't use this. | - | `ga_nothing` | Does nothing. | - | `ga_playdemo` | Don't use this. | - | `ga_recordgame` | Don't use this. | - | `ga_savegame` | Don't use this. | - | `ga_screenshot` | Takes a screenshot. | - | `ga_slideshow` | Don't use this. | - | `ga_togglemap` | Toggles the auto-map. | - | `ga_worlddone` | Don't use this. | +| Name | Description | +| ---- | ----------- | +| `ga_autoloadgame` | Don't use this. | +| `ga_autosave` | Creates an autosave. | +| `ga_completed` | Don't use this. | +| `ga_fullconsole` | Don't use this. | +| `ga_loadgamehideicon` | Don't use this. | +| `ga_loadgameplaydemo` | Don't use this. | +| `ga_loadgame` | Don't use this. | +| `ga_loadlevel` | Don't use this. | +| `ga_newgame2` | Don't use this. | +| `ga_newgame` | Don't use this. | +| `ga_nothing` | Does nothing. | +| `ga_playdemo` | Don't use this. | +| `ga_recordgame` | Don't use this. | +| `ga_savegame` | Don't use this. | +| `ga_screenshot` | Takes a screenshot. | +| `ga_slideshow` | Don't use this. | +| `ga_togglemap` | Toggles the auto-map. | +| `ga_worlddone` | Don't use this. | -- `GameState` +### `GameState` - Current global game state. May be one of: +Current global game state. May be one of: - | Name | Description | - | ---- | ----------- | - | `GS_DEMOSCREEN` | Inside a level but watching a demo in the main menu. | - | `GS_FINALE` | Reading a cluster end text or at the end sequence. | - | `GS_FULLCONSOLE` | Outside of a level, console only. | - | `GS_HIDECONSOLE` | Outside of a level, console hidden (i.e. main menu.) | - | `GS_INTERMISSION` | In between levels. | - | `GS_LEVEL` | Inside a level. | - | `GS_STARTUP` | Game not yet initialized. | - | `GS_TITLELEVEL` | Watching a `TITLEMAP` in the main menu. | +| Name | Description | +| ---- | ----------- | +| `GS_DEMOSCREEN` | Inside a level but watching a demo in the main menu. | +| `GS_FINALE` | Reading a cluster end text or at the end sequence. | +| `GS_FULLCONSOLE` | Outside of a level, console only. | +| `GS_HIDECONSOLE` | Outside of a level, console hidden (i.e. main menu.) | +| `GS_INTERMISSION` | In between levels. | +| `GS_LEVEL` | Inside a level. | +| `GS_STARTUP` | Game not yet initialized. | +| `GS_TITLELEVEL` | Watching a `TITLEMAP` in the main menu. | -- `GameTic` +### `GameTic` - Number of game tics passed since engine initialization. **Not deterministic.** +Number of game tics passed since engine initialization. **Not deterministic.** -- `Level` +### `Level` - All level info as defined in `LevelLocals`. +All level info as defined in `LevelLocals`. -- `MusPlaying` +### `MusPlaying` - TODO +TODO -- `GlobalFreeze` +### `GlobalFreeze` - Deprecated. Don't use. +Deprecated. Don't use. -- `ValidCount` +### `ValidCount` - Don't use this. +Don't use this. diff --git a/api/global/data/Information.md b/api/global/data/Information.md index 36e3ba1..c7f2221 100644 --- a/api/global/data/Information.md +++ b/api/global/data/Information.md @@ -16,47 +16,46 @@ readonly textureid SkyFlatNum; readonly Weapon WP_NOCHANGE; ``` -- `AllActorClasses` +### `AllActorClasses` - An array of every actor class type reference. +An array of every actor class type reference. -- `AllClasses` +### `AllClasses` - An array of every class type reference. +An array of every class type reference. -- `PlayerClasses` +### `PlayerClasses` - An array of all player classes as defined in `MAPINFO`/GameInfo and - `KEYCONF`. +An array of all player classes as defined in `MAPINFO`/GameInfo and `KEYCONF`. -- `PlayerSkins` +### `PlayerSkins` - An array of all player skins as defined in `SKININFO` and `S_SKIN`. +An array of all player skins as defined in `SKININFO` and `S_SKIN`. -- `Teams` +### `Teams` - An array of all teams. Maximum index is `Team.Max`. +An array of all teams. Maximum index is `Team.Max`. -- `Deh` +### `Deh` - Static DeHackEd information. +Static DeHackEd information. -- `GameInfo` +### `GameInfo` - Static information from `MAPINFO`/GameInfo. +Static information from `MAPINFO`/GameInfo. -- `OptionMenuSettings` +### `OptionMenuSettings` - Defaults for `OptionMenu`s as defined in `MENUDEF`'s `OptionMenuSettings` - block and `MAPINFO`/GameInfo. +Defaults for `OptionMenu`s as defined in `MENUDEF`'s `OptionMenuSettings` block +and `MAPINFO`/GameInfo. -- `SkyFlatNum` +### `SkyFlatNum` - The texture ID for sky flats. `F_SKY1` by default in Doom. +The texture ID for sky flats. `F_SKY1` by default in Doom. -- `WP_NOCHANGE` +### `WP_NOCHANGE` - A constant denoting that the weapon the player is currently holding - shouldn't be switched from. +A constant denoting that the weapon the player is currently holding shouldn't +be switched from. diff --git a/api/global/data/Player.md b/api/global/data/Player.md index 4eaa450..6b4fd6f 100644 --- a/api/global/data/Player.md +++ b/api/global/data/Player.md @@ -10,24 +10,24 @@ readonly bool PlayerInGame[MAXPLAYERS]; play PlayerInfo Players[MAXPLAYERS]; ``` -- `ConsolePlayer` +### `ConsolePlayer` - Number of the player running the client. **Not deterministic.** +Number of the player running the client. **Not deterministic.** -- `Multiplayer` +### `Multiplayer` - Game is networked. +Game is networked. -- `Net_Arbitrator` +### `Net_Arbitrator` - Number of the player who initiated or currently hosts the game. +Number of the player who initiated or currently hosts the game. -- `PlayerInGame` +### `PlayerInGame` - `true` if the player is currently in-game. +`true` if the player is currently in-game. -- `Players` +### `Players` - `PlayerInfo` structures for each player. +`PlayerInfo` structures for each player. diff --git a/api/global/func/Classes.md b/api/global/func/Classes.md index 7be431f..57d1430 100644 --- a/api/global/func/Classes.md +++ b/api/global/func/Classes.md @@ -7,17 +7,16 @@ Type GetDefaultByType(class type); Type New(class typename = ThisClass); ``` -- `GetDefaultByType` +### `GetDefaultByType` - Returns an object containing the default values for each member of the - `Actor` type provided as they would be set in `BeginPlay`. **Note that the - return value cannot be serialized and if stored must be marked as - `transient`.** The returned object is a pseudo-object which is stored only - in-memory. +Returns an object containing the default values for each member of the `Actor` +type provided as they would be set in `BeginPlay`. **Note that the return value +cannot be serialized and if stored must be marked as `transient`.** The +returned object is a pseudo-object which is stored only in-memory. -- `New` +### `New` - Typically spelled lowercase (`new`), creates an object with type `typename`. - Defaults to using the class of the calling object. +Typically spelled lowercase (`new`), creates an object with type `typename`. +Defaults to using the class of the calling object. diff --git a/api/global/func/Game.md b/api/global/func/Game.md index 95da709..2f6964c 100644 --- a/api/global/func/Game.md +++ b/api/global/func/Game.md @@ -11,64 +11,64 @@ deprecated("3.8") vector3, int G_PickDeathmatchStart(); deprecated("3.8") vector3, int G_PickPlayerStart(int pnum, int flags = 0); ``` -- `G_SkillName` +### `G_SkillName` - The name of the skill in play. +The name of the skill in play. -- `G_SkillPropertyInt` +### `G_SkillPropertyInt` - Returns a skill property. `p` may be: +Returns a skill property. `p` may be: - | Name | - | ---- | - | `SKILLP_ACSRETURN` | - | `SKILLP_AUTOUSEHEALTH` | - | `SKILLP_DISABLECHEATS` | - | `SKILLP_EASYBOSSBRAIN` | - | `SKILLP_EASYKEY` | - | `SKILLP_FASTMONSTERS` | - | `SKILLP_INFIGHT` | - | `SKILLP_NOPAIN` | - | `SKILLP_PLAYERRESPAWN` | - | `SKILLP_RESPAWNLIMIT` | - | `SKILLP_RESPAWN` | - | `SKILLP_SLOWMONSTERS` | - | `SKILLP_SPAWNFILTER` | +| Name | +| ---- | +| `SKILLP_ACSRETURN` | +| `SKILLP_AUTOUSEHEALTH` | +| `SKILLP_DISABLECHEATS` | +| `SKILLP_EASYBOSSBRAIN` | +| `SKILLP_EASYKEY` | +| `SKILLP_FASTMONSTERS` | +| `SKILLP_INFIGHT` | +| `SKILLP_NOPAIN` | +| `SKILLP_PLAYERRESPAWN` | +| `SKILLP_RESPAWNLIMIT` | +| `SKILLP_RESPAWN` | +| `SKILLP_SLOWMONSTERS` | +| `SKILLP_SPAWNFILTER` | -- `G_SkillPropertyFloat` +### `G_SkillPropertyFloat` - Returns a skill property. `p` may be: +Returns a skill property. `p` may be: - | Name | - | ---- | - | `SKILLP_AGGRESSIVENESS` | - | `SKILLP_AMMOFACTOR` | - | `SKILLP_ARMORFACTOR` | - | `SKILLP_DAMAGEFACTOR` | - | `SKILLP_DROPAMMOFACTOR` | - | `SKILLP_FRIENDLYHEALTH` | - | `SKILLP_HEALTHFACTOR` | - | `SKILLP_MONSTERHEALTH` | - | `SKILLP_KICKBACKFACTOR` | +| Name | +| ---- | +| `SKILLP_AGGRESSIVENESS` | +| `SKILLP_AMMOFACTOR` | +| `SKILLP_ARMORFACTOR` | +| `SKILLP_DAMAGEFACTOR` | +| `SKILLP_DROPAMMOFACTOR` | +| `SKILLP_FRIENDLYHEALTH` | +| `SKILLP_HEALTHFACTOR` | +| `SKILLP_MONSTERHEALTH` | +| `SKILLP_KICKBACKFACTOR` | -- `G_PickDeathmatchStart` +### `G_PickDeathmatchStart` - Note: This function is deprecated and `LevelLocals::PickDeathmatchStart` - should be used instead. +Note: This function is deprecated and `LevelLocals::PickDeathmatchStart` should +be used instead. - Returns the position and angle of a random death-match start location. +Returns the position and angle of a random death-match start location. -- `G_PickPlayerStart` +### `G_PickPlayerStart` - Note: This function is deprecated and `LevelLocals::PickPlayerStart` should - be used instead. +Note: This function is deprecated and `LevelLocals::PickPlayerStart` should be +used instead. - Returns the position and angle of a player start for player `pnum`. `flags` - may be: +Returns the position and angle of a player start for player `pnum`. `flags` may +be: - | Name | Description | - | ---- | ----------- | - | `PPS_FORCERANDOM` | Always picks a random player spawn for this player. | - | `PPS_NOBLOCKINGCHECK` | Does not check if an object is blocking the player spawn. | +| Name | Description | +| ---- | ----------- | +| `PPS_FORCERANDOM` | Always picks a random player spawn for this player. | +| `PPS_NOBLOCKINGCHECK` | Does not check if an object is blocking the player spawn. | diff --git a/api/global/func/Math.md b/api/global/func/Math.md index 4edc6c9..53837fd 100644 --- a/api/global/func/Math.md +++ b/api/global/func/Math.md @@ -28,97 +28,97 @@ double TanH(double n); double VectorAngle(double x, double y); ``` -- `Abs` +### `Abs` - Returns `|n|` (absolute of `n`.) +Returns `|n|` (absolute of `n`.) -- `ACos` +### `ACos` - Returns the arc-cosine of `n`. +Returns the arc-cosine of `n`. -- `ASin` +### `ASin` - Returns the arc-sine of `n`. +Returns the arc-sine of `n`. -- `ATan` +### `ATan` - Returns the arc-tangent of `n`. +Returns the arc-tangent of `n`. -- `ATan2` +### `ATan2` - Returns the arc-tangent of `y / x` using the arguments' signs to determine - the correct quadrant. +Returns the arc-tangent of `y / x` using the arguments' signs to determine the +correct quadrant. -- `BAM` +### `BAM` - Returns a byte angle of `angle` (`degrees * (0x40000000 / 90.0)`.) +Returns a byte angle of `angle` (`degrees * (0x40000000 / 90.0)`.) -- `Ceil` +### `Ceil` - Returns the integral portion of `n`, rounded up. +Returns the integral portion of `n`, rounded up. -- `Clamp` +### `Clamp` - Returns `n` if `n` is more than `minimum` and less than `maximum`, or either - of those values if it is not. +Returns `n` if `n` is more than `minimum` and less than `maximum`, or either of +those values if it is not. -- `Cos` +### `Cos` - Returns the cosine of `n`. +Returns the cosine of `n`. -- `CosH` +### `CosH` - Returns the hyperbolic cosine of `n`. +Returns the hyperbolic cosine of `n`. -- `Exp` +### `Exp` - Returns euler's number raised to the power `n`. Note that you probably want - instead the `**` binary operator, as in `a ** b`, since euler's number is - generally not a very useful constant when programming games. +Returns euler's number raised to the power `n`. Note that you probably want +instead the `**` binary operator, as in `a ** b`, since euler's number is +generally not a very useful constant when programming games. -- `Floor` +### `Floor` - Returns the integral portion of `n`, rounded down. +Returns the integral portion of `n`, rounded down. -- `Log` +### `Log` - Returns the natural (base of euler's number) logarithm of `n`. +Returns the natural (base of euler's number) logarithm of `n`. -- `Log10` +### `Log10` - Returns the common (base 10) logarithm of `n`. Note that this is useful for - instance when calculating the number of decimal digits in a number. +Returns the common (base 10) logarithm of `n`. Note that this is useful for +instance when calculating the number of decimal digits in a number. -- `Max` +### `Max` - Returns `n` if `n` is less than `maximum`, or `maximum`. +Returns `n` if `n` is less than `maximum`, or `maximum`. -- `Min` +### `Min` - Returns `n` if `n` is more than `minimum`, or `minimum`. +Returns `n` if `n` is more than `minimum`, or `minimum`. -- `Sin` +### `Sin` - Returns the sine of `n`. +Returns the sine of `n`. -- `SinH` +### `SinH` - Returns the hyperbolic sine of `n`. +Returns the hyperbolic sine of `n`. -- `Sqrt` +### `Sqrt` - Returns the square root of `n`. +Returns the square root of `n`. -- `Tan` +### `Tan` - Returns the tangent of `n`. +Returns the tangent of `n`. -- `TanH` +### `TanH` - Returns the hyperbolic tangent of `n`. +Returns the hyperbolic tangent of `n`. -- `VectorAngle` +### `VectorAngle` - Same as `ATan2`, but with arguments reversed. +Same as `ATan2`, but with arguments reversed. diff --git a/api/global/func/Random.md b/api/global/func/Random.md index bfc0cf6..285c834 100644 --- a/api/global/func/Random.md +++ b/api/global/func/Random.md @@ -13,30 +13,30 @@ int RandomPick(int...); void SetRandomSeed(uint num); ``` -- `FRandom` +### `FRandom` - Returns a random float between `min` and `max`. +Returns a random float between `min` and `max`. -- `FRandomPick` +### `FRandomPick` - Same as `RandomPick`, but with floats. +Same as `RandomPick`, but with floats. -- `Random` +### `Random` - Returns a random integer between `min` and `max`. +Returns a random integer between `min` and `max`. -- `Random2` +### `Random2` - Returns a random integer value between `-mask` and `mask`. `mask` is used as - a bit mask, so it is recommended to use a value of one less than a power of - two (i.e. 3, 7, 15, 31, 63, 127, 255...) +Returns a random integer value between `-mask` and `mask`. `mask` is used as a +bit mask, so it is recommended to use a value of one less than a power of two +(i.e. 3, 7, 15, 31, 63, 127, 255...) -- `RandomPick` +### `RandomPick` - Returns one of the provided parameters randomly. +Returns one of the provided parameters randomly. -- `SetRandomSeed` +### `SetRandomSeed` - Sets the seed of the RNG table to `num`. +Sets the seed of the RNG table to `num`. diff --git a/api/global/func/Sound.md b/api/global/func/Sound.md index 4822895..a766341 100644 --- a/api/global/func/Sound.md +++ b/api/global/func/Sound.md @@ -12,84 +12,84 @@ void S_ResumeSound(bool notsfx); void S_Sound(sound id, int channel, float volume = 1, float attenuation = ATTN_NORM); ``` -- `MarkSound` +### `MarkSound` - Marks `snd` to be pre-cached (loaded into memory early.) +Marks `snd` to be pre-cached (loaded into memory early.) -- `SetMusicVolume` +### `SetMusicVolume` - Sets the volume of the music relative to the user's volume. Range is 0-1, - inclusive. +Sets the volume of the music relative to the user's volume. Range is 0-1, +inclusive. -- `S_ChangeMusic` +### `S_ChangeMusic` - Changes the music to `name`. If `name` is `"*"`, the music will be set to - the default music for this level. Will loop if `looping` is `true`. `force` - will force the music to play even if a playlist (from the `playlist` console - command) is playing. +Changes the music to `name`. If `name` is `"*"`, the music will be set to the +default music for this level. Will loop if `looping` is `true`. `force` will +force the music to play even if a playlist (from the `playlist` console +command) is playing. - `order` may mean something different based on the music format: +`order` may mean something different based on the music format: - | Format | Meaning | - | ------ | ------- | - | Tracker music (`.mod`, `.xm`, etc.) | Specifies the order the song will start at. | - | Multi-track `.ogg`, `.flac`, etc. | Specifies the track to begin playing at. | - | Any other format | No meaning, will be ignored. | +| Format | Meaning | +| ------ | ------- | +| Tracker music (`.mod`, `.xm`, etc.) | Specifies the order the song will start at. | +| Multi-track `.ogg`, `.flac`, etc. | Specifies the track to begin playing at. | +| Any other format | No meaning, will be ignored. | -- `S_GetLength` +### `S_GetLength` - Returns the length of a sound in seconds. **Potentially non-deterministic if - all users in a networked game are not using the same sounds.** +Returns the length of a sound in seconds. **Potentially non-deterministic if +all users in a networked game are not using the same sounds.** -- `S_PauseSound` +### `S_PauseSound` - Pauses music if `notmusic` is `false` and all game sounds if `notsfx` is - `false`. Used for instance in the time stop power-up. +Pauses music if `notmusic` is `false` and all game sounds if `notsfx` is +`false`. Used for instance in the time stop power-up. -- `S_ResumeSound` +### `S_ResumeSound` - Resumes playing music and, if `notsfx` is `false`, all game sounds as well. +Resumes playing music and, if `notsfx` is `false`, all game sounds as well. -- `S_Sound` +### `S_Sound` - Plays a sound (as defined in `SNDINFO`) from the calling object if it has - world presence (is an actor or sector etc.) +Plays a sound (as defined in `SNDINFO`) from the calling object if it has world +presence (is an actor or sector etc.) - `channel` may be: +`channel` may be: - | Name | Description | - | ---- | ----------- | - | `CHAN_AUTO` | Automatically assigns the sound to a free channel (if one exists.) | - | `CHAN_BODY` | For footsteps and generally anything else. | - | `CHAN_ITEM` | For item pickups. | - | `CHAN_VOICE` | For player grunts. | - | `CHAN_WEAPON` | For weapon noises. | - | `CHAN_5` | Extra sound channel. | - | `CHAN_6` | Extra sound channel. | - | `CHAN_7` | Extra sound channel. | +| Name | Description | +| ---- | ----------- | +| `CHAN_AUTO` | Automatically assigns the sound to a free channel (if one exists.) | +| `CHAN_BODY` | For footsteps and generally anything else. | +| `CHAN_ITEM` | For item pickups. | +| `CHAN_VOICE` | For player grunts. | +| `CHAN_WEAPON` | For weapon noises. | +| `CHAN_5` | Extra sound channel. | +| `CHAN_6` | Extra sound channel. | +| `CHAN_7` | Extra sound channel. | - `channel` may also have the following flags applied with the binary OR - operator `|`: +`channel` may also have the following flags applied with the binary OR +operator `|`: - | Name | Description | - | ---- | ----------- | - | `CHAN_LISTENERZ` | Sound ignores height entirely, playing at the listener's vertical position. | - | `CHAN_LOOP` | Continues playing the sound on loop until it is stopped manually. | - | `CHAN_MAYBE_LOCAL` | Does not play sound to other players if the silent pickup compatibility flag is enabled. | - | `CHAN_NOPAUSE` | Does not pause in menus or when `S_PauseSound` is called. | - | `CHAN_NOSTOP` | Does not start a new sound if the channel is already playing something. | - | `CHAN_UI` | Does not record sound in saved games or demos. | +| Name | Description | +| ---- | ----------- | +| `CHAN_LISTENERZ` | Sound ignores height entirely, playing at the listener's vertical position. | +| `CHAN_LOOP` | Continues playing the sound on loop until it is stopped manually. | +| `CHAN_MAYBE_LOCAL` | Does not play sound to other players if the silent pickup compatibility flag is enabled. | +| `CHAN_NOPAUSE` | Does not pause in menus or when `S_PauseSound` is called. | +| `CHAN_NOSTOP` | Does not start a new sound if the channel is already playing something. | +| `CHAN_UI` | Does not record sound in saved games or demos. | - Additionally, `CHAN_PICKUP` is equivalent to `CHAN_ITEM | CHAN_MAYBE_LOCAL`. +Additionally, `CHAN_PICKUP` is equivalent to `CHAN_ITEM | CHAN_MAYBE_LOCAL`. - `attenuation` determines the drop-off distance of the sound. The higher the - value, the quicker it fades. Constants include: +`attenuation` determines the drop-off distance of the sound. The higher the +value, the quicker it fades. Constants include: - | Name | Value | Description | - | ---- | ----- | ----------- | - | `ATTN_IDLE` | `1.001` | Uses Doom's default sound attenuation. | - | `ATTN_NONE` | `0` | Does not drop off at all, plays throughout the whole map. | - | `ATTN_NORM` | `1` | Drops off using the `close_dist` and `clipping_dist` defined in `SNDINFO`. Default. | - | `ATTN_STATIC` | `3` | Drops off quickly, at around 512 units. | +| Name | Value | Description | +| ---- | ----- | ----------- | +| `ATTN_IDLE` | `1.001` | Uses Doom's default sound attenuation. | +| `ATTN_NONE` | `0` | Does not drop off at all, plays throughout the whole map. | +| `ATTN_NORM` | `1` | Drops off using the `close_dist` and `clipping_dist` defined in `SNDINFO`. Default. | +| `ATTN_STATIC` | `3` | Drops off quickly, at around 512 units. | diff --git a/api/global/func/System.md b/api/global/func/System.md index 6747100..0f6b2c7 100644 --- a/api/global/func/System.md +++ b/api/global/func/System.md @@ -7,12 +7,13 @@ uint MSTime(); vararg void ThrowAbortException(string format, ...); ``` -- `MSTime` +### `MSTime` - Returns the number of milliseconds since the engine was started. **Not deterministic.** +Returns the number of milliseconds since the engine was started. **Not +deterministic.** -- `ThrowAbortException` +### `ThrowAbortException` - Kills the VM and ends the game (without exiting) with a formatted error. +Kills the VM and ends the game (without exiting) with a formatted error. diff --git a/api/global/type/DehInfo.md b/api/global/type/DehInfo.md index 8c81baf..7a9f9d3 100644 --- a/api/global/type/DehInfo.md +++ b/api/global/type/DehInfo.md @@ -15,36 +15,36 @@ struct DehInfo } ``` -- `BfgCells` +### `BfgCells` - The amount of ammunition `A_FireBfg` will deplete. Default is 40. +The amount of ammunition `A_FireBfg` will deplete. Default is 40. -- `BlueAC` +### `BlueAC` - Multiple of 100 for `BlueArmor`'s `Armor.SaveAmount`. Default is 2 for 200 - armor. +Multiple of 100 for `BlueArmor`'s `Armor.SaveAmount`. Default is 2 for 200 +armor. -- `ExplosionAlpha` +### `ExplosionAlpha` - For actors with the `DEHEXPLOSION` flag, the alpha to set the actor to on - explosion. +For actors with the `DEHEXPLOSION` flag, the alpha to set the actor to on +explosion. -- `ExplosionStyle` +### `ExplosionStyle` - For actors with the `DEHEXPLOSION` flag, the render style to be applied on - explosion. +For actors with the `DEHEXPLOSION` flag, the render style to be applied on +explosion. -- `MaxHealth` +### `MaxHealth` - TODO +TODO -- `MaxSoulsphere` +### `MaxSoulsphere` - The `Inventory.MaxAmount` for `Soulsphere`. Default is 200. +The `Inventory.MaxAmount` for `Soulsphere`. Default is 200. -- `NoAutofreeze` +### `NoAutofreeze` - Overrides generic freezing deaths if not zero, making all actors act as if - they had the `NOICEDEATH` flag. +Overrides generic freezing deaths if not zero, making all actors act as if they +had the `NOICEDEATH` flag. diff --git a/api/global/type/FOptionMenuSettings.md b/api/global/type/FOptionMenuSettings.md index 4131130..500eed6 100644 --- a/api/global/type/FOptionMenuSettings.md +++ b/api/global/type/FOptionMenuSettings.md @@ -17,36 +17,36 @@ struct FOptionMenuSettings } ``` -- `mTitleColor` +### `mTitleColor` - TODO +TODO -- `mFontColor` +### `mFontColor` - TODO +TODO -- `mFontColorValue` +### `mFontColorValue` - TODO +TODO -- `mFontColorMore` +### `mFontColorMore` - TODO +TODO -- `mFontColorHeader` +### `mFontColorHeader` - TODO +TODO -- `mFontColorHighlight` +### `mFontColorHighlight` - TODO +TODO -- `mFontColorSelection` +### `mFontColorSelection` - TODO +TODO -- `mLineSpacing` +### `mLineSpacing` - The spacing in virtual pixels between two lines in an `OptionMenu`. +The spacing in virtual pixels between two lines in an `OptionMenu`. diff --git a/api/global/type/LevelLocals.md b/api/global/type/LevelLocals.md index 1b7ef56..ca8a717 100644 --- a/api/global/type/LevelLocals.md +++ b/api/global/type/LevelLocals.md @@ -53,7 +53,7 @@ struct LevelLocals float SkySpeed2; // Physics - play double AirControl + play double AirControl; play double AirFriction; play int AirSupply; play double Gravity; @@ -149,12 +149,12 @@ struct LevelLocals TODO -- `ClusterFlags` +### `ClusterFlags` - Flags for this cluster. May contain any of the following bit flags: +Flags for this cluster. May contain any of the following bit flags: - | Name | Description | - | ---- | ----------- | - | `Level.CLUSTER_HUB` | This cluster uses hub behaviour. | +| Name | Description | +| ---- | ----------- | +| `Level.CLUSTER_HUB` | This cluster uses hub behaviour. | diff --git a/api/inter/InterBackground.md b/api/inter/InterBackground.md index 289271e..c25f6ae 100644 --- a/api/inter/InterBackground.md +++ b/api/inter/InterBackground.md @@ -13,20 +13,20 @@ class InterBackground : Object play } ``` -- `Create` +### `Create` - TODO +TODO -- `DrawBackground` +### `DrawBackground` - TODO +TODO -- `LoadBackground` +### `LoadBackground` - TODO +TODO -- `UpdateAnimatedBack` +### `UpdateAnimatedBack` - TODO +TODO diff --git a/api/inter/PatchInfo.md b/api/inter/PatchInfo.md index 3b15c5e..18d61a8 100644 --- a/api/inter/PatchInfo.md +++ b/api/inter/PatchInfo.md @@ -13,23 +13,23 @@ struct PatchInfo play } ``` -- `mColor` +### `mColor` - The color of the font, if this is a string. +The color of the font, if this is a string. -- `mFont` +### `mFont` - The font, if this is a string, or `null`. +The font, if this is a string, or `null`. -- `mPatch` +### `mPatch` - The patch, if this is a patch, or an invalid texture. +The patch, if this is a patch, or an invalid texture. -- `Init` +### `Init` - Initializes the structure. If `gifont.Color` is `'Null'`, and - `gifont.FontName` is a valid patch, `mPatch` will be set accordingly. - Otherwise, if the font has a color or the patch is invalid, - `gifont.FontName` is used to set `mFont` (or it is defaulted to `BigFont`.) +Initializes the structure. If `gifont.Color` is `'Null'`, and `gifont.FontName` +is a valid patch, `mPatch` will be set accordingly. Otherwise, if the font has +a color or the patch is invalid, `gifont.FontName` is used to set `mFont` (or +it is defaulted to `BigFont`.) diff --git a/api/inter/StatusScreen.md b/api/inter/StatusScreen.md index ae5a415..cebf441 100644 --- a/api/inter/StatusScreen.md +++ b/api/inter/StatusScreen.md @@ -5,10 +5,10 @@ The base class for intermission status screens. Any status screen used by Status screens have four stages: -- `STATCOUNT`, where the stats are counted and displayed. -- `SHOWNEXTLOC`, where the next map is shown as "ENTERING (map name)" and in episodic maps, the world map. -- `NOSTATE`, at the very end of this process, where the last frame is drawn and the intermission is exited. -- `LEAVINGINTERMISSION`, which is used only to signify that all stages are done and the status screen has been exited. +* `STATCOUNT`, where the stats are counted and displayed. +* `SHOWNEXTLOC`, where the next map is shown as "ENTERING (map name)" and in episodic maps, the world map. +* `NOSTATE`, at the very end of this process, where the last frame is drawn and the intermission is exited. +* `LEAVINGINTERMISSION`, which is used only to signify that all stages are done and the status screen has been exited. These are provided as constants in `StatusScreen`. The starting stage is `STATCOUNT`. @@ -103,324 +103,322 @@ class StatusScreen : Object abstract play } ``` -- `NG_STATSY` +### `NG_STATSY` - TODO +TODO -- `SHOWNEXTLOCDELAY` +### `SHOWNEXTLOCDELAY` - TODO +TODO -- `SP_STATSX` +### `SP_STATSX` - TODO +TODO -- `SP_STATSY` +### `SP_STATSY` - TODO +TODO -- `SP_TIMEX` +### `SP_TIMEX` - TODO +TODO -- `SP_TIMEY` +### `SP_TIMEY` - TODO +TODO -- `TITLEY` +### `TITLEY` - The Y position (in 320x200 pixels) to draw the top of the "finished" and - "entering" texts. Used by `DrawEL` and `DrawLF`. +The Y position (in 320x200 pixels) to draw the top of the "finished" and +"entering" texts. Used by `DrawEL` and `DrawLF`. -- `BG` +### `BG` - The `InterBackground` object for this intermission, set by `Start` with the - initial `Wbs` object. +The `InterBackground` object for this intermission, set by `Start` with the +initial `Wbs` object. -- `Plrs` +### `Plrs` - The value of `Wbs.Plyr` when `Start` was called. Usually not changed, so - essentially equivalent to `Wbs.Plyr`. +The value of `Wbs.Plyr` when `Start` was called. Usually not changed, so +essentially equivalent to `Wbs.Plyr`. -- `Wbs` +### `Wbs` - The `WBStartStruct` passed to this class via the `Start` function. +The `WBStartStruct` passed to this class via the `Start` function. -- `AccelerateStage` +### `AccelerateStage` - Used to signify to the current stage that it should go quicker or be skipped - entirely. +Used to signify to the current stage that it should go quicker or be skipped +entirely. -- `BCnt` +### `BCnt` - TODO +TODO -- `Cnt` +### `Cnt` - TODO +TODO -- `Cnt_Deaths` +### `Cnt_Deaths` - TODO +TODO -- `Cnt_Frags` +### `Cnt_Frags` - TODO +TODO -- `Cnt_Items` +### `Cnt_Items` - TODO +TODO -- `Cnt_Kills` +### `Cnt_Kills` - TODO +TODO -- `Cnt_Par` +### `Cnt_Par` - TODO +TODO -- `Cnt_Pause` +### `Cnt_Pause` - TODO +TODO -- `Cnt_Secret` +### `Cnt_Secret` - TODO +TODO -- `Cnt_Time` +### `Cnt_Time` - TODO +TODO -- `Cnt_Total_Time` +### `Cnt_Total_Time` - TODO +TODO -- `CurState` +### `CurState` - The current stage the intermission is in. +The current stage the intermission is in. -- `DoFrags` +### `DoFrags` - TODO +TODO -- `Me` +### `Me` - The value of `Wbs.PNum` when `Start` was called. Usually not changed, so - essentially equivalent to `Wbs.PNum`. +The value of `Wbs.PNum` when `Start` was called. Usually not changed, so +essentially equivalent to `Wbs.PNum`. -- `NG_State` +### `NG_State` - TODO +TODO -- `NoAutoStartMap` +### `NoAutoStartMap` - TODO +TODO -- `PlayerReady` +### `PlayerReady` - Used in networked games to signify when each player is ready to continue to - the next map. Set by `CheckForAccelerate`. +Used in networked games to signify when each player is ready to continue to the +next map. Set by `CheckForAccelerate`. -- `Player_Deaths` +### `Player_Deaths` - TODO +TODO -- `Snl_PointerOn` +### `Snl_PointerOn` - TODO +TODO -- `SP_State` +### `SP_State` - Used in single-player status screens during the `STATCOUNT` stage for - indicating the current round of statistics to count up. +Used in single-player status screens during the `STATCOUNT` stage for +indicating the current round of statistics to count up. -- `ShadowAlpha` +### `ShadowAlpha` - TODO +TODO -- `Total_Deaths` +### `Total_Deaths` - TODO +TODO -- `Total_Frags` +### `Total_Frags` - TODO +TODO -- `Entering` +### `Entering` - TODO +TODO -- `Finished` +### `Finished` - TODO +TODO -- `MapName` +### `MapName` - TODO +TODO -- `Items` +### `Items` - The "ITEMS" (default `WIOSTI`) graphic. +The "ITEMS" (default `WIOSTI`) graphic. -- `Kills` +### `Kills` - The "KILLS" (default `WIOSTK`) graphic. +The "KILLS" (default `WIOSTK`) graphic. -- `P_Secret` +### `P_Secret` - The "SECRET" (default `WISCRT2`) graphic. +The "SECRET" (default `WISCRT2`) graphic. -- `Par` +### `Par` - The "PAR" (default `WIPAR`) graphic. +The "PAR" (default `WIPAR`) graphic. -- `Secret` +### `Secret` - The "SCRT" (default `WIOSTS`) graphic. +The "SCRT" (default `WIOSTS`) graphic. -- `Sucks` +### `Sucks` - The "SUCKS" (default `WISUCKS`) graphic. +The "SUCKS" (default `WISUCKS`) graphic. -- `Timepic` +### `Timepic` - The "TIME" (default `WITIME`) graphic. +The "TIME" (default `WITIME`) graphic. -- `LNameTexts` +### `LNameTexts` - TODO +TODO -- `DrawCharPatch` +### `DrawCharPatch` - TODO +TODO -- `DrawEL` +### `DrawEL` - TODO +TODO -- `DrawLF` +### `DrawLF` - TODO +TODO -- `DrawName` +### `DrawName` - TODO +TODO -- `DrawNum` +### `DrawNum` - TODO +TODO -- `DrawPatchText` +### `DrawPatchText` - TODO +TODO -- `DrawPercent` +### `DrawPercent` - TODO +TODO -- `DrawTime` +### `DrawTime` - TODO +TODO -- `AutoSkip` +### `AutoSkip` - TODO +TODO -- `Drawer` +### `Drawer` - Called by `WI_Drawer`, which is called every frame when `GameState` is - `GS_INTERMISSION`. +Called by `WI_Drawer`, which is called every frame when `GameState` is +`GS_INTERMISSION`. -- `End` +### `End` - Called when the intermission should end. Default behaviour is to set - `CurState` to `LEAVINGINTERMISSION` and remove bots in death-match. - Generally, `Level.WorldDone` should be called directly after this. +Called when the intermission should end. Default behaviour is to set `CurState` +to `LEAVINGINTERMISSION` and remove bots in death-match. Generally, +`Level.WorldDone` should be called directly after this. -- `Start` +### `Start` - Called by `WI_Start` after the `WBStartStruct` is populated, sounds are - stopped and the screen blend is set to black. Sets up initial values and - runs `InitStats`. +Called by `WI_Start` after the `WBStartStruct` is populated, sounds are stopped +and the screen blend is set to black. Sets up initial values and runs +`InitStats`. -- `StartMusic` +### `StartMusic` - Called in the first tick by `Ticker` to set the intermission music. +Called in the first tick by `Ticker` to set the intermission music. -- `Ticker` +### `Ticker` - Called by `WI_Ticker`, which is called every game tick when `GameState` is - `GS_INTERMISSION`. +Called by `WI_Ticker`, which is called every game tick when `GameState` is +`GS_INTERMISSION`. -- `DrawNoState` +### `DrawNoState` - Called by `Drawer` when `CurState` is `NOSTATE` or any other non-state. +Called by `Drawer` when `CurState` is `NOSTATE` or any other non-state. -- `DrawShowNextLoc` +### `DrawShowNextLoc` - Called by `Drawer` when `CurState` is `SHOWNEXTLOC` and, by default, - `DrawNoState` after setting `Snl_PointerOn` to `true`. +Called by `Drawer` when `CurState` is `SHOWNEXTLOC` and, by default, +`DrawNoState` after setting `Snl_PointerOn` to `true`. -- `DrawStats` +### `DrawStats` - Called by `Drawer` directly after drawing the animated background when - `CurState` is `STATCOUNT`. +Called by `Drawer` directly after drawing the animated background when +`CurState` is `STATCOUNT`. -- `InitNoState` +### `InitNoState` - Called by `UpdateShowNextLoc` to initiate the `NOSTATE` stage. +Called by `UpdateShowNextLoc` to initiate the `NOSTATE` stage. -- `InitShowNextLoc` +### `InitShowNextLoc` - Called by `UpdateStats` to initiate the `SHOWNEXTLOC` stage. +Called by `UpdateStats` to initiate the `SHOWNEXTLOC` stage. -- `InitStats` +### `InitStats` - Called by `Start` to initiate the `STATCOUNT` stage. +Called by `Start` to initiate the `STATCOUNT` stage. -- `UpdateNoState` +### `UpdateNoState` - Called by `Ticker` when `CurState` is `NOSTATE` or any other non-state. - Exits the intermission by calling `End` and `Level.WorldDone` when - appropriate. +Called by `Ticker` when `CurState` is `NOSTATE` or any other non-state. Exits +the intermission by calling `End` and `Level.WorldDone` when appropriate. -- `UpdateShowNextLoc` +### `UpdateShowNextLoc` - Called by `Ticker` when `CurState` is `SHOWNEXTLOC`. Runs `InitNoState` when - appropriate and alternates `Snl_PointerOn`. +Called by `Ticker` when `CurState` is `SHOWNEXTLOC`. Runs `InitNoState` when +appropriate and alternates `Snl_PointerOn`. -- `UpdateStats` +### `UpdateStats` - Called by `Ticker` when `CurState` is `STATCOUNT`. Runs `InitShowNextLoc` - when appropriate. +Called by `Ticker` when `CurState` is `STATCOUNT`. Runs `InitShowNextLoc` +when appropriate. -- `CheckForAccelerate` +### `CheckForAccelerate` - Updates the values of `AccelerateStage` and `PlayerReady` according to each - player's inputs. +Updates the values of `AccelerateStage` and `PlayerReady` according to each +player's inputs. -- `FragSum` +### `FragSum` - Returns the number of frags player `playernum` has accumulated against all - currently in-game players. This is different from `WBPlayerStruct.FragCount` - because it is counted dynamically, i.e. if a player leaves the count will be - changed. This is only useful for game modes where frags do not count as - score. +Returns the number of frags player `playernum` has accumulated against all +currently in-game players. This is different from `WBPlayerStruct.FragCount` +because it is counted dynamically, i.e. if a player leaves the count will be +changed. This is only useful for game modes where frags do not count as score. -- `GetPlayerWidths` +### `GetPlayerWidths` - TODO +TODO -- `GetRowColor` +### `GetRowColor` - TODO +TODO -- `GetSortedPlayers` +### `GetSortedPlayers` - TODO +TODO -- `PlaySound` +### `PlaySound` - Plays a UI sound at full volume using `S_Sound`. +Plays a UI sound at full volume using `S_Sound`. diff --git a/api/inter/WBPlayerStruct.md b/api/inter/WBPlayerStruct.md index 5b55845..15bea2d 100644 --- a/api/inter/WBPlayerStruct.md +++ b/api/inter/WBPlayerStruct.md @@ -15,29 +15,29 @@ struct WBPlayerStruct } ``` -- `SItems` +### `SItems` - The number of items this player acquired. +The number of items this player acquired. -- `SKills` +### `SKills` - The number of monsters this player killed. +The number of monsters this player killed. -- `SSecret` +### `SSecret` - The number of secrets this player found. +The number of secrets this player found. -- `STime` +### `STime` - The time this player finished the level at, in ticks. (This is the same for - all players.) +The time this player finished the level at, in ticks. (This is the same for all +players.) -- `FragCount` +### `FragCount` - The total amount of frags this player scored against all players. +The total amount of frags this player scored against all players. -- `Frags` +### `Frags` - The number of frags this player scored against each other player. +The number of frags this player scored against each other player. diff --git a/api/inter/WBStartStruct.md b/api/inter/WBStartStruct.md index e4a6535..c98739c 100644 --- a/api/inter/WBStartStruct.md +++ b/api/inter/WBStartStruct.md @@ -29,68 +29,68 @@ struct WBStartStruct } ``` -- `Plyr` +### `Plyr` - The `WBPlayerStruct` for each player. +The `WBPlayerStruct` for each player. -- `PNum` +### `PNum` - The index of the player to show stats for. +The index of the player to show stats for. -- `Finished_Ep` +### `Finished_Ep` - The cluster of the finished map, minus one. +The cluster of the finished map, minus one. -- `Next_Ep` +### `Next_Ep` - The cluster of the next map, minus one. +The cluster of the next map, minus one. -- `Current` +### `Current` - The name of the map that was finished. +The name of the map that was finished. -- `Next` +### `Next` - The name of the next map. +The name of the next map. -- `NextName` +### `NextName` - The printable name of the next map. +The printable name of the next map. -- `LName0` +### `LName0` - Texture ID of the level name of the map that was finished. +Texture ID of the level name of the map that was finished. -- `LName1` +### `LName1` - Texture ID of the level name of the map being entered. +Texture ID of the level name of the map being entered. -- `MaxFrags` +### `MaxFrags` - Unknown purpose, not actually used by any part of the engine. +Unknown purpose, not actually used by any part of the engine. -- `MaxItems` +### `MaxItems` - The maximum number of acquired items in the map. +The maximum number of acquired items in the map. -- `MaxKills` +### `MaxKills` - The maximum number of killed monsters in the map. +The maximum number of killed monsters in the map. -- `MaxSecret` +### `MaxSecret` - The maximum number of found secrets in the map. +The maximum number of found secrets in the map. -- `ParTime` +### `ParTime` - The par time of the map, in ticks. +The par time of the map, in ticks. -- `SuckTime` +### `SuckTime` - The suck time of the map, in minutes. +The suck time of the map, in minutes. -- `TotalTime` +### `TotalTime` - The total time for the whole game, in ticks. +The total time for the whole game, in ticks. diff --git a/api/level/FColorMap.md b/api/level/FColorMap.md index 06a6a64..a3355fc 100644 --- a/api/level/FColorMap.md +++ b/api/level/FColorMap.md @@ -12,21 +12,21 @@ struct FColorMap } ``` -- `BlendFactor` +### `BlendFactor` - TODO: "This is for handling Legacy-style color maps which use a different - formula to calculate how the color affects lighting." +TODO: "This is for handling Legacy-style color maps which use a different +formula to calculate how the color affects lighting." -- `Desaturation` +### `Desaturation` - How much to desaturate colors in this sector. Range is 0 to 255, inclusive. +How much to desaturate colors in this sector. Range is 0 to 255, inclusive. -- `FadeColor` +### `FadeColor` - The color of fog in this sector. None if all components are 0. +The color of fog in this sector. None if all components are 0. -- `LightColor` +### `LightColor` - The color of the sector. Default if all components are 0. +The color of the sector. Default if all components are 0. diff --git a/api/level/Line.md b/api/level/Line.md index 7c7c0a4..4f826e0 100644 --- a/api/level/Line.md +++ b/api/level/Line.md @@ -44,135 +44,135 @@ struct Line play } ``` -- `BackSector`, `FrontSector` +### `BackSector`, `FrontSector` - The sector of the front and back sides of this line. +The sector of the front and back sides of this line. -- `BBox` +### `BBox` - The top, bottom, left and right of the line, respective to array index. +The top, bottom, left and right of the line, respective to array index. -- `Delta` +### `Delta` - Equivalent to `V2 - V1`. +Equivalent to `V2 - V1`. -- `V1`, `V2` +### `V1`, `V2` - Returns the start and end points of this line segment, respectively. +Returns the start and end points of this line segment, respectively. -- `Sidedef` +### `Sidedef` - The front and back sides of this line, 0 and 1 respectively. The aliases - `Line.Front` and `Line.Back` are provided as well. +The front and back sides of this line, 0 and 1 respectively. The aliases +`Line.Front` and `Line.Back` are provided as well. -- `PortalIndex` +### `PortalIndex` - TODO +TODO -- `PortalTransferred` +### `PortalTransferred` - TODO +TODO -- `Health` +### `Health` - TODO +TODO -- `HealthGroup` +### `HealthGroup` - TODO +TODO -- `Alpha` +### `Alpha` - Alpha of the middle texture on both sides. +Alpha of the middle texture on both sides. -- `Flags` +### `Flags` - Any combination of the following bit flags: +Any combination of the following bit flags: - | Name | Description | - | ---- | ----------- | - | `ML_3DMIDTEX_IMPASS` | Middle texture will collide with projectiles and allow them to pass through. | - | `ML_3DMIDTEX` | Middle texture can be collided with and walked on as if it were a thin sector. | - | `ML_ADDTRANS` | Middle textures are drawn with additive translucency on both sides. | - | `ML_BLOCKEVERYTHING` | Line blocks everything. | - | `ML_BLOCKHITSCAN` | Line blocks hit scan attacks. | - | `ML_BLOCKING` | Line is solid and blocks everything but projectiles and hit scan attacks. | - | `ML_BLOCKMONSTERS` | Line blocks non-flying monsters. | - | `ML_BLOCKPROJECTILE` | Line blocks projectiles. | - | `ML_BLOCKSIGHT` | Line blocks line of sight. | - | `ML_BLOCKUSE` | Line blocks use actions. | - | `ML_BLOCK_FLOATERS` | Line blocks flying monsters. | - | `ML_BLOCK_PLAYERS` | Line blocks players. | - | `ML_CHECKSWITCHRANGE` | Checks the activator's vertical position as well as horizontal before activating. | - | `ML_CLIP_MIDTEX` | Applies `WALLF_CLIP_MIDTEX` to both sides. | - | `ML_DONTDRAW` | Never shown on the auto-map. | - | `ML_DONTPEGBOTTOM` | Lower texture is unpegged on both sides. | - | `ML_DONTPEGTOP` | Upper texture is unpegged on both sides. | - | `ML_FIRSTSIDEONLY` | Special can only be activated from the front side. | - | `ML_MAPPED` | Always shown on the auto-map. | - | `ML_MONSTERSCANACTIVATE` | Monsters may activate this line. | - | `ML_RAILING` | Line is a railing that can be jumped over. | - | `ML_REPEAT_SPECIAL` | Special may be activated multiple times. | - | `ML_SECRET` | Line will be shown as one-sided on the auto-map. | - | `ML_SOUNDBLOCK` | Blocks sound propagation after two lines with this flag. | - | `ML_TWOSIDED` | Line has a back side. | - | `ML_WRAP_MIDTEX` | Applies `WALLF_WRAP_MIDTEX` to both sides. | - | `ML_ZONEBOUNDARY` | Reverb zone boundary. | +| Name | Description | +| ---- | ----------- | +| `ML_3DMIDTEX_IMPASS` | Middle texture will collide with projectiles and allow them to pass through. | +| `ML_3DMIDTEX` | Middle texture can be collided with and walked on as if it were a thin sector. | +| `ML_ADDTRANS` | Middle textures are drawn with additive translucency on both sides. | +| `ML_BLOCKEVERYTHING` | Line blocks everything. | +| `ML_BLOCKHITSCAN` | Line blocks hit scan attacks. | +| `ML_BLOCKING` | Line is solid and blocks everything but projectiles and hit scan attacks. | +| `ML_BLOCKMONSTERS` | Line blocks non-flying monsters. | +| `ML_BLOCKPROJECTILE` | Line blocks projectiles. | +| `ML_BLOCKSIGHT` | Line blocks line of sight. | +| `ML_BLOCKUSE` | Line blocks use actions. | +| `ML_BLOCK_FLOATERS` | Line blocks flying monsters. | +| `ML_BLOCK_PLAYERS` | Line blocks players. | +| `ML_CHECKSWITCHRANGE` | Checks the activator's vertical position as well as horizontal before activating. | +| `ML_CLIP_MIDTEX` | Applies `WALLF_CLIP_MIDTEX` to both sides. | +| `ML_DONTDRAW` | Never shown on the auto-map. | +| `ML_DONTPEGBOTTOM` | Lower texture is unpegged on both sides. | +| `ML_DONTPEGTOP` | Upper texture is unpegged on both sides. | +| `ML_FIRSTSIDEONLY` | Special can only be activated from the front side. | +| `ML_MAPPED` | Always shown on the auto-map. | +| `ML_MONSTERSCANACTIVATE` | Monsters may activate this line. | +| `ML_RAILING` | Line is a railing that can be jumped over. | +| `ML_REPEAT_SPECIAL` | Special may be activated multiple times. | +| `ML_SECRET` | Line will be shown as one-sided on the auto-map. | +| `ML_SOUNDBLOCK` | Blocks sound propagation after two lines with this flag. | +| `ML_TWOSIDED` | Line has a back side. | +| `ML_WRAP_MIDTEX` | Applies `WALLF_WRAP_MIDTEX` to both sides. | +| `ML_ZONEBOUNDARY` | Reverb zone boundary. | -- `ValidCount` +### `ValidCount` - Don't use this. +Don't use this. -- `Activation` +### `Activation` - TODO +TODO -- `Args` +### `Args` - Arguments of the line's special action. +Arguments of the line's special action. -- `LockNumber` +### `LockNumber` - TODO +TODO -- `Special` +### `Special` - Number of the special action to be executed when this line is activated. +Number of the special action to be executed when this line is activated. -- `Index` +### `Index` - Returns the index of this line. +Returns the index of this line. -- `Activate` +### `Activate` - TODO +TODO -- `RemoteActivate` +### `RemoteActivate` - TODO +TODO -- `GetPortalDestination` +### `GetPortalDestination` - TODO +TODO -- `IsLinePortal` +### `IsLinePortal` - TODO +TODO -- `IsVisualPortal` +### `IsVisualPortal` - TODO +TODO -- `GetHealth` +### `GetHealth` - TODO +TODO -- `SetHealth` +### `SetHealth` - TODO +TODO -- `GetUdmfFloat`, `GetUdmfInt`, `GetUdmfString` +### `GetUdmfFloat`, `GetUdmfInt`, `GetUdmfString` - Gets a named UDMF property attached to this linedef. +Gets a named UDMF property attached to this linedef. diff --git a/api/level/LineIdIterator.md b/api/level/LineIdIterator.md index 3ae8c33..63e9fc0 100644 --- a/api/level/LineIdIterator.md +++ b/api/level/LineIdIterator.md @@ -11,13 +11,13 @@ class LineIdIterator : Object } ``` -- `Create` +### `Create` - Creates a new iterator over lines with tag `tag`. +Creates a new iterator over lines with tag `tag`. -- `Next` +### `Next` - Returns the index of the current line and advances the iterator. Returns - `-1` when the list is exhausted. +Returns the index of the current line and advances the iterator. Returns `-1` +when the list is exhausted. diff --git a/api/level/SecPlane.md b/api/level/SecPlane.md index 1bfcb50..a96c4a8 100644 --- a/api/level/SecPlane.md +++ b/api/level/SecPlane.md @@ -22,52 +22,52 @@ struct SecPlane play } ``` -- `D` +### `D` - TODO +TODO -- `NegiC` +### `NegiC` - TODO +TODO -- `Normal` +### `Normal` - TODO +TODO -- `ChangeHeight` +### `ChangeHeight` - TODO +TODO -- `GetChangedHeight` +### `GetChangedHeight` - TODO +TODO -- `HeightDiff` +### `HeightDiff` - TODO +TODO -- `IsEqual` +### `IsEqual` - TODO +TODO -- `IsSlope` +### `IsSlope` - TODO +TODO -- `PointOnSide` +### `PointOnSide` - TODO +TODO -- `PointToDist` +### `PointToDist` - TODO +TODO -- `ZAtPointDist` +### `ZAtPointDist` - TODO +TODO -- `ZAtPoint` +### `ZAtPoint` - TODO +TODO diff --git a/api/level/SecSpecial.md b/api/level/SecSpecial.md index 33d7a5e..e9be430 100644 --- a/api/level/SecSpecial.md +++ b/api/level/SecSpecial.md @@ -14,28 +14,28 @@ struct SecSpecial play } ``` -- `DamageAmount` +### `DamageAmount` - TODO +TODO -- `DamageInterval` +### `DamageInterval` - TODO +TODO -- `DamageType` +### `DamageType` - TODO +TODO -- `Flags` +### `Flags` - TODO +TODO -- `LeakyDamage` +### `LeakyDamage` - TODO +TODO -- `Special` +### `Special` - TODO +TODO diff --git a/api/level/SectorEffect.md b/api/level/SectorEffect.md index 15c3496..e3e8b06 100644 --- a/api/level/SectorEffect.md +++ b/api/level/SectorEffect.md @@ -11,12 +11,12 @@ class SectorEffect : Thinker } ``` -- `m_Sector` +### `m_Sector` - The sector this effect is attached to. +The sector this effect is attached to. -- `GetSector` +### `GetSector` - Returns the sector this effect is attached to. +Returns the sector this effect is attached to. diff --git a/api/level/SectorTagIterator.md b/api/level/SectorTagIterator.md index 8a896cd..52282fa 100644 --- a/api/level/SectorTagIterator.md +++ b/api/level/SectorTagIterator.md @@ -12,20 +12,20 @@ class SectorTagIterator : Object } ``` -- `Create` +### `Create` - Creates a new iterator over sectors with tag `tag`. TODO: I can't find where - `defline` is actually used. It is a mystery. +Creates a new iterator over sectors with tag `tag`. TODO: I can't find where +`defline` is actually used. It is a mystery. -- `Next` +### `Next` - Returns the index of the current sector and advances the iterator. Returns - `-1` when the list is exhausted. +Returns the index of the current sector and advances the iterator. Returns `-1` +when the list is exhausted. -- `NextCompat` +### `NextCompat` - If `compat` is `false`, acts exactly as `Next`. Otherwise, returns the - index of the current sector and advances the iterator in a manner - compatible with Doom's stair builders. +If `compat` is `false`, acts exactly as `Next`. Otherwise, returns the index of +the current sector and advances the iterator in a manner compatible with Doom's +stair builders. diff --git a/api/level/Side.md b/api/level/Side.md index 00adc8c..b1ee46f 100644 --- a/api/level/Side.md +++ b/api/level/Side.md @@ -61,76 +61,76 @@ struct Side play } ``` -- `Linedef` +### `Linedef` - The line this side belongs to. +The line this side belongs to. -- `Sector` +### `Sector` - The sector this side belongs to. +The sector this side belongs to. -- `Flags` +### `Flags` - Any combination of the following bit flags: +Any combination of the following bit flags: - | Name | Description | - | ---- | ----------- | - | `WALLF_ABSLIGHTING` | Light is absolute instead of relative to the sector. | - | `WALLF_CLIP_MIDTEX` | Clips the middle texture when it goes under the floor or above the ceiling. | - | `WALLF_LIGHT_FOG` | The wall's lighting will ignore fog effects. | - | `WALLF_NOAUTODECALS` | Don't attach decals to this surface. | - | `WALLF_NOFAKECONTRAST` | Disables the "fake contrast" effect for this side. | - | `WALLF_POLYOBJ` | This sidedef belongs to a polyobject. | - | `WALLF_SMOOTHLIGHTING` | Applies a unique contrast at all angles. | - | `WALLF_WRAP_MIDTEX` | Repeats the middle texture infinitely on the vertical axis. | +| Name | Description | +| ---- | ----------- | +| `WALLF_ABSLIGHTING` | Light is absolute instead of relative to the sector. | +| `WALLF_CLIP_MIDTEX` | Clips the middle texture when it goes under the floor or above the ceiling. | +| `WALLF_LIGHT_FOG` | The wall's lighting will ignore fog effects. | +| `WALLF_NOAUTODECALS` | Don't attach decals to this surface. | +| `WALLF_NOFAKECONTRAST` | Disables the "fake contrast" effect for this side. | +| `WALLF_POLYOBJ` | This sidedef belongs to a polyobject. | +| `WALLF_SMOOTHLIGHTING` | Applies a unique contrast at all angles. | +| `WALLF_WRAP_MIDTEX` | Repeats the middle texture infinitely on the vertical axis. | -- `Light` +### `Light` - The light level of this side. Relative to the sector lighting unless - `WALLF_ABSLIGHTING`. +The light level of this side. Relative to the sector lighting unless +`WALLF_ABSLIGHTING`. -- `Index` +### `Index` - Returns the index of this side. +Returns the index of this side. -- `V1`, `V2` +### `V1`, `V2` - Returns the start and end points of this sidedef, respectively. +Returns the start and end points of this sidedef, respectively. -- `GetTexture`, `SetTexture` +### `GetTexture`, `SetTexture` - Gets or sets the texture of one portion of the sidedef. +Gets or sets the texture of one portion of the sidedef. -- `GetTextureXOffset`, `SetTextureXOffset`, `AddTextureXOffset` +### `GetTextureXOffset`, `SetTextureXOffset`, `AddTextureXOffset` - Gets, sets or adds to the texture portion's horizontal offset. +Gets, sets or adds to the texture portion's horizontal offset. -- `GetTextureYOffset`, `SetTextureYOffset`, `AddTextureYOffset` +### `GetTextureYOffset`, `SetTextureYOffset`, `AddTextureYOffset` - Gets, sets or adds to the texture portion's vertical offset. +Gets, sets or adds to the texture portion's vertical offset. -- `GetTextureXScale`, `SetTextureXScale`, `MultiplyTextureXScale` +### `GetTextureXScale`, `SetTextureXScale`, `MultiplyTextureXScale` - Gets, sets or multiplies the texture portion's horizontal scale. +Gets, sets or multiplies the texture portion's horizontal scale. -- `GetTextureYScale`, `SetTextureYScale`, `MultiplyTextureYScale` +### `GetTextureYScale`, `SetTextureYScale`, `MultiplyTextureYScale` - Gets, sets or multiplies the texture portion's vertical scale. +Gets, sets or multiplies the texture portion's vertical scale. -- `SetSpecialColor` +### `SetSpecialColor` - TODO +TODO -- `GetAdditiveColor`, `SetAdditiveColor` +### `GetAdditiveColor`, `SetAdditiveColor` - TODO +TODO -- `EnableAdditiveColor` +### `EnableAdditiveColor` - TODO +TODO -- `GetUdmfFloat`, `GetUdmfInt`, `GetUdmfString` +### `GetUdmfFloat`, `GetUdmfInt`, `GetUdmfString` - Gets a named UDMF property attached to this sidedef. +Gets a named UDMF property attached to this sidedef. diff --git a/api/level/Vertex.md b/api/level/Vertex.md index e4fc8cc..2372ad3 100644 --- a/api/level/Vertex.md +++ b/api/level/Vertex.md @@ -11,12 +11,12 @@ struct Vertex play } ``` -- `P` +### `P` - The point this object represents. +The point this object represents. -- `Index` +### `Index` - The index of this vertex in the global vertices array. +The index of this vertex in the global vertices array. diff --git a/api/player/PlayerClass.md b/api/player/PlayerClass.md index 569e31c..1f2d3e9 100644 --- a/api/player/PlayerClass.md +++ b/api/player/PlayerClass.md @@ -15,29 +15,29 @@ struct PlayerClass } ``` -- `Flags` +### `Flags` - Not currently implemented correctly, `PCF_NOMENU` does not exist in ZScript, - but its value is `1` if you need to check for that. +Not currently implemented correctly, `PCF_NOMENU` does not exist in ZScript, +but its value is `1` if you need to check for that. -- `Skins` +### `Skins` - Skin indices available to this player class. +Skin indices available to this player class. -- `Type` +### `Type` - The class type reference for this player class. +The class type reference for this player class. -- `CheckSkin` +### `CheckSkin` - Checks if `skin` is in `Skins`. +Checks if `skin` is in `Skins`. -- `EnumColorsets` +### `EnumColorsets` - TODO +TODO -- `GetColorsetName` +### `GetColorsetName` - TODO +TODO diff --git a/api/player/PlayerSkin.md b/api/player/PlayerSkin.md index 9f61a03..9a8d73f 100644 --- a/api/player/PlayerSkin.md +++ b/api/player/PlayerSkin.md @@ -18,54 +18,54 @@ struct PlayerSkin } ``` -- `CrouchSprite` +### `CrouchSprite` - The crouching sprite ID for this skin. +The crouching sprite ID for this skin. -- `Face` +### `Face` - Prefix for statusbar face graphics. +Prefix for statusbar face graphics. -- `Gender` +### `Gender` - Default gender of the skin. May be one of the following: +Default gender of the skin. May be one of the following: - | Name | Value | Description | - | ---- | :---: | ----------- | - | `GENDER_FEMALE` | `1` | Feminine. | - | `GENDER_MALE` | `0` | Masculine. | - | `GENDER_NEUTRAL` | `2` | Neutral. | - | `GENDER_OTHER` | `3` | Other (robot, zombie, etc.) | +| Name | Value | Description | +| ---- | :---: | ----------- | +| `GENDER_FEMALE` | `1` | Feminine. | +| `GENDER_MALE` | `0` | Masculine. | +| `GENDER_NEUTRAL` | `2` | Neutral. | +| `GENDER_OTHER` | `3` | Other (robot, zombie, etc.) | -- `NameSpc` +### `NameSpc` - If this skin was defined in S_SKIN, this is the lump ID of the marker itself. +If this skin was defined in S_SKIN, this is the lump ID of the marker itself. -- `OtherGame` +### `OtherGame` - The player skin is made for another game and needs to be color remapped - differently. +The player skin is made for another game and needs to be color remapped +differently. -- `Range0End` +### `Range0End` - The end index of the translation range to be used for changing the player - sprite's color. +The end index of the translation range to be used for changing the player +sprite's color. -- `Range0Start` +### `Range0Start` - The beginning index of the translation range to be used for changing the - player sprite's color. +The beginning index of the translation range to be used for changing the player +sprite's color. -- `Scale` +### `Scale` - The scaling factor used for the player sprite. +The scaling factor used for the player sprite. -- `SkinName` +### `SkinName` - Name of the skin. +Name of the skin. -- `Sprite` +### `Sprite` - The sprite ID for this skin. +The sprite ID for this skin. diff --git a/api/player/Team.md b/api/player/Team.md index 7df69af..77c0f17 100644 --- a/api/player/Team.md +++ b/api/player/Team.md @@ -12,16 +12,16 @@ struct Team } ``` -- `Max` +### `Max` - The maximum number of teams. +The maximum number of teams. -- `NoTeam` +### `NoTeam` - A constant index for a player with no team. +A constant index for a player with no team. -- `mName` +### `mName` - The name of the team. +The name of the team. diff --git a/api/sound/SeqNode.md b/api/sound/SeqNode.md index 7657aec..4c45057 100644 --- a/api/sound/SeqNode.md +++ b/api/sound/SeqNode.md @@ -15,28 +15,28 @@ class SeqNode : Object } ``` -- `GetSequenceSlot` +### `GetSequenceSlot` - TODO +TODO -- `MarkPrecacheSounds` +### `MarkPrecacheSounds` - TODO +TODO -- `AddChoice` +### `AddChoice` - TODO +TODO -- `AreModesSame` +### `AreModesSame` - TODO +TODO -- `AreModesSameID` +### `AreModesSameID` - TODO +TODO -- `GetSequenceName` +### `GetSequenceName` - TODO +TODO diff --git a/api/weapon/PSprite.md b/api/weapon/PSprite.md index 63405f6..99168cf 100644 --- a/api/weapon/PSprite.md +++ b/api/weapon/PSprite.md @@ -47,93 +47,93 @@ class PSprite : Object play } ``` -- `CurState` +### `CurState` - TODO +TODO -- `ID` +### `ID` - TODO +TODO -- `Next` +### `Next` - TODO +TODO -- `Owner` +### `Owner` - TODO +TODO -- `Alpha` +### `Alpha` - The amount of translucency of the PSprite, range 0-1 inclusive. +The amount of translucency of the PSprite, range 0-1 inclusive. -- `Caller` +### `Caller` - TODO +TODO -- `FirstTic` +### `FirstTic` - TODO +TODO -- `Frame` +### `Frame` - Frame number of the sprite. +Frame number of the sprite. -- `OldX` +### `OldX` - TODO +TODO -- `OldY` +### `OldY` - TODO +TODO -- `ProcessPending` +### `ProcessPending` - TODO +TODO -- `Sprite` +### `Sprite` - The sprite to display on this layer. +The sprite to display on this layer. -- `Tics` +### `Tics` - The number of game ticks before the next state takes over. +The number of game ticks before the next state takes over. -- `X` +### `X` - The offset from the weapon's normal resting position on the horizontal axis. +The offset from the weapon's normal resting position on the horizontal axis. -- `Y` +### `Y` - The offset from the weapon's normal resting position on the vertical axis. - Note that `32` is the real resting position because of `A_Raise`. +The offset from the weapon's normal resting position on the vertical axis. Note +that `32` is the real resting position because of `A_Raise`. -- `bAddBob` +### `bAddBob` - Adds the weapon's bobbing to this layer's offset. +Adds the weapon's bobbing to this layer's offset. -- `bAddWeapon` +### `bAddWeapon` - Adds the weapon layer's offsets to this layer's offset. +Adds the weapon layer's offsets to this layer's offset. -- `bCVarFast` +### `bCVarFast` - Layer will respect `sv_fastweapons`. +Layer will respect `sv_fastweapons`. -- `bFlip` +### `bFlip` - Flips the weapon visually horizontally. +Flips the weapon visually horizontally. -- `bPowDouble` +### `bPowDouble` - Layer will respect `PowerDoubleFiringSpeed`. +Layer will respect `PowerDoubleFiringSpeed`. -- `SetState` +### `SetState` - TODO +TODO -- `Tick` +### `Tick` - Called by `PlayerPawn::TickPSprites` to advance the frame. +Called by `PlayerPawn::TickPSprites` to advance the frame. diff --git a/entry.md b/entry.md index 4c0b37b..41ffed2 100644 --- a/entry.md +++ b/entry.md @@ -4,7 +4,7 @@ * [ACS](#acs) * [Actors](#actors) - * [Examples: Actor Replacement](#examples-actor-replacement) + * [Examples: Actor Replacement](#examples-actor-replacement) * [Console Commands](#console-commands) * [CVARINFO](#cvarinfo) * [DECALDEF](#decaldef) @@ -125,24 +125,24 @@ TODO: this can be used for custom buttons In `MAPINFO`, the `GameInfo` block (referred to as `MAPINFO`/GameInfo in this document) the following properties interact directly with ZScript: -- `EventHandlers` and `AddEventHandlers` override or add to the list of +* `EventHandlers` and `AddEventHandlers` override or add to the list of `StaticEventHandler` or `EventHandler` classes registered by the game (as opposed to event handlers registered per-map.) -- `MessageBoxClass` sets the `MessageBoxMenu` class to use for message boxes +* `MessageBoxClass` sets the `MessageBoxMenu` class to use for message boxes used by the engine's GUI. -- `PlayerClasses` and `AddPlayerClasses` override or add to the list of +* `PlayerClasses` and `AddPlayerClasses` override or add to the list of `PlayerPawn` classes the game provides. -- `PrecacheClasses` will pre-cache all sprites used by an `Actor` class. Note +* `PrecacheClasses` will pre-cache all sprites used by an `Actor` class. Note that this also works for `StateProvider` degenerates like `Weapon`. -- `StatScreen_CoOp` sets the `StatusScreen` class to use for co-op intermission +* `StatScreen_CoOp` sets the `StatusScreen` class to use for co-op intermission screens. -- `StatScreen_DM` sets the `StatusScreen` class to use for Deathmatch +* `StatScreen_DM` sets the `StatusScreen` class to use for Deathmatch intermission screens. -- `StatScreen_Single` sets the `StatusScreen` class to use for single-player +* `StatScreen_Single` sets the `StatusScreen` class to use for single-player intermission screens. -- `StatusBarClass` sets the status bar class used by the game to the provided +* `StatusBarClass` sets the status bar class used by the game to the provided `BaseStatusBar` class. -- `WeaponSlot` sets the game's default weapon slots to the provided `Weapon` +* `WeaponSlot` sets the game's default weapon slots to the provided `Weapon` classes. TODO: there are other things here as well, like map event handlers diff --git a/glossary/Concepts.md b/glossary/Concepts.md index 5ac053e..a1e813d 100644 --- a/glossary/Concepts.md +++ b/glossary/Concepts.md @@ -1,16 +1,17 @@ -# Concepts - -* [Action Scoping](#action-scoping) -* [Object Scoping](#object-scoping) -* [Format String](#format-string) -* [Sprite](#sprite) -* [Game Tick](#game-tick) -* [Interpolation](#interpolation) +* [Concepts](#concepts) + * [Action Scoping](#action-scoping) + * [Object Scoping](#object-scoping) + * [Format String](#format-string) + * [Sprite](#sprite) + * [Game Tick](#game-tick) + * [Interpolation](#interpolation) +# Concepts + Here is a cursory view of concepts vital to ZScript and ZDoom in general. If you can't find something here, it's likely inherited directly from Doom, so you should check [the Doom Wiki][1] for more relevant information. @@ -72,12 +73,12 @@ arbitrary data to a contiguous character string. A format string contains normal characters and *conversion specifiers*. See [this page][2] for more information. Differences between C's `printf` and ZScript formats include: -- Since there's no `char` type, `int` is used for `%c`. -- `%s` also works for `name`. -- No `%n` specifier. -- An additional conversion specifier `%B` exists which converts a number to +* Since there's no `char` type, `int` is used for `%c`. +* `%s` also works for `name`. +* No `%n` specifier. +* An additional conversion specifier `%B` exists which converts a number to binary. -- An additional conversion specifier `%H` exists which works like `%g` but +* An additional conversion specifier `%H` exists which works like `%g` but automatically selects the smallest appropriate precision. [2]: https://en.cppreference.com/w/c/io/fprintf @@ -102,23 +103,22 @@ The Doom engine, as long as it has existed and into every faithful-enough port of it, no matter how different from the source material, runs the game simulation in the same way: -- Input events are processed. +*Input events are processed.* - Keyboard, mouse, gamepad, etc. if a local player, the demo file if watching - a demo, packets over the internet in networked games. +Keyboard, mouse, gamepad, etc. if a local player, the demo file if watching a +demo, packets over the internet in networked games. -- The game is *ticked*. +*The game is "ticked".* - Every 1/35th of a second that passes, a new "game tick" takes place, also - referred to as *gametic*, *tick* or simply *tic*. +Every 1/35th of a second that passes, a new "game tick" takes place, also +referred to as *gametic*, *tick* or simply *tic*. -- The game is rendered. +*The game is rendered.* - All information from the *current* game tick is rendered. This usually - happens more often than the game is actually ticked. In ZDoom, Eternity - Engine, and some other ports, the information is interpolated between the - last and current game tick when there is extra time available to give - smoother rendering. +All information from the *current* game tick is rendered. This usually happens +more often than the game is actually ticked. In ZDoom, Eternity Engine, and +some other ports, the information is interpolated between the last and current +game tick when there is extra time available to give smoother rendering. For more information on ticks, please refer to [the relevant Doom Wiki article][4]. diff --git a/glossary/Style.md b/glossary/Style.md index e6ed858..4a138b9 100644 --- a/glossary/Style.md +++ b/glossary/Style.md @@ -1,22 +1,23 @@ -# Style - -* [Capitalization Conventions](#capitalization-conventions) - * [Rationale](#rationale) -* [Word Choice](#word-choice) - * [Rationale](#rationale-1) -* [Naming Type Members](#naming-type-members) - * [Rationale](#rationale-2) -* [Layout Conventions](#layout-conventions) - * [Rationale](#rationale-3) -* [Commenting Conventions](#commenting-conventions) - * [Rationale](#rationale-4) -* [Language Guidelines](#language-guidelines) - * [Rationale](#rationale-5) +* [Style](#style) + * [Capitalization Conventions](#capitalization-conventions) + * [Rationale](#rationale) + * [Word Choice](#word-choice) + * [Rationale](#rationale-1) + * [Naming Type Members](#naming-type-members) + * [Rationale](#rationale-2) + * [Layout Conventions](#layout-conventions) + * [Rationale](#rationale-3) + * [Commenting Conventions](#commenting-conventions) + * [Rationale](#rationale-4) + * [Language Guidelines](#language-guidelines) + * [Rationale](#rationale-5) +# Style + This is a style guide for the ZScript documentation to encourage best-practice coding with it, focused on clarity and consistency of formatting. It is also intended to be a general style guide for writing new code, but this purpose is diff --git a/glossary/Versions.md b/glossary/Versions.md index 9932474..fdd1a18 100644 --- a/glossary/Versions.md +++ b/glossary/Versions.md @@ -1,35 +1,36 @@ -# Versions - -* [Version 3.1.0](#version-310) -* [Version 3.2.0](#version-320) -* [Version 3.2.1](#version-321) -* [Version 3.2.2](#version-322) -* [Version 3.2.3](#version-323) -* [Version 3.2.4](#version-324) -* [Version 3.2.5](#version-325) -* [Version 3.3.0](#version-330) -* [Version 3.3.1](#version-331) -* [Version 3.3.2](#version-332) -* [Version 3.4.0](#version-340) -* [Version 3.5.0](#version-350) -* [Version 3.5.1](#version-351) -* [Version 3.6.0](#version-360) -* [Version 3.7.0](#version-370) -* [Version 3.7.2](#version-372) -* [Version 3.8.0 (Legacy)](#version-380-legacy) -* [Version 3.8.1 (Legacy)](#version-381-legacy) -* [Version 3.8.2 (Legacy)](#version-382-legacy) -* [Version 4.0.0](#version-400) -* [Version 4.1.0](#version-410) -* [Version 4.1.1](#version-411) -* [Version 4.1.2](#version-412) -* [Version 4.1.3](#version-413) -* [Version 4.2.0](#version-420) +* [Versions](#versions) + * [Version 3.1.0](#version-310) + * [Version 3.2.0](#version-320) + * [Version 3.2.1](#version-321) + * [Version 3.2.2](#version-322) + * [Version 3.2.3](#version-323) + * [Version 3.2.4](#version-324) + * [Version 3.2.5](#version-325) + * [Version 3.3.0](#version-330) + * [Version 3.3.1](#version-331) + * [Version 3.3.2](#version-332) + * [Version 3.4.0](#version-340) + * [Version 3.5.0](#version-350) + * [Version 3.5.1](#version-351) + * [Version 3.6.0](#version-360) + * [Version 3.7.0](#version-370) + * [Version 3.7.2](#version-372) + * [Version 3.8.0 (Legacy)](#version-380-legacy) + * [Version 3.8.1 (Legacy)](#version-381-legacy) + * [Version 3.8.2 (Legacy)](#version-382-legacy) + * [Version 4.0.0](#version-400) + * [Version 4.1.0](#version-410) + * [Version 4.1.1](#version-411) + * [Version 4.1.2](#version-412) + * [Version 4.1.3](#version-413) + * [Version 4.2.0](#version-420) +# Versions + Here is a list of differences between ZScript versions. ## Version 3.1.0 diff --git a/language.md b/language.md index 9978e8e..6d20063 100644 --- a/language.md +++ b/language.md @@ -7,7 +7,7 @@ * [Versions](#versions) * [Top-level](#top-level) * [Include directives](#include-directives) - * [Example: Include directives](#example-include-directives) + * [Example: Include directives](#example-include-directives) * [Table of Contents](#table-of-contents) @@ -89,11 +89,11 @@ version of ZScript. The minimum version supported by this documentation is 3.0. A ZScript file can have one of several things at the top level of the file, following a version directive: -- Class definitions -- Structure definitions -- Enumeration definitions -- Constant definitions -- Include directives +* Class definitions +* Structure definitions +* Enumeration definitions +* Constant definitions +* Include directives # Include directives diff --git a/language/Classes.md b/language/Classes.md index 9a8bb7c..ec2b8cb 100644 --- a/language/Classes.md +++ b/language/Classes.md @@ -1,7 +1,6 @@ -# Class Definitions - +* [Class Definitions](#class-definitions) * [Example: Class headers](#example-class-headers) * [Example: Class definitions](#example-class-definitions) * [Class Flags](#class-flags) @@ -17,6 +16,8 @@ +# Class Definitions + A class defines an object type within ZScript, and is most of what you'll be creating within the language. @@ -148,16 +149,16 @@ inherits `Actor`. Class contents are an optional list of various things logically contained within the class, including: -- Member declarations -- Method definitions -- Property definitions -- Flag definitions -- Default blocks -- State definitions -- Enumeration definitions -- Structure definitions -- Constant definitions -- Static array definitions +* Member declarations +* Method definitions +* Property definitions +* Flag definitions +* Default blocks +* State definitions +* Enumeration definitions +* Structure definitions +* Constant definitions +* Static array definitions # Property Definitions diff --git a/language/Constants.md b/language/Constants.md index 2059883..4db2251 100644 --- a/language/Constants.md +++ b/language/Constants.md @@ -1,12 +1,13 @@ -# Constant Definitions - - * [Example: Constant definitions](#example-constant-definitions) +* [Constant Definitions](#constant-definitions) + * [Example: Constant definitions](#example-constant-definitions) * [Static array definitions](#static-array-definitions) +# Constant Definitions + Constants are simple named values. They are created with the syntax: ``` diff --git a/language/Enumerations.md b/language/Enumerations.md index 7a400c3..522a4d1 100644 --- a/language/Enumerations.md +++ b/language/Enumerations.md @@ -1,12 +1,12 @@ -Enumeration Definitions -======================= - -* [Example: Enumeration definitions](#example-enumeration-definitions) +* [Enumeration Definitions](#enumeration-definitions) + * [Example: Enumeration definitions](#example-enumeration-definitions) +# Enumeration Definitions + An enumeration is a list of named numbers, which by default will be incremental from 0. By default they decay to the type `int`, but the default decay type can be set manually. diff --git a/language/Expressions.md b/language/Expressions.md index cfc1e23..f5c39e4 100644 --- a/language/Expressions.md +++ b/language/Expressions.md @@ -1,27 +1,30 @@ -# Expressions and Operators - +* [Expressions and Operators](#expressions-and-operators) * [Literals](#literals) - * [String literals](#string-literals) - * [Class type literals](#class-type-literals) - * [Name literals](#name-literals) - * [Integer literals](#integer-literals) - * [Float literals](#float-literals) - * [Boolean literals](#boolean-literals) - * [Null pointer](#null-pointer) + * [String literals](#string-literals) + * [Class type literals](#class-type-literals) + * [Name literals](#name-literals) + * [Integer literals](#integer-literals) + * [Float literals](#float-literals) + * [Boolean literals](#boolean-literals) + * [Null pointer](#null-pointer) * [Expressions](#expressions) - * [Primary expressions](#primary-expressions) - * [Vector literals](#vector-literals) - * [Postfix expressions](#postfix-expressions) - * [Argument list](#argument-list) - * [Unary expressions](#unary-expressions) - * [Binary expressions](#binary-expressions) - * [Assignment expressions](#assignment-expressions) - * [Ternary expression](#ternary-expression) + * [Primary expressions](#primary-expressions) + * [Vector literals](#vector-literals) + * [Postfix expressions](#postfix-expressions) + * [Argument list](#argument-list) + * [Unary expressions](#unary-expressions) + * [Binary expressions](#binary-expressions) + * [Assignment expressions](#assignment-expressions) + * [Ternary expression](#ternary-expression) +# Expressions and Operators + +TODO + # Literals Much like C or most other programming languages, ZScript has object literals, @@ -166,11 +169,11 @@ arithmetic and various conditions. Basic expressions, also known as primary expressions, can be one of: -- An identifier for a constant or variable. -- The `Super` keyword. -- Any object literal. -- A vector literal. -- An expression in parentheses. +* An identifier for a constant or variable. +* The `Super` keyword. +* Any object literal. +* A vector literal. +* An expression in parentheses. Identifiers work as you expect, they reference a variable or constant. The `Super` keyword references the parent type or any member within it. diff --git a/language/Members.md b/language/Members.md index 6add2ab..253d89f 100644 --- a/language/Members.md +++ b/language/Members.md @@ -1,12 +1,13 @@ -# Member Declarations - - * [Example: Member declarations](#example-member-declarations) +* [Member Declarations](#member-declarations) + * [Example: Member declarations](#example-member-declarations) * [Member Declaration Flags](#member-declaration-flags) +# Member Declarations + Member declarations define data within a structure or class that can be accessed directly within methods of the object (or its derived classes,) or indirectly from instances of it with the member access operator. diff --git a/language/Methods.md b/language/Methods.md index 762b0cc..1729d20 100644 --- a/language/Methods.md +++ b/language/Methods.md @@ -1,14 +1,15 @@ -# Method Definitions - +* [Method Definitions](#method-definitions) * [Method Argument List](#method-argument-list) - * [Example: Method argument lists](#example-method-argument-lists) + * [Example: Method argument lists](#example-method-argument-lists) * [Method Definition Flags](#method-definition-flags) - * [Action functions](#action-functions) + * [Action functions](#action-functions) +# Method Definitions + Method definitions define functions within a structure or class that can be accessed directly within other methods of the object (or its derived classes,) or indirectly from instances of it with the member access operator. diff --git a/language/Statements.md b/language/Statements.md index 455c91f..f04df7d 100644 --- a/language/Statements.md +++ b/language/Statements.md @@ -1,25 +1,26 @@ -# Statements - +* [Statements](#statements) * [Compound Statements](#compound-statements) * [Expression Statements](#expression-statements) - * [Example: Expression statements](#example-expression-statements) + * [Example: Expression statements](#example-expression-statements) * [Conditional Statements](#conditional-statements) - * [Example: Conditional statements](#example-conditional-statements) + * [Example: Conditional statements](#example-conditional-statements) * [Switch Statements](#switch-statements) - * [Example: Switch statements](#example-switch-statements) + * [Example: Switch statements](#example-switch-statements) * [Loop Statements](#loop-statements) * [Control Flow Statements](#control-flow-statements) - * [Example: Control flow statements](#example-control-flow-statements) + * [Example: Control flow statements](#example-control-flow-statements) * [Local Variable Statements](#local-variable-statements) * [Multi-assignment Statements](#multi-assignment-statements) - * [Example: Multi-assignment statements](#example-multi-assignment-statements) + * [Example: Multi-assignment statements](#example-multi-assignment-statements) * [Static Array Statements](#static-array-statements) * [Null Statements](#null-statements) +# Statements + All functions are made up of a list of *statements* enclosed with left and right braces, which in and of itself is a statement called a *compound statement*, or *block*. diff --git a/language/Structures.md b/language/Structures.md index 76e4a11..615acd0 100644 --- a/language/Structures.md +++ b/language/Structures.md @@ -1,13 +1,14 @@ -# Structure Definitions - - * [Example: Structure definitions](#example-structure-definitions) +* [Structure Definitions](#structure-definitions) + * [Example: Structure definitions](#example-structure-definitions) * [Structure Flags](#structure-flags) * [Structure Content](#structure-content) +# Structure Definitions + A structure is an object type that does not inherit from Object and is not always (though occasionally is) a reference type, unlike classes. Structures marked as `native` are passed by-reference to and from the engine in an @@ -59,9 +60,9 @@ struct MyCoolStructure Structure contents are an optional list of various things logically contained within the structure, including: -- Member declarations -- Method definitions -- Enumeration definitions -- Constant definitions +* Member declarations +* Method definitions +* Enumeration definitions +* Constant definitions diff --git a/language/Types.md b/language/Types.md index 84e9cdd..506b56c 100644 --- a/language/Types.md +++ b/language/Types.md @@ -1,11 +1,24 @@ -# Types - +* [Types](#types) * [Integer Types](#integer-types) - * [Symbols](#symbols) + * [Symbols](#symbols) + * [`Max`](#max) + * [`Min`](#min) * [Floating-point Types](#floating-point-types) - * [Symbols](#symbols-1) + * [Symbols](#symbols-1) + * [`Dig`](#dig) + * [`Epsilon`](#epsilon) + * [`Infinity`](#infinity) + * [`Mant_Dig`](#mant_dig) + * [`Max`](#max-1) + * [`Max_Exp`](#max_exp) + * [`Max_10_Exp`](#max_10_exp) + * [`Min_Denormal`](#min_denormal) + * [`Min_Exp`](#min_exp) + * [`Min_Normal`](#min_normal) + * [`Min_10_Exp`](#min_10_exp) + * [`NaN`](#nan) * [Strings](#strings) * [Names](#names) * [Colors](#colors) @@ -22,6 +35,8 @@ +# Types + ZScript has several categories of types: Integer types, floating-point (decimal) types, strings, vectors, names, classes, et al. There are a wide variety of ways to use these types, as well as a wide variety of places they @@ -62,13 +77,13 @@ Some types have aliases as well: Integer types have symbols attached which can be accessed by `typename.name`, for instance `int.Max`. -- `Max` +### `Max` - Maximum value of type. +Maximum value of type. -- `Min` +### `Min` - Minimum value of type. +Minimum value of type. # Floating-point Types @@ -87,53 +102,53 @@ numbers. There are two such types available to ZScript: Floating-point types have symbols attached which can be accessed by `typename.name`, for instance `double.Infinity`. -- `Dig` +### `Dig` - Number of decimal digits in type. +Number of decimal digits in type. -- `Epsilon` +### `Epsilon` - ε value of type. +ε value of type. -- `Infinity` +### `Infinity` - ∞ value of type. +∞ value of type. -- `Mant_Dig` +### `Mant_Dig` - Number of mantissa bits in type. +Number of mantissa bits in type. -- `Max` +### `Max` - Maximum value of type. +Maximum value of type. -- `Max_Exp` +### `Max_Exp` - Maximum exponent bits value of type. +Maximum exponent bits value of type. -- `Max_10_Exp` +### `Max_10_Exp` - Maximum exponent of type. +Maximum exponent of type. -- `Min_Denormal` +### `Min_Denormal` - Minimum positive subnormal value of type. +Minimum positive subnormal value of type. -- `Min_Exp` +### `Min_Exp` - Minimum exponent bits value of type. +Minimum exponent bits value of type. -- `Min_Normal` +### `Min_Normal` - Minimum value of type. +Minimum value of type. -- `Min_10_Exp` +### `Min_10_Exp` - Minimum exponent of type. +Minimum exponent of type. -- `NaN` +### `NaN` - Not-a-Number value of type. +Not-a-Number value of type. # Strings