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

Support for Yarn 2.3+, other enhancements #7

Closed
wants to merge 23 commits into from

Conversation

will-hart
Copy link

Thanks for the great library.

I've been working on adding yharnam 2.x support, and filling a few gaps I found as I went along. I realise that you may not be maintaining the repo any more but thought I'd make a PR in case it was useful. Let me know if you would prefer not to take contributions and I can publish my fork separately :)

The changes in this PR include:

  • Support Yarn Spinner 2.3, including updating all tests for 2.3 syntax.
  • Update dependencies
  • Update the proto file (no real changes)
  • Return Result from a lot of internal functions instead of panics (potentially addresses Return Errors instead of panicking #6?)
  • Add support + tests for visited and visited_count built-in functions (requires passing the VirtualMachine to functions)
  • Add support + tests for the built-in maths functions available in Yarn Spinner 2.3
  • Add support + tests for random functions behind a feature flag. The RNG can be randomly seeded or supplied with an optional seed for determinism.
  • Add support + tests for line tags
  • Add support + tests for optional options, e.g. -> Option 1 <<if $my_var == true >>

@mystal
Copy link
Owner

mystal commented Nov 27, 2023

Hello! My apologies, I missed this notification completely. I'm glad you found the library useful and thank you so much for contributing to it! I'm not yet sure what the status of yharnam should be, given how little time I have to maintain a library right now--and how much effort it is to keep up with YarnSpinner!

My desire with yharnam was to have a decent dialogue system for games in Rust (and mostly through Bevy since that's what I make my Rust games in). Earlier this year yarn-slinger came along and got a lot of steam. It seems to have slowed down significantly, but I still mean to look into their implementation and Bevy plugin to see if it satisfies my needs.

I'm more than happy to take a look over and possibly merge your changes here if you like. And happy to drop it if you'd rather keep working on your fork. Let me know what you prefer and I can find some time to review if needed :)

@will-hart
Copy link
Author

Hey! No problems, thanks for the response and for yarnham :)

I'm happy to close the PR.

@will-hart will-hart closed this Nov 27, 2023
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.

None yet

2 participants