// Token: 0x060032A7 RID: 12967 RVA: 0x0011A35C File Offset: 0x0011855C
        public override StateGraph CreateGraph()
        {
            StateGraph          stateGraph          = new StateGraph();
            LordToil_DefendBase lordToil_DefendBase = new LordToil_DefendBase(this.baseCenter);

            stateGraph.StartingToil = lordToil_DefendBase;
            LordToil_DefendBase lordToil_DefendBase2 = new LordToil_DefendBase(this.baseCenter);

            stateGraph.AddToil(lordToil_DefendBase2);
            LordToil_AssaultColony lordToil_AssaultColony = new LordToil_AssaultColony(true);

            lordToil_AssaultColony.useAvoidGrid = true;
            stateGraph.AddToil(lordToil_AssaultColony);
            Transition transition = new Transition(lordToil_DefendBase, lordToil_DefendBase2, false, true);

            transition.AddSource(lordToil_AssaultColony);
            transition.AddTrigger(new Trigger_BecameNonHostileToPlayer());
            stateGraph.AddTransition(transition, false);
            Transition transition2 = new Transition(lordToil_DefendBase2, lordToil_DefendBase, false, true);

            transition2.AddTrigger(new Trigger_BecamePlayerEnemy());
            stateGraph.AddTransition(transition2, false);
            Transition transition3 = new Transition(lordToil_DefendBase, lordToil_AssaultColony, false, true);

            transition3.AddTrigger(new Trigger_FractionPawnsLost(0.2f));
            transition3.AddTrigger(new Trigger_PawnHarmed(0.4f, false, null));
            transition3.AddTrigger(new Trigger_ChanceOnTickInterval(2500, 0.03f));
            transition3.AddTrigger(new Trigger_TicksPassed(251999));
            transition3.AddTrigger(new Trigger_ChanceOnPlayerHarmNPCBuilding(0.4f));
            transition3.AddTrigger(new Trigger_OnClamor(ClamorDefOf.Ability));
            transition3.AddPostAction(new TransitionAction_WakeAll());
            TaggedString taggedString = "MessageDefendersAttacking".Translate(this.faction.def.pawnsPlural, this.faction.Name, Faction.OfPlayer.def.pawnsPlural).CapitalizeFirst();

            transition3.AddPreAction(new TransitionAction_Message(taggedString, MessageTypeDefOf.ThreatBig, null, 1f));
            stateGraph.AddTransition(transition3, false);
            return(stateGraph);
        }
        // Token: 0x0600319A RID: 12698 RVA: 0x00114360 File Offset: 0x00112560
        public override StateGraph CreateGraph()
        {
            StateGraph stateGraph = new StateGraph();
            LordToil_DefendAndExpandHive lordToil_DefendAndExpandHive = new LordToil_DefendAndExpandHive();

            lordToil_DefendAndExpandHive.distToHiveToAttack = 10f;
            stateGraph.StartingToil = lordToil_DefendAndExpandHive;
            LordToil_DefendHiveAggressively lordToil_DefendHiveAggressively = new LordToil_DefendHiveAggressively();

            lordToil_DefendHiveAggressively.distToHiveToAttack = 40f;
            stateGraph.AddToil(lordToil_DefendHiveAggressively);
            LordToil_AssaultColony lordToil_AssaultColony = new LordToil_AssaultColony(false);

            stateGraph.AddToil(lordToil_AssaultColony);
            Transition transition = new Transition(lordToil_DefendAndExpandHive, this.aggressive ? (LordToil)lordToil_AssaultColony : lordToil_DefendHiveAggressively, false, true);

            transition.AddTrigger(new Trigger_Memo(Hive.MemoAssaultOnSpawn));
            transition.AddTrigger(new Trigger_PawnHarmed(0.5f, true, null));
            transition.AddTrigger(new Trigger_PawnLostViolently(false));
            transition.AddTrigger(new Trigger_Memo(RimWorld.Hive.MemoAttackedByEnemy));
            transition.AddTrigger(new Trigger_Memo(Hive.MemoAttackedByEnemy));
            transition.AddTrigger(new Trigger_Memo(RimWorld.Hive.MemoBurnedBadly));
            transition.AddTrigger(new Trigger_Memo(Hive.MemoBurnedBadly));
            transition.AddTrigger(new Trigger_Memo(RimWorld.Hive.MemoDestroyedNonRoofCollapse));
            transition.AddTrigger(new Trigger_Memo(Hive.MemoDestroyedNonRoofCollapse));
            transition.AddTrigger(new Trigger_Memo(HediffGiver_Heat.MemoPawnBurnedByAir));
            transition.AddPostAction(new TransitionAction_EndAllJobs());
            stateGraph.AddTransition(transition, false);
            Transition transition2 = new Transition(lordToil_DefendAndExpandHive, lordToil_AssaultColony, false, true);

            transition2.AddTrigger(new Trigger_PawnHarmed(0.5f, false, base.Map.ParentFaction));
            transition2.AddPostAction(new TransitionAction_EndAllJobs());
            stateGraph.AddTransition(transition2, false);
            Transition transition3 = new Transition(lordToil_DefendHiveAggressively, lordToil_AssaultColony, false, true);

            transition3.AddTrigger(new Trigger_PawnHarmed(0.5f, false, base.Map.ParentFaction));
            transition3.AddPostAction(new TransitionAction_EndAllJobs());
            stateGraph.AddTransition(transition3, false);
            Transition transition4 = new Transition(lordToil_DefendAndExpandHive, lordToil_DefendAndExpandHive, true, true);

            transition4.AddTrigger(new Trigger_Memo(RimWorld.Hive.MemoDeSpawned));
            transition4.AddTrigger(new Trigger_Memo(Hive.MemoDeSpawned));
            stateGraph.AddTransition(transition4, false);
            Transition transition5 = new Transition(lordToil_DefendHiveAggressively, lordToil_DefendHiveAggressively, true, true);

            transition5.AddTrigger(new Trigger_Memo(RimWorld.Hive.MemoDeSpawned));
            transition5.AddTrigger(new Trigger_Memo(Hive.MemoDeSpawned));
            stateGraph.AddTransition(transition5, false);
            Transition transition6 = new Transition(lordToil_AssaultColony, lordToil_DefendAndExpandHive, false, true);

            transition6.AddSource(lordToil_DefendHiveAggressively);
            transition6.AddTrigger(new Trigger_TicksPassedWithoutHarmOrMemos(1200, new string[]
            {
                RimWorld.Hive.MemoAttackedByEnemy,
                Hive.MemoAttackedByEnemy,
                RimWorld.Hive.MemoBurnedBadly,
                Hive.MemoBurnedBadly,
                RimWorld.Hive.MemoDestroyedNonRoofCollapse,
                Hive.MemoDestroyedNonRoofCollapse,
                RimWorld.Hive.MemoDeSpawned,
                Hive.MemoDeSpawned,

                HediffGiver_Heat.MemoPawnBurnedByAir
            }));
            transition6.AddPostAction(new TransitionAction_EndAttackBuildingJobs());
            stateGraph.AddTransition(transition6, false);
            return(stateGraph);
        }