Esempio n. 1
0
 /*
  * Gives the given thing the TrainCombatDesignation
  */
 public override void DesignateThing(Thing t)
 {
     if (t != null)
     {
         HugsLibUtility.ToggleDesignation(t, this.defOf, true);
     }
 }
Esempio n. 2
0
        public override void DesignateThing(Thing t)
        {
            bool flag = !this.CanDesignateThing(t).Accepted;

            if (!flag)
            {
                HugsLibUtility.ToggleDesignation(t, AllowToolReleaseDefOf.ReleaseDesignation, true);
            }
        }
        public void determineDesignation()
        {
            HugsLibUtility.ToggleDesignation((Thing)this, CombatTrainingDefOf.TrainCombatDesignation, false);
            HugsLibUtility.ToggleDesignation((Thing)this, CombatTrainingDefOf.TrainCombatDesignationMeleeOnly, false);
            HugsLibUtility.ToggleDesignation((Thing)this, CombatTrainingDefOf.TrainCombatDesignationRangedOnly, false);
            switch (trainingType)
            {
            case TrainingTypes.None:
                break;

            case TrainingTypes.Melee:
                HugsLibUtility.ToggleDesignation((Thing)this, CombatTrainingDefOf.TrainCombatDesignationMeleeOnly, true);
                break;

            case TrainingTypes.Ranged:
                HugsLibUtility.ToggleDesignation((Thing)this, CombatTrainingDefOf.TrainCombatDesignationRangedOnly, true);
                break;

            case TrainingTypes.Any:
                HugsLibUtility.ToggleDesignation((Thing)this, CombatTrainingDefOf.TrainCombatDesignation, true);
                break;
            }
        }