docs & feat: add license & attribution notice (Apache-2.0 / GPL-3.0) and core system enhancements
This commit is contained in:
1 parent
507836d367
commit
ce6aabfc55
47 files changed
+5674
-724
No files matched your search
@@ -194,54 +194,16 @@ func init() {
|
||||
})
|
||||
|
||||
handle("CycleScoreRewardTakeReward", func(s *Session, req *goproto.CycleScoreRewardTakeRewardCsReq, rsp *goproto.CycleScoreRewardTakeRewardScRsp) error {
|
||||
cfg, err := common.LoadRuntimeConfig()
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
rsp.Reward = &goproto.ItemList{}
|
||||
if req != nil {
|
||||
rsp.NGKOFMBBGNL = append(rsp.NGKOFMBBGNL, req.JKCEBHFIENI...)
|
||||
}
|
||||
rsp.NFEDANFBIBE = &goproto.GAAMBBFPCHB{
|
||||
EndTime: *cfg.ActivitySchedule.EndTime,
|
||||
}
|
||||
if cfg.ActivitySchedule.BeginTime != nil {
|
||||
rsp.NFEDANFBIBE.IFEPJHGNCOI = *cfg.ActivitySchedule.BeginTime
|
||||
}
|
||||
if scoreCatalog, err := common.LoadCurrencyWarsScore(nil); err == nil {
|
||||
rsp.NFEDANFBIBE.PMJGAJGIFOA = scoreCatalog.WeeklyCap
|
||||
for _, r := range scoreCatalog.WeeklyRanks {
|
||||
rsp.NFEDANFBIBE.OPLNKCOLCKJ = append(rsp.NFEDANFBIBE.OPLNKCOLCKJ, r.Rank)
|
||||
}
|
||||
}
|
||||
rsp.Retcode = 0
|
||||
PacketLog(fmt.Sprintf("CYCLE_SCORE_REWARD_TAKE claims=%v", rsp.NGKOFMBBGNL))
|
||||
// Reward eligibility, grant mapping and atomic claim persistence are not
|
||||
// verified yet. Never consume a claim or report an empty success.
|
||||
rsp.Retcode = uint32(goproto.Retcode_RET_GRID_FIGHT_CONF_MISS)
|
||||
return nil
|
||||
})
|
||||
|
||||
cwHandle("GridFightTakeWeeklyReward", func(s *Session, req *goproto.GridFightTakeWeeklyRewardCsReq, rsp *goproto.GridFightTakeWeeklyRewardScRsp) error {
|
||||
cfg, err := common.LoadRuntimeConfig()
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
rsp.Reward = &goproto.ItemList{}
|
||||
if req != nil {
|
||||
rsp.NGKOFMBBGNL = append(rsp.NGKOFMBBGNL, req.JKCEBHFIENI...)
|
||||
}
|
||||
rsp.MGBNEAHCDMA = &goproto.NDLNIKCCALK{
|
||||
EndTime: *cfg.ActivitySchedule.EndTime,
|
||||
}
|
||||
if cfg.ActivitySchedule.BeginTime != nil {
|
||||
rsp.MGBNEAHCDMA.IFEPJHGNCOI = *cfg.ActivitySchedule.BeginTime
|
||||
}
|
||||
if scoreCatalog, err := common.LoadCurrencyWarsScore(nil); err == nil {
|
||||
rsp.MGBNEAHCDMA.EDHKHJAPMKA = scoreCatalog.WeeklyCap
|
||||
for _, r := range scoreCatalog.WeeklyRanks {
|
||||
rsp.MGBNEAHCDMA.OPLNKCOLCKJ = append(rsp.MGBNEAHCDMA.OPLNKCOLCKJ, r.Rank)
|
||||
}
|
||||
}
|
||||
rsp.Retcode = 0
|
||||
PacketLog(fmt.Sprintf("CW_TAKE_WEEKLY_REWARD claims=%v", rsp.NGKOFMBBGNL))
|
||||
// Reward eligibility, grant mapping and atomic claim persistence are not
|
||||
// verified yet. Never consume a claim or report an empty success.
|
||||
rsp.Retcode = uint32(goproto.Retcode_RET_GRID_FIGHT_CONF_MISS)
|
||||
return nil
|
||||
})
|
||||
|
||||
|
||||
Reference in new issue
Block a user