protected void finalizeChase()
    {
        //object ob = null;

        if (lostTarget)
        {
            BasicMessageFSM pame = new BasicMessageFSM("Suspicious");
            //ob = (object) pame;

            //Debug.Log("aggiunto messaggio");
            addFinalizeMessage(pame);
        }

        weakPointCollider.offset = new Vector2(0.0f, weakPointCollider.offset.y);
        weakPointCollider.size   = new Vector2(0.75f, weakPointCollider.size.y);

        //return ob;
    }
Beispiel #2
0
    protected void patrolFinalize()
    {
                #if _DEBUG
        Debug.Log("finisco patrol--------------------------------");
                #endif

        //object ob = null;

        if (foundTarget != null)
        {
                        #if _DEBUG
            Debug.Log(" PATROL - ritorno foundtarget : " + foundTarget.name);
                        #endif

            BasicMessageFSM mess = new BasicMessageFSM(foundTarget);

            addFinalizeMessage(mess);
        }
        else
        {
                        #if _DEBUG
            Debug.Log("PATROL - ritorno NULL come foundtarget");
                        #endif
        }

        if (defaultChildPatrolState != null)
        {
            setActiveState(defaultChildPatrolState);
        }
        else
        {
            Debug.Log("ATTENZIONE - nel finalize defaultChildPatrolState è NULL");
        }


        //ob = (object)foundTarget;



        //return ob;
    }
    protected void stunnedFinalize()
    {
                #if _DEBUG
        Debug.Log("finisco stunn --------------------------------");
                #endif

        //finishStunned = false;

        killDuringStunn = false;

        stunnedFinish = false;

        _StopCoroutine(stunnedCor);

        i_stunned(false);
        //TODO: inserire altra roba per cui serve riattivare altro...
        setDefaultLayer();

        BasicMessageFSM pame = new BasicMessageFSM("Suspicious");
        addFinalizeMessage(pame);

        //return null;
    }
    protected void finalizeCrashChase()
    {
        //object ob = null;

                #if _DEBUG
        Debug.Log("fine da " + stateName);
                #endif

        //return ob;
        if (lostInFront)
        {
            BasicMessageFSM pame = new BasicMessageFSM("Suspicious");

            addFinalizeMessage(pame);
        }

        lostInFront = false;

        losingInFront = false;

        _StopCoroutine(lostCor);

        i_charged(false);
    }