Jump to content
  • Advertisement
Sign in to follow this  
  • entries
    21
  • comments
    30
  • views
    12145

java scripting engine

Sign in to follow this  
pinacolada

241 views

Okay the time has come for some RAD. I'm looking into scripting engines to use in conjunction with Java, because I feel like I can really tear things up if I get a nice scripting engine with an interactive mode that lets me edit scripts while playing the game.

So I checked out what's available and I narrowed it down to Jython and JRuby.

Jython pros:
- The Python language is pretty popular for games
- Looks pretty stable (they are up to version 2)

Jython cons:
- Library is 2.7mb, which is pretty big if I ever hope to sell any games to people on dial-up.
- The whitespace thing bugs me. Are brackets really so bad, that we need to come up with a clever way to avoid writing brackets?

JRuby pros:
- Smaller library (800k)
- I kind of like the language more. One of the things I want out of a scripting language is closures, the whole passing-functions-as-data thing. Python certainly supports closures, but the difference is Ruby encourages them, by making them so easy to do. Looking at Ruby code, you see them all over the freaking place.

JRuby cons:
- Not really finished. It seems like most of the upcoming work is for tighter integration with Java, which I don't really need except as far as it increases performance. But there's some important stuff missing, like continuations. I've never ever used a continuation, but maybe I want to!
- Performance concerns. I know that the point of a scripting language isn't high performance, but when I look at this, it makes me worried.

But anyway, I think I'm going with JRuby, as that language seems more like what I want.
Sign in to follow this  


3 Comments


Recommended Comments

OMG! javascript via Rhino! There is no other logical choice!

Seriously, you can seemlessly call back and forth between the two in both directions, and you can expose only the classes/methods from Java that you want.

Share this comment


Link to comment
Cool, it looks pretty solid, I'll check it out. I think I'm still leaning towards Ruby though, as I want a language that's really hacker-friendly and RAD-friendly.

Share this comment


Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!