Difference between revisions of "Debug Script"

From the CreationKit Wiki
Jump to navigation Jump to search
imported>Jog
imported>CraftySentinel
m (→‎Global Functions: Formatting Change)
Line 14: Line 14:


== Global Functions ==
== Global Functions ==
'''Function [[CenterOnCell - Debug|CenterOnCell]](string asCellName)'''
*Teleports the player to the specified cell.


'''float Function [[CenterOnCellAndWait - Debug|CenterOnCellAndWait]](string asCellName)'''
{|class="wikitable" width =100%
*Teleports the player to the specified cell and doesn't return until he gets there.
!style="text-align:left;"|Function
!style="text-align:left;"|Description
|-
|[[CenterOnCell - Debug|'''CenterOnCell'''(String ''asCellName'')]]
|Teleports the player to the specified cell.
|-


'''float Function [[PlayerMoveToAndWait - Debug|PlayerMoveToAndWait]](string asDestRef)'''
|[[CenterOnCellAndWait - Debug|Float '''CenterOnCellAndWait'''(String ''asCellName'')]]
*Teleports the player to the specified reference and doesn't return until he gets there.
|Teleports the player to the specified cell and doesn't return until he gets there.
|-


'''Function [[CloseUserLog - Debug|CloseUserLog]](string asLogName)'''
|[[PlayerMoveToAndWait - Debug|Float '''PlayerMoveToAndWait'''(String ''asDestRef'')]]
*Closes the specified user log
|Teleports the player to the specified reference and doesn't return until he gets there.
|-


'''Function [[DumpAliasData - Debug|DumpAliasData]](Quest akQuest)'''
|[[CloseUserLog - Debug|'''CloseUserLog'''(String ''asLogName'')]]
*Dumps all alias fill information to the alias dump log.
|Closes the specified user log
|-


'''string Function [[GetConfigName - Debug|GetConfigName]]()'''
|[[DumpAliasData - Debug|'''DumpAliasData'''(Quest ''akQuest'')]]
*Obtains the build configuration name
|Dumps all alias fill information to the alias dump log.
|-


'''string Function [[GetPlatformName - Debug|GetPlatformName]]()'''
|[[GetConfigName - Debug|String '''GetConfigName'''()]]
*Obtains the current platform name
|Obtains the build configuration name
|-


'''string Function [[GetVersionNumber - Debug|GetVersionNumber]]()'''
|[[GetPlatformName - Debug|String '''GetPlatformName'''()]]
*Obtains the current version number
|Obtains the current platform name
|-


'''Function [[MessageBox - Debug|MessageBox]](string asMessageBoxText)'''
|[[GetVersionNumber - Debug|String '''GetVersionNumber'''()]]
*Displays an OK message box with the specified text
|Obtains the current version number
|-


'''Function [[Notification - Debug|Notification]](string asNotificationText)'''
|[[MessageBox - Debug|'''MessageBox'''(String ''asMessageBoxText'')]]
*Displays an in-game notification message (on the top-left corner)
|Displays an OK message box with the specified text
|-


'''bool Function [[OpenUserLog - Debug|OpenUserLog]](string asLogName)'''
|[[Notification - Debug|'''Notification'''(String ''asNotificationText'')]]
*Opens the specified user log (fails if already open)
|Displays an in-game notification message (on the top-left corner)
|-


'''Function [[QuitGame - Debug|QuitGame]]()'''
|[[OpenUserLog - Debug|Bool '''OpenUserLog'''(String ''asLogName'')]]
*Quits the game
|Opens the specified user log (fails if already open)
|-


'''Function [[SetFootIK - Debug|SetFootIK]](bool abFootIK)'''
|[[QuitGame - Debug|'''QuitGame'''()]]
*Turns foot IK on and off
|Quits the game
|-


'''Function [[SetGodMode - Debug|SetGodMode]](bool abGodMode)'''
|[[SetFootIK - Debug|'''SetFootIK'''(Bool ''abFootIK'')]]
*Turns god mode on and off
|Turns foot IK on and off
|-


'''Function [[SendAnimationEvent - Debug|SendAnimationEvent]](ObjectReference arRef, string asEventName)'''
|[[SetGodMode - Debug|'''SetGodMode'''(Bool ''abGodMode'')]]
*Sends an animation event to the specified reference.
|Turns god mode on and off
|-


'''Function [[StartScriptProfiling - Debug|StartScriptProfiling]](string asScriptName)'''
|[[SendAnimationEvent - Debug|'''SendAnimationEvent'''(ObjectReference ''arRef'', String ''asEventName'')]]
*Starts profiling a specific Papyrus script
|Sends an animation event to the specified reference.
|-


'''Function [[StartStackProfiling - Debug|StartStackProfiling]]()'''
|[[StartScriptProfiling - Debug|'''StartScriptProfiling'''(String ''asScriptName'')]]
*Starts profiling the calling stack
|Starts profiling a specific Papyrus script
|-


'''Function [[StopScriptProfiling - Debug|StopScriptProfiling]](string asScriptName)'''
|[[StartStackProfiling - Debug|'''StartStackProfiling'''()]]
*Stops profiling a specific Papyrus script
|Starts profiling the calling stack
|-


'''Function [[StopStackProfiling - Debug|StopStackProfiling]]()'''
|[[StopScriptProfiling - Debug|'''StopScriptProfiling'''(String ''asScriptName'')]]
*Stops profiling the calling stack
|Stops profiling a specific Papyrus script
|-


'''Function [[ToggleAI - Debug|ToggleAI]]()'''
|[[StopStackProfiling - Debug|'''StopStackProfiling'''()]]
*Turns AI on and off.
|Stops profiling the calling stack
|-


'''Function [[ToggleCollisions - Debug|ToggleCollisions]]()'''
|[[ToggleAI - Debug|'''ToggleAI'''()]]
*Turns collision on and off.
|Turns AI on and off.
|-


'''Function [[ToggleMenus - Debug|ToggleMenus]]()'''
|[[ToggleCollisions - Debug|'''ToggleCollisions'''()]]
*Toggles menus on and off.
|Turns collision on and off.
|-


'''Function [[Trace - Debug|Trace]](string asTextToPrint, int aiSeverity)'''
|[[ToggleMenus - Debug|'''ToggleMenus'''()]]
*Outputs the string to the Papyrus log and debug text page
|Toggles menus on and off.
|-


'''Function [[TraceAndBox - Debug|TraceAndBox]](string asTextToPrint, int aiSeverity)'''
|[[Trace - Debug|'''Trace'''(String ''asTextToPrint'', Int ''aiSeverity'')]]
*Outputs the string to the log and puts up a message box
|Outputs the string to the Papyrus log and debug text page
|-


'''Function [[TraceConditional - Debug|TraceConditional]](string TextToPrint, bool ShowTrace)'''
|[[TraceAndBox - Debug|'''TraceAndBox'''(String ''asTextToPrint'', Int ''aiSeverity'')]]
*Outputs the string to the Papyrus log, but only if the condition is true
|Outputs the string to the log and puts up a message box
|-


'''Function [[TraceStack - Debug|TraceStack]](string asTextToPrint, int aiSeverity)'''
|[[TraceConditional - Debug|'''TraceConditional'''(String ''TextToPrint'', Bool ''ShowTrace'')]]
*Outputs the string to the Papyrus log and debug text page, along with a full call stack
|Outputs the string to the Papyrus log, but only if the condition is true
|-


'''bool Function [[TraceUser - Debug|TraceUser]](string asUserLog, string asTextToPrint, int aiSeverity)'''
|[[TraceStack - Debug|'''TraceStack'''(String ''asTextToPrint'', Int ''aiSeverity'')]]
*Outputs the string to the specified user log (and debug text page)
|Outputs the string to the Papyrus log and debug text page, along with a full call stack
|-
 
|[[TraceUser - Debug|Bool '''TraceUser'''(String ''asUserLog'', String ''asTextToPrint'', Int ''aiSeverity'')]]
|Outputs the string to the specified user log (and debug text page)
|-
 
|}


== Member Functions ==
== Member Functions ==

Revision as of 03:53, 24 October 2013


Collection of debug-related global functions

Definition

ScriptName Debug

Properties

None

Global Functions

Function Description
CenterOnCell(String asCellName) Teleports the player to the specified cell.
Float CenterOnCellAndWait(String asCellName) Teleports the player to the specified cell and doesn't return until he gets there.
Float PlayerMoveToAndWait(String asDestRef) Teleports the player to the specified reference and doesn't return until he gets there.
CloseUserLog(String asLogName) Closes the specified user log
DumpAliasData(Quest akQuest) Dumps all alias fill information to the alias dump log.
String GetConfigName() Obtains the build configuration name
String GetPlatformName() Obtains the current platform name
String GetVersionNumber() Obtains the current version number
MessageBox(String asMessageBoxText) Displays an OK message box with the specified text
Notification(String asNotificationText) Displays an in-game notification message (on the top-left corner)
Bool OpenUserLog(String asLogName) Opens the specified user log (fails if already open)
QuitGame() Quits the game
SetFootIK(Bool abFootIK) Turns foot IK on and off
SetGodMode(Bool abGodMode) Turns god mode on and off
SendAnimationEvent(ObjectReference arRef, String asEventName) Sends an animation event to the specified reference.
StartScriptProfiling(String asScriptName) Starts profiling a specific Papyrus script
StartStackProfiling() Starts profiling the calling stack
StopScriptProfiling(String asScriptName) Stops profiling a specific Papyrus script
StopStackProfiling() Stops profiling the calling stack
ToggleAI() Turns AI on and off.
ToggleCollisions() Turns collision on and off.
ToggleMenus() Toggles menus on and off.
Trace(String asTextToPrint, Int aiSeverity) Outputs the string to the Papyrus log and debug text page
TraceAndBox(String asTextToPrint, Int aiSeverity) Outputs the string to the log and puts up a message box
TraceConditional(String TextToPrint, Bool ShowTrace) Outputs the string to the Papyrus log, but only if the condition is true
TraceStack(String asTextToPrint, Int aiSeverity) Outputs the string to the Papyrus log and debug text page, along with a full call stack
Bool TraceUser(String asUserLog, String asTextToPrint, Int aiSeverity) Outputs the string to the specified user log (and debug text page)

Member Functions

None

Events

None