个播PK规则、关注房主、连麦优化
This commit is contained in:
@@ -50,7 +50,6 @@
|
||||
#import "XPAcrossRoomPKResultView.h"
|
||||
#import "XPAcrossRoomPKForceEndResultView.h"
|
||||
#import "XPAnchorPKInviteView.h"
|
||||
#import "XPAnchorPKRuleView.h"
|
||||
#import "XPAnchorPKResultView.h"
|
||||
#import "XPAnchorPKFinishView.h"
|
||||
#import "XPSendGiftView.h"
|
||||
@@ -58,7 +57,6 @@
|
||||
#import "XPRoomViewController.h"
|
||||
#import "XPLittleGameMiniStageView.h"
|
||||
#import "XPLittleGameRoomListView.h"
|
||||
#import "XPAcrossRoomPKPrizeView.h"
|
||||
#import "AcrossRoomPKPrizeModel.h"
|
||||
///个播PK
|
||||
#import "XPAnchorFansTeamEntranceView.h"
|
||||
@@ -332,6 +330,8 @@
|
||||
if (code == 200) {
|
||||
AcrossRoomPKPanelModel * acrossPKPanelInfo = [AcrossRoomPKPanelModel modelWithJSON:data.data];
|
||||
self.delegate.getRoomInfo.roundId = acrossPKPanelInfo.roundId;
|
||||
self.delegate.getRoomInfo.pkUid = acrossPKPanelInfo.aUid;
|
||||
self.delegate.getRoomInfo.pkRoomId = acrossPKPanelInfo.aRoomId;
|
||||
if (acrossPKPanelInfo.pkType == AcrossRoomPkTypeAnchor) {
|
||||
if (acrossPKPanelInfo.aUid.integerValue > 0) {
|
||||
if (!self.anchorPKPanelView.superview) {
|
||||
@@ -545,11 +545,8 @@
|
||||
dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(3 * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{
|
||||
[inviteResutView removeFromSuperview];
|
||||
});
|
||||
NSNumber *aRoomId = (NSNumber *)attachment.data[@"aRoomId"];
|
||||
NSNumber *aUid = (NSNumber *)attachment.data[@"aUid"];
|
||||
NSString *otherRoomId = [NSString stringWithFormat:@"%@", aRoomId];
|
||||
NSString *otherUid =[NSString stringWithFormat:@"%@", aUid];
|
||||
[[RtcManager instance] connectOtherRoom:otherRoomId userId:otherUid];
|
||||
AcrossRoomPKPanelModel * acrossPKPanelInfo = [AcrossRoomPKPanelModel modelWithJSON:attachment.data];
|
||||
[[RtcManager instance] connectOtherRoom:acrossPKPanelInfo.aRoomId userId:acrossPKPanelInfo.aUid];
|
||||
}
|
||||
}
|
||||
}];
|
||||
@@ -615,7 +612,9 @@
|
||||
[self.anchorPKPanelView removeFromSuperview];
|
||||
self.anchorPKPanelView = nil;
|
||||
[[RtcManager instance] disconnectOtherRoom];
|
||||
AcrossRoomPKPanelModel * acrossPKPanelInfo = [AcrossRoomPKPanelModel modelWithJSON:attachment.data];
|
||||
XPAnchorPKFinishView *view = [[XPAnchorPKFinishView alloc] init];
|
||||
view.data = acrossPKPanelInfo;
|
||||
[TTPopup popupView:view style:TTPopupStyleAlert];
|
||||
}
|
||||
break;
|
||||
@@ -748,6 +747,15 @@
|
||||
[self.delegate.getCurrentNav presentViewController:userCardVC animated:YES completion:nil];
|
||||
}
|
||||
|
||||
///去房间
|
||||
- (void)xPAnchorPKPanelView:(XPAnchorPkPanelView *)view onlookRoom:(NSString *)roomUid {
|
||||
[self.delegate exitRoom];
|
||||
///这个为啥加个延迟的 因为会先退房 有一个dismiss的动画 所以加个延迟吧
|
||||
dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(1 * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{
|
||||
[XPRoomViewController openRoom:roomUid viewController:[XCCurrentVCStackManager shareManager].getCurrentVC];
|
||||
});
|
||||
}
|
||||
|
||||
#pragma mark - Event Response
|
||||
- (void)contributionButtonAction:(UIButton *)sender {
|
||||
NSString * roomUid = [NSString stringWithFormat:@"%ld", self.delegate.getRoomInfo.uid];
|
||||
@@ -863,7 +871,11 @@
|
||||
}
|
||||
|
||||
- (void)updateRoomTopic {
|
||||
self.topicStackView.hidden= ([ClientConfig shareConfig].configInfo.appStoreAuditNoticeVersion || self.delegate.getRoomInfo.type == RoomType_MiniGame) == YES;
|
||||
if (self.delegate.getRoomInfo.type == RoomType_Anchor && self.delegate.getRoomInfo.roomModeType == RoomModeType_Open_AcrossRoomPK_mode) {
|
||||
self.topicStackView.hidden = YES;
|
||||
} else {
|
||||
self.topicStackView.hidden = ([ClientConfig shareConfig].configInfo.appStoreAuditNoticeVersion || self.delegate.getRoomInfo.type == RoomType_MiniGame) == YES;
|
||||
}
|
||||
[self updateRoomTopicViewConstraint];
|
||||
NIMChatroomMembersByIdsRequest *request = [[NIMChatroomMembersByIdsRequest alloc]init];
|
||||
request.roomId = [NSString stringWithFormat:@"%ld", self.delegate.getRoomInfo.roomId];
|
||||
|
Reference in New Issue
Block a user