public void onSubscribeRoomDone(RoomEvent eventObj)
    {
        if (eventObj.getResult() == WarpResponseResultCode.SUCCESS)
        {
            appwrapTeenpatti.roomID             = eventObj.getData().getId();
            GameControllerTeenPatti.isConnected = true;
            PlayerPrefs.SetString(TagsTeenpatti.ROOM_ID, eventObj.getData().getId());

            // eventObj.getData().
            if (GameControllerTeenPatti.PrivateGameType.Equals(TagsTeenpatti.JOIN_PRIVATE_TABLE))
            {
                WarpClient.GetInstance().GetLiveRoomInfo(eventObj.getData().getId());
            }
            else
            {
                appwrapTeenpatti.gameRequest();
            }
            //string privateType = PlayerPrefs.GetString (PrefebTagsTeenpatti.PRIVATE_TYPE);
            if (GameControllerTeenPatti.PrivateGameType.Equals(TagsTeenpatti.CREATE_PRIVATE_TABLE))
            {
                GameDelegateTeenPatti.ShowPrivateTableCode(eventObj.getData().getId());
            }
        }

        //		if (eventObj.getResult () == WarpResponseResultCode.SUCCESS) {
        //			// set room id in prefeb
        //			//PlayerPrefs.SetString (GameTags.ROOM_ID, eventObj.getData ().getId ());
        //			//GameConstantData.showToast (eventObj.getData ().getId ());
        //
        //			string roomID = eventObj.getData ().getId ();
        //			if (WarpClient.GetInstance () != null) {
        //				//WarpClient.GetInstance ().GetLiveRoomInfo (eventObj.getData ().getId ());
        //				//GameConstantData.showToast("onSubscribeRoomDone successful");
        //				appwrapTeenpatti.joinGame ();
        //			}
        //
        //			string tableType = PlayerPrefs.GetString (PrefebTagsTeenpatti.PRIVATE_TYPE);
        //			if (tableType.Equals (PrefebTagsTeenpatti.CREATE)) {
        //				// show create table popup
        //				//GameDelegate.showSendTableCode (roomID);
        //				PlayerPrefs.SetString (PrefebTagsTeenpatti.PRIVATE_TYPE, "");
        //			}
        //
        //		}
    }
Exemplo n.º 2
0
    public void onSubscribeRoomDone(RoomEvent eventObj)
    {
        if (eventObj.getResult() == WarpResponseResultCode.SUCCESS)
        {
            appwrapTeenpatti.roomID             = eventObj.getData().getId();
            GameControllerTeenPatti.isConnected = true;
            PlayerPrefs.SetString(TagsTeenpatti.ROOM_ID, eventObj.getData().getId());


            if (GameControllerTeenPatti.PrivateGameType.Equals(TagsTeenpatti.JOIN_PRIVATE_TABLE))
            {
                WarpClient.GetInstance().GetLiveRoomInfo(eventObj.getData().getId());
            }
            else
            {
                appwrapTeenpatti.gameRequest();
            }

            if (GameControllerTeenPatti.PrivateGameType.Equals(TagsTeenpatti.CREATE_PRIVATE_TABLE))
            {
                GameDelegateTeenPatti.ShowPrivateTableCode(eventObj.getData().getId());
            }
        }
    }