public static IEnumerable <FloatMenuOption> GetFloatMenuOptions(Caravan caravan, AnnualExpo annualExpo)
 {
     return(CaravanArrivalActionUtility.GetFloatMenuOptions(acceptanceReportGetter: () => CanVisit(caravan, annualExpo),
                                                            arrivalActionGetter: () => new CaravanArrivalAction_VisitAnnualExpo(annualExpo),
                                                            label: "VisitPeaceTalks".Translate(annualExpo.Label),
                                                            caravan: caravan, pathDestination: annualExpo.Tile,
                                                            revalidateWorldClickTarget: annualExpo));
 }
Exemplo n.º 2
0
 public static IEnumerable <FloatMenuOption> GetFloatMenuOptions(Caravan caravan, MysticalShaman mysticalShaman)
 {
     return(CaravanArrivalActionUtility.GetFloatMenuOptions(acceptanceReportGetter: () => CanVisit(caravan: caravan, mysticalShaman: mysticalShaman),
                                                            arrivalActionGetter: () => new CaravanArrivalAction_VisitMysticalShaman(mysticalShaman: mysticalShaman),
                                                            label: "VisitPeaceTalks".Translate(mysticalShaman.Label),
                                                            caravan: caravan, pathDestination: mysticalShaman.Tile,
                                                            revalidateWorldClickTarget: mysticalShaman));
 }
 public static IEnumerable <FloatMenuOption> GetFloatMenuOptions(Caravan caravan, AnnualExpo annualExpo)
 {
     return(CaravanArrivalActionUtility.GetFloatMenuOptions(() => CanVisit(annualExpo),
                                                            () => new CaravanArrivalAction_VisitAnnualExpo(annualExpo),
                                                            "VisitPeaceTalks".Translate(annualExpo.Label),
                                                            caravan, annualExpo.Tile,
                                                            annualExpo));
 }
 public static IEnumerable <FloatMenuOption> GetFloatMenuOptions(Caravan caravan,
                                                                 FactionWarPeaceTalks factionWarPeaceTalks)
 {
     return(CaravanArrivalActionUtility.GetFloatMenuOptions(() => CanVisit(factionWarPeaceTalks),
                                                            () => new CaravanArrivalAction_VisitFactionWarPeaceTalks(factionWarPeaceTalks),
                                                            "VisitPeaceTalks".Translate(factionWarPeaceTalks.Label),
                                                            caravan, factionWarPeaceTalks.Tile,
                                                            factionWarPeaceTalks));
 }
 public static IEnumerable <FloatMenuOption> GetFloatMenuOptions(Caravan caravan, MysticalShaman mysticalShaman)
 {
     return(CaravanArrivalActionUtility.GetFloatMenuOptions(
                () => CanVisit(mysticalShaman),
                () => new CaravanArrivalAction_VisitMysticalShaman(mysticalShaman),
                "VisitPeaceTalks".Translate(mysticalShaman.Label),
                caravan, mysticalShaman.Tile,
                mysticalShaman));
 }
Exemplo n.º 6
0
 public static IEnumerable <FloatMenuOption> GetFloatMenuOptions(Caravan caravan, FactionWarPeaceTalks factionWarPeaceTalks)
 {
     return(CaravanArrivalActionUtility.GetFloatMenuOptions(acceptanceReportGetter:
                                                            () => CanVisit(caravan: caravan, factionWarPeaceTalks: factionWarPeaceTalks), arrivalActionGetter:
                                                            () => new CaravanArrivalAction_VisitFactionWarPeaceTalks(factionWarPeaceTalks: factionWarPeaceTalks),
                                                            label: "VisitPeaceTalks".Translate(factionWarPeaceTalks.Label),
                                                            caravan: caravan, pathDestination: factionWarPeaceTalks.Tile,
                                                            revalidateWorldClickTarget: factionWarPeaceTalks));
 }
 public static IEnumerable <FloatMenuOption> GetFloatMenuOptions(
     Caravan caravan,
     WorldSettlementFC settlement)
 {
     return(CaravanArrivalActionUtility.GetFloatMenuOptions(
                () => settlement.Spawned && settlement.settlement.isUnderAttack,
                () => new WorldSettlementDefendAction(settlement),
                "DefendColony".Translate(), caravan,
                settlement.Tile, settlement));
 }
Exemplo n.º 8
0
        public override IEnumerable <FloatMenuOption> GetFloatMenuOptions(Caravan caravan)
        {
            if (Faction.PlayerRelationKind == FactionRelationKind.Hostile)
            {
                foreach (var act in CaravanArrivalActionUtility.GetFloatMenuOptions(() => caravanAction.CanAttack(caravan, this), () => caravanAction, caravanAction.Label, caravan, Tile, this))
                {
                    yield return(act);
                }
            }

            yield break;
        }
Exemplo n.º 9
0
 public override IEnumerable <FloatMenuOption> GetFloatMenuOptions(Caravan caravan, MapParent mapParent)
 {
     if (!Visited)
     {
         CaravanArrivalAction_EnterToQuestMapBasic caravanArrivalAction_EnterToQuestMapBasic = new CaravanArrivalAction_EnterToQuestMapBasic(mapParent);
         return(CaravanArrivalActionUtility.GetFloatMenuOptions(() => true, () => caravanArrivalAction_EnterToQuestMapBasic, "EnterMap".Translate(mapParent.Label), caravan, mapParent.Tile, mapParent));
     }
     else
     {
         CaravanArrivalAction_TransferPrisoners caravanArrivalAction_TransferPrisoners = new CaravanArrivalAction_TransferPrisoners(mapParent, this);
         return(CaravanArrivalActionUtility.GetFloatMenuOptions(() => caravanArrivalAction_TransferPrisoners.CanVisit(caravan), () => caravanArrivalAction_TransferPrisoners, "TransferPrisoners".Translate(), caravan, mapParent.Tile, mapParent));
     }
 }
Exemplo n.º 10
0
        public override IEnumerable <FloatMenuOption> GetFloatMenuOptions(Caravan caravan)
        {
            if (!CompStarted)
            {
                CaravanArrivalAction_StartCompetitions caravanArrivalAction = new CaravanArrivalAction_StartCompetitions(this);
                foreach (var p in CaravanArrivalActionUtility.GetFloatMenuOptions(() => caravanArrivalAction.CanVisit(caravan), () => caravanArrivalAction, "EnterToCompetitions".Translate(), caravan, Tile, this))
                {
                    yield return(p);
                }
            }

            yield break;
        }
Exemplo n.º 11
0
        public override IEnumerable <FloatMenuOption> GetFloatMenuOptions(Caravan caravan, MapParent mapParent)
        {
            foreach (var option in CaravanArrivalActionUtility.GetFloatMenuOptions(() => caravanAction.CanVisit(caravan, mapParent), () => caravanAction, "EnterMap".Translate(mapParent.Label), caravan, mapParent.Tile, mapParent))
            {
                yield return(option);
            }

            int  reqCount  = 50000 - comp.FactionSilver;
            bool hasSilver = CaravanInventoryUtility.HasThings(caravan, ThingDefOf.Silver, reqCount);

            foreach (var option in CaravanArrivalActionUtility.GetFloatMenuOptions(() => caravanAction2.CanGiveRansom(caravan, mapParent), () => caravanAction2, hasSilver ? "GiveRansom".Translate() : "NotEnoughSilverDoom".Translate(), caravan, mapParent.Tile, mapParent))
            {
                yield return(option);
            }
        }
Exemplo n.º 12
0
 public override IEnumerable <FloatMenuOption> GetFloatMenuOptions(Caravan caravan, MapParent mapParent)
 {
     if (saved)
     {
         CaravanArrivalAction_TransferMissingPeople caravanAction2 = new CaravanArrivalAction_TransferMissingPeople(mapParent, this);
         foreach (var opt in CaravanArrivalActionUtility.GetFloatMenuOptions(() => true, () => caravanAction2, "Quest_CheckMissingPeople_Action2".Translate(), caravan, mapParent.Tile, mapParent))
         {
             yield return(opt);
         }
     }
     else
     {
         CaravanArrivalAction_CheckMissingPeople caravanAction = new CaravanArrivalAction_CheckMissingPeople(mapParent, this);
         foreach (var opt in CaravanArrivalActionUtility.GetFloatMenuOptions(() => true, () => caravanAction, "Quest_CheckMissingPeople_Action".Translate(), caravan, mapParent.Tile, mapParent))
         {
             yield return(opt);
         }
     }
 }
        public override IEnumerable <FloatMenuOption> GetFloatMenuOptions(Caravan caravan, MapParent mapParent)
        {
            CaravanArrivalAction_StartResearchSharing action = new CaravanArrivalAction_StartResearchSharing(mapParent, this);

            return(CaravanArrivalActionUtility.GetFloatMenuOptions(() => action.CanUse(caravan), () => action, CardLabel, caravan, mapParent.Tile, mapParent));
        }
