Commit b5540360 authored by hujiebin's avatar hujiebin

fix:二级以上才有进场特效

parent f2f086fe
......@@ -304,10 +304,12 @@ func GetUserCpEntryEffect(c *gin.Context) (*mycontext.MyContext, error) {
privilegeList[i].UserSwitch = userPrivileges[userId][v.Type]
}
}
// 我的特权,有开关并且打开才返回
for _, v := range privilegeList {
if v.Type == cp_e.CpPrivilegeRoomEffect && v.UserSwitch {
response.CpEntryEffect = true
// 二级以上才有进场特效
if cpLevel >= cp_e.CpLevel2 {
for _, v := range privilegeList {
if v.Type == cp_e.CpPrivilegeRoomEffect && v.UserSwitch {
response.CpEntryEffect = true
}
}
}
if cpUser, _ := user_c.GetUserTinyById(model, cpUserId); cpUser != nil {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment