diff --git a/rpc/user_center_func.go b/rpc/user_center_func.go index 2467c7bb9b8f9f2b369c5988fb491240b1a1dfac..e0546d0c74806f82d9ac2b93b3426456a8fe6759 100644 --- a/rpc/user_center_func.go +++ b/rpc/user_center_func.go @@ -68,12 +68,10 @@ func SendGlobalRocketNotice(groupId string, period string, round uint32, stage u } // 发送钻石变化通知 -func SendDiamondChange(userId uint64, diamond uint32, pinkDiamond ...uint32) error { +func SendDiamondChange(userId uint64, diamond, pinkDiamond uint32) error { msg := &userProxy.DiamondChange{ - RemainDiamond: diamond, - } - if len(pinkDiamond) > 0 { - msg.RemainPinkDiamond = pinkDiamond[0] + RemainDiamond: diamond, + RemainPinkDiamond: pinkDiamond, } if buffer, err := proto.Marshal(msg); err == nil { rspUids, err := multicast([]uint64{userId}, MsgDiamondChange, buffer)