Exemplo n.º 14
0
        public override IEnumerable <FloatMenuOption> GetFloatMenuOptions(Caravan caravan, MapParent mapParent)
        {
            CaravanArrivalAction_HelpWithBuildings caravanAction = new CaravanArrivalAction_HelpWithBuildings(mapParent, this);

            return(CaravanArrivalActionUtility.GetFloatMenuOptions(() => caravanAction.CanHelp(caravan, mapParent), () => caravanAction, "Quest_HelpWithBuilding_Option".Translate(), caravan, mapParent.Tile, mapParent));
        }
Exemplo n.º 15
0
        public override IEnumerable <FloatMenuOption> GetFloatMenuOptions(Caravan caravan)
        {
            CaravanArrivalAction_EnterToMapWithGenerator caravanAction = new CaravanArrivalAction_EnterToMapWithGenerator(this, MapGenerator);

            return(CaravanArrivalActionUtility.GetFloatMenuOptions(() => true, () => caravanAction, "EnterToMap_Option".Translate(Label), caravan, this.Tile, this));
        }
 public static IEnumerable <FloatMenuOption> GetFloatMenuOptions(Caravan caravan, DockedBoat dockedBoat)
 {
     return(CaravanArrivalActionUtility.GetFloatMenuOptions(() => CanVisit(caravan, dockedBoat), () => new CaravanArrivalAction_DockedBoats(dockedBoat),
                                                            "CommandUndockShip".Translate(dockedBoat.Label), caravan, dockedBoat.Tile, dockedBoat));
 }
 public static IEnumerable <FloatMenuOption> GetFloatMenuOptions(Caravan caravan, MapParent mapParent)
 {
     return(CaravanArrivalActionUtility.GetFloatMenuOptions(() => CanEnter(caravan, mapParent), () => new CaravanArrivalAction_VisitRealRuinsPOI(mapParent), "EnterMap".Translate(mapParent.Label), caravan, mapParent.Tile, mapParent));
 }
Exemplo n.º 18
0
 public IEnumerable <FloatMenuOption> VoidSonGetFloatMenuOptions(Caravan caravan)
 {
     return(CaravanArrivalActionUtility.GetFloatMenuOptions(
                () => CaravanArrivalAction_VoidSon.CanVisit(caravan, this),
                () => new CaravanArrivalAction_VoidSon(this), "VisitVoidSon".Translate(Label), caravan, Tile, this));
 }
Exemplo n.º 19
0
        public override IEnumerable <FloatMenuOption> GetFloatMenuOptions(Caravan caravan, MapParent mapParent)
        {
            CaravanArrivalAction_GiveItems caravanAction = new CaravanArrivalAction_GiveItems(mapParent, this);

            return(CaravanArrivalActionUtility.GetFloatMenuOptions(() => caravanAction.CanGiveItems(caravan, mapParent), () => caravanAction, "GiveItemsOption".Translate(), caravan, mapParent.Tile, mapParent));
        }
Exemplo n.º 20
0
        public override IEnumerable <FloatMenuOption> GetFloatMenuOptions(Caravan caravan, MapParent mapParent)
        {
            CaravanArrivalAction_EnterToEmptyMap caravanArrivalAction = new CaravanArrivalAction_EnterToEmptyMap(this, new IntVec3(MapDef.size.x, 1, MapDef.size.z));

            return(CaravanArrivalActionUtility.GetFloatMenuOptions(() => caravanArrivalAction.CanVisit(caravan, mapParent), () => caravanArrivalAction, "EnterMap".Translate(mapParent.LabelCap), caravan, mapParent.Tile, mapParent));
        }
Exemplo n.º 21
0
        public override IEnumerable <FloatMenuOption> GetFloatMenuOptions(Caravan caravan)
        {
            CaravanArrivalAction_EnterToRaidMap caravanAction = new CaravanArrivalAction_EnterToRaidMap(this);

            return(CaravanArrivalActionUtility.GetFloatMenuOptions(() => true, () => caravanAction, "EnterMap".Translate(Label), caravan, this.Tile, this));
        }
