Commit 2446333e21d2b528f7bbf5dad4c18929666d7623
1 parent
d28494f7
Exists in
master
提交
Showing
1 changed file
with
2 additions
and
2 deletions
Show diff stats
src/HttpServer/logic/logic.go
@@ -309,7 +309,7 @@ func HandlerGetUserData(w http.ResponseWriter, data string, uuid int) { | @@ -309,7 +309,7 @@ func HandlerGetUserData(w http.ResponseWriter, data string, uuid int) { | ||
309 | resp.Data.TimingReward = true | 309 | resp.Data.TimingReward = true |
310 | resp.Data.Now = int(time.Now().Unix()) | 310 | resp.Data.Now = int(time.Now().Unix()) |
311 | 311 | ||
312 | - uinfo.Gold = addgold | 312 | + uinfo.Gold += addgold |
313 | uinfo.GoldSum += addgold | 313 | uinfo.GoldSum += addgold |
314 | uinfo.AddToRank() | 314 | uinfo.AddToRank() |
315 | resp.Data.Output = strconv.FormatInt(uinfo.Goldrate, 10) | 315 | resp.Data.Output = strconv.FormatInt(uinfo.Goldrate, 10) |
@@ -485,7 +485,7 @@ func HandlerGetMainPageInfo(w http.ResponseWriter, data string, uuid int) { | @@ -485,7 +485,7 @@ func HandlerGetMainPageInfo(w http.ResponseWriter, data string, uuid int) { | ||
485 | addgold = uinfo.Goldrate * offsec | 485 | addgold = uinfo.Goldrate * offsec |
486 | } | 486 | } |
487 | 487 | ||
488 | - uinfo.Gold = addgold | 488 | + uinfo.Gold += addgold |
489 | uinfo.GoldSum += addgold | 489 | uinfo.GoldSum += addgold |
490 | uinfo.AddToRank() | 490 | uinfo.AddToRank() |
491 | } | 491 | } |