Releases: Kapiainen/SublimePapyrus
Releases · Kapiainen/SublimePapyrus
Version 2.6.2
Skyrim
- Added exception handling to the plugin and linter to catch UnicodeDecodeError errors raised when attempting to read scripts while using the default encoding of the operating system's locale.
- Added a confirmation dialog to the 'Generate completions' command when attempting to process more than 100 scripts.
Version 2.6.1
Skyrim
- Fixed issue that caused errors when attempting to call Find and RFind functions on arrays of base types.
- The name of the first argument in the completions for the Find and RFind functions of arrays now changes based on the array's element type (abElement, afElement, aiElement, asElement, or akElement).
Version 2.6.0
Core
- Added a boolean setting for displaying docstrings in function/event call tooltips.
- Added a warning to the build system framework for when an import path defined in a module's settings does not actually exist on the filesystem.
Skyrim
- Added docstring support to classes representing scriptheaders, functions, events, and properties in the linter.
- Added support for displaying docstrings in tooltips for function/event calls.
Version 2.5.0
Skyrim
- Added indentation and comment rules with a .tmPreferences file.
- Fixed a bug in the linter. The bug caused accessing the Length property of bool, float, int, and string arrays to throw a semantic error.
Version 2.4.0
Core
- Added setting for splitting the full paths to scripts into filenames and folder paths in the Open script command.
Skyrim
- Shortened descriptions in definition completions (e.g. state, function).
- Updated syntax highlighting to support whitespace between function/event identifiers and left parentheses in function/event definitions.
- Fixed incorrect syntax highlighting when passing ' == ' as an argument. It was previously highlighted as if one were passing an argument while specifying the corresponding parameter identifier.
Fallout 4
- This module has been removed until further notice. The changes made in the latest version of Papyrus, which is used in Fallout 4, are extensive and incompatible with e.g. the build system framework. The package provided by Bethesda on the official Fallout 4 Creation Kit wiki should be used while this module is being developed.
Version 2.3.0
The Fallout 4 module should be considered experimental at the moment. The Papyrus language has changed significantly.
Core
- Added support for "arguments" setting in build systems.
Fallout 4
- Added "Release" and "Final" build systems to Fallout 4.
Version 2.2.0
The Fallout 4 module should be considered experimental at the moment. The Papyrus language has changed significantly.
Core
- Added the ability to use the Open script command in views that do not have a compatible syntax. An additional panel, which allows you to select which module's import paths should be used, opens up after you enter the (partial) name of the script to look for.
- Added support for listing all scripts with the Open script command by typing in an asterisk (*) as the only character.
- Added an optional title setting to module settings. The string value is used when listing modules by name. If this setting does not exist, then the module's key is used instead in listings.
Fallout 4
- Added syntax highlighting.
- Added basic completions.
- Added build systems.
- Added module settings.
Version 2.1.1
Skyrim
- Code completion
- Added completions for imported global functions when defining arguments in function/event calls.
- Tooltips
- Refactored tooltips for function/event parameters in order to reduce the amount of work that is done.
- Added parameter tooltips for imported global functions.
Version 2.1.0
Core
- Added new settings for toggling tooltips and customizing the looks of tooltips.
- Added a setting to toggle function/event parameters in function/event call completions.
Skyrim
- Added an optional tooltip that shows the name of the function/event and its parameters when typing inside of a function/event call (Sublime Text 3 build 3070 or newer only).
- Linter
- Fixed validation of explicit casting.
- Fixed argument validation in function calls.
- Added restrictions imposed on functions by the 'Global' keyword to the semantic analysis.
- Added a warning when no import paths are passed to the semantic analysis (e.g. if no paths have been defined in the settings).
- Code completion
- Updated completions for functions/events in states.
- Added completions for parameters of the function/event that is being called.
- Added back completions for inherited functions/events that had been missing since the previous version.
Version 2.0.0
Core
- The build system now places the compiled script one folder above the script's source file ("\Scripts\Source\Example.psc" is compiled to "\Scripts\Example.pex") if no output folder has been specified in the user settings.
- Updated function, event, and property completions to always include the source (i.e. the script) that the completions are from.
- The Open script command automatically uses the first selection, if a piece of text has been selected, as the initial value.
- Added a new setting (_linter_error_line_threshold_) that defines how many lines a linter error can move up or down by between passes before it is considered a new error that should be centered.
Skyrim
- Added a command to manually clear the various caches relevant to the linter and code completion without needing to restart Sublime Text. It is useful when modifying the contents of the import setting in the user settings or one of the folders specified in that setting.
- Linter
- Switched from using filenames to using a view's buffer ID for identification purposes. Scripts no longer have to have been saved to a file for the linter, and subsequently the code completion, to work.
- Switched to using the unmodified lexical and syntactic analysis classes in semantic analysis when processing other scripts in order to get their properties, functions, and events.
- Changed the way that lexical and syntactic analysis are performed in an effort to catch syntactic errors earlier.
- Semantic analysis has been modified to no longer discard statements after use and instead store them in an object, which represents the script and can be used by the code completion system.
- NodeVisitor now returns an object with type, array, and object fields instead of just a string.
- Error messages in the status bar are now persistent until they have been resolved.
- Removed gutter icon from highlighted lines.
- Errors are no longer centered multiple times unless either the line with the error has moved up or down more than specified in the user settings (default: 2 lines) or there has been a linter pass without errors.
- Modified error messages.
- Fixed GetPath so that it works in a Unix environment where many file systems are case-sensitive.
- Fixed a bug that caused issues when using identifiers starting with 'true' and 'false'.
- Fixed NodeVisitor so that it returns the correct values from binary operator nodes involving comparison or logical operators.
- Fixed a bug that caused non-global functions from imported scripts to be taken into account when checking for ambiguous function calls.
- Fixed a bug that stopped casting 'self' to a type that extends the current script.
- Fixed a bug that prevented the use of 'self' as an argument in function calls when the parameter type is the same as the current script.
- Added specific warnings when declaring a variable/property with an identifier that is already in use in a property declaration in a parent script.
- Added support for distinguishing between attempts to call global and non-global functions.
- Added errors when attempting to use the Self or Parent variables in functions with the Global keyword.
- Added validation of function return types.
- Added more specific exceptions (e.g. when expecting a type, a literal, a keyword, or an identifier).
- Added an error about casting to non-existing types.
- Added an error when attempting to cast an expression that does not return a value.
- Added errors when attempting to explicitly cast outside of the chain of inheritance of the type that the left-hand side expression evaluates to.
- Added an error when attempting to access properties, functions, or events of expressions that evaluate to a base type or nothing.
- Added an error when a variable's, property's, or parameter's name is the same as a known type.
- Added an error when attempting to assign a non-array value to an array.
- Added an error when attempting to use a type as if it were a variable (e.g. accessing a property directly via a type).
- Added errors when attempting to incorrectly use arithmetic or logical operators.
- Code completion
- Performance has been improved by caching the result of the linter's semantic analysis.
- More scenarios are now supported (e.g. keywords in script headers, variable declarations, property declarations, function/event declarations).
- The source (the current script, the parent script, or another script) of the completion is specified.