Exemplo n.º 22
0
 public static IEnumerable <FloatMenuOption> GetFloatMenuOptions(Caravan caravan, WorldObject_ResearchRequestLGE researchRequest)
 {
     return(CaravanArrivalActionUtility.GetFloatMenuOptions <CaravanArrivalAction_VisitResearchRequest>(() => CanVisit(caravan, researchRequest), () => new CaravanArrivalAction_VisitResearchRequest(researchRequest), "VisitPeaceTalks".Translate(researchRequest.Label), caravan, researchRequest.Tile, researchRequest));
 }
Exemplo n.º 23
0
 public static IEnumerable <FloatMenuOption> GetFloatMenuOptions(Caravan caravan, WorldObject_InterceptedMessageLGE interceptedMessage)
 {
     return(CaravanArrivalActionUtility.GetFloatMenuOptions <CaravanArrivalAction_VisitInterceptedMessageLGE>(() => CanVisit(caravan, interceptedMessage), () => new CaravanArrivalAction_VisitInterceptedMessageLGE(interceptedMessage), "VisitPeaceTalks".Translate(interceptedMessage.Label), caravan, interceptedMessage.Tile, interceptedMessage));
 }
Exemplo n.º 24
0
 public static IEnumerable <FloatMenuOption> GetFloatMenuOptions(Caravan caravan, EnemyCaravan enemyCaravan)
 {
     return(CaravanArrivalActionUtility.GetFloatMenuOptions(() => CanVisit(caravan, enemyCaravan), () => new CaravanArrivalAction_AttackEnemyCaravan(enemyCaravan),
                                                            "VanillaFactionsExpanded.AttackEnemyCaravan".Translate(enemyCaravan.Label), caravan, enemyCaravan.Tile, enemyCaravan));
 }
 public static IEnumerable <FloatMenuOption> GetFloatMenuOptions(Caravan caravan, MedievalTournament tournament)
 {
     return(CaravanArrivalActionUtility.GetFloatMenuOptions(() => CanVisit(caravan, tournament), () => new CaravanArrivalAction_AttendMedievalTournament(tournament),
                                                            "VanillaFactionsExpanded.AttendMedievalTournament".Translate(tournament.Label), caravan, tournament.Tile, tournament));
 }
 public static IEnumerable <FloatMenuOption> GetFloatMenuOptions(Caravan caravan, WarObject warObject)
 {
     return(CaravanArrivalActionUtility.GetFloatMenuOptions(() => CanAttack(caravan, warObject), () => new CaravanArrivalAction_AttackWarObject(warObject), "RW_AttackWarObject".Translate(warObject.Label), caravan, warObject.Tile, warObject));
 }
Exemplo n.º 27
0
        public override IEnumerable <FloatMenuOption> GetFloatMenuOptions(Caravan caravan, MapParent mapParent)
        {
            CaravanArrivalAction_EnterToKillOrderMap caravanAction = new CaravanArrivalAction_EnterToKillOrderMap(mapParent, this);

            return(CaravanArrivalActionUtility.GetFloatMenuOptions(() => true, () => caravanAction, "EnterToMapQuest_Option".Translate(), caravan, mapParent.Tile, mapParent));
        }
Exemplo n.º 28
0
 public override IEnumerable <FloatMenuOption> GetFloatMenuOptions(Caravan caravan, MapParent mapParent)
 {
     return(CaravanArrivalActionUtility.GetFloatMenuOptions(() => caravanAction.CanVisit(caravan, mapParent), () => caravanAction, "EnterMap".Translate(mapParent.Label), caravan, mapParent.Tile, mapParent));
 }
Exemplo n.º 29
0
 private IEnumerable <FloatMenuOption> GetFloatMenuOptions(Caravan caravan, MapParent mapParent)
 {
     return(CaravanArrivalActionUtility.GetFloatMenuOptions(() => CaravanArrivalAction_EnterToShipCrash.CanVisit(caravan, mapParent), () => new CaravanArrivalAction_EnterToShipCrash(mapParent, Generator), "EnterMap".Translate(mapParent.Label), caravan, mapParent.Tile, mapParent));
 }
Exemplo n.º 30
0
        public override IEnumerable <FloatMenuOption> GetFloatMenuOptions(Caravan caravan, MapParent mapParent)
        {
            CaravanArrivalAction_EnterToQuestMapWithGenerator caravanAction = new CaravanArrivalAction_EnterToQuestMapWithGenerator(mapParent, MapGenerator, UseMapSpawnPos);

            return(CaravanArrivalActionUtility.GetFloatMenuOptions(() => true, () => caravanAction, "EnterToMapQuest_Option".Translate(), caravan, mapParent.Tile, mapParent));
        }