示例#1
0
 void Off(behaviour_type bType)
 {
     if (On(bType))
     {
         m_iflag ^= bType;
     }
 }
示例#2
0
    behaviour_type Off(behaviour_type bType, behaviour_type iflag)
    {
        if (On(bType, iflag))
        {
            iflag ^= bType;
        }

        return(iflag);
    }
示例#3
0
    public bool IsSteering()
    {
        behaviour_type clongFlag = m_iflag;

        clongFlag = Off(behaviour_type.obstacle_avoidance, clongFlag);
        clongFlag = Off(behaviour_type.wall_avoidance, clongFlag);

        return(((int)clongFlag > 1) ? true : false);
    }
示例#4
0
 public void FollowPathOn()
 {
     m_iflag |= behaviour_type.follow_path;
 }
示例#5
0
 public void AlignmentOn()
 {
     m_iflag |= behaviour_type.allignment;
 }
示例#6
0
 public void WanderOn()
 {
     m_iflag |= behaviour_type.wander;
 }
示例#7
0
 public void ArriveOn()
 {
     m_iflag |= behaviour_type.arrive;
 }
示例#8
0
 public void SeekOn()
 {
     m_iflag |= behaviour_type.seek;
 }
 public bool isOn(behaviour_type behaviour)
 {
     return((flags & (int)behaviour) == (int)behaviour);
 }
示例#10
0
 public bool isOn(behaviour_type behaviour)
 {
     return ((flags & (int)behaviour) == (int)behaviour);
 }
示例#11
0
 public void BasicOn()
 {
     m_iflag |= behaviour_type.obstacle_avoidance;
     m_iflag |= behaviour_type.wall_avoidance;
 }
示例#12
0
 bool On(behaviour_type bType, behaviour_type iflag)
 {
     return((iflag & bType) == bType);
 }
示例#13
0
 bool On(behaviour_type bType)
 {
     return((m_iflag & bType) == bType);
 }
 public void turnOn(behaviour_type behaviour)
 {
     flags |= ((int)behaviour);
 }
示例#15
0
 public void GravityOn()
 {
     m_iflag |= behaviour_type.gravity;
 }
示例#16
0
 public void CohesionOn()
 {
     m_iflag |= behaviour_type.cohesion;
 }
示例#17
0
 public void FleeOn()
 {
     m_iflag |= behaviour_type.flee;
 }
示例#18
0
 public void turnOn(behaviour_type behaviour)
 {
     flags |= ((int)behaviour);
 }
 public void turnOff(behaviour_type behaviour)
 {
     flags &= ( ~ (int)behaviour);
 }