Beispiel #1
0
		public void Set(HitAttribute attribute, Int32 time, Boolean negation)
		{
			if (attribute == null) throw new ArgumentNullException("attribute");

			m_attribute = attribute;
			m_time = time;
			m_negation = negation;
			m_isactive = true;
		}
Beispiel #2
0
		public void Set(HitAttribute attribute, Int32 statenumber, Int32 time, Boolean forceair)
		{
			if (attribute == null) throw new ArgumentNullException("attribute");

			m_attr = attribute;
			m_statenumber = statenumber;
			m_time = time;
			m_forceair = forceair;
			m_isactive = true;
		}
Beispiel #3
0
        public void Set(HitAttribute attribute, Int32 time, Boolean negation)
        {
            if (attribute == null)
            {
                throw new ArgumentNullException("attribute");
            }

            m_attribute = attribute;
            m_time      = time;
            m_negation  = negation;
            m_isactive  = true;
        }
Beispiel #4
0
        public void Set(HitAttribute attribute, int time, bool negation)
        {
            if (attribute == null)
            {
                throw new ArgumentNullException(nameof(attribute));
            }

            m_attribute = attribute;
            m_time      = time;
            m_negation  = negation;
            m_isactive  = true;
        }
Beispiel #5
0
        public void Set(HitAttribute attribute, int statenumber, int time, bool forceair)
        {
            if (attribute == null)
            {
                throw new ArgumentNullException(nameof(attribute));
            }

            m_attr        = attribute;
            m_statenumber = statenumber;
            m_time        = time;
            m_forceair    = forceair;
            m_isactive    = true;
        }
Beispiel #6
0
        public void Set(HitAttribute attribute, Int32 statenumber, Int32 time, Boolean forceair)
        {
            if (attribute == null)
            {
                throw new ArgumentNullException("attribute");
            }

            m_attr        = attribute;
            m_statenumber = statenumber;
            m_time        = time;
            m_forceair    = forceair;
            m_isactive    = true;
        }
Beispiel #7
0
        public Boolean CanHit(HitAttribute attr)
        {
            if (attr == null)
            {
                throw new ArgumentNullException("attr");
            }

            if (IsActive == false)
            {
                return(true);
            }

            if (m_negation == false)
            {
                if (m_attribute.HasHeight(attr.AttackHeight) == false)
                {
                    return(false);
                }
                foreach (HitType hittype in attr.AttackData)
                {
                    if (m_attribute.HasData(hittype) == false)
                    {
                        return(false);
                    }
                }

                return(true);
            }
            else
            {
                if (m_attribute.HasHeight(attr.AttackHeight) == true)
                {
                    return(false);
                }
                foreach (HitType hittype in attr.AttackData)
                {
                    if (m_attribute.HasData(hittype) == true)
                    {
                        return(false);
                    }
                }

                return(true);
            }
        }
Beispiel #8
0
        public bool CanHit(HitAttribute attr)
        {
            if (attr == null)
            {
                throw new ArgumentNullException(nameof(attr));
            }

            if (IsActive == false)
            {
                return(true);
            }

            if (m_negation == false)
            {
                if (m_attribute.HasHeight(attr.AttackHeight) == false)
                {
                    return(false);
                }
                foreach (var hittype in attr.AttackData)
                {
                    if (m_attribute.HasData(hittype) == false)
                    {
                        return(false);
                    }
                }

                return(true);
            }

            if (m_attribute.HasHeight(attr.AttackHeight))
            {
                return(false);
            }
            foreach (var hittype in attr.AttackData)
            {
                if (m_attribute.HasData(hittype))
                {
                    return(false);
                }
            }

            return(true);
        }
Beispiel #9
0
		public Boolean CanHit(HitAttribute attr)
		{
			if (attr == null) throw new ArgumentNullException("attr");

			if (IsActive == false) return true;

			if (m_negation == false)
			{
				if (m_attribute.HasHeight(attr.AttackHeight) == false) return false;
				foreach (HitType hittype in attr.AttackData) if (m_attribute.HasData(hittype) == false) return false;

				return true;
			}
			else
			{
				if (m_attribute.HasHeight(attr.AttackHeight) == true) return false;
				foreach (HitType hittype in attr.AttackData) if (m_attribute.HasData(hittype) == true) return false;

				return true;
			}
		}
Beispiel #10
0
		static HitAttribute()
		{
			s_default = new HitAttribute(AttackStateType.None, new ReadOnlyList<HitType>());
		}
Beispiel #11
0
 static HitAttribute()
 {
     s_default = new HitAttribute(AttackStateType.None, new ReadOnlyList <HitType>());
 }