void Awake()
    {
        children = new List <GameObject>();

        foreach (Transform child in transform)
        {
            children.Add(child.gameObject);
        }

        VisualEncryptorAgent.SetSprites(children);
    }
    void Awake()
    {
        if( mInstance != null )
        {
            Debug.LogError( string.Format( "Only one instance of VisualEncryptorAgent allowed! Destroying:" + gameObject.name +", Other:" + mInstance.gameObject.name ) );
            Destroy( gameObject );
            return;
        }

        mInstance = this;
    }
예제 #3
0
    void Awake()
    {
        if (mInstance != null)
        {
            Debug.LogError(string.Format("Only one instance of VisualEncryptorAgent allowed! Destroying:" + gameObject.name + ", Other:" + mInstance.gameObject.name));
            Destroy(gameObject);
            return;
        }

        mInstance = this;
    }
예제 #4
0
    void OnEnable()
    {
        content = "Find a friend!";

        int monID = MonAgent.GetCurrentMonID();

        if (monID != -1)
        {
            content = MonAgent.MonFromID(monID).ToString();
        }

        VisualEncryptorAgent.DisplaySprite(monID);
    }