Sarrus1 / sourcepawn-studio

VSCode extension for SourcePawn scripting
https://sarrus1.github.io/sourcepawn-studio/
MIT License
139 stars 21 forks source link

The current file is not a SourcePawn script. #408

Open ZBzibing opened 3 weeks ago

ZBzibing commented 3 weeks ago

Basic informations

Compile file: The current file is not a SourcePawn script.

maxijabase commented 3 weeks ago

This happens when you freshly open VSCode and the program hasn't realized you're actually stepping on a SourcePawn file. Selecting a couple files back and forth fixes the issue, that is, if you're actually on a valid .sp file. The extension should not do this actually, we should find a way to force it to select an open document if there's one already opened.

ZBzibing commented 3 weeks ago

I don't know why this is happening, at least it wasn't before he updated it, I've completed hundreds of SPs with him, and many more excellent SP author docs that won't compile, all I want to do now is uninstall it and find the previous version to use!

ZBzibing commented 3 weeks ago

Solution. Upgrade the compiler to sourcemod-1.11.0-git6952

Sarrus1 commented 3 weeks ago

I thanks for reporting this. I don't think updating the compiler is the fix you are looking for.

ZBzibing commented 3 weeks ago

You can try using a lower version of 1.11, which will still report errors And I upgraded just by replacing the 3 exe files with the latest version

Spyro-Dragon commented 1 week ago

Ive gotten this issue before. What fixed it for me is unchecking "Main Path Compilation"