Exemplo n.º 1
0
        internal static void AddQuestEntities(WalkerDetail walkerDetail, DataSet dataSet, List <Fox2EntityClass> entityList)
        {
            List <WalkerGear> walkers = walkerDetail.walkers;

            if (walkers.Count() > 0)
            {
                GameObject TppCommonWalkerGear2 = new GameObject("WalkerGearGameObject", dataSet, "TppCommonWalkerGear2", walkers.Count(), walkers.Count());
                TppWalkerGear2Parameter walkerGear2Parameter = new TppWalkerGear2Parameter(TppCommonWalkerGear2);

                TppCommonWalkerGear2.SetParameter(walkerGear2Parameter);

                entityList.Add(TppCommonWalkerGear2);
                entityList.Add(walkerGear2Parameter);

                foreach (WalkerGear walker in walkers)
                {
                    GameObjectLocator walkerLocator   = new GameObjectLocator(walker.GetObjectName(), dataSet, "TppCommonWalkerGear2");
                    Transform         walkerTransform = new Transform(walkerLocator, walker.position);
                    TppWalkerGear2LocatorParameter walkerLocatorParameter = new TppWalkerGear2LocatorParameter(walkerLocator);

                    walkerLocator.SetTransform(walkerTransform);
                    walkerLocator.SetParameter(walkerLocatorParameter);

                    entityList.Add(walkerLocator);
                    entityList.Add(walkerTransform);
                    entityList.Add(walkerLocatorParameter);
                }
            }
        }
Exemplo n.º 2
0
        internal static void GetDefinition(WalkerDetail walkerDetail, DefinitionLua definitionLua)
        {
            int walkerCount = walkerDetail.walkers.Count;

            if (walkerCount > 0)
            {
                definitionLua.AddPackPath("/Assets/tpp/pack/mission2/common/mis_com_walkergear.fpk");
            }
        }
Exemplo n.º 3
0
        private static Table BuildWalkerList(WalkerDetail walkerDetail)
        {
            Table             walkerList = new Table("walkerList");
            List <WalkerGear> walkers    = walkerDetail.walkers;
            WalkerMetadata    meta       = walkerDetail.walkerMetadata;

            foreach (WalkerGear walker in walkers)
            {
                walkerList.Add($@"
        {{
            walkerName = ""{walker.GetObjectName()}"",{(walker.pilot.Equals("NONE") ? "" : $@"
            riderName = ""{walker.pilot}"",")}
            colorType = {GetEnum(walker.paint)},
Exemplo n.º 4
0
        internal static void GetMain(WalkerDetail detail, MainLua mainLua)
        {
            List <WalkerGear> walkers = detail.walkers;
            WalkerMetadata    meta    = detail.walkerMetadata;

            if (detail.walkers.Count > 0)
            {
                mainLua.AddToOpeningVariables("questWalkerGearList", "{}");
                mainLua.AddToOpeningVariables("playerWGResetPosition");
                mainLua.AddToOpeningVariables("walkerGearGameId");
                mainLua.AddToOpeningVariables("inMostActiveQuestArea", "true");
                mainLua.AddToOpeningVariables("exitOnce", "true");

                mainLua.AddToQuestTable(BuildWalkerList(detail));

                mainLua.AddToAuxiliary(OneTimeAnnounce);
                mainLua.AddToAuxiliary(ReboundWalkerGear);
                mainLua.AddToQStep_Main(ExitTrap, EnterTrap, FinishTimerActiveArea, FinishTimerCooldown);
                mainLua.AddToQStep_Main(QStep_MainCommonMessages.mechaCaptureTargetMessages);

                mainLua.AddToAuxiliary("local setupOnce = true");
                mainLua.AddToOnUpdate("setupOnce = this.SetupGearsQuest(setupOnce)");
                mainLua.AddToAuxiliary(SetupGearsQuest);

                mainLua.AddToQStep_Start_OnEnter(BuildWalkerGameObjectIdList);
                mainLua.AddToAuxiliary(BuildWalkerGameObjectIdList);

                if (walkers.Any(walker => walker.isTarget))
                {
                    CheckQuestGenericEnemy checkQuestMethod = new CheckQuestGenericEnemy(mainLua, checkWalkerGear, meta.objectiveType);
                    foreach (WalkerGear walker in walkers)
                    {
                        if (walker.isTarget)
                        {
                            mainLua.AddToTargetList(walker.GetObjectName());
                        }
                    }
                }
            }
        }
Exemplo n.º 5
0
 public WalkerManager(WalkerDetail detail) : base(detail, walkerVisualizer)
 {
 }