-
Notifications
You must be signed in to change notification settings - Fork 44
feat: implement validation for native script definitions #37
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
I've cleaned up the code and updated some things @wopss. The popup now looks like this: It's meant to be readable for regular users. The logs contain detailed information with source file references and line numbers:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Poggies!
Thanks! I have a few minor remarks.
@wopss addressed all your comments |
Thanks! |
RIP, I think this may crash or cause other issues if path contains unicode chars as mentioned in comment... |
Probably not an issue for regular installs, but if someone put their legit copy in some weird path this is an issue... And you can do that with Steam and GOG at least, dunno about EGS... Probably not for majority though... Should still be patched. |
depends on wopss/RED4ext.SDK#102
my c++ isn't very good, feel free to make commits here if you don't like something
the overview is:
scc_shared.dll
file which can be used to interact with the compilerExecuteProcess
has been updated to dynamically load this dll when it's present, use it to compile scripts and then finally retrieve information necessary to map all native definitions to source files (which we use later)SourceRefRepository
class for management of source references, it uses a string interner to store strings as an optimiation, because paths and class names are going to repeat a lotValidateScripts
hook, which invokes existing script validation that's already implemented in the game, parses the validation errors into a simple structure, and then finally converts that into a nice error message notifying the user about the problematic scripts