this post was submitted on 14 Oct 2024
56 points (96.7% liked)
Gaming
2489 readers
143 users here now
The Lemmy.zip Gaming Community
For news, discussions and memes!
Community Rules
This community follows the Lemmy.zip Instance rules, with the inclusion of the following rule:
You can see Lemmy.zip's rules by going to our Code of Conduct.
What to Expect in Our Code of Conduct:
- Respectful Communication: We strive for positive, constructive dialogue and encourage all members to engage with one another in a courteous and understanding manner.
- Inclusivity: Embracing diversity is at the core of our community. We welcome members from all walks of life and expect interactions to be conducted without discrimination.
- Privacy: Your privacy is paramount. Please respect the privacy of others just as you expect yours to be treated. Personal information should never be shared without consent.
- Integrity: We believe in the integrity of speech and action. As such, honesty is expected, and deceptive practices are strictly prohibited.
- Collaboration: Whether you're here to learn, teach, or simply engage in discussion, collaboration is key. Support your fellow members and contribute positively to shared learning and growth.
If you enjoy reading legal stuff, you can check it all out at legal.lemmy.zip.
founded 1 year ago
MODERATORS
I recognize you and your profile picture from some quite popular Luanti mods. :D I have a question regarding making content for Luanti:
I've been interested in maybe some day making a game for Luanti, but I don't really like Lua (I for example imagine that undefined variables evaluating to
nil
rather than directly throwing an error, identifiers by default being public, and absence of static checking of possibility of null dereference before runtime to be things that can cause quite some annoying bugs). Is there some popular X to Lua transpiler that you've heard people using? Something like what Typescript is to JS or Kotlin/Clojure/Scala to Java (not exactly the same thing since they all compile directly to jvm bytecode rather than java, but you get the point).I hope I'm not insulting you by asking such a question.
@Faresh Yeah, Lua definitely does have some weaknesses but I’ve seen worse so it doesn’t stop me from using it.
I’m not aware of any TypeScript-like language for Lua.
I found TypeScriptToLua but I don’t like the idea as those are entirely different languages.
But luacheck is relatively popular in the Luanti community for static code analysis and linting.
Thanks! Yeah, typescript was just an example that I gave because it was made to tackle the perceived problems in javascript. I never used it myself and just mentioned it to explain the idea I was getting at.
I've seen typescript being used for modding using typescript-to-lua. See https://github.com/jordan4ibanez/forgotten-lands and https://github.com/RepComm/mt-api