Qhimm.com Forums
Miscellaneous Forums => Scripting and Reverse Engineering => Topic started by: Akari on 2008-11-15 18:36:55
-
Wondering about FFVII battle ai scripting.
In Terrense enemy mechanics there are conditions
If (All Opponents are in Front Row) Then
{
Choose Random Opponent
1/4 Chance: TempVar:ChosenAtt = Machine Gun
3/4 Chance: TempVar:ChosenAtt = <Tonfa>
} Else If (All Opponents are in Back Row) Then {
1/8 Chance: TempVar:ChosenAtt = <Tonfa>
7/8 Chance: TempVar:ChosenAtt = Machine Gun
} Else {
If (1/2 Chance) Then
{
Choose Random Opponent in Back Row
TempVar:ChosenAtt = Machine Gun
} Else {
Choose Random Opponent in Front Row
TempVar:ChosenAtt = <Tonfa>
}
}
But when I dump psx script there are folowing code (already simplified)
0000 [0004 + 00] = (00);
0006 [0008 + 00] = (00);
000c [0000 + 00] = (00);
0012 JumpIfNotAllFriendsInFrontRow(0029);
001f [0008 + 00] = [0008 + 00] & (01);
0029 JumpIfNotAllFriendsInBackRow(0040);
0036 [0008 + 00] = [0008 + 00] & (02);
0040 JumpIfNotAllOpponentsInFrontRow(0057);
004d [0004 + 00] = [0004 + 00] & (01);
0057 JumpIfNotAllOpponentsInBackRow(006e);
0064 [0004 + 00] = [0004 + 00] & (02);
006e JumpIfSelfNotInFrontRow(0084);
007b [0000 + 00] = (00);
0081 0x72 JumpTo(0x008a)
0084 [0000 + 00] = (01);
variable 0 - where we store if we in front row or not.
but variable where we store enemy position always zero. It is set to 0 at the beginning and if we &2 or &1 it - nothing change. I check with debugger - this variables always zero.
Everything else - exactly like in Fergusson faq... just those conditions always false.
So there are questions - are PC and PSX version of scripts different?
If anyone can post here part of dumped ai code from MP enemy or send me scene.bin file ([email protected]) it will be very convinient.
-
They not different. Just terrence was wrong about it a little.
-
They not different. Just terrence was wrong about it a little.
Oh? A bit of information being wrong could do that. Terrance did quite a bit of work on it.
I have noticed things seem take forever when you are younger, now they DO take forever to do LOL. (side track)
So in any case what was the information that was in error?
Cyb