views:

43

answers:

1

I am writing a small game for the android platform (HTC Desire) and i am trying to implement a simple scripting language, mostly to set variables and check if conditions are met.

So I thought maybe there was a runtime parser in the android library, that way I can put some of the logic in scripts, instead of in the engine.

It's quite basic stuff, like setting variables; "skill_accuracy = 5", IF conditions "if (skill_accuracy > nme.accuracy) { hit = true}" and maybe call a function like "call level_won();" but Im guessing that can be done using method invokation.

Any ideas?

+2  A: 

Do not invent the wheel. Use Android Scripting Environment

cement
That's exactly what I was looking for, thanks.
Thomas