礼物值送礼物更新礼物值
This commit is contained in:
@@ -305,7 +305,7 @@
|
|||||||
E8DEC98F27643EB30078CB70 /* XPCandyTreeAnimationManager.m in Sources */ = {isa = PBXBuildFile; fileRef = E8DEC98E27643EB30078CB70 /* XPCandyTreeAnimationManager.m */; };
|
E8DEC98F27643EB30078CB70 /* XPCandyTreeAnimationManager.m in Sources */ = {isa = PBXBuildFile; fileRef = E8DEC98E27643EB30078CB70 /* XPCandyTreeAnimationManager.m */; };
|
||||||
E8DEC992276441AA0078CB70 /* XPCandyTreeAnimationModel.m in Sources */ = {isa = PBXBuildFile; fileRef = E8DEC991276441AA0078CB70 /* XPCandyTreeAnimationModel.m */; };
|
E8DEC992276441AA0078CB70 /* XPCandyTreeAnimationModel.m in Sources */ = {isa = PBXBuildFile; fileRef = E8DEC991276441AA0078CB70 /* XPCandyTreeAnimationModel.m */; };
|
||||||
E8DACCFB2766EDC60052092C /* MicroGiftValueView.m in Sources */ = {isa = PBXBuildFile; fileRef = E8DACCFA2766EDC60052092C /* MicroGiftValueView.m */; };
|
E8DACCFB2766EDC60052092C /* MicroGiftValueView.m in Sources */ = {isa = PBXBuildFile; fileRef = E8DACCFA2766EDC60052092C /* MicroGiftValueView.m */; };
|
||||||
E8DACCFE27673F870052092C /* MicroGiftValueModel.m in Sources */ = {isa = PBXBuildFile; fileRef = E8DACCFD27673F870052092C /* MicroGiftValueModel.m */; };
|
E8DACCFE27673F870052092C /* GiftValueInfoModel.m in Sources */ = {isa = PBXBuildFile; fileRef = E8DACCFD27673F870052092C /* GiftValueInfoModel.m */; };
|
||||||
E8DEC99527648FA50078CB70 /* ClientConfig.m in Sources */ = {isa = PBXBuildFile; fileRef = E8DEC99427648FA50078CB70 /* ClientConfig.m */; };
|
E8DEC99527648FA50078CB70 /* ClientConfig.m in Sources */ = {isa = PBXBuildFile; fileRef = E8DEC99427648FA50078CB70 /* ClientConfig.m */; };
|
||||||
E8DEC99E2764A5B60078CB70 /* XPRoomMoreMenuViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = E8DEC99D2764A5B60078CB70 /* XPRoomMoreMenuViewController.m */; };
|
E8DEC99E2764A5B60078CB70 /* XPRoomMoreMenuViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = E8DEC99D2764A5B60078CB70 /* XPRoomMoreMenuViewController.m */; };
|
||||||
E8DEC9A12764A5D20078CB70 /* XPRoomMoreItemModel.m in Sources */ = {isa = PBXBuildFile; fileRef = E8DEC9A02764A5D20078CB70 /* XPRoomMoreItemModel.m */; };
|
E8DEC9A12764A5D20078CB70 /* XPRoomMoreItemModel.m in Sources */ = {isa = PBXBuildFile; fileRef = E8DEC9A02764A5D20078CB70 /* XPRoomMoreItemModel.m */; };
|
||||||
@@ -931,8 +931,8 @@
|
|||||||
E8DEC991276441AA0078CB70 /* XPCandyTreeAnimationModel.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = XPCandyTreeAnimationModel.m; sourceTree = "<group>"; };
|
E8DEC991276441AA0078CB70 /* XPCandyTreeAnimationModel.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = XPCandyTreeAnimationModel.m; sourceTree = "<group>"; };
|
||||||
E8DACCF92766EDC60052092C /* MicroGiftValueView.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MicroGiftValueView.h; sourceTree = "<group>"; };
|
E8DACCF92766EDC60052092C /* MicroGiftValueView.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MicroGiftValueView.h; sourceTree = "<group>"; };
|
||||||
E8DACCFA2766EDC60052092C /* MicroGiftValueView.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = MicroGiftValueView.m; sourceTree = "<group>"; };
|
E8DACCFA2766EDC60052092C /* MicroGiftValueView.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = MicroGiftValueView.m; sourceTree = "<group>"; };
|
||||||
E8DACCFC27673F870052092C /* MicroGiftValueModel.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MicroGiftValueModel.h; sourceTree = "<group>"; };
|
E8DACCFC27673F870052092C /* GiftValueInfoModel.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GiftValueInfoModel.h; sourceTree = "<group>"; };
|
||||||
E8DACCFD27673F870052092C /* MicroGiftValueModel.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = MicroGiftValueModel.m; sourceTree = "<group>"; };
|
E8DACCFD27673F870052092C /* GiftValueInfoModel.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = GiftValueInfoModel.m; sourceTree = "<group>"; };
|
||||||
E8DEC99327648FA50078CB70 /* ClientConfig.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = ClientConfig.h; sourceTree = "<group>"; };
|
E8DEC99327648FA50078CB70 /* ClientConfig.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = ClientConfig.h; sourceTree = "<group>"; };
|
||||||
E8DEC99427648FA50078CB70 /* ClientConfig.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = ClientConfig.m; sourceTree = "<group>"; };
|
E8DEC99427648FA50078CB70 /* ClientConfig.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = ClientConfig.m; sourceTree = "<group>"; };
|
||||||
E8DEC99C2764A5B60078CB70 /* XPRoomMoreMenuViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = XPRoomMoreMenuViewController.h; sourceTree = "<group>"; };
|
E8DEC99C2764A5B60078CB70 /* XPRoomMoreMenuViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = XPRoomMoreMenuViewController.h; sourceTree = "<group>"; };
|
||||||
@@ -1987,8 +1987,6 @@
|
|||||||
E874B88727215D39003954B9 /* MicroStateModel.m */,
|
E874B88727215D39003954B9 /* MicroStateModel.m */,
|
||||||
E874B88927215EAF003954B9 /* MicroQueueModel.h */,
|
E874B88927215EAF003954B9 /* MicroQueueModel.h */,
|
||||||
E874B88A27215EAF003954B9 /* MicroQueueModel.m */,
|
E874B88A27215EAF003954B9 /* MicroQueueModel.m */,
|
||||||
E8DACCFC27673F870052092C /* MicroGiftValueModel.h */,
|
|
||||||
E8DACCFD27673F870052092C /* MicroGiftValueModel.m */,
|
|
||||||
);
|
);
|
||||||
path = Model;
|
path = Model;
|
||||||
sourceTree = "<group>";
|
sourceTree = "<group>";
|
||||||
@@ -2018,6 +2016,8 @@
|
|||||||
E884C36B2743951B00E1EBED /* GiftReceiveInfoModel.m */,
|
E884C36B2743951B00E1EBED /* GiftReceiveInfoModel.m */,
|
||||||
E8E7DAE92745158500C631CC /* XPGiftUserInfoModel.h */,
|
E8E7DAE92745158500C631CC /* XPGiftUserInfoModel.h */,
|
||||||
E8E7DAEA2745158500C631CC /* XPGiftUserInfoModel.m */,
|
E8E7DAEA2745158500C631CC /* XPGiftUserInfoModel.m */,
|
||||||
|
E8DACCFC27673F870052092C /* GiftValueInfoModel.h */,
|
||||||
|
E8DACCFD27673F870052092C /* GiftValueInfoModel.m */,
|
||||||
);
|
);
|
||||||
path = Model;
|
path = Model;
|
||||||
sourceTree = "<group>";
|
sourceTree = "<group>";
|
||||||
@@ -3073,7 +3073,7 @@
|
|||||||
E8AEAED6271412EC0017FCE0 /* XPRoomViewController.m in Sources */,
|
E8AEAED6271412EC0017FCE0 /* XPRoomViewController.m in Sources */,
|
||||||
E8E70D9226F2F60C00F03460 /* XPMineItemModel.m in Sources */,
|
E8E70D9226F2F60C00F03460 /* XPMineItemModel.m in Sources */,
|
||||||
189DD74A26E21D8400AB55B1 /* SSKeychain.m in Sources */,
|
189DD74A26E21D8400AB55B1 /* SSKeychain.m in Sources */,
|
||||||
E8DACCFE27673F870052092C /* MicroGiftValueModel.m in Sources */,
|
E8DACCFE27673F870052092C /* GiftValueInfoModel.m in Sources */,
|
||||||
E8B846CF26FDD96100A777FE /* XPMineRechageHeadView.m in Sources */,
|
E8B846CF26FDD96100A777FE /* XPMineRechageHeadView.m in Sources */,
|
||||||
186A534926FC6ED900D67B2C /* TTAlertMessageAttributedConfig.m in Sources */,
|
186A534926FC6ED900D67B2C /* TTAlertMessageAttributedConfig.m in Sources */,
|
||||||
E81C27AE26EF39AB0031E639 /* AppDelegate+ThirdConfig.m in Sources */,
|
E81C27AE26EF39AB0031E639 /* AppDelegate+ThirdConfig.m in Sources */,
|
||||||
|
@@ -24,6 +24,8 @@ typedef NS_ENUM(NSUInteger, CustomMessageType) {
|
|||||||
CustomMessageType_Kick_User = 18,
|
CustomMessageType_Kick_User = 18,
|
||||||
///糖果树
|
///糖果树
|
||||||
CustomMessageType_Candy_Tree = 26,
|
CustomMessageType_Candy_Tree = 26,
|
||||||
|
///房间礼物值
|
||||||
|
CustomMessageType_Room_GiftValue = 42,
|
||||||
///福袋消息
|
///福袋消息
|
||||||
CustomMessageType_LuckyBag = 61,
|
CustomMessageType_LuckyBag = 61,
|
||||||
};
|
};
|
||||||
@@ -96,6 +98,12 @@ typedef NS_ENUM(NSUInteger, CustomMessageSubCandyTree) {
|
|||||||
//暴击的没用 不写了
|
//暴击的没用 不写了
|
||||||
};
|
};
|
||||||
|
|
||||||
|
///first = CustomMessageType_Room_GiftValue
|
||||||
|
typedef NS_ENUM(NSUInteger, CustomMessageSubRoomGiftValue) {
|
||||||
|
///礼物值同步
|
||||||
|
Custom_Message_Sub_Room_GiftValue_Sync = 421
|
||||||
|
};
|
||||||
|
|
||||||
///first = CustomMessageType_LuckyBag
|
///first = CustomMessageType_LuckyBag
|
||||||
typedef NS_ENUM(NSUInteger, CustomMessageSubLuckyBag) {
|
typedef NS_ENUM(NSUInteger, CustomMessageSubLuckyBag) {
|
||||||
/// 福袋礼物房间飘屏通知
|
/// 福袋礼物房间飘屏通知
|
||||||
|
@@ -4,47 +4,10 @@
|
|||||||
//
|
//
|
||||||
// Created by 冯硕 on 2021/11/16.
|
// Created by 冯硕 on 2021/11/16.
|
||||||
//
|
//
|
||||||
|
|
||||||
/*
|
|
||||||
avatar = "http://img.uat.lecheng163.com/FoNOJJrSIf9WpJ8jHC_7OGxP841o?imageslim";
|
|
||||||
currentTime = 1637047533593;
|
|
||||||
gift = {
|
|
||||||
consumeType = 1;
|
|
||||||
giftId = 1423;
|
|
||||||
giftName = "\U795e\U79d8\U7cbd\U5b50";
|
|
||||||
giftType = 2;
|
|
||||||
giftUrl = "http://image.uat.zhongjialx.com/FmDCm483cDGPfM1cy-KW2558HUHx?imageslim";
|
|
||||||
goldPrice = 33;
|
|
||||||
hasEffect = 0;
|
|
||||||
hasLatest = 0;
|
|
||||||
hasTimeLimit = 0;
|
|
||||||
hasVggPic = 0;
|
|
||||||
isNobleGift = 0;
|
|
||||||
isSendMsg = 0;
|
|
||||||
isSkipRoom = 0;
|
|
||||||
isWholeServer = 0;
|
|
||||||
nobleId = 0;
|
|
||||||
nobleName = "";
|
|
||||||
roomExclude = 0;
|
|
||||||
seqNo = 1;
|
|
||||||
vggUrl = "http://image.uat.zhongjialx.com/FmDCm483cDGPfM1cy-KW2558HUHx?imageslim";
|
|
||||||
};
|
|
||||||
giftId = 1423;
|
|
||||||
giftNum = 1;
|
|
||||||
nick = "\U636e\U5065\U5065\U5eb7\U5eb7****";
|
|
||||||
targetUsers = (
|
|
||||||
{
|
|
||||||
avatar = "http://img.uat.lecheng163.com/FnEA7WfDtE2gMLyEvGLkY0Sa9cRk?imageslim";
|
|
||||||
nick = "IU\U7684\U79d8\U5bc6\U7537\U53cb";
|
|
||||||
uid = 940317;
|
|
||||||
}
|
|
||||||
);
|
|
||||||
uid = 940318;*/
|
|
||||||
|
|
||||||
#import <Foundation/Foundation.h>
|
#import <Foundation/Foundation.h>
|
||||||
#import "GiftInfoModel.h"
|
#import "GiftInfoModel.h"
|
||||||
NS_ASSUME_NONNULL_BEGIN
|
NS_ASSUME_NONNULL_BEGIN
|
||||||
|
@class GiftValueInfoModel;
|
||||||
@interface GiftReceiveUserInfoModel : NSObject
|
@interface GiftReceiveUserInfoModel : NSObject
|
||||||
///收礼物的人
|
///收礼物的人
|
||||||
@property(nonatomic, strong)NSString *nick;
|
@property(nonatomic, strong)NSString *nick;
|
||||||
@@ -113,6 +76,8 @@ NS_ASSUME_NONNULL_BEGIN
|
|||||||
@property (nonatomic,assign) GiftSourceType sourceType;
|
@property (nonatomic,assign) GiftSourceType sourceType;
|
||||||
///房间送礼物的类型
|
///房间送礼物的类型
|
||||||
@property (nonatomic,assign) RoomSendGiftType roomSendGiftType;
|
@property (nonatomic,assign) RoomSendGiftType roomSendGiftType;
|
||||||
|
///礼物值信息
|
||||||
|
@property (nonatomic, strong) NSArray<GiftValueInfoModel *> *giftValueVos;
|
||||||
///是否是背包礼物
|
///是否是背包礼物
|
||||||
@property (nonatomic,assign) BOOL isLuckyBagGift;
|
@property (nonatomic,assign) BOOL isLuckyBagGift;
|
||||||
///是不是全麦
|
///是不是全麦
|
||||||
|
@@ -8,13 +8,13 @@
|
|||||||
#import <Foundation/Foundation.h>
|
#import <Foundation/Foundation.h>
|
||||||
|
|
||||||
NS_ASSUME_NONNULL_BEGIN
|
NS_ASSUME_NONNULL_BEGIN
|
||||||
@class MicroGiftValueDetailModel;
|
@class GiftValueDetailModel;
|
||||||
@interface MicroGiftValueModel : NSObject
|
@interface GiftValueInfoModel : NSObject
|
||||||
@property (nonatomic, copy) NSString *currentTime;//系统时间戳
|
@property (nonatomic, copy) NSString *currentTime;//系统时间戳
|
||||||
@property (nonatomic, strong) NSArray<MicroGiftValueDetailModel *> *giftValueVos;
|
@property (nonatomic, strong) NSArray<GiftValueDetailModel *> *giftValueVos;
|
||||||
@end
|
@end
|
||||||
|
|
||||||
@interface MicroGiftValueDetailModel : NSObject
|
@interface GiftValueDetailModel : NSObject
|
||||||
///用户的uid
|
///用户的uid
|
||||||
@property (nonatomic, copy) NSString * uid;
|
@property (nonatomic, copy) NSString * uid;
|
||||||
///礼物值
|
///礼物值
|
@@ -0,0 +1,23 @@
|
|||||||
|
//
|
||||||
|
// MicroGiftValueModel.m
|
||||||
|
// xplan-ios
|
||||||
|
//
|
||||||
|
// Created by 冯硕 on 2021/12/13.
|
||||||
|
//
|
||||||
|
|
||||||
|
#import "GiftValueInfoModel.h"
|
||||||
|
|
||||||
|
@implementation GiftValueInfoModel
|
||||||
|
|
||||||
|
+ (NSDictionary *)objectClassInArray {
|
||||||
|
return @{@"giftValueVos":GiftValueDetailModel.class};
|
||||||
|
}
|
||||||
|
|
||||||
|
@end
|
||||||
|
|
||||||
|
|
||||||
|
@implementation GiftValueDetailModel
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@end
|
@@ -249,6 +249,7 @@
|
|||||||
- (MicroGiftValueView *)giftValueView {
|
- (MicroGiftValueView *)giftValueView {
|
||||||
if (!_giftValueView) {
|
if (!_giftValueView) {
|
||||||
_giftValueView = [[MicroGiftValueView alloc] init];
|
_giftValueView = [[MicroGiftValueView alloc] init];
|
||||||
|
_giftValueView.hidden = YES;
|
||||||
}
|
}
|
||||||
return _giftValueView;
|
return _giftValueView;
|
||||||
}
|
}
|
||||||
|
@@ -1,23 +0,0 @@
|
|||||||
//
|
|
||||||
// MicroGiftValueModel.m
|
|
||||||
// xplan-ios
|
|
||||||
//
|
|
||||||
// Created by 冯硕 on 2021/12/13.
|
|
||||||
//
|
|
||||||
|
|
||||||
#import "MicroGiftValueModel.h"
|
|
||||||
|
|
||||||
@implementation MicroGiftValueModel
|
|
||||||
|
|
||||||
+ (NSDictionary *)objectClassInArray {
|
|
||||||
return @{@"giftValueVos":MicroGiftValueDetailModel.class};
|
|
||||||
}
|
|
||||||
|
|
||||||
@end
|
|
||||||
|
|
||||||
|
|
||||||
@implementation MicroGiftValueDetailModel
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@end
|
|
@@ -26,7 +26,7 @@
|
|||||||
#import "MicroQueueModel.h"
|
#import "MicroQueueModel.h"
|
||||||
#import "AttachmentModel.h"
|
#import "AttachmentModel.h"
|
||||||
#import "GiftReceiveInfoModel.h"
|
#import "GiftReceiveInfoModel.h"
|
||||||
#import "MicroGiftValueModel.h"
|
#import "GiftValueInfoModel.h"
|
||||||
///View
|
///View
|
||||||
#import "NetImageView.h"
|
#import "NetImageView.h"
|
||||||
#import "XPUserCardViewController.h"
|
#import "XPUserCardViewController.h"
|
||||||
@@ -171,6 +171,7 @@
|
|||||||
[view configMicroView:model];
|
[view configMicroView:model];
|
||||||
[view showLeaveMode:i == 0 && leaveMode];
|
[view showLeaveMode:i == 0 && leaveMode];
|
||||||
if (model.userInfo == nil) [view resetGiftValue];
|
if (model.userInfo == nil) [view resetGiftValue];
|
||||||
|
[view showGiftValueMode:roomInfo.showGiftValue];
|
||||||
if (self.hostDelegate.getUserInfo.uid && model.userInfo.uid == self.hostDelegate.getUserInfo.uid) {
|
if (self.hostDelegate.getUserInfo.uid && model.userInfo.uid == self.hostDelegate.getUserInfo.uid) {
|
||||||
selfNeedBroadcast = model.microState.micState == MicroMicStateType_Open;
|
selfNeedBroadcast = model.microState.micState == MicroMicStateType_Open;
|
||||||
}
|
}
|
||||||
@@ -190,9 +191,9 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
- (void)giftValueUpdate:(NSDictionary *)dic {
|
- (void)giftValueUpdate:(NSDictionary *)dic {
|
||||||
MicroGiftValueModel * model = [MicroGiftValueModel modelWithDictionary:dic];
|
GiftValueInfoModel * model = [GiftValueInfoModel modelWithDictionary:dic];
|
||||||
for (int i = 0; i < model.giftValueVos.count; i++) {
|
for (int i = 0; i < model.giftValueVos.count; i++) {
|
||||||
MicroGiftValueDetailModel * giftValueModel = [model.giftValueVos objectAtIndex:i];
|
GiftValueDetailModel * giftValueModel = [model.giftValueVos objectAtIndex:i];
|
||||||
UIView<MicroViewProtocol> * view = [self findMicroViewByUid:giftValueModel.uid];
|
UIView<MicroViewProtocol> * view = [self findMicroViewByUid:giftValueModel.uid];
|
||||||
if (view == nil) continue;
|
if (view == nil) continue;
|
||||||
[view configGiftValue:giftValueModel.giftValue];
|
[view configGiftValue:giftValueModel.giftValue];
|
||||||
@@ -256,8 +257,29 @@
|
|||||||
if (changeType == 1) { // 上麦
|
if (changeType == 1) { // 上麦
|
||||||
MicroQueueModel *sequence = [self.micQueue objectForKey:position];
|
MicroQueueModel *sequence = [self.micQueue objectForKey:position];
|
||||||
sequence.userInfo = userInfo;
|
sequence.userInfo = userInfo;
|
||||||
|
if (self.hostDelegate.getRoomInfo.showGiftValue && userInfo.uid == [AccountInfoStorage instance].getUid.integerValue) {
|
||||||
|
RoomInfoModel * roomInfo =self.hostDelegate.getRoomInfo;
|
||||||
|
NSString * roomUid = [NSString stringWithFormat:@"%ld", roomInfo.uid];
|
||||||
|
NSString * uid = [NSString stringWithFormat:@"%ld", userInfo.uid];
|
||||||
|
[Api roomGiftValueUpMic:^(BaseModel * _Nullable data, NSInteger code, NSString * _Nullable msg) {
|
||||||
|
if (code == 200) {
|
||||||
|
NIMMessage * message = [[NIMMessage alloc] init];
|
||||||
|
AttachmentModel * attachMent = [[AttachmentModel alloc] init];
|
||||||
|
attachMent.first = CustomMessageType_Room_GiftValue;
|
||||||
|
attachMent.second = Custom_Message_Sub_Room_GiftValue_Sync;
|
||||||
|
attachMent.data = data.data;
|
||||||
|
NIMCustomObject *object = [[NIMCustomObject alloc] init];
|
||||||
|
object.attachment = attachMent;
|
||||||
|
message.messageObject = object;
|
||||||
|
//构造会话
|
||||||
|
NSString * sessionId = [NSString stringWithFormat:@"%ld", roomInfo.roomId];
|
||||||
|
NIMSession *session = [NIMSession session:sessionId type:NIMSessionTypeChatroom];
|
||||||
|
[[NIMSDK sharedSDK].chatManager sendMessage:message toSession:session error:nil];
|
||||||
|
}
|
||||||
|
} roomUid:roomUid micUid:uid position:position uid:uid];
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
microQueueChanged = YES;
|
microQueueChanged = YES;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
@@ -319,7 +341,14 @@
|
|||||||
}];
|
}];
|
||||||
}];
|
}];
|
||||||
}
|
}
|
||||||
}
|
} else if(attachment.first == CustomMessageType_Room_GiftValue && attachment.second == Custom_Message_Sub_Room_GiftValue_Sync) {
|
||||||
|
[self giftValueUpdate:attachment.data];
|
||||||
|
} else if(attachment.first == CustomMessageType_Gift && (attachment.second == Custom_Message_Sub_Gift_Send || attachment.second == Custom_Message_Sub_Gift_LuckySend || attachment.second == Custom_Message_Sub_Gift_ChannelNotify)) {
|
||||||
|
[self giftValueUpdate:attachment.data];
|
||||||
|
}else if(attachment.first == CustomMessageType_AllMicroSend && (attachment.second == Custom_Message_Sub_AllMicroSend || attachment.second == Custom_Message_Sub_AllBatchSend || attachment.second == Custom_Message_Sub_AllMicroLuckySend || attachment.second == Custom_Message_Sub_AllBatchMicroLuckySend)) {
|
||||||
|
[self giftValueUpdate:attachment.data];
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#pragma mark - RtcDelegate - 讲话的波纹回调
|
#pragma mark - RtcDelegate - 讲话的波纹回调
|
||||||
|
@@ -285,6 +285,17 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//发送消息成功回调
|
||||||
|
- (void)sendMessage:(NIMMessage *)message didCompleteWithError:(NSError *)error {
|
||||||
|
if (error) return;
|
||||||
|
if (message.messageType == NIMMessageTypeCustom) {
|
||||||
|
NIMCustomObject *obj = (NIMCustomObject *)message.messageObject;
|
||||||
|
if (obj.attachment != nil && [obj.attachment isKindOfClass:[AttachmentModel class]]) {
|
||||||
|
[self.stageView handleNIMCustomMessage:obj.attachment];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
#pragma mark - RoomDelegate
|
#pragma mark - RoomDelegate
|
||||||
- (RoomInfoModel *)getRoomInfo {
|
- (RoomInfoModel *)getRoomInfo {
|
||||||
return self.roomInfo;
|
return self.roomInfo;
|
||||||
|
Reference in New Issue
Block a user