Dungeon (functions): Difference between revisions
No edit summary |
No edit summary |
||
| Line 36: | Line 36: | ||
== DungeonDisplayName == | == DungeonDisplayName == | ||
Returns the localized name of the current dungeon. Takes no arguments. | Returns the localized name of the current dungeon. Takes no arguments. | ||
| Line 42: | Line 41: | ||
=== Usage === | === Usage === | ||
== CharSetEmote == | |||
== | |||
Set a character's emote in a dungeon map. Argument order is <code>DUNGEON:CharSetEmote(chara, emoteID, cycles)</code>. | Set a character's emote in a dungeon map. Argument order is <code>DUNGEON:CharSetEmote(chara, emoteID, cycles)</code>. | ||
| Line 61: | Line 58: | ||
|} | |} | ||
== | == CharStartAnim == | ||
Set a character's animation. Argument order is <code>DUNGEON:CharStartAnim(chara, emoteID, | Set a character's animation. Argument order is <code>DUNGEON:CharStartAnim(chara, emoteID, doLoop)</code> | ||
{| class="wikitable" | {| class="wikitable" | ||
|- | |- | ||
| Line 72: | Line 69: | ||
| emoteID || String || System.String || Name of the animation | | emoteID || String || System.String || Name of the animation | ||
|- | |- | ||
| | | doLoop || Boolean || System.Bool|| Whether to loop the animation | ||
|- | |- | ||
|} | |} | ||
=== Example === | === Example === | ||
| Line 93: | Line 83: | ||
== DUNGEON:CharEndAnim == | == DUNGEON:CharEndAnim == | ||
Stops a character's current animation, reverting them to default idle. Usage is <code>DUNGEON:CharEndAnim(chara)</code>. | |||
Stops a character's current animation, reverting them to default idle. | |||
=== Arguments === | === Arguments === | ||
* <code>chara</code>: Character to stop animating | * <code>chara</code>: Character to stop animating | ||
{| class="wikitable" | |||
|- | |||
! Name !! Type !! Technical Type !! Purpose | |||
|- | |||
| chara || Dungeon Character ||RogueEssence.Dungeon.Character || Character to stop animating | |||
|- | |||
|} | |||
=== Example === | === Example === | ||
| Line 109: | Line 105: | ||
</pre> | </pre> | ||
== | == CharWaitAnim == | ||
Set a character's animation, and waits until it completed before continue. Usage is <code>CharWaitAnim(chara, anim)</code>. | |||
=== Arguments === | === Arguments === | ||
{| class="wikitable" | |||
{{ArgHeader}} | |||
{{{ArgRow | |||
|name=chara | |||
|type=Character | |||
|techt=- | |||
|purp=The character to animate. | |||
}}} | |||
{{{ArgRow | |||
|name=anim | |||
|type=String | |||
|techt=- | |||
|purp=The string name of the animation. | |||
}}} | |||
|} | |||
=== Example === | === Example === | ||
| Line 125: | Line 131: | ||
DUNGEON:CharStartAnim(player, anim) | DUNGEON:CharStartAnim(player, anim) | ||
</pre> | </pre> | ||
== | == PlayVFX == | ||
Plays a VFX in the dungeon map. Usage is <code>DUNGEON:PlayVFX(emitter, x, y, dir)</code>. | |||
=== Arguments === | === Arguments === | ||
{| class="wikitable" | |||
{{ArgHeader}} | |||
{{{ArgRow | |||
|name=emitter | |||
|type=Emitter | |||
|techt=RogueEssence.Content.FiniteEmitter | |||
|purp=The VFX emitter | |||
}}} | |||
{{{ArgRow | |||
|name=X | |||
|type=Integer | |||
|techt=System.Int32 | |||
|purp=X Position in pixels | |||
}}} | |||
{{{ArgRow | |||
|name=Y | |||
|type=Integer | |||
|techt=System.Int32 | |||
|purp=Y Position in pixels | |||
}}} | |||
{{{ArgRow | |||
|name=dir | |||
|type=Direction | |||
|techt=RogueElements.Dir8 | |||
|purp=Direction to orient the VFX, defaults to Down | |||
}}} | |||
|} | |||
== PlayVFX == | |||
== | |||
Plays a VFX that has a start position and an end position. It uses a finite emitter that generates BaseAnims. {{FuncUsage|nmspace=DUNGEON|nm=PlayVFX|args=emitter, x, y, dir, xTo, yTo}} | |||
=== Arguments === | === Arguments === | ||
{| class="wikitable" | |||
{{ArgHeader}} | |||
{{{ArgRow | |||
|name=emitter | |||
|type=Emitter | |||
|techt=RogueEssence.Content.FiniteEmitter | |||
|purp=The VFX emitter | |||
}}} | |||
{{{ArgRow | |||
|name=x | |||
|type=Integer | |||
|techt=System.Int32 | |||
|purp=Start X position in pixels | |||
}}} | |||
{{{ArgRow | |||
|name=y | |||
|type=Integer | |||
|techt=System.Int32 | |||
|purp=Start Y Position in pixels | |||
}}} | |||
{{{ArgRow | |||
|name=dir | |||
|type=Direction | |||
|techt=RogueElements.Dir8 | |||
|purp=Direction to orient the VFX, defaults to Down. | |||
}}} | |||
{{{ArgRow | |||
|name=xTo | |||
|type=Integer | |||
|techt=System.Int32 | |||
|purp=End X position in pixels | |||
}}} | |||
{{{ArgRow | |||
|name=yTo | |||
|type=Integer | |||
|techt=System.Int32 | |||
|purp=End Y Position in pixels | |||
}}} | |||
|} | |||
== PlayVFXAnim == | |||
== | |||
Plays a VFX using just a BaseAnim. {{FuncUsage|nmspace=DUNGEON|nm=PlayVFXAnim|args=anim, layer}} | |||
=== Arguments === | === Arguments === | ||
{| class="wikitable" | |||
{{ArgHeader}} | |||
{{{ArgRow | |||
|name=anim | |||
|type=Animation | |||
|techt=RogueEssence.Content.BaseAnim | |||
|purp=The animation to play. | |||
}}} | |||
{{{ArgRow | |||
|name=layer | |||
|type=Layer | |||
|techt=RogueEssence.Content.DrawLayer | |||
|purp=The layer to draw. | |||
}}} | |||
|} | |||
== MoveScreen == | |||
== | |||
Plays a screen-moving effect. {{FuncUsage|nmspace=DUNGEON|nm=MoveScreen|args=mover}} | |||
=== Arguments === | === Arguments === | ||
{| class="wikitable" | |||
{{ArgHeader}} | |||
{{{ArgRow | |||
|name=mover | |||
|type=Screen Mover | |||
|techt=DUNGEON:MoveScreen(RogueEssence.Content.ScreenMover) | |||
|purp=The screen mover. | |||
}}} | |||
|} | |||
Revision as of 18:38, 17 January 2026
The dungeon functions involve actions that are performed within dungeons.
CharTurnToChar
Makes a character turn to face another.
Arguments
Argument order is DUNGEON:CharTurnToChar(curch, turnto).
| Name | Type | Technical Type | Purpose |
|---|---|---|---|
| curch | Dungeon Character | RogueEssence.Dungeon.Character | The character that will turn. |
| turnto | Dungeon Character | RogueEssence.Dungeon.Character | The character being turned to. |
LastDungeonResult
Gets the result of the last dungeon adventure. Takes no arguments.
Usage
DungeonCurrentFloor
Returns the floor number of the current dungeon. Takes no arguments.
Usage
DungeonAssetName
Returns the internal name for the current dungeon. Takes no arguments.
Usage
DungeonDisplayName
Returns the localized name of the current dungeon. Takes no arguments.
Usage
CharSetEmote
Set a character's emote in a dungeon map. Argument order is DUNGEON:CharSetEmote(chara, emoteID, cycles).
Arguments
| Name | Type | Technical Type | Purpose |
|---|---|---|---|
| chara | Dungeon Character | RogueEssence.Dungeon.Character | Character to emote |
| emoteID | String | System.String | ID of the emote |
| emoteID | Integer | System.Int32 | The number of times to play the emote. |
CharStartAnim
Set a character's animation. Argument order is DUNGEON:CharStartAnim(chara, emoteID, doLoop)
| Name | Type | Technical Type | Purpose |
|---|---|---|---|
| chara | Dungeon Character | RogueEssence.Dungeon.Character | Character to animate |
| emoteID | String | System.String | Name of the animation |
| doLoop | Boolean | System.Bool | Whether to loop the animation |
Example
DUNGEON:CharStartAnim(player, anim, false)
DUNGEON:CharEndAnim
Stops a character's current animation, reverting them to default idle. Usage is DUNGEON:CharEndAnim(chara).
Arguments
chara: Character to stop animating
| Name | Type | Technical Type | Purpose |
|---|---|---|---|
| chara | Dungeon Character | RogueEssence.Dungeon.Character | Character to stop animating |
Example
DUNGEON:CharEndAnim(player)
CharWaitAnim
Set a character's animation, and waits until it completed before continue. Usage is CharWaitAnim(chara, anim).
Arguments
| Name | Type | Technical Type | Purpose |
|---|
Example
DUNGEON:CharStartAnim(player, anim)
PlayVFX
Plays a VFX in the dungeon map. Usage is DUNGEON:PlayVFX(emitter, x, y, dir).
Arguments
| Name | Type | Technical Type | Purpose |
|---|
PlayVFX
Plays a VFX that has a start position and an end position. It uses a finite emitter that generates BaseAnims. Argument order is DUNGEON:PlayVFX(emitter, x, y, dir, xTo, yTo).
Arguments
| Name | Type | Technical Type | Purpose |
|---|
PlayVFXAnim
Plays a VFX using just a BaseAnim. Argument order is DUNGEON:PlayVFXAnim(anim, layer).
Arguments
| Name | Type | Technical Type | Purpose |
|---|
MoveScreen
Plays a screen-moving effect. Argument order is DUNGEON:MoveScreen(mover).
Arguments
| Name | Type | Technical Type | Purpose |
|---|
