Skip to content
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

Rewrite SScript Implementation #12922

Merged
merged 4 commits into from Jul 31, 2023
Merged

Rewrite SScript Implementation #12922

merged 4 commits into from Jul 31, 2023

Conversation

ghost
Copy link

@ghost ghost commented Jul 29, 2023

This PR rewrites most of the SScript implementation.
(Resolved the conflicts)

  • Ditched doString, HScript uses now new which is better optimized.
  • Due to doString change, runHaxeCode can now use files. getTextFromFile is unnecessary.
  • runHaxeCode now can return values without a function.
  • Scripts now gets cleared from memory completely using destroy().
  • global is used to check for conflicting scripts.
  • Rewrote callOnHScript, which fixes not being able to call the same function from multiple scripts.
  • Replaced interpName with origin which is used for Lua traces.
  • addHaxeLibrary now doesn't initialize Haxe scripts for its Lua script, so you can use it after or before runHaxeCode.

Copy link
Contributor

@Stefan2008Git Stefan2008Git left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes

@ShadowMario ShadowMario merged commit 876565b into ShadowMario:main Jul 31, 2023
3 checks passed
@frantastic24
Copy link

this seems to have broken scripts that use runHaxeCode more than once?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants