This commit is contained in:
aozhiwei 2024-04-25 08:36:11 +08:00
parent a2faf6e60a
commit 75e3d5dde8
3 changed files with 9 additions and 0 deletions

View File

@ -44,6 +44,7 @@ type PlayerMgr interface {
type Mail interface {
GetMailId() int64
IsValid(Player) bool
GetExpireTime() int32
}
type MailMgr interface{

View File

@ -46,6 +46,10 @@ func (this *mail) GetMailId() int64 {
return this.mailId
}
func (this *mail) GetExpireTime() int32 {
return this.expireTime
}
func (this *mail) fillMailDto(p *common.MailDto) bool {
p.MailId = q5.ToString(this.mailId)
p.From = ""

View File

@ -57,6 +57,10 @@ func (this *player) MarkMails(mails []common.Mail) error {
break
}
mi = new(inbox)
mi.mailId = m.GetMailId()
mi.state = constant.INBOX_STATE_READ
mi.expireTime = m.GetExpireTime()
this.inboxHash[mi.mailId] = mi
}
}
}