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

Fix for newer version of Love2D #1

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Conversation

pkhead
Copy link

@pkhead pkhead commented Jan 4, 2025

This pull request updates the generator to work with newer versions of Love2D, and also to work on Windows.

Here is a comprehensive list of the changes I've made:

  1. If it detects you are running on Windows, it uses the mkdir command (instead of mkdir -p) and corrects the path separators in the arguments to the command.
  2. The KeyConstant and Scancode enums have been fixed by using a handwritten file instead of automatically generating one. Since those enums have now been fixed, it now uses them instead of using the String type.
  3. It now generates an enum abstract (added in a more recent version of Haxe) instead of an @:enum abstract.
  4. If it generates an enum identifier that starts with a digit, it prepends an underscore so that it compiles correctly.
  5. It escapes special characters for generated enum string values.
  6. Union types (those defined as "A or B") generate as a Dynamic.
  7. The FFI cdata type is generated as Dynamic.

@skial skial mentioned this pull request Jan 5, 2025
1 task
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.

1 participant