Add on script builder add support for specifying starting line

Started by
3 comments, last by Boost113 9 years, 6 months ago

I'd like to see the ability to specify starting line numbers in script builder AddSectionFromMemory.

I've been doing my own changes to support this for a few versions now but it is kind of annoying to have to redo that every new version.

Why I need this is because I have my own custom format for GUI files which contain angelscript code and it is much easier to debug when I can specify the line numbers that match with the actual file.

Could this be supported in the future? It would be only like 5 changes.

The method definition I'm using right now:


    int AddSectionFromMemory(const char *sectionName,

                             const char *scriptCode,

                             unsigned int startLine = 1,

                             unsigned int scriptLength = 0);

This works for me but the startLine argument being before the length could cause issues...

I can give you the lines I changed.

I would have made a patch file or a pull request but as far as I can tell there isn't a repo for angelscript.

Advertisement

I'll add a note for including this support for the next release. Thanks for the suggestion.

The svn for angelscript is hosted on sourceforge.net, as mentioned on the WIP page.

AngelCode.com - game development and more - Reference DB - game developer references
AngelScript - free scripting library - BMFont - free bitmap font generator - Tower - free puzzle game

Somehow I must have missed that link...

Thanks

I've included this in revision 2010.

Thanks,

Andreas

AngelCode.com - game development and more - Reference DB - game developer references
AngelScript - free scripting library - BMFont - free bitmap font generator - Tower - free puzzle game

Awesome, thanks!

This topic is closed to new replies.

Advertisement