Пример #1
0
//	void OnLevelWasLoaded(int level) {
//		if (Application.loadedLevelName == "MainRoom"){
//
//
//	}

	public void OpenSpace(SpaceObj _space){

		if (_space == null) return;

		_spaceLoader.StartLoading(_space._textureName, _space.gameObject.GetComponent<Renderer>());

	}
Пример #2
0
    void CloseSpace()
    {
        Debug.Log("CloseOldSpace");

        if (_activeSpace != null){
            _activeSpace.gameObject.SetActive(false);
            _activeSpace = null;
        }

        _snd.Stop();
    }
Пример #3
0
	void CloseSpace(){

		Debug.Log("CloseOldSpace");

		if (_activeSpace != null){
			_activeSpace.gameObject.SetActive(false);
			_activeSpace = null;
		}

		_snd.Stop();
	}
Пример #4
0
	public void RoomLoaded(SpaceObj _space){
		CloseSpace();
		
		_snd.clip = _space._sound;
		_snd.Play();
		_spaceInfo.text = _space._name + "\n" + _space._info;
		
		_activeSpace = _space;
		_activeSpace.gameObject.SetActive(true);
		
		Debug.Log("OpenSpace");
	}
Пример #5
0
    public void RoomLoaded(SpaceObj _space)
    {
        CloseSpace();

        _snd.clip = _space._sound;
        _snd.Play();
        _spaceInfo.text = _space._name + "\n" + _space._info;

        _activeSpace = _space;
        _activeSpace.gameObject.SetActive(true);

        Debug.Log("OpenSpace");
    }
Пример #6
0
    //    void OnLevelWasLoaded(int level) {
    //        if (Application.loadedLevelName == "MainRoom"){
    //
    //
    //    }
    public void OpenSpace(SpaceObj _space)
    {
        if (_space == null) return;

        _spaceLoader.StartLoading(_space._textureName, _space.gameObject.GetComponent<Renderer>());
    }