Page 1 of 1

Jive - compiling Java on the fly

PostPosted: 20 Oct 2009, 19:34
by mtgrares
I wanted to mention to you that compile Java on the flying using either Jive or the GNU Java compiler. I know that Jive is just one exe file although it doesn't support newer Java features like templates.

I think it would be nice to stick some Java code in cards.txt and then compile it on the fly on the user's computer.

Re: Jive - compiling Java on the fly

PostPosted: 21 Oct 2009, 13:03
by nantuko84
at first look sounds great, on other side - won't it make cards.txt unreadable? I guess cards.txt scripting is needed for special cases when keywords doesn't help. But unfortunately Java is not so light weight language (as functional) and it may bring complexity.
btw, as far as I know Incantus uses python scripts within card description files.

upd. what I found about Incantus card code is that it is described this way:
Code: Select all
@activated(txt=text[0])
def ability():
def effects(controller, source):
cost = yield SacrificeCost()
target = yield Target(isCreatureOrPlayer)
source.deal_damage(target, 1)
yield
return effects
abilities.add(ability)
not readable for me, but I believe the reason is that I don't know Python at all

the major question is: why we need this and what are the advantages of using it?