修复bug
This commit is contained in:
@@ -286,7 +286,7 @@ UIKIT_EXTERN NSString *kTabShowAnchorCardKey;
|
||||
///
|
||||
-(void)requestGiftList{
|
||||
[self dealWithDefaultSvga];
|
||||
// /保存时间,一天只请求一次
|
||||
///所有礼物接口,缓存礼物,保存时间,一天只请求一次
|
||||
NSString *time = [NSDate getNowTimeTimestamp];
|
||||
NSString *curTime = [NSDate timestampSwitchTime:[time integerValue] andFormatter:@"yyyy-MM-dd"];
|
||||
NSDictionary *timeDic = [[NSUserDefaults standardUserDefaults]valueForKey:@"kRequestGiftList"];
|
||||
@@ -323,10 +323,12 @@ UIKIT_EXTERN NSString *kTabShowAnchorCardKey;
|
||||
}
|
||||
|
||||
-(void)dealWithDefaultSvga{
|
||||
///寻爱之旅动效
|
||||
NSArray *loveList = @[@"https://image.hfighting.com/candyTree_light.svga",@"https://image.hfighting.com/candyTree_open.svga",@"https://image.hfighting.com/candyTree_transform.svga"];
|
||||
for (NSString *url in loveList) {
|
||||
[self dealWithGiftListWithUrl:url fileName:url isSvga:YES];
|
||||
}
|
||||
///夺宝精灵动效
|
||||
NSArray *elfList = @[@"https://image.hfighting.com/treasure_fairy_trials_middle.mp4",@"https://image.hfighting.com/treasure_fairy_ten.mp4",@"https://image.hfighting.com/treasure_fairy_trials_high.mp4",@"https://image.hfighting.com/treasure_fairy_one.mp4"];
|
||||
for (NSString *url in elfList) {
|
||||
[self dealWithGiftListWithUrl:url fileName:url isSvga:NO];
|
||||
@@ -510,7 +512,7 @@ UIKIT_EXTERN NSString *kTabShowAnchorCardKey;
|
||||
#pragma mark - NIMChatManagerDelegate
|
||||
|
||||
- (void)onRecvMessages:(NSArray<NIMMessage *> *)messages {
|
||||
if (self.parentMode || ![ClientConfig shareConfig].canOpen) {
|
||||
if (self.parentMode || ![ClientConfig shareConfig].canOpen || [AccountInfoStorage instance].getTicket.length == 0) {
|
||||
return;
|
||||
}
|
||||
for (NIMMessage * message in messages) {
|
||||
@@ -518,7 +520,7 @@ UIKIT_EXTERN NSString *kTabShowAnchorCardKey;
|
||||
if(message.messageType == NIMMessageTypeCustom) {
|
||||
NIMCustomObject *obj = (NIMCustomObject *)message.messageObject;
|
||||
if (obj.attachment != nil && [obj.attachment isKindOfClass:[AttachmentModel class]]) {
|
||||
AttachmentModel * attachment = obj.attachment;
|
||||
AttachmentModel * attachment = (AttachmentModel *)obj.attachment;
|
||||
if (attachment.first == CustomMessageType_FindNew && attachment.second == Custom_Message_Find_New_Greet_New_User) {
|
||||
FindNewGreetMessageModel * greetInfo = [FindNewGreetMessageModel modelWithDictionary:attachment.data];
|
||||
if (greetInfo.uid.integerValue != [AccountInfoStorage instance].getUid.integerValue) {
|
||||
@@ -595,6 +597,9 @@ UIKIT_EXTERN NSString *kTabShowAnchorCardKey;
|
||||
}else if(attachment.first == CustomMessageType_Look_Love && attachment.second == Custom_Message_Sub_Look_Love_InRoom_NeedAllMicSend){
|
||||
if([XPSkillCardPlayerManager shareInstance].isInRoomVC == YES)return;
|
||||
[self.roomAnimation receiveCandyTreeGiftHighLevle:attachment];
|
||||
}else if (attachment.first == CustomMessageType_Treasure_Fairy && (attachment.second == Custom_Message_Sub_Treasure_Fairy_Draw_Gift_L4 || attachment.second == Custom_Message_Sub_Treasure_Fairy_Draw_Gift_L5 || attachment.second == Custom_Message_Sub_Treasure_Fairy_Convert_L1 || attachment.second == Custom_Message_Sub_Treasure_Fairy_Convert_L2 || attachment.second == Custom_Message_Sub_Treasure_Fairy_Convert_L3)) { //夺宝精灵
|
||||
if([XPSkillCardPlayerManager shareInstance].isInRoomVC == YES)return;
|
||||
[self.roomAnimation receiveTreasureFairyGiftHighLevel:attachment];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user