Ejemplo n.º 1
0
    void OnPhotonPlayerDisconnected(PhotonPlayer player)
    {
        Debug.Log("OnPhotonPlayerDisconnected: " + player);

        /**
         * add I won,
         */
        Debug.Log("I won");

        manager_script manager = GameObject.Find("the game").GetComponent <manager_script>();

        manager.won(PhotonNetwork.player.ID);
    }
Ejemplo n.º 2
0
    // Use this for initialization
    void Start()
    {
        Debug.Log("created " + gameObject.name);
        wind_str     = GameObject.Find("wind").GetComponent <wind>().wind_str;
        pixel_cnr    = GameObject.Find("ground").GetComponent <pixel_control>();
        game_manager = GameObject.Find("the game").GetComponent <manager_script>();
        Debug.Log(game_manager);
        GameObject the_game = GameObject.Find("the game");

        text_game_obj    = GameObject.Find("bullet_text");
        transform.parent = the_game.transform;

        rigid = GetComponent <Rigidbody2D>();

        if (bullet_type == bullet_type_e.grenade)
        {
            text            = text_game_obj.GetComponent <Text>();
            timer_coroutine = counter();
            StartCoroutine(timer_coroutine);
        }
    }
Ejemplo n.º 3
0
 // Use this for initialization
 void Start()
 {
     wind_str = GameObject.Find("wind").GetComponent<wind>().wind_str;
     pixel_cnr = GameObject.Find("ground").GetComponent<pixel_control>();
     game_manager = GameObject.Find("the game").GetComponent<manager_script>();
 }
Ejemplo n.º 4
0
 // Use this for initialization
 void Start()
 {
     game_manager = GameObject.Find("the game").GetComponent <manager_script>();
     game_manager.follow_bullet(this.gameObject);
 }
Ejemplo n.º 5
0
 // Use this for initialization
 void Start()
 {
     current_hp = hp;
     manager    = GameObject.Find("the game").GetComponent <manager_script>();
 }