v0.2 download:
http://www.ficedula.co.uk/Conformer/Conformer_0_2.zipOld versions:
v0.1 download:
http://www.ficedula.co.uk/Conformer/Conformer_0_1.zip (you will need an up to date version of the .NET framework installed also).
This is an initial release: there's many things missing I'd like to add but enough is working now for it to be functional and for me to gather some feedback, so, here you go.
Conformer is essentially a script compiler for the AI scripts. (It doesn't replace Proud Clod - in fact you currently need Proud Clod to make any good use of it). The idea is that rather than writing AI scripts in the raw bytecode you can write them in a vaguely friendly scripting language and Conformer will compile your textual script down into the bytecode FF7 uses.
Here's a very simple example:
Import common
const word ATT_BODYBLOW := $0172
const word ATT_FANG := $0189
function AI.Main: void
Targets := PickRandomBit(Enemies)
if (Random() mod 2) = 0 then
Call Perform(ENEMY_ATTACK, ATT_FANG)
else
Call Perform(ENEMY_ATTACK, ATT_BODYBLOW)
end if
end function
Obviously this is pretty simple and the sort of thing you could code in the bytecode manually but it's a bit nicer to do it this way
Here's something a bit more complex:
Import common
const word ATT_BODYBLOW := $0172
function AI.Main: void
if LoadStats(Me, StatCurrentHP) < (LoadStats(Me, StatMaxHP) / 2) then
Targets := PickRandomBit(FindLargest(LoadStats(Enemies, StatCurrentHP)))
else
Targets := PickRandomBit(Allies)
end if
Call Perform(ENEMY_ATTACK, ATT_BODYBLOW)
end function
I can't see why you
would implement a script like this
but it's a good example of the language. In this case, it loads the current creature's HP, and if it's less than half of their maximum HP, it loads the HP of all the enemies, finds which of them has the most, and picks a random one of those to target. Otherwise it targets a random ally.
How to actually use it...:
You type your script into location (1). (You can load, save, etc. scripts from the menu like normal.)
Once you've entered your script, pick one of the AI functions you've written (e.g. AI.Main) from the list (2).
Then click Compile (3).
Either it'll work, or it'll show you errors in the listbox (4), in which case you need to fix the errors first!
If it works, it'll output the bytecode in area (5), in three formats: plain binary, commented binary explaining what each block of bytecode is doing, and (most usefully) in the text format Proud Clod expects for you to paste into the AI editor. Since Conformer doesn't have an option yet to edit the scene.bin files that's how you'll want to get your AI into the actual game.
A language reference is available from the Help menu or here:
http://www.ficedula.co.uk/Conformer/0.1/Language.html or off course post questions here!
I have quite a few planned features to add; direct write support into scene.bin is an obvious one, the bytecode it produces could be optimised further, and some other things, but requests are also welcome.
Cheers!