SourcePawn highlighting and autocompletion for Visual Studio Code. Supports the SourceMod 1.7+ syntax.
- Compile from VSCode with a simple button.
- Autocompletion.
- Go to definition.
- Upload to an FTP/SFTP server on successful compile.
- Automatically run
sm plugins refresh
on a successful upload. - Hover for details.
- Add icons for
.smx
,.sp
and.inc
files - Automatically scan include files for natives, defines, methodmaps and more.
- Useful snippets.
- Detailed highlighting for
.sp
,.inc
,.cfg
,.games.txt
and.phrases.txt
. - Parse sourcemod files from a custom location.
- Linting capabilities.
Details on how to use the extension available in the Wiki.
- Dreae's extension which is not supported anymore, and on which this extension is based on.
- Deathreus' extension which helped me to implement the linting feature.
- Everybody that has helped me improved the extension on the discord server.
Thanks for considering this. But please remember that all of this wouldn't be possible without the Alliedmodders community. If you wish to make a donation for this community, you can make it here. If you prefer to make a donation to me for this project, you can buy me a coffee
This usually happens when you have sourcepawn.MainPath
set but don't actually need it. This setting is only to be used for large projects with multiple .sp
files, as a way to provide an entry point for the compiler.
Don't use this setting if you don't need to.
NOTE: This error shouldn't appear as much as of version 1.12.0.
The Command not found
error means that the extension could not start properly.
This is usually due to the user trying to open a single file only and not a folder.
As of version 1.12.0, this is partly supported, however, for full support, please open a folder when editing a project, and not just the .sp
file.
First, go to the releases page and download the .vsix
file attached to the latest release.
Then, open VSCode and in the extension manager, click on the ...
icon and select install from VSIX.
Select the file you've just downloaded and you're done.
Pull requests and suggestions are welcome.
- To make a suggestion or to report an issue, please create a new issue here.
- To make a contribution, fork the repository, make the desired changes, and open a pull request.
To run the extension from the source, do the following: