上传竞技场代码
This commit is contained in:
parent
70cb9f1150
commit
13fd75e2e9
@ -104,9 +104,21 @@ func (this *Arena) Reddot(session comm.IUserSession, rid ...comm.ReddotType) (re
|
||||
ticket int32
|
||||
err error
|
||||
)
|
||||
|
||||
result = make(map[comm.ReddotType]*pb.ReddotItem)
|
||||
if model, err = this.modelArena.getpandataModel(); err != nil {
|
||||
this.Errorln(err)
|
||||
result[comm.Reddot22100] = &pb.ReddotItem{
|
||||
Rid: int32(comm.Reddot22100),
|
||||
Activated: false,
|
||||
}
|
||||
result[comm.Reddot22102] = &pb.ReddotItem{
|
||||
Rid: int32(comm.Reddot22102),
|
||||
Activated: false,
|
||||
}
|
||||
result[comm.Reddot22202] = &pb.ReddotItem{
|
||||
Rid: int32(comm.Reddot22202),
|
||||
Activated: false,
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
@ -117,11 +129,11 @@ func (this *Arena) Reddot(session comm.IUserSession, rid ...comm.ReddotType) (re
|
||||
for _, v := range rid {
|
||||
switch v {
|
||||
case comm.Reddot22100:
|
||||
result[comm.Reddot22102] = &pb.ReddotItem{
|
||||
Rid: int32(comm.Reddot22102),
|
||||
result[comm.Reddot22100] = &pb.ReddotItem{
|
||||
Rid: int32(comm.Reddot22100),
|
||||
}
|
||||
if ticket == this.ModuleTools.GetGlobalConf().ArenaTicketCos.N {
|
||||
result[comm.Reddot22102].Activated = true
|
||||
result[comm.Reddot22100].Activated = true
|
||||
}
|
||||
break
|
||||
case comm.Reddot22102:
|
||||
@ -132,8 +144,8 @@ func (this *Arena) Reddot(session comm.IUserSession, rid ...comm.ReddotType) (re
|
||||
break
|
||||
|
||||
case comm.Reddot22202:
|
||||
result[comm.Reddot22102] = &pb.ReddotItem{
|
||||
Rid: int32(comm.Reddot22102),
|
||||
result[comm.Reddot22202] = &pb.ReddotItem{
|
||||
Rid: int32(comm.Reddot22202),
|
||||
Activated: true,
|
||||
Progress: ticket,
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user