예제 #1
0
	public void EnterChannel()
	{
		if( s_ChannelSelected == false)
		{
			if( null != AsHudDlgMgr.Instance)
				AsHudDlgMgr.Instance.CollapseMenuBtn();	// #10694
			
			s_ChannelSelected = true;
			
//			AsUserInfo.Instance.currentChannelName = channelData.szChannelName;
			
			body_CG_CHANNEL_SELECT channelSelect = new body_CG_CHANNEL_SELECT( channelData.nChannel);
			byte[] data = channelSelect.ClassToPacketBytes();
			AsNetworkMessageHandler.Instance.Send( data);
		}
	}
예제 #2
0
	private void CharacterSelectResult( byte[] _packet)
	{
		Debug.Log( "CharacterSelectResult");

		AsPartyManager.Instance.Initilize();
		AsSocialManager.Instance.Initilize();

		body_GC_CHAR_SELECT_RESULT_1 result = new body_GC_CHAR_SELECT_RESULT_1();
		result.PacketBytesToClass( _packet);

		Debug.Log( "CharacterSelectResult: result.nChannel = " + result.nChannel);

		switch( result.eResult)
		{
		case eRESULTCODE.eRESULT_SUCC:
			break;
		case eRESULTCODE.eRESULT_FAIL_PRIVATESHOP_ANOTHERCHAR_OPENED:
			AsNotify.Instance.MessageBox( AsTableManager.Instance.GetTbl_String(4086), AsTableManager.Instance.GetTbl_String(403), AsNotify.MSG_BOX_TYPE.MBT_OK, AsNotify.MSG_BOX_ICON.MBI_ERROR);
			return;
		default:
			AsNotify.Instance.MessageBox( AsTableManager.Instance.GetTbl_String(4086), AsTableManager.Instance.GetTbl_String(400), AsNotify.MSG_BOX_TYPE.MBT_OK, AsNotify.MSG_BOX_ICON.MBI_ERROR);
			return;
		}

		AsUserInfo.Instance.SetCostumeOnOff( result.bCostumeOnOff);
		AsUserInfo.Instance.SetItemViews( result.sNormalItemVeiw);
		AsUserInfo.Instance.SetCosItemView( result.sCosItemView);
		AsUserInfo.Instance.SaveCurCharStat( result);
		AsUserInfo.Instance.CurConditionValue = ( int)result.nCondition;
		//AsUserInfo.Instance.PvpPoint = result.nPvpPoint;
		AsUserInfo.Instance.YesterdayPvpRank = result.nYesterdayPvpRank;
		AsUserInfo.Instance.YesterdayPvpPoint = result.nYesterdayPvpPoint;
		AsUserInfo.Instance.YesterdayPvpRankRate = result.nYesterdayPvpRankRate;
		AsUserInfo.Instance.RankPoint = result.nRankPoint;
		AsUserInfo.Instance.FreeGachaPoint = result.nFreeGachaPoint;
		
		BonusManager.Instance.SetCompleteLevelBonus(result.nLevelComplete);

		#region -Designation
		AsDesignationManager.Instance.CurrentID = result.body.nSubTitleTableIdx;
		AsUserInfo.Instance.SubTitleHide = result.body.bSubTitleHide;
		AsGameMain.SetOptionState( OptionBtnType.OptionBtnType_SubTitleName, result.body.bSubTitleHide);
		AsDesignationManager.Instance.ResetDesignationRewardReceiveFlag();
		#endregion

#if false
		if( 0 == result.nChannel)
		{
			body_CG_CHANNEL_LIST channelList = new body_CG_CHANNEL_LIST( false);
			byte[] data = channelList.ClassToPacketBytes();
			AsNetworkMessageHandler.Instance.Send( data);
		}
		else
		{
			body_CG_CHANNEL_SELECT channelSelect = new body_CG_CHANNEL_SELECT( result.nChannel);
			byte[] data = channelSelect.ClassToPacketBytes();
			AsNetworkMessageHandler.Instance.Send( data);
		}
#endif

		if( null != result.body)
			AsHudDlgMgr.productRadioClassIndex = ( eCLASS)result.body.eClass;
	}