Groovy web console

subscribe to the feed Subscribe
to this
site
embed in your blog Embed
this
script
mic (via #groovywebconsole)
tweet this snippet Tweet
this
script

To embed this script in your site, just drop the content below where you want to embed it.

mic

Published 1 month ago by mic
Actions  ➤ Edit in console Back to console Show/hide line numbers View recent scripts
class Game {
    void look() {
        println "You look around and see nothing"
    }
}


def game = new Game()
String playerInput = "look()"
new GroovyShell().evaluate("game.${playerInput}")

Recent scripts