Exemple #1
0
        // Function from file: twohanded.dm
        public override bool afterattack(dynamic target = null, dynamic user = null, bool?proximity_flag = null, string click_parameters = null)
        {
            dynamic L = null;
            Mob_Living_SimpleAnimal_Hostile_Illusion M = null;

            base.afterattack((object)(target), (object)(user), proximity_flag, click_parameters);

            if (!(proximity_flag == true))
            {
                return(false);
            }
            user.faction |= new Txt("greytide(").Ref(user).str(")").ToString();

            if (target is Mob_Living)
            {
                L = target;

                if (L is Mob_Living_SimpleAnimal_Hostile_Illusion)
                {
                    return(false);
                }

                if (!Lang13.Bool(L.stat) && Rand13.PercentChance(50))
                {
                    M         = new Mob_Living_SimpleAnimal_Hostile_Illusion(user.loc);
                    M.faction = user.faction.Copy();
                    M.Copy_Parent(user, 100, user.health / 2.5, 12, 30);
                    M.GiveTarget(L);
                }
            }
            return(false);
        }
Exemple #2
0
        // Function from file: illusion.dm
        public override bool AttackingTarget(  )
        {
            dynamic L = null;
            Mob_Living_SimpleAnimal_Hostile_Illusion M = null;

            base.AttackingTarget();

            if (this.target is Mob_Living && Rand13.PercentChance(((int)(this.multiply_chance ?? 0))))
            {
                L = this.target;

                if (Convert.ToInt32(L.stat) == 2)
                {
                    return(false);
                }
                M         = new Mob_Living_SimpleAnimal_Hostile_Illusion(this.loc);
                M.faction = this.faction.Copy();
                M.Copy_Parent(this.parent_mob, 80, this.health / 2, this.melee_damage_upper, (this.multiply_chance ?? 0) / 2);
                M.GiveTarget(L);
            }
            return(false);
        }