Example #1
0
        protected override void OnFighterAdded(FightTeam team, FightActor actor)
        {
            if (actor is TaxCollectorFighter)
            {
                if (TaxCollector != null)
                {
                    logger.Error("There is already a tax collector in this fight !");
                }
                else
                {
                    TaxCollector       = (TaxCollectorFighter)actor;
                    TaxCollector.Dead += OnTaxCollectorDeath;
                }
            }

            if (State == FightState.Placement && team == ChallengersTeam)
            {
                TaxCollectorHandler.SendGuildFightPlayersEnemiesListMessage(
                    TaxCollector.TaxCollectorNpc.Guild.Clients, TaxCollector.TaxCollectorNpc,
                    ChallengersTeam.Fighters.OfType <CharacterFighter>().Select(x => x.Character));
            }


            base.OnFighterAdded(team, actor);
        }
Example #2
0
 protected override void OnFighterAdded(FightTeam team, FightActor actor)
 {
     if (actor is TaxCollectorFighter)
     {
         if (this.TaxCollector != null)
         {
             FightPvT.logger.Error("There is already a tax collector in this fight !");
         }
         else
         {
             this.TaxCollector = (actor as TaxCollectorFighter);
         }
     }
     if (base.State == FightState.Placement && team == this.AttackersTeam)
     {
         TaxCollectorHandler.SendGuildFightPlayersEnemiesListMessage(this.TaxCollector.TaxCollectorNpc.Guild.Clients, this.TaxCollector.TaxCollectorNpc,
                                                                     from x in this.AttackersTeam.Fighters.OfType <CharacterFighter>()
                                                                     select x.Character);
     }
     base.OnFighterAdded(team, actor);
 }