コード例 #1
0
ファイル: AirmanBoss.cs プロジェクト: Jasuutu/Megaman
    // Constructor
    protected void Awake()
    {
        GameEngine.AirMan = this;

        rend = gameObject.GetComponent <Renderer>();
        Assert.IsNotNull(rend);

        col = gameObject.GetComponent <Collider2D>();
        Assert.IsNotNull(col);

        anim = gameObject.GetComponent <Animation>();
        Assert.IsNotNull(anim);

        player = FindObjectOfType <Player>();
        Assert.IsNotNull(player);

        health = gameObject.GetComponent <Health>();
        Assert.IsNotNull(health);

        weapon = gameObject.GetComponent <AirmanWindWeapon>();
        Assert.IsNotNull(weapon);
    }
コード例 #2
0
ファイル: AirmanBoss.cs プロジェクト: ellioman/Megaman
    // Constructor
    protected void Awake()
    {
        GameEngine.AirMan = this;

        rend = gameObject.GetComponent<Renderer>();
        Assert.IsNotNull(rend);

        col = gameObject.GetComponent<Collider>();
        Assert.IsNotNull(col);

        anim = gameObject.GetComponent<Animation>();
        Assert.IsNotNull(anim);

        player = FindObjectOfType<Player>();
        Assert.IsNotNull(player);

        health = gameObject.GetComponent<Health>();
        Assert.IsNotNull(health);

        weapon = gameObject.GetComponent<AirmanWindWeapon>();
        Assert.IsNotNull(weapon);
    }