|
@@ -90,12 +90,18 @@ func (p *actorPlayer) OnInit() {
|
|
|
p.Timer().Add(1*time.Minute, p.upatePlayerLevelStat)
|
|
|
|
|
|
//在线用户定时刷新
|
|
|
- p.Timer().Add(1*time.Minute, p.Player.InitDaily)
|
|
|
+ p.Timer().Add(1*time.Minute, p.initDaily)
|
|
|
|
|
|
//p.Timer().Add(30*time.Second, p.getAndUpdateAvatar) //排行榜头像
|
|
|
|
|
|
}
|
|
|
|
|
|
+func (p *actorPlayer) initDaily() {
|
|
|
+ if p.isOnline {
|
|
|
+ p.Player.InitDaily()
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
func (p *actorPlayer) addRoll() {
|
|
|
if p.isOnline {
|
|
|
if p.Player.Item[models.ItemRoll].Num < 10 {
|