中心服优化
This commit is contained in:
parent
fefc3e6eae
commit
485280243a
@ -902,17 +902,11 @@ func CreateRobot(M float64, GroupId int) *ChampshipRobot {
|
||||
PerScore = math.Round((M/10*0.34)/(float64(GoUtil.NextZeroTimestampDuration())/1800)*100) / 100
|
||||
Score = 2
|
||||
}
|
||||
num, err := db.RedisZCard(RANK_USER)
|
||||
if err != nil {
|
||||
num = 0
|
||||
}
|
||||
id := rand.Intn(int(num)) + 1
|
||||
rinfo, err := db.RedisZGetByIndexWithScore(RANK_USER, int64(id))
|
||||
playerSimpleData := G_GameLogicPtr.GetSimplePlayerByUid(GoUtil.Int(rinfo.Member))
|
||||
return &ChampshipRobot{
|
||||
Max: M / 10,
|
||||
Type: Type,
|
||||
Name: randnameCfg.GetRandName(),
|
||||
PetName: randnameCfg.GetRandName(),
|
||||
Avatar: avatarCfg.GetRandInitId(),
|
||||
Face: faceCfg.GetRandInitId(),
|
||||
Level: GoUtil.RandNum(1, 10),
|
||||
@ -920,9 +914,6 @@ func CreateRobot(M float64, GroupId int) *ChampshipRobot {
|
||||
Time: GoUtil.Now(),
|
||||
Score: Score,
|
||||
PerScore: PerScore,
|
||||
Playroom: playerSimpleData.Playroom,
|
||||
DressSet: playerSimpleData.DressSet,
|
||||
FurSet: playerSimpleData.PetFur,
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user