Example #1
0
 void CancelTripToCrime()
 {
     currentCrime      = null;
     m_destinationType = types.DestinationType.Building;
     m_officerState    = types.OfficerState.isTravelling_interruptible;
     SubmitTask((Structure)theDepot);
 }
Example #2
0
    void LeaveCompletedCrimeScene()
    {
        m_officerState = types.OfficerState.isTravelling_interruptible;
        currentCrime   = null;

        InitiateTrip((Structure)theDepot);
    }
Example #3
0
    void AssignCrime(Crime _crime)
    {
        currentCrime      = _crime;
        m_destinationType = types.DestinationType.Crime;
        m_officerState    = types.OfficerState.isTravelling_interruptible;

        InitiateTrip(_crime.GetBuilding());
    }
Example #4
0
 IEnumerator Incarcerate()
 {
     while (incarcerationTime > 0.0f)
     {
         incarcerationTime -= Clock.GetDeltaTime();
         yield return(null);
     }
     print("end");
     m_officerState = types.OfficerState.isAtDepot;
 }
Example #5
0
 void EnterDepot(bool _hasCriminal)
 {
     ArriveAtLocation();
     if (_hasCriminal)
     {
         m_officerState = types.OfficerState.isIncarcerating;
         StartCoroutine("Incarcerate");
     }
     else
     {
         m_officerState = types.OfficerState.isAtDepot;
     }
 }
Example #6
0
    void ResolveCurrentCrime()
    {
        // record crime as a resolved crime
        theDepot.ReportResolvedCrime(currentCrime);
        m_officerState = types.OfficerState.isTravelling_uninterruptible;

        // adjust officer experience as necessary

        currentCrime.ResolveCrime();
        currentCrime = null;

        InitiateTrip((Structure)theDepot);
    }
Example #7
0
    void GoToLocation(Structure _s)
    {
        Depot structure_depot = _s as Depot;

        if (structure_depot != null)
        {
            m_destinationType = types.DestinationType.Depot;
        }
        else
        {
            m_destinationType = types.DestinationType.Building;
        }

        currentCrime   = null;
        m_officerState = types.OfficerState.isTravelling_interruptible;
        InitiateTrip(_s);
    }
Example #8
0
 void ArriveAtBuildingNoActivity()
 {
     m_officerState = types.OfficerState.isAtBuilding;
     ArriveAtLocation();
 }
Example #9
0
 void ArriveAtCrime()
 {
     m_officerState = types.OfficerState.isAtCrime;
     ArriveAtLocation();
 }