24 lines
664 B
Go
24 lines
664 B
Go
|
|
package controller
|
||
|
|
|
||
|
|
import (
|
||
|
|
"blazing/common/socket/errorcode"
|
||
|
|
"blazing/logic/service/item"
|
||
|
|
"blazing/logic/service/player"
|
||
|
|
)
|
||
|
|
|
||
|
|
func (h Controller) PlayerGoldCount(data *item.GoldOnlineRemainInboundInfo, c *player.Player) (result *item.GoldOnlineRemainOutboundInfo, err errorcode.ErrorCode) {
|
||
|
|
|
||
|
|
return &item.GoldOnlineRemainOutboundInfo{
|
||
|
|
|
||
|
|
GoldNumber: uint32(c.Info.GoldBean) * 100,
|
||
|
|
Coin: c.Info.Coins,
|
||
|
|
}, 0
|
||
|
|
}
|
||
|
|
func (h Controller) PlayerExp(data *item.ExpTotalRemainInboundInfo, c *player.Player) (result *item.ExpTotalRemainOutboundInfo, err errorcode.ErrorCode) {
|
||
|
|
|
||
|
|
return &item.ExpTotalRemainOutboundInfo{
|
||
|
|
|
||
|
|
TotalExp: uint32(c.Info.ExpPool),
|
||
|
|
}, 0
|
||
|
|
}
|