Open main menu
Home
Random
Log in
Settings
About the CreationKit Wiki
Disclaimers
the CreationKit Wiki
Search
Editing
OpenUserLog - Debug
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
[[Category:Scripting]] [[Category:Papyrus]] [[Category:Non-delayed Native Function]] '''Member of:''' [[Debug Script]] Opens a new user log on disk. This will also cycle the older logs (so log 0 becomes 1, 1 becomes 2, etc). The log files are stored in "My Documents/My Games/Skyrim/Logs/Script/User". If the log is already open, the function will return false (but not print an error to the main script log). Note that you do not have to close the log yourself unless you want to, it will close automatically when the game ends, the player goes back to the main menu, or a save is loaded. == Syntax == <syntaxhighlight lang="papyrus"> bool Function OpenUserLog(string asLogName) native global </syntaxhighlight> == Parameters == *asLogName: The name of the log to open, case-insensitive. User log names may use any combination of letters, numbers, and underscores ("_"). == Return Value == True if the log was successfully opened. False if the name was invalid, or the log was already open. == Examples == <syntaxhighlight lang="papyrus"> ; Opens a new user log name "myUserLog" Debug.OpenUserLog("myUserLog") ; Outputs "Hello World" to the "myUserLog" log Debug.TraceUser("myUserLog", "Hello World") </syntaxhighlight> == Notes == *A new log file is created each game session (a session ends when the game is no longer running). *Multiple scripts and plugins can write to the same logfile. == See Also == *[[Debug Script]] *[[CloseUserLog - Debug]] *[[TraceUser - Debug]]
Summary:
Please note that all contributions to the CreationKit Wiki are considered to be released under the Creative Commons Attribution-ShareAlike (see
CreationKit:Copyrights
for details). If you do not want your writing to be edited mercilessly and redistributed at will, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource.
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)