Esempio n. 1
0
 // Use this for initialization
 void Start()
 {
     KomponenGerak = GameObject.Find("ball").GetComponent <gerak>();
     levelManager  = FindObjectOfType <LevelManager>();
     gameObject.AddComponent <AudioSource>();
     source.clip        = sound;
     source.playOnAwake = false;
 }
    public void clickedJurus()
    {
        Debug.Log("Menjalankan jurus, BOOOM!!");
        //anim3.SetTrigger ("serang");
        sr              = GameObject.Find("Player").GetComponent <gerak> ();
        sr.tombolJurus  = true;
        jr.weaponDamage = 30;

        Invoke("unClickedJurus", delayUsingJurus);
        jurusON = false;
        btnJurus.SetActive(false);
        Debug.Log("Jurus mati? = " + jurusON);
    }
Esempio n. 3
0
    // Use this for initialization
    void Start()
    {
        //Animasi
        anim = GetComponent <Animator>();

        Enemy  = GameObject.FindGameObjectWithTag("Enemy");
        Player = GameObject.FindGameObjectWithTag("Player");

        KomponenGerak = GameObject.Find("Player").GetComponent <gerak>();
        //Rest ();

        //------------------Enemy Move----------------------------------------------------------------
        myTrans = this.transform;
        myBody  = this.GetComponent <Rigidbody2D>();
        SpriteRenderer mySprite = this.GetComponent <SpriteRenderer>();

        myWidth  = mySprite.bounds.extents.x;
        myHeight = mySprite.bounds.extents.y;
        //------------------End Enemy Move------------------------------------------------------------------
        theSwordHit = GameObject.Find("pedang").GetComponentInChildren <swordHit>();
    }
Esempio n. 4
0
 // Start is called before the first frame update
 void Start()
 {
     bawahtanah = GameObject.Find("player").GetComponent <gerak>();
 }
Esempio n. 5
0
 void Start()
 {
     KomponenGerak = GameObject.Find("player").GetComponent <gerak>();
 }
Esempio n. 6
0
 // Start is called before the first frame update
 void Start()
 {
     deteksisungai = GameObject.Find("player").GetComponent <gerak>();
 }
Esempio n. 7
0
 void Start()
 {
     gerak = GameObject.FindGameObjectWithTag("Player").GetComponent <gerak>();
 }
 // Use this for initialization
 void Start()
 {
     KomponenGerak = GameObject.Find("ball").GetComponent <gerak>();
     //objRef = GameObject.FindGameObjectsWithTag("Player");
 }
 public void unClickedJurus()
 {
     sr              = GameObject.Find("Player").GetComponent <gerak> ();
     sr.tombolJurus  = false;
     jr.weaponDamage = 10;
 }
Esempio n. 10
0
 void Start()
 {
     Finish = GameObject.Find("player").GetComponent <gerak>();
 }