// Save the previous transition so that we don't execute the same transition multiple times in a row.
        private void ExecuteTransition(Transition transition, string defaultDescription = "")
        {
            bool suspended = false;

            if (transition != PreviouslyExecutedTransition)
            {
                if (transition.Suspendable)
                {
                    Game.Suspend();
                    suspended = true;
                }

                transition.Execute(defaultDescription);

                if (!transition.Repeatable)
                {
                    PreviouslyExecutedTransition = transition;
                }

                if (suspended)
                {
                    Game.Resume();
                }
            }
        }
        public override void Execute(string defaultDescription = "")
        {
            Process process = memoryWatchers.Process;

            if (base.memoryWatchers.RonsoTransition.Current > 0)
            {
                if (base.memoryWatchers.MovementLock.Current == 0x20 && Stage == 0)
                {
                    base.Execute();

                    BaseCutsceneValue = base.memoryWatchers.EventFileStart.Current;

                    Stage += 1;
                }
                else if (base.memoryWatchers.RonsoTransition.Current > (BaseCutsceneValue + 0x12907) && Stage == 1)
                {
                    RonsoFormation = process.ReadBytes(memoryWatchers.Formation.Address, 10);

                    WriteValue <int>(base.memoryWatchers.RonsoTransition, BaseCutsceneValue + 0x13F9F);
                    Stage += 1;
                }
                else if (base.memoryWatchers.RonsoTransition.Current == (BaseCutsceneValue + 0x14056) && Stage == 2)
                {
                    Transition FormationSwitch = new Transition {
                        ForceLoad = false, ConsoleOutput = true, FormationSwitch = Transition.formations.PostBiranYenke, Formation = RonsoFormation, Description = "Fix party after Biran and Yenke"
                    };
                    FormationSwitch.Execute();

                    Stage += 1;
                }
            }
        }
示例#3
0
        public override void Execute(string defaultDescription = "")
        {
            if (base.memoryWatchers.SpherimorphTransition.Current > 0)
            {
                if (base.memoryWatchers.CutsceneAlt.Current == 355 && Stage == 0)
                {
                    base.Execute();

                    BaseCutsceneValue = base.memoryWatchers.EventFileStart.Current;
                    Stage            += 1;
                }
                else if (base.memoryWatchers.SpherimorphTransition.Current == (BaseCutsceneValue + 0x3477) && Stage == 1) // 486
                {
                    WriteValue <int>(base.memoryWatchers.SpherimorphTransition, BaseCutsceneValue + 0x35A5);              // 1B44

                    Transition actorPositions;
                    //Position Wendigo
                    actorPositions = new Transition {
                        ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { 4217 }, Target_x = 0.0f, Target_y = -14.0f, Target_z = 140.0f
                    };
                    actorPositions.Execute();

                    Stage += 1;
                }
                else if (base.memoryWatchers.PlayerTurn.Current == 1 && Stage == 2)                          // 1200 is HP of Guado
                {
                    WriteValue <int>(base.memoryWatchers.SpherimorphTransition, BaseCutsceneValue + 0x36CC); // 1E34
                    Stage += 1;
                }
            }
        }
示例#4
0
        public override void Execute(string defaultDescription = "")
        {
            Process process = memoryWatchers.Process;

            if (Stage == 0)
            {
                process.Suspend();

                new Transition {
                    EncounterMapID = 74, EncounterFormationID = 0, ScriptedBattleFlag1 = 0, ScriptedBattleFlag2 = 1, ScriptedBattleVar1 = 0x00000501, EncounterTrigger = 2, Description = "Right Fin", ForceLoad = false
                }.Execute();

                Stage += 1;

                process.Resume();
            }
            else if (base.memoryWatchers.BattleState2.Current > 0 && Stage == 1)
            {
                Transition actorPositions;
                //Position Sin
                actorPositions = new Transition {
                    ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { 4233 }, Target_x = -1205.0f, Target_y = -440.0f, Target_z = 428.0f
                };
                actorPositions.Execute();

                Stage += 1;
            }
        }
示例#5
0
        public override void Execute(string defaultDescription = "")
        {
            int baseAddress = base.memoryWatchers.GetBaseAddress();

            if (base.memoryWatchers.DjoseTransition.Current > 0)
            {
                if (CutsceneAltList.Contains(base.memoryWatchers.CutsceneAlt.Current) && Stage == 0)
                {
                    base.Execute();

                    BaseCutsceneValue = base.memoryWatchers.DjoseTransition.Current;

                    Stage += 1;
                }
                else if (base.memoryWatchers.DjoseTransition.Current == (BaseCutsceneValue + 0x160) && Stage == 1) // 160
                {
                    WriteValue <int>(base.memoryWatchers.DjoseTransition, BaseCutsceneValue + 0x4ED);

                    Transition actorPositions;
                    //Position Tidus
                    actorPositions = new Transition {
                        ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { 1 }, Target_x = 1.628f, Target_y = 0.0f, Target_z = -6.528f
                    };
                    actorPositions.Execute();

                    Stage += 1;
                }
            }
        }
        public override void Execute(string defaultDescription = "")
        {
            if (base.memoryWatchers.EchuillesTransition.Current > 0)
            {
                if (Stage == 0)
                {
                    base.Execute();

                    BaseCutsceneValue = base.memoryWatchers.EventFileStart.Current;
                    Stage            += 1;
                }
                else if (base.memoryWatchers.EchuillesTransition.Current >= (BaseCutsceneValue + 0x20D0) && Stage == 1)
                {
                    WriteValue <int>(base.memoryWatchers.EchuillesTransition, BaseCutsceneValue + 0x248A); // 0x2490

                    Transition actorPositions;

                    //Position Echuilles
                    actorPositions = new Transition {
                        ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { 4210 }, Target_x = 0.0f, Target_y = -124.0f, Target_z = -40.0f
                    };
                    actorPositions.Execute();

                    Stage += 1;
                }
            }
        }
示例#7
0
        public override void Execute(string defaultDescription = "")
        {
            if (base.memoryWatchers.BikanelTransition.Current > 0)
            {
                if (base.memoryWatchers.MovementLock.Current == 0x20 && Stage == 0)
                {
                    base.Execute();

                    BaseCutsceneValue = base.memoryWatchers.BikanelTransition.Current;
                    Stage            += 1;
                }
                else if (base.memoryWatchers.BikanelTransition.Current == (BaseCutsceneValue + 0x11F) && Stage == 1)
                {
                    WriteValue <int>(base.memoryWatchers.BikanelTransition, BaseCutsceneValue + 0x1DC); // 1DC

                    Transition actorPositions;
                    // After the transition Kimahri's model is still visible so we bin him off to Narnia
                    actorPositions = new Transition {
                        ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { 4 }, Target_x = 1000.0f, Target_y = 0.0f, Target_z = -1000.0f
                    };
                    actorPositions.Execute();

                    Stage += 1;
                }
            }
        }
        public override void Execute(string defaultDescription = "")
        {
            Process process = memoryWatchers.Process;

            if (Stage == 0)
            {
                base.Execute();

                BaseCutsceneValue = base.memoryWatchers.EventFileStart.Current;
                Stage            += 1;
            }
            else if (base.memoryWatchers.EvraeAirshipTransition.Current == (BaseCutsceneValue + 0x15FFC) && Stage == 1)
            {
                WriteValue <int>(base.memoryWatchers.EvraeAirshipTransition, BaseCutsceneValue + 0x16217);
                Stage += 1;
            }
            else if (base.memoryWatchers.Gil.Current > base.memoryWatchers.Gil.Old && Stage == 2)
            {
                Stage += 1;
            }
            else if (base.memoryWatchers.Gil.Current == base.memoryWatchers.Gil.Old && Stage == 3)
            {
                process.Suspend();

                Transition ExitMenu = new Transition {
                    Menu = 0, Description = "Exit Menu", ForceLoad = false
                };
                ExitMenu.Execute();

                Stage += 1;

                process.Resume();
            }
        }
        public override void Execute(string defaultDescription = "")
        {
            Process process = memoryWatchers.Process;

            if (base.memoryWatchers.NatusTransition.Current > 0)
            {
                if (CutsceneAltList.Contains(base.memoryWatchers.CutsceneAlt.Current) && Stage == 0)
                {
                    base.Execute();

                    BaseCutsceneValue = base.memoryWatchers.EventFileStart.Current;
                    Stage            += 1;
                }
                else if (base.memoryWatchers.NatusTransition.Current == (BaseCutsceneValue + 0xE0F0) && Stage == 1) // 1893
                {
                    Transition FormationSwitch = new Transition {
                        ForceLoad = false, ConsoleOutput = true, FormationSwitch = Transition.formations.PreNatus, Description = "Fix party before Natus"
                    };
                    FormationSwitch.Execute();

                    formation = process.ReadBytes(base.memoryWatchers.Formation.Address, 10);

                    WriteValue <int>(base.memoryWatchers.NatusTransition, BaseCutsceneValue + 0xE2DF);//

                    Transition actorPositions;
                    //Position Party Member 1
                    actorPositions = new Transition {
                        ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { (short)(formation[0] + 1) }, Target_x = -31.0f, Target_y = 0.0f, Target_z = -25.0f
                    };
                    actorPositions.Execute();

                    //Position Party Member 2
                    actorPositions = new Transition {
                        ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { (short)(formation[1] + 1) }, Target_x = 0.0f, Target_y = 0.0f, Target_z = -13.0f
                    };
                    actorPositions.Execute();

                    //Position Party Member 3
                    actorPositions = new Transition {
                        ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { (short)(formation[2] + 1) }, Target_x = 31.0f, Target_y = 0.0f, Target_z = -25.0f
                    };
                    actorPositions.Execute();

                    //Position Natus
                    actorPositions = new Transition {
                        ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { 4222 }, Target_x = 0.0f, Target_y = -29.0f, Target_z = -100.0f
                    };
                    actorPositions.Execute();

                    Stage += 1;
                }
                else if (base.memoryWatchers.NatusTransition.Current == (BaseCutsceneValue + 0xE2FD) && base.memoryWatchers.HpEnemyA.Current < 36000 && base.memoryWatchers.HpEnemyA.Old == 36000 && Stage == 2)
                {
                    WriteValue <int>(base.memoryWatchers.NatusTransition, BaseCutsceneValue + 0xE395);
                    Stage += 1;
                }
            }
        }
示例#10
0
 // Save the previous transition so that we don't execute the same transition multiple times in a row.
 private void ExecuteTransition(Transition transition, string defaultDescription = "")
 {
     if (transition != PreviouslyExecutedTransition)
     {
         Game.Suspend();
         transition.Execute(defaultDescription);
         PreviouslyExecutedTransition = transition;
         Game.Resume();
     }
 }
示例#11
0
        public override void Execute(string defaultDescription = "")
        {
            Process process = memoryWatchers.Process;

            if (base.memoryWatchers.SanctuaryTransition.Current > 0)
            {
                formation = process.ReadBytes(base.memoryWatchers.Formation.Address, 7);

                if (Stage == 0)
                {
                    process.Suspend();

                    new Transition
                    {
                        EncounterMapID       = 68,
                        EncounterFormationID = 0,
                        ScriptedBattleFlag1  = 0,
                        ScriptedBattleFlag2  = 1,
                        ScriptedBattleVar1   = 0x00010504,
                        ScriptedBattleVar3   = 0x0000013C,
                        ScriptedBattleVar4   = 0x00000014,
                        EncounterTrigger     = 2,
                        Description          = "Sanctuary Keeper",
                        ForceLoad            = false
                    }.Execute();

                    Stage += 1;

                    process.Resume();
                }
                else if (base.memoryWatchers.BattleState2.Current == 22 && Stage == 1)
                {
                    Transition actorPositions;
                    //Position Party Member 1
                    actorPositions = new Transition {
                        ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { (short)(formation[0] + 1) }, Target_x = 1173.339722f, Target_y = -30.04813004f, Target_z = -1097.457031f
                    };
                    actorPositions.Execute();

                    //Position Party Member 2
                    actorPositions = new Transition {
                        ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { (short)(formation[1] + 1) }, Target_x = 1178.746948f, Target_y = -30.04813004f, Target_z = -1135.846924f
                    };
                    actorPositions.Execute();

                    //Position Party Member 3
                    actorPositions = new Transition {
                        ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { (short)(formation[2] + 1) }, Target_x = 1173.22583f, Target_y = -30.04813004f, Target_z = -1180.447388f
                    };
                    actorPositions.Execute();

                    Stage += 1;
                }
            }
        }
示例#12
0
        public override void Execute(string defaultDescription = "")
        {
            Process process = memoryWatchers.Process;

            if (base.memoryWatchers.TidusActionCount.Current == 1 && Stage == 0)
            {
                base.Execute();

                BaseCutsceneValue = base.memoryWatchers.EventFileStart.Current;
                Stage             = 1;
            }
            else if (base.memoryWatchers.AmmesTransition.Current == (BaseCutsceneValue + 0x97FA) && Stage == 1)
            {
                Transition actorPositions;
                //Position Ammes
                actorPositions = new Transition {
                    ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { 4255 }, Target_x = 843.5f, Target_y = -42.0f, Target_z = -126.7f
                };
                actorPositions.Execute();

                WriteValue <int>(base.memoryWatchers.AmmesTransition, BaseCutsceneValue + 0x9936);// 2AB , 255 , 21A

                Stage += 1;
            }
            else if (base.memoryWatchers.AmmesTransition.Current == (BaseCutsceneValue + 0x9A2C) && Stage == 2)
            {
                process.Suspend();

                new Transition {
                    Storyline = 16, SpawnPoint = 1, Description = "Sinscales to Ammes"
                }.Execute();

                Stage += 1;

                process.Resume();
            }
            else if (Stage == 3)
            {
                Transition actorPositions;
                //Position Tidus
                actorPositions = new Transition {
                    ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { 1 }, Target_x = 749.636f, Target_y = -41.589f, Target_z = -71.674f
                };
                actorPositions.Execute();
                //Position Ammes
                actorPositions = new Transition {
                    ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { 4255 }, Target_x = 843.5f, Target_y = -42.0f, Target_z = -126.7f
                };
                actorPositions.Execute();

                Stage += 1;
            }
        }
        public override void Execute(string defaultDescription = "")
        {
            Process process = memoryWatchers.Process;

            if (base.memoryWatchers.SinFinTransition.Current > 0)
            {
                if (CutsceneAltList.Contains(base.memoryWatchers.CutsceneAlt.Current) && Stage == 0)
                {
                    base.Execute();

                    BaseCutsceneValue = base.memoryWatchers.SinFinTransition.Current;

                    Stage = 1;
                }
                else if (base.memoryWatchers.SinFinTransition.Current == (BaseCutsceneValue + 0x76F) && Stage == 1)
                {
                    WriteValue <int>(base.memoryWatchers.SinFinTransition, BaseCutsceneValue + 0xBF0);

                    Transition actorPositions;

                    //Position Tidus
                    actorPositions = new Transition {
                        ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { 1 }, Target_x = -29.0f, Target_y = -50.0f, Target_z = 131.5f
                    };
                    actorPositions.Execute();

                    //Position Sin Fin
                    actorPositions = new Transition {
                        ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { 4209 }, Target_x = 1.0f, Target_z = 945.0f
                    };
                    actorPositions.Execute();

                    Stage += 1;
                }
                else if (base.memoryWatchers.SinFinTransition.Current == (BaseCutsceneValue + 0xCFD) && base.memoryWatchers.PlayerTurn.Current == 1 && Stage == 2) //200 = Sinscale HP
                {
                    process.Suspend();

                    new Transition {
                        ForceLoad = false, Storyline = 272, Description = "Post Sin Fin"
                    }.Execute();

                    WriteValue <int>(base.memoryWatchers.SinFinTransition, BaseCutsceneValue + 0x114A);

                    Stage += 1;

                    process.Resume();
                }
            }
        }
        public override void Execute(string defaultDescription = "")
        {
            int baseAddress = base.memoryWatchers.GetBaseAddress();

            if (base.memoryWatchers.YunalescaTransition.Current > 0)
            {
                Process process = memoryWatchers.Process;

                if (Stage == 0)
                {
                    base.Execute();

                    BaseCutsceneValue = base.memoryWatchers.EventFileStart.Current;
                    Stage            += 1;
                }//*/
                else if (base.memoryWatchers.YunalescaTransition.Current == (BaseCutsceneValue + 0x5DF0) && Stage == 1)
                {
                    WriteValue <int>(base.memoryWatchers.YunalescaTransition, BaseCutsceneValue + 0x645A);
                    Stage += 1;
                }
                else if (base.memoryWatchers.YunalescaTransition.Current == (BaseCutsceneValue + 0x64BA) && Stage == 2)
                {
                    WriteValue <int>(base.memoryWatchers.YunalescaTransition, BaseCutsceneValue + 0x67B4);
                    WriteValue <byte>(base.memoryWatchers.CutsceneTiming, 0);
                    Stage += 1;
                }
                else if (base.memoryWatchers.PlayerTurn.Current == 1 && Stage == 3)
                {
                    WriteValue <int>(base.memoryWatchers.YunalescaTransition, BaseCutsceneValue + 0x6C8D);
                    Stage += 1;
                }
                else if (base.memoryWatchers.Gil.Current > base.memoryWatchers.Gil.Old && Stage == 4)
                {
                    Stage += 1;
                }
                else if (base.memoryWatchers.Gil.Current == base.memoryWatchers.Gil.Old && Stage == 5)
                {
                    process.Suspend();

                    Transition ExitMenu = new Transition {
                        Menu = 0, Description = "Exit Menu", ForceLoad = false
                    };
                    ExitMenu.Execute();

                    Stage += 1;

                    process.Resume();
                }
            }
        }
示例#15
0
        public override void Execute(string defaultDescription = "")
        {
            int baseAddress = base.memoryWatchers.GetBaseAddress();

            List <short> CutsceneAltList = new List <short>(new short[] { 780, 347, 2253 });

            if (base.memoryWatchers.SahaginTransition.Current > 0)
            {
                if (CutsceneAltList.Contains(base.memoryWatchers.CutsceneAlt.Current) && Stage == 0)
                {
                    base.Execute();

                    BaseCutsceneValue = base.memoryWatchers.SahaginTransition.Current;
                    Stage             = 1;
                }
                else if (base.memoryWatchers.SahaginTransition.Current == (BaseCutsceneValue + 0xC9) && Stage == 1)
                {
                    WriteValue <int>(base.memoryWatchers.SahaginTransition, BaseCutsceneValue + 0x45A);

                    Transition actorPositions;
                    //Position Wakka
                    actorPositions = new Transition {
                        ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { 5 }, Target_x = -20.0f, Target_y = -510.0f, Target_z = 0.0f
                    };
                    actorPositions.Execute();

                    //Position Tidus
                    actorPositions = new Transition {
                        ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { 1 }, Target_x = 20.0f, Target_y = -510.0f, Target_z = 0.0f
                    };
                    actorPositions.Execute();

                    //Position Sahagins
                    actorPositions = new Transition {
                        ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { 4252 }, Target_x = 0.0f, Target_y = -510.0f, Target_z = -60.0f
                    };
                    actorPositions.Execute();

                    Stage = 2;
                }
                else if (base.memoryWatchers.SahaginTransition.Current == (BaseCutsceneValue + 0x491) && base.memoryWatchers.TidusActionCount.Current == 1 && Stage == 2)
                {
                    WriteValue <int>(base.memoryWatchers.SahaginTransition, BaseCutsceneValue + 0x556);
                    Stage = 3;
                }
            }
        }
        public override void Execute(string defaultDescription = "")
        {
            Process process = memoryWatchers.Process;

            if (base.memoryWatchers.MovementLock.Current == 0x20 && Stage == 0)
            {
                base.Execute();

                BaseCutsceneValue = base.memoryWatchers.EventFileStart.Current;
                Stage             = 1;
            }
            else if (base.memoryWatchers.GeneauxTransition.Current == (BaseCutsceneValue + 0x65CA) && Stage == 1) // 0x65CA
            {
                WriteValue <int>(base.memoryWatchers.GeneauxTransition, BaseCutsceneValue + 0x67AA);

                formation = process.ReadBytes(memoryWatchers.Formation.Address, 10);

                Transition actorPositions;
                //Position Party Member 1
                actorPositions = new Transition {
                    ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { (short)(formation[0] + 1) }, Target_x = -6.565776825f, Target_y = -159.9975586f, Target_z = 551.0246582f
                };
                actorPositions.Execute();

                //Position Party Member 2
                actorPositions = new Transition {
                    ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { (short)(formation[1] + 1) }, Target_x = 31.14787483f, Target_y = -159.9975586f, Target_z = 514.7622681f
                };
                actorPositions.Execute();

                //Position Party Member 3
                actorPositions = new Transition {
                    ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { (short)(formation[2] + 1) }, Target_x = 43.50946045f, Target_y = -159.9975586f, Target_z = 571.7218628f
                };
                actorPositions.Execute();

                Stage += 1;
            }
            else if (base.memoryWatchers.GeneauxTransition.Current == (BaseCutsceneValue + 0x67F4) && Stage == 2) // 0x68C3 , 0x67E9
            {
                WriteValue <int>(base.memoryWatchers.GeneauxTransition, BaseCutsceneValue + 0x6A47);
                Stage += 1;
            }
        }
示例#17
0
        public override void Execute(string defaultDescription = "")
        {
            if (base.memoryWatchers.WendigoTransition.Current > 0)
            {
                if (Stage == 0)
                {
                    base.Execute();

                    BaseCutsceneValue = base.memoryWatchers.WendigoTransition.Current;
                    Stage            += 1;
                }
                else if (base.memoryWatchers.WendigoTransition.Current == (BaseCutsceneValue + 0x19BF) && Stage == 1) // 486
                {
                    WriteValue <int>(base.memoryWatchers.WendigoTransition, BaseCutsceneValue + 0x1B1E);              // 1B44

                    Transition actorPositions;
                    //Position Party Members off screen
                    actorPositions = new Transition {
                        ForceLoad = false, ConsoleOutput = false, PositionPartyOffScreen = true, PartyTarget_x = 205.0f, PartyTarget_z = -480.0f
                    };
                    actorPositions.Execute();

                    //Position Guados
                    actorPositions = new Transition {
                        ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { 4309 }, Target_x = -100.0f, Target_z = -350.0f
                    };
                    actorPositions.Execute();

                    //Position Wendigo
                    actorPositions = new Transition {
                        ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { 4308 }, Target_x = -100.0f, Target_z = -350.0f
                    };
                    actorPositions.Execute();

                    Stage += 1;
                }
                else if (base.memoryWatchers.WendigoTransition.Current == (BaseCutsceneValue + 0x1B7E) && base.memoryWatchers.HpEnemyA.Current < 1200 && base.memoryWatchers.HpEnemyA.Old == 1200 && Stage == 2) // 1200 is HP of Guado
                {
                    WriteValue <int>(base.memoryWatchers.WendigoTransition, BaseCutsceneValue + 0x1E31);                                                                                                         // 1E34
                    Stage += 1;
                }
            }
        }
        public override void Execute(string defaultDescription = "")
        {
            if (base.memoryWatchers.UnderwaterRuinsTransition.Current > 0)
            {
                if (Stage == 0)
                {
                    base.Execute();

                    BaseCutsceneValue = base.memoryWatchers.UnderwaterRuinsTransition.Current;

                    Stage += 1;
                }/*/ Skipping piranhas pre fight causes a lot of jankiness - Probably not worth it
                  * else if (base.memoryWatchers.UnderwaterRuinsTransition.Current == (BaseCutsceneValue + 0x219) && Stage == 1)
                  * {
                  * WriteValue<int>(base.memoryWatchers.UnderwaterRuinsTransition, BaseCutsceneValue + 0x2B7);// 2B7
                  * Stage += 1;
                  * }//*/
                // To Do: Work out how to skip Tidus bashing the machine leading into Tros appearing
                else if (base.memoryWatchers.UnderwaterRuinsTransition.Current == (BaseCutsceneValue + 0x584) && Stage == 1)
                {
                    WriteValue <int>(base.memoryWatchers.UnderwaterRuinsTransition, BaseCutsceneValue + 0x636);
                    Stage += 1;
                }
                else if (base.memoryWatchers.Menu.Current == 0 && base.memoryWatchers.Menu.Old == 1 && Stage == 2)
                {
                    Transition actorPositions;
                    //Position ??? (Rikku)
                    actorPositions = new Transition {
                        ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { 41 }, Target_x = 75.648f, Target_y = 6.306f, Target_z = 16.575f
                    };
                    actorPositions.Execute();

                    //Position Tros
                    actorPositions = new Transition {
                        ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { 4197 }, Target_y = -100.0f
                    };
                    actorPositions.Execute();

                    Stage += 1;
                }
            }
        }
        public override void Execute(string defaultDescription = "")
        {
            Process process = memoryWatchers.Process;

            if (base.memoryWatchers.FrameCounterFromLoad.Current < 5 && base.memoryWatchers.State.Current == 0 && Stage == 0)
            {
                process.Suspend();

                new Transition {
                    EncounterMapID = 52, EncounterFormationID = 0, ScriptedBattleFlag1 = 0, ScriptedBattleFlag2 = 1, ScriptedBattleVar1 = 0x00014503, EncounterTrigger = 2, Description = "Evrae", ForceLoad = false
                }.Execute();

                Transition actorPositions;
                //Position Tidus
                actorPositions = new Transition {
                    ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { 4215 }, Target_x = -140.0f, Target_y = -35.0f, Target_z = 80.0f
                };
                actorPositions.Execute();

                Stage += 1;

                process.Resume();
            }

            /*
             * else if (base.memoryWatchers.BattleState2.Current == 22 && Stage == 1)
             * {
             *  Stage += 1;
             * }
             * else if (base.memoryWatchers.BattleState2.Current == 0 && Stage == 2)
             * {
             *  process.Suspend();
             *
             *  new Transition { RoomNumber = 367, Storyline = 20, Description = "Post Tanker" }.Execute();
             *
             *  Stage += 1;
             *
             *  process.Resume();
             * }
             */
        }
示例#20
0
        public override void Execute(string defaultDescription = "")
        {
            Process process = memoryWatchers.Process;

            if (base.memoryWatchers.MovementLock.Current == 0x20 && Stage == 0)
            {
                base.Execute();

                BaseCutsceneValue = base.memoryWatchers.EventFileStart.Current;

                Stage += 1;
            }
            else if (base.memoryWatchers.FluxTransition.Current == (BaseCutsceneValue + 0x5D5C) && Stage == 1)
            {
                WriteValue <int>(base.memoryWatchers.FluxTransition, BaseCutsceneValue + 0x6BC7);
                Stage += 1;
            }
            else if (base.memoryWatchers.PlayerTurn.Current == 1 && Stage == 2)
            {
                WriteValue <int>(base.memoryWatchers.FluxTransition, BaseCutsceneValue + 0x6E23);
                Stage += 1;
            }
            else if (base.memoryWatchers.Gil.Current > base.memoryWatchers.Gil.Old && Stage == 3)
            {
                Stage += 1;
            }
            else if (base.memoryWatchers.Gil.Current == base.memoryWatchers.Gil.Old && Stage == 4)
            {
                process.Suspend();

                Transition ExitMenu = new Transition {
                    Menu = 0, Description = "Exit Menu", ForceLoad = false
                };
                ExitMenu.Execute();

                Stage += 1;

                process.Resume();
            }
        }
        public override void Execute(string defaultDescription = "")
        {
            int baseAddress = base.memoryWatchers.GetBaseAddress();

            if (base.memoryWatchers.JechtShotTransition.Current > 0)
            {
                if (Stage == 0)
                {
                    base.Execute();

                    BaseCutsceneValue = base.memoryWatchers.EventFileStart.Current;
                    Stage            += 1;
                }//*/
                else if (base.memoryWatchers.JechtShotTransition.Current == (BaseCutsceneValue + 0xF3A7) && Stage == 1)
                {
                    WriteValue <int>(base.memoryWatchers.JechtShotTransition, BaseCutsceneValue + 0xF9E4);

                    Stage += 1;
                }
                else if (base.memoryWatchers.JechtShotTransition.Current == (BaseCutsceneValue + 0xFAAE) && Stage == 2)
                {
                    Transition actorPositions;
                    //Position Tidus
                    actorPositions = new Transition {
                        ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { 1 }, Target_x = 1.0f, Target_y = -49.99626923f, Target_z = 172.0000153f, Target_var1 = 100
                    };
                    actorPositions.Execute();

                    //Position Yuna
                    actorPositions = new Transition {
                        ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { 2 }, Target_x = 22.70000076f, Target_y = -49.99626923f, Target_z = 104.5999985f, Target_var1 = 120
                    };
                    actorPositions.Execute();

                    Stage += 1;
                }
            }
        }
示例#22
0
        public override void Execute(string defaultDescription = "")
        {
            Process process = base.memoryWatchers.Process;

            if (base.memoryWatchers.ChocoboEaterTransition.Current > 0)
            {
                if (base.memoryWatchers.MovementLock.Current == 0x20 && Stage == 0)
                {
                    base.Execute();

                    BaseCutsceneValue = base.memoryWatchers.ChocoboEaterTransition.Current;
                    Stage            += 1;
                }
                else if (base.memoryWatchers.ChocoboEaterTransition.Current >= (BaseCutsceneValue + 0x7A5) && Stage == 1) // 21B , EC
                {
                    WriteValue <int>(base.memoryWatchers.ChocoboEaterTransition, BaseCutsceneValue + 0xC96);              // 30A

                    byte[] ActiveParty = process.ReadBytes(base.memoryWatchers.Formation.Address, 3);

                    for (int i = 0; i < 3; i++)
                    {
                        if (ActiveParty[i] == 0x00)
                        {
                            Transition actorPositions;
                            //Position Tidus if he is in the party
                            actorPositions = new Transition {
                                ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { 1 }, Target_x = 100.0f, Target_y = 0.0f, Target_z = 30.0f
                            };
                            actorPositions.Execute();
                        }
                    }

                    Stage += 1;
                }
            }
        }
        public override void Execute(string defaultDescription = "")
        {
            Process process = memoryWatchers.Process;

            if (base.memoryWatchers.Dialogue1.Current == 95 && base.memoryWatchers.DialogueBoxOpen_Gui.Current == 1 && Stage == 0)
            {
                Stage += 1;
            }
            else if (base.memoryWatchers.DialogueOption_Gui.Current == 0 && base.memoryWatchers.DialogueBoxOpen_Gui.Current == 0 && Stage == 1)
            {
                Stage -= 1;
            }
            else if (base.memoryWatchers.DialogueOption_Gui.Current == 1 && base.memoryWatchers.DialogueBoxOpen_Gui.Current == 0 && Stage == 1)
            {
                process.Suspend();

                new Transition
                {
                    EncounterMapID       = 27,
                    EncounterFormationID = 0,
                    ScriptedBattleFlag1  = 1,
                    ScriptedBattleFlag2  = 1,
                    ScriptedBattleVar1   = 0x00004501,
                    ScriptedBattleVar3   = 0x00000000,
                    ScriptedBattleVar4   = 0x00000000,
                    EncounterTrigger     = 2,
                    Description          = "Sinspawn Gui 1",
                    ForceLoad            = false
                }.Execute();

                // Reposition Party Members just off screen to run into battle
                Transition actorPositions = new Transition {
                    ForceLoad = false, ConsoleOutput = false, PartyTarget_x = 427.0f, PartyTarget_z = 3350.0f, PositionPartyOffScreen = true
                };
                actorPositions.Execute();

                Stage += 1;

                process.Resume();
            }
            else if (base.memoryWatchers.HpEnemyA.Current == 12000 && Stage == 2)
            {
                DiagnosticLog.Information("Test");
                Stage += 1;
            }
            else if (base.memoryWatchers.BattleState2.Current == 0 && Stage == 3)
            {
                process.Suspend();

                GuiFormation = process.ReadBytes(memoryWatchers.Formation.Address, 10);

                new Transition
                {
                    RoomNumber           = 247,
                    Storyline            = 865,
                    EncounterMapID       = 29,
                    EncounterFormationID = 0,
                    ScriptedBattleFlag1  = 0,
                    ScriptedBattleFlag2  = 1,
                    ScriptedBattleVar1   = 0x00014504,
                    ScriptedBattleVar3   = 0x00000129,
                    ScriptedBattleVar4   = 0x00000014,
                    EncounterTrigger     = 2,
                    FormationSwitch      = formations.PreGui2,
                    Description          = "Sinspawn Gui 2",
                    ForceLoad            = false
                }.Execute();

                Stage += 1;

                process.Resume();
            }
            else if (base.memoryWatchers.Menu.Current == 1 && Stage == 4)
            {
                process.Suspend();

                new Transition {
                    Formation = GuiFormation, FormationSwitch = formations.PostGui, Description = "Fix Party", ForceLoad = false
                }.Execute();

                Stage += 1;

                process.Resume();
            }
        }
示例#24
0
        public override void Execute(string defaultDescription = "")
        {
            Process process = memoryWatchers.Process;

            int baseAddress = base.memoryWatchers.GetBaseAddress();

            if (base.memoryWatchers.MovementLock.Current == 0 && Stage == 0)
            {
                process.Suspend();

                base.Execute();

                MemoryWatcher <byte> shivaEnabled1 = new MemoryWatcher <byte>(new IntPtr(baseAddress + 0xD3211C));
                WriteValue <byte>(shivaEnabled1, 0x11);

                MemoryWatcher <byte> shivaEnabled2 = new MemoryWatcher <byte>(new IntPtr(baseAddress + 0xD326E4));
                WriteValue <byte>(shivaEnabled2, 0x11);

                BaseCutsceneValue = base.memoryWatchers.EventFileStart.Current;

                Stage += 1;

                process.Resume();
            }
            else if (base.memoryWatchers.MovementLock.Current == 0x10 && Stage == 1)
            {
                process.Suspend();

                WriteValue <int>(base.memoryWatchers.SeymourTransition, BaseCutsceneValue + 0x75DF);
                WriteValue <byte>(base.memoryWatchers.CutsceneTiming, 0);

                formation = process.ReadBytes(base.memoryWatchers.Formation.Address, 7);

                Transition actorPositions;
                //Position Party Member 1
                actorPositions = new Transition {
                    ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { (short)(formation[0] + 1) }, Target_x = 35.668f, Target_y = 0.0f, Target_z = -42.0f
                };
                actorPositions.Execute();

                //Position Party Member 2
                actorPositions = new Transition {
                    ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { (short)(formation[1] + 1) }, Target_x = 3.668f, Target_y = 0.0f, Target_z = -55.0f
                };
                actorPositions.Execute();

                //Position Party Member 3
                actorPositions = new Transition {
                    ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { (short)(formation[2] + 1) }, Target_x = -28.332f, Target_y = 0.0f, Target_z = -42.0f
                };
                actorPositions.Execute();

                Stage += 1;

                process.Resume();
            }
            else if (base.memoryWatchers.SeymourTransition2.Current == (BaseCutsceneValue + 0x77D6) && Stage == 2)
            {
                process.Suspend();
                WriteValue <int>(base.memoryWatchers.SeymourTransition2, BaseCutsceneValue + 0x7F85);

                Stage += 1;

                process.Resume();
            }
            else if (base.memoryWatchers.Menu.Current == 1 && base.memoryWatchers.CutsceneAlt.Current == 0 && Stage == 3)
            {
                process.Suspend();

                new Transition {
                    Storyline = 1545, ConsoleOutput = false, PositionTidusAfterLoad = true, Target_x = 1.470157981f, Target_y = 0.0f, Target_z = 0.3889299929f, Target_rot = -0.1195230484f, Target_var1 = 53
                }.Execute();

                Stage += 1;

                process.Resume();
            }
        }
        public void MainLoop()
        {
            while (true)
            {
                ConnectToTarget();

                if (Game == null)
                {
                    continue;
                }

                MemoryWatchers.Initialize(Game);

                Console.WriteLine("Starting main loop!");
                while (!Game.HasExited)
                {
                    if (PrintDebugValues)
                    {
                        MemoryWatchers.Watchers.UpdateAll(Game);
                        MemoryWatcherList watchers = MemoryWatchers.Watchers;

                        // Report the current status of all of our watched memory. For debug purposes
                        foreach (MemoryWatcher watcher in watchers)
                        {
                            Console.WriteLine(watcher.Name + ": " + watcher.Current);
                        }
                    }

                    /* This loop iterates over the list of standard transitions
                     * and applies them when necessary. Most transitions can be performed here.*/
                    Dictionary <IGameState, Transition> standardTransitions = Transitions.StandardTransitions;
                    foreach (var transition in standardTransitions)
                    {
                        if (transition.Key.CheckState())
                        {
                            transition.Value.Execute();
                            Console.WriteLine("Executing Standard Transition");
                        }
                    }

                    /* Loop for post boss fights transitions. Once we enter the fight we set the boss bit and the transition
                     * to perform once we exit the AP menu. */
                    Dictionary <IGameState, Transition> postBossBattleTransitions = Transitions.PostBossBattleTransitions;
                    if (!InBossFight)
                    {
                        foreach (var transition in postBossBattleTransitions)
                        {
                            if (transition.Key.CheckState())
                            {
                                InBossFight             = true;
                                PostBossFightTransition = transition.Value;
                                Console.WriteLine("Entered Boss Fight");
                            }
                        }
                    }
                    else if (new GameState {
                        Menu = 0
                    }.CheckState() && MemoryWatchers.Menu.Old == 1)
                    {
                        PostBossFightTransition.Execute();
                        InBossFight             = false;
                        PostBossFightTransition = null;
                        Console.WriteLine("Executing Post Boss Fight Transition");
                    }

                    // SPECIAL CHECKS

                    /*
                     * A GameState object is created in order to verify the current state of the game
                     * based on the inputs provided. Inputs not provided will be ignored.
                     * Once the CheckState() returns true, indicating the game is in the state we want,
                     * then a Transition object is created with inputs required to execute the transition.
                     * The Execute() method causes the transition to write the updated values to memory.
                     *
                     * IF YOU ONLY NEED TO CHECK IF ADDRESSES ARE CERTAIN VALUES (ALMOST ALL CASES), THEN ADD YOUR
                     * TRANSITION INTO THE 'Resources\Transitions.cs' FILE.
                     *
                     * Rarely there are conditions where the check we want is not equality. In that case you can write your
                     * own condition. An example is below.
                     */
                    // Soft reset by holding L1 R1 L2 R2 + Start - Disabled in battle because game crashes
                    if (new GameState {
                        Input = 2063
                    }.CheckState() && MemoryWatchers.BattleState.Current != 10)
                    {
                        new Transition {
                            RoomNumber = 23, BattleState = 778
                        }.Execute();
                    }
                }
            }
        }
示例#26
0
        public override void Execute(string defaultDescription = "")
        {
            Process process = memoryWatchers.Process;

            if (base.memoryWatchers.CrawlerTransition.Current > 0)
            {
                if (CutsceneAltList.Contains(base.memoryWatchers.CutsceneAlt.Current) && Stage == 0)
                {
                    base.Execute();

                    BaseCutsceneValue = base.memoryWatchers.CrawlerTransition.Current;

                    Stage += 1;
                }
                //First 4 stages are an attempt to emulate the logic from the PS2 Pnach. Values don't line up perfectly but it works.
                else if (base.memoryWatchers.CrawlerTransition.Current == (BaseCutsceneValue + 0x11) && Stage == 1)
                {
                    WriteValue <int>(base.memoryWatchers.CrawlerTransition, BaseCutsceneValue + 0x466);
                    Stage += 1;
                }
                else if (base.memoryWatchers.CrawlerTransition.Current >= (BaseCutsceneValue + 0x47C) && Stage == 2)
                {
                    WriteValue <int>(base.memoryWatchers.CrawlerTransition, BaseCutsceneValue + 0x542);
                    Stage += 1;
                }
                else if (base.memoryWatchers.CrawlerTransition.Current >= (BaseCutsceneValue + 0x54B) && Stage == 3)
                {
                    WriteValue <int>(base.memoryWatchers.CrawlerTransition, BaseCutsceneValue + 0x562);
                    Stage += 1;
                }
                else if (base.memoryWatchers.CrawlerTransition.Current >= (BaseCutsceneValue + 0x562) && Stage == 4)
                {
                    WriteValue <int>(base.memoryWatchers.CrawlerTransition, BaseCutsceneValue + 0x5ED);
                    Stage += 1;
                }
                else if (base.memoryWatchers.CrawlerTransition.Current == (BaseCutsceneValue + 0x635) && base.memoryWatchers.HpEnemyA.Current < 16000 && base.memoryWatchers.HpEnemyA.Old == 16000 && Stage == 5)
                {
                    WriteValue <int>(base.memoryWatchers.CrawlerTransition, BaseCutsceneValue + 0x886);
                    Stage += 1;
                }

                //A value of +0x886 launches the end of the fight straight into results screen which seems to be the only way to not crash the game post battle.
                //This causes a menu glitch if game is allowed to progress past the item rewards screen so the next stage removes the menu flag once gil has finished
                //ticking and the game will process Crawler post boss logic

                else if (base.memoryWatchers.Gil.Current > base.memoryWatchers.Gil.Old && Stage == 6)
                {
                    Stage += 1;
                }
                else if (base.memoryWatchers.Gil.Current == base.memoryWatchers.Gil.Old && Stage == 7)
                {
                    process.Suspend();

                    Transition FormationSwitch = new Transition {
                        ForceLoad = false, ConsoleOutput = false, FormationSwitch = Transition.formations.PostCrawler, Description = "Fix party after Crawler"
                    };
                    FormationSwitch.Execute();

                    Transition ExitMenu = new Transition {
                        Menu = 0, Description = "Exit Menu", ForceLoad = false
                    };
                    ExitMenu.Execute();

                    Stage += 1;

                    process.Resume();
                }
            }
        }
示例#27
0
        public override void Execute(string defaultDescription = "")
        {
            Process process = memoryWatchers.Process;

            if (Stage == 0)
            {
                base.Execute();

                BaseCutsceneValue = base.memoryWatchers.EventFileStart.Current;
                Stage            += 1;
            }
            else if (base.memoryWatchers.GeosTransition.Current == (BaseCutsceneValue + 0xA4F8) && Stage == 1)
            {
                process.Suspend();

                new Transition {
                    EncounterMapID = 1, EncounterFormationID = 0, ScriptedBattleFlag1 = 1, ScriptedBattleFlag2 = 1, ScriptedBattleVar1 = 0x00014501, EncounterTrigger = 2, Description = "Sahagins", ForceLoad = false
                }.Execute();

                Transition actorPositions;
                //Position Tidus
                actorPositions = new Transition {
                    ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { 1 }, Target_x = 0.0f, Target_y = -50.0f, Target_z = -20.0f
                };
                actorPositions.Execute();

                Stage += 1;

                process.Resume();
            }
            else if (base.memoryWatchers.BattleState2.Current == 22 && Stage == 2)
            {
                Stage += 1;
            }
            else if (base.memoryWatchers.BattleState2.Current == 0 && Stage == 3)
            {
                process.Suspend();

                new Transition {
                    EncounterMapID = 1, EncounterFormationID = 1, ScriptedBattleFlag1 = 1, ScriptedBattleFlag2 = 1, ScriptedBattleVar1 = 0x00010501, EncounterTrigger = 2, Description = "Geosgaeno", ForceLoad = false
                }.Execute();

                Stage += 1;

                process.Resume();
            }
            else if (base.memoryWatchers.BattleState2.Current == 22 && Stage == 4)
            {
                Transition actorPositions;
                //Position Tidus
                actorPositions = new Transition {
                    ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { 1 }, Target_x = 0.0f, Target_y = -50.0f, Target_z = -20.0f
                };
                actorPositions.Execute();

                Stage += 1;
            }
            else if (base.memoryWatchers.BattleState2.Current == 0 && Stage == 5)
            {
                process.Suspend();

                new Transition {
                    RoomNumber = 50, Storyline = 48, SpawnPoint = 0, Description = "Escape from Geogaesno"
                }.Execute();

                Stage += 1;

                process.Resume();
            }
        }
示例#28
0
        public override void Execute(string defaultDescription = "")
        {
            Process process = memoryWatchers.Process;

            if (base.memoryWatchers.FrameCounterFromLoad.Current > 10 && Stage == 0)
            {
                process.Suspend();

                //base.Execute();

                new Transition
                {
                    EncounterMapID       = 86,
                    EncounterFormationID = 0,
                    ScriptedBattleFlag1  = 1,
                    ScriptedBattleFlag2  = 1,
                    ScriptedBattleVar1   = 0x00014504,
                    ScriptedBattleVar3   = 0x000002A1,
                    ScriptedBattleVar4   = 0x00000014,
                    EncounterTrigger     = 2,
                    Description          = "Tanker",
                    ForceLoad            = false
                }.Execute();

                Transition actorPositions;
                actorPositions = new Transition {
                    ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { 1 }, Target_x = 251.9134674f, Target_y = 0.005895767361f, Target_z = -24.76922226f
                };
                actorPositions.Execute();

                actorPositions = new Transition {
                    ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { 3 }, Target_x = 251.2454987f, Target_y = 0.005895767361f, Target_z = 20.62436295f
                };
                actorPositions.Execute();

                Stage += 1;

                process.Resume();
            }
            else if (base.memoryWatchers.BattleState2.Current == 22 && Stage == 1)
            {
                Stage += 1;
            }
            else if (base.memoryWatchers.BattleState2.Current == 1 && Stage == 2)
            {
                Stage += 1;
            }
            else if (base.memoryWatchers.BattleState2.Current == 0 && Stage == 3)
            {
                process.Suspend();

                new Transition {
                    RoomNumber = 367, Storyline = 19, Description = "Post Tanker"
                }.Execute();

                Stage += 1;

                process.Resume();

                DiagnosticLog.Information("Test");
            }
        }
        public override void Execute(string defaultDescription = "")
        {
            Process process = memoryWatchers.Process;

            if (base.memoryWatchers.AltanaTransition.Current > 0)
            {
                if (Stage == 0)
                {
                    base.Execute();

                    BaseCutsceneValue = base.memoryWatchers.AltanaTransition.Current;
                    Stage            += 1;
                }
                else if (base.memoryWatchers.AltanaTransition.Current == (BaseCutsceneValue + 0x69) && Stage == 1) // CC
                {
                    WriteValue <int>(base.memoryWatchers.AltanaTransition, BaseCutsceneValue + 0x307);             //

                    formation = process.ReadBytes(base.memoryWatchers.Formation.Address, 3);

                    Transition actorPositions;
                    //Position Party Member 1
                    actorPositions = new Transition {
                        ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { (short)(formation[0] + 1) }, Target_x = 998.0f, Target_y = -30.0f, Target_z = -1474.0f
                    };
                    actorPositions.Execute();

                    //Position Party Member 2
                    actorPositions = new Transition {
                        ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { (short)(formation[1] + 1) }, Target_x = 998.0f, Target_y = -30.0f, Target_z = -1444.0f
                    };
                    actorPositions.Execute();

                    //Position Party Member 3
                    actorPositions = new Transition {
                        ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { (short)(formation[2] + 1) }, Target_x = 998.0f, Target_y = -30.0f, Target_z = -1414.0f
                    };
                    actorPositions.Execute();

                    Stage += 1;
                }
                else if (base.memoryWatchers.AltanaTransition.Current == (BaseCutsceneValue + 0x32C) && Stage == 2) // This is a filler stage which only serves to facilitate fight end logic
                {
                    Stage += 1;
                }/*/
                  * else if (base.memoryWatchers.AltanaTransition.Current == (BaseCutsceneValue + 0x50E) && Stage == 3)
                  * {
                  * DiagnosticLog.Information("Stage: " + Stage.ToString());
                  * WriteValue<int>(base.memoryWatchers.AltanaTransition, BaseCutsceneValue + 0x709);
                  *
                  * Stage += 1;
                  * }
                  * else if (base.memoryWatchers.AltanaTransition.Current == (BaseCutsceneValue + 0x72B) && Stage == 4)
                  * {
                  * DiagnosticLog.Information("Stage: " + Stage.ToString());
                  *
                  * Transition actorPositions;
                  * //Position Party Member 1
                  * actorPositions = new Transition { ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { (short)(formation[0] + 1) }, Target_x = 529.0f, Target_y = -30.0f, Target_z = -828.0f };
                  * actorPositions.Execute();
                  *
                  * //Position Party Member 2
                  * actorPositions = new Transition { ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { (short)(formation[1] + 1) }, Target_x = 569.0f, Target_y = -30.0f, Target_z = -828.0f };
                  * actorPositions.Execute();
                  *
                  * //Position Party Member 3
                  * actorPositions = new Transition { ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { (short)(formation[2] + 1) }, Target_x = 609.0f, Target_y = -30.0f, Target_z = -828.0f };
                  * actorPositions.Execute();
                  *
                  * //Position Evrae Altana
                  * actorPositions = new Transition { ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { 4216 }, Target_x = 569.0f, Target_y = -30.0f, Target_z = -988.0f };
                  * actorPositions.Execute();
                  *
                  * //Position Lock Pin Left
                  * actorPositions = new Transition { ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { 4267 }, Target_x = 528.7f, Target_y = -10.0f, Target_z = -790.7f };
                  * actorPositions.Execute();
                  *
                  * //Position Lock Pin Right
                  * actorPositions = new Transition { ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { 162 }, Target_x = 611.3f, Target_y = -10.0f, Target_z = -790.7f };
                  * actorPositions.Execute();
                  *
                  * Stage += 1;
                  * }
                  * else if (base.memoryWatchers.AltanaTransition.Current == (BaseCutsceneValue + 0x8EE) && Stage == 5) // 50E
                  * {
                  * DiagnosticLog.Information("Stage: " + Stage.ToString());
                  * WriteValue<int>(base.memoryWatchers.AltanaTransition, BaseCutsceneValue + 0x94A);// 96B
                  *
                  * WriteValue<int>(base.memoryWatchers.Camera, 0);
                  * Stage += 1;
                  * }
                  * else if (base.memoryWatchers.AltanaTransition.Current == (BaseCutsceneValue + 0xA16) && Stage == 6)
                  * {
                  * DiagnosticLog.Information("Stage: " + Stage.ToString());
                  *
                  * Transition actorPositions;
                  * //Position Party Member 1
                  * actorPositions = new Transition { ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { (short)(formation[0] + 1) }, Target_x = 378.582f, Target_y = -43.0f, Target_z = -234.134f };
                  * actorPositions.Execute();
                  *
                  * //Position Party Member 2
                  * actorPositions = new Transition { ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { (short)(formation[1] + 1) }, Target_x = 368.730f, Target_y = -70.0f, Target_z = -260.191f };
                  * actorPositions.Execute();
                  *
                  * //Position Party Member 3
                  * actorPositions = new Transition { ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { (short)(formation[2] + 1) }, Target_x = 338.239f, Target_y = -37.0f, Target_z = -328.214f };
                  * actorPositions.Execute();
                  *
                  * //Position Evrae Altana
                  * actorPositions = new Transition { ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { 4216 }, Target_x = 613.0f, Target_y = -35.0f, Target_z = -281.0f };
                  * actorPositions.Execute();
                  *
                  * Stage += 1;
                  * }//*/
                else if (base.memoryWatchers.BattleState.Current == 522 && Stage == 7)
                {
                    WriteValue <int>(base.memoryWatchers.AltanaTransition, BaseCutsceneValue + 0xA7D);//
                    Stage = 99;
                }
                else if (base.memoryWatchers.BattleState.Current == 522 && Stage == 5)
                {
                    WriteValue <int>(base.memoryWatchers.AltanaTransition, BaseCutsceneValue + 0x7A2);// Camera is jank if ending fight in second room. Need to work out how to move camera.
                    Stage = 98;
                }
                else if (base.memoryWatchers.BattleState.Current == 522 && Stage == 3)
                {
                    WriteValue <int>(base.memoryWatchers.AltanaTransition, BaseCutsceneValue + 0x3A9);//
                    Stage = 99;
                }
                else if (base.memoryWatchers.Menu.Current == 0 && base.memoryWatchers.Menu.Old == 1 && Stage == 98)
                {
                    Transition actorPositions;
                    //Position Tidus
                    actorPositions = new Transition {
                        ForceLoad = false, ConsoleOutput = false, TargetActorIDs = new short[] { 1 }, Target_x = 529.320f, Target_y = -30.0f, Target_z = -830.060f
                    };
                    actorPositions.Execute();

                    Stage = 99;
                }
            }
        }