This commit is contained in:
liwei 2023-08-10 15:22:51 +08:00
commit 959a467d3a
5 changed files with 138 additions and 108 deletions

View File

@ -122,6 +122,9 @@ func (this *apiComp) UseGift(session comm.IUserSession, req *pb.LibraryUseGiftRe
}
}
}
if likeStates == 0 {
addExp = int32(math.Floor(float64(addExp / 1000)))
}
res = append(res, &cfg.Gameatn{
A: "item",

View File

@ -5,6 +5,7 @@ import (
"go_dreamfactory/comm"
"go_dreamfactory/pb"
cfg "go_dreamfactory/sys/configure/structs"
"strconv"
)
//参数校验
@ -80,12 +81,21 @@ func (this *apiComp) Event(session comm.IUserSession, req *pb.StonehengeEventReq
}
} else if eventConf.EventType == EventType25 {
lenSelect := len(stone.Rooms.Selectbuff)
if lenSelect == 0 || lenSelect <= int(req.Param1) {
if pos, err := strconv.Atoi(req.Param1); err == nil {
if lenSelect == 0 || lenSelect <= pos {
return
}
stone.Userbuff[stone.Rooms.Selectbuff[req.Param1]] = 1
stone.Userbuff[stone.Rooms.Selectbuff[pos]] = 1
stone.Rooms.Selectbuff = []int32{}
update["userbuff"] = stone.Userbuff
} else { // 参数错误
errdata = &pb.ErrorData{
Code: pb.ErrorCode_ReqParameterError,
Title: pb.ErrorCode_ReqParameterError.ToString(),
Message: err.Error(),
}
}
} else if eventConf.EventType == EventType14 || eventConf.EventType == EventType28 { // 战斗事件合并
if req.Report == nil {
errdata = &pb.ErrorData{

View File

@ -2,6 +2,7 @@ package stonehenge
// 事件类型
const (
EventType10 = 10 // 宝箱事件
EventType14 = 14 // 战斗事件
EventType16 = 16 // 捡垃圾事件
EventType25 = 25 // buff三选一

View File

@ -34,6 +34,7 @@ type RoomData struct {
Index int32 `protobuf:"varint,6,opt,name=index,proto3" json:"index"` // 房间索引
Roomid int32 `protobuf:"varint,7,opt,name=roomid,proto3" json:"roomid"` // 房间id
Hero []string `protobuf:"bytes,8,rep,name=hero,proto3" json:"hero"` //上阵英雄 继承血量用
Box map[int32]int32 `protobuf:"bytes,9,rep,name=box,proto3" json:"box" protobuf_key:"varint,1,opt,name=key,proto3" protobuf_val:"varint,2,opt,name=value,proto3"` // 宝箱事件
}
func (x *RoomData) Reset() {
@ -117,6 +118,13 @@ func (x *RoomData) GetHero() []string {
return nil
}
func (x *RoomData) GetBox() map[int32]int32 {
if x != nil {
return x.Box
}
return nil
}
type DBStonehenge struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
@ -376,7 +384,7 @@ var file_stonehenge_stonehenge_db_proto_rawDesc = []byte{
0x0a, 0x1e, 0x73, 0x74, 0x6f, 0x6e, 0x65, 0x68, 0x65, 0x6e, 0x67, 0x65, 0x2f, 0x73, 0x74, 0x6f,
0x6e, 0x65, 0x68, 0x65, 0x6e, 0x67, 0x65, 0x5f, 0x64, 0x62, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f,
0x1a, 0x16, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x2f, 0x62, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x5f,
0x64, 0x62, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x8e, 0x02, 0x0a, 0x08, 0x52, 0x6f, 0x6f,
0x64, 0x62, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xec, 0x02, 0x0a, 0x08, 0x52, 0x6f, 0x6f,
0x6d, 0x44, 0x61, 0x74, 0x61, 0x12, 0x30, 0x0a, 0x07, 0x65, 0x76, 0x65, 0x6e, 0x74, 0x69, 0x64,
0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x16, 0x2e, 0x52, 0x6f, 0x6f, 0x6d, 0x44, 0x61, 0x74,
0x61, 0x2e, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x69, 0x64, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x07,
@ -389,72 +397,78 @@ var file_stonehenge_stonehenge_db_proto_rawDesc = []byte{
0x6e, 0x64, 0x65, 0x78, 0x18, 0x06, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x69, 0x6e, 0x64, 0x65,
0x78, 0x12, 0x16, 0x0a, 0x06, 0x72, 0x6f, 0x6f, 0x6d, 0x69, 0x64, 0x18, 0x07, 0x20, 0x01, 0x28,
0x05, 0x52, 0x06, 0x72, 0x6f, 0x6f, 0x6d, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x68, 0x65, 0x72,
0x6f, 0x18, 0x08, 0x20, 0x03, 0x28, 0x09, 0x52, 0x04, 0x68, 0x65, 0x72, 0x6f, 0x1a, 0x3a, 0x0a,
0x0c, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x69, 0x64, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a,
0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12,
0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x05,
0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0xac, 0x05, 0x0a, 0x0c, 0x44, 0x42,
0x53, 0x74, 0x6f, 0x6e, 0x65, 0x68, 0x65, 0x6e, 0x67, 0x65, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64,
0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69,
0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x18, 0x0a, 0x07,
0x73, 0x74, 0x61, 0x67, 0x65, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x73,
0x74, 0x61, 0x67, 0x65, 0x49, 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x63, 0x75, 0x72, 0x52, 0x6f, 0x6f,
0x6d, 0x49, 0x6e, 0x64, 0x65, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0c, 0x63, 0x75,
0x72, 0x52, 0x6f, 0x6f, 0x6d, 0x49, 0x6e, 0x64, 0x65, 0x73, 0x12, 0x1f, 0x0a, 0x05, 0x72, 0x6f,
0x6f, 0x6d, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x09, 0x2e, 0x52, 0x6f, 0x6f, 0x6d,
0x44, 0x61, 0x74, 0x61, 0x52, 0x05, 0x72, 0x6f, 0x6f, 0x6d, 0x73, 0x12, 0x16, 0x0a, 0x06, 0x77,
0x65, 0x62, 0x75, 0x66, 0x66, 0x18, 0x06, 0x20, 0x03, 0x28, 0x05, 0x52, 0x06, 0x77, 0x65, 0x62,
0x75, 0x66, 0x66, 0x12, 0x1c, 0x0a, 0x09, 0x65, 0x6e, 0x65, 0x6d, 0x79, 0x62, 0x75, 0x66, 0x66,
0x18, 0x07, 0x20, 0x03, 0x28, 0x05, 0x52, 0x09, 0x65, 0x6e, 0x65, 0x6d, 0x79, 0x62, 0x75, 0x66,
0x66, 0x12, 0x37, 0x0a, 0x08, 0x75, 0x73, 0x65, 0x72, 0x62, 0x75, 0x66, 0x66, 0x18, 0x08, 0x20,
0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x44, 0x42, 0x53, 0x74, 0x6f, 0x6e, 0x65, 0x68, 0x65, 0x6e,
0x67, 0x65, 0x2e, 0x55, 0x73, 0x65, 0x72, 0x62, 0x75, 0x66, 0x66, 0x45, 0x6e, 0x74, 0x72, 0x79,
0x52, 0x08, 0x75, 0x73, 0x65, 0x72, 0x62, 0x75, 0x66, 0x66, 0x12, 0x2b, 0x0a, 0x04, 0x68, 0x65,
0x72, 0x6f, 0x18, 0x09, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x44, 0x42, 0x53, 0x74, 0x6f,
0x6e, 0x65, 0x68, 0x65, 0x6e, 0x67, 0x65, 0x2e, 0x48, 0x65, 0x72, 0x6f, 0x45, 0x6e, 0x74, 0x72,
0x79, 0x52, 0x04, 0x68, 0x65, 0x72, 0x6f, 0x12, 0x31, 0x0a, 0x06, 0x72, 0x65, 0x77, 0x61, 0x72,
0x64, 0x18, 0x0a, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x44, 0x42, 0x53, 0x74, 0x6f, 0x6e,
0x65, 0x68, 0x65, 0x6e, 0x67, 0x65, 0x2e, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x45, 0x6e, 0x74,
0x72, 0x79, 0x52, 0x06, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x12, 0x3a, 0x0a, 0x09, 0x61, 0x64,
0x64, 0x77, 0x65, 0x69, 0x67, 0x68, 0x74, 0x18, 0x0b, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1c, 0x2e,
0x44, 0x42, 0x53, 0x74, 0x6f, 0x6e, 0x65, 0x68, 0x65, 0x6e, 0x67, 0x65, 0x2e, 0x41, 0x64, 0x64,
0x77, 0x65, 0x69, 0x67, 0x68, 0x74, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x09, 0x61, 0x64, 0x64,
0x77, 0x65, 0x69, 0x67, 0x68, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x65, 0x74, 0x69, 0x6d, 0x65, 0x18,
0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x65, 0x74, 0x69, 0x6d, 0x65, 0x1a, 0x3b, 0x0a, 0x0d,
0x55, 0x73, 0x65, 0x72, 0x62, 0x75, 0x66, 0x66, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a,
0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12,
0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05,
0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x1a, 0x44, 0x0a, 0x09, 0x48, 0x65, 0x72,
0x6f, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20,
0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x21, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75,
0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0b, 0x2e, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65,
0x52, 0x6f, 0x6c, 0x65, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x1a,
0x39, 0x0a, 0x0b, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10,
0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6b, 0x65, 0x79,
0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52,
0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x1a, 0x3c, 0x0a, 0x0e, 0x41, 0x64,
0x64, 0x77, 0x65, 0x69, 0x67, 0x68, 0x74, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03,
0x6f, 0x18, 0x08, 0x20, 0x03, 0x28, 0x09, 0x52, 0x04, 0x68, 0x65, 0x72, 0x6f, 0x12, 0x24, 0x0a,
0x03, 0x62, 0x6f, 0x78, 0x18, 0x09, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x52, 0x6f, 0x6f,
0x6d, 0x44, 0x61, 0x74, 0x61, 0x2e, 0x42, 0x6f, 0x78, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x03,
0x62, 0x6f, 0x78, 0x1a, 0x3a, 0x0a, 0x0c, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x69, 0x64, 0x45, 0x6e,
0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05,
0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02,
0x20, 0x01, 0x28, 0x08, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x1a,
0x36, 0x0a, 0x08, 0x42, 0x6f, 0x78, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b,
0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a,
0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x76, 0x61,
0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0xac, 0x05, 0x0a, 0x0c, 0x44, 0x42, 0x53, 0x74,
0x6f, 0x6e, 0x65, 0x68, 0x65, 0x6e, 0x67, 0x65, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01,
0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, 0x18,
0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x74,
0x61, 0x67, 0x65, 0x49, 0x44, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x73, 0x74, 0x61,
0x67, 0x65, 0x49, 0x44, 0x12, 0x22, 0x0a, 0x0c, 0x63, 0x75, 0x72, 0x52, 0x6f, 0x6f, 0x6d, 0x49,
0x6e, 0x64, 0x65, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0c, 0x63, 0x75, 0x72, 0x52,
0x6f, 0x6f, 0x6d, 0x49, 0x6e, 0x64, 0x65, 0x73, 0x12, 0x1f, 0x0a, 0x05, 0x72, 0x6f, 0x6f, 0x6d,
0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x09, 0x2e, 0x52, 0x6f, 0x6f, 0x6d, 0x44, 0x61,
0x74, 0x61, 0x52, 0x05, 0x72, 0x6f, 0x6f, 0x6d, 0x73, 0x12, 0x16, 0x0a, 0x06, 0x77, 0x65, 0x62,
0x75, 0x66, 0x66, 0x18, 0x06, 0x20, 0x03, 0x28, 0x05, 0x52, 0x06, 0x77, 0x65, 0x62, 0x75, 0x66,
0x66, 0x12, 0x1c, 0x0a, 0x09, 0x65, 0x6e, 0x65, 0x6d, 0x79, 0x62, 0x75, 0x66, 0x66, 0x18, 0x07,
0x20, 0x03, 0x28, 0x05, 0x52, 0x09, 0x65, 0x6e, 0x65, 0x6d, 0x79, 0x62, 0x75, 0x66, 0x66, 0x12,
0x37, 0x0a, 0x08, 0x75, 0x73, 0x65, 0x72, 0x62, 0x75, 0x66, 0x66, 0x18, 0x08, 0x20, 0x03, 0x28,
0x0b, 0x32, 0x1b, 0x2e, 0x44, 0x42, 0x53, 0x74, 0x6f, 0x6e, 0x65, 0x68, 0x65, 0x6e, 0x67, 0x65,
0x2e, 0x55, 0x73, 0x65, 0x72, 0x62, 0x75, 0x66, 0x66, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x08,
0x75, 0x73, 0x65, 0x72, 0x62, 0x75, 0x66, 0x66, 0x12, 0x2b, 0x0a, 0x04, 0x68, 0x65, 0x72, 0x6f,
0x18, 0x09, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x44, 0x42, 0x53, 0x74, 0x6f, 0x6e, 0x65,
0x68, 0x65, 0x6e, 0x67, 0x65, 0x2e, 0x48, 0x65, 0x72, 0x6f, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52,
0x04, 0x68, 0x65, 0x72, 0x6f, 0x12, 0x31, 0x0a, 0x06, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x18,
0x0a, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x44, 0x42, 0x53, 0x74, 0x6f, 0x6e, 0x65, 0x68,
0x65, 0x6e, 0x67, 0x65, 0x2e, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x45, 0x6e, 0x74, 0x72, 0x79,
0x52, 0x06, 0x72, 0x65, 0x77, 0x61, 0x72, 0x64, 0x12, 0x3a, 0x0a, 0x09, 0x61, 0x64, 0x64, 0x77,
0x65, 0x69, 0x67, 0x68, 0x74, 0x18, 0x0b, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1c, 0x2e, 0x44, 0x42,
0x53, 0x74, 0x6f, 0x6e, 0x65, 0x68, 0x65, 0x6e, 0x67, 0x65, 0x2e, 0x41, 0x64, 0x64, 0x77, 0x65,
0x69, 0x67, 0x68, 0x74, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x09, 0x61, 0x64, 0x64, 0x77, 0x65,
0x69, 0x67, 0x68, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x65, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x0c, 0x20,
0x01, 0x28, 0x03, 0x52, 0x05, 0x65, 0x74, 0x69, 0x6d, 0x65, 0x1a, 0x3b, 0x0a, 0x0d, 0x55, 0x73,
0x65, 0x72, 0x62, 0x75, 0x66, 0x66, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b,
0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a,
0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x76, 0x61,
0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x1a, 0x44, 0x0a, 0x09, 0x48, 0x65, 0x72, 0x6f, 0x45,
0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28,
0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x21, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18,
0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0b, 0x2e, 0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x52, 0x6f,
0x6c, 0x65, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x1a, 0x39, 0x0a,
0x0b, 0x52, 0x65, 0x77, 0x61, 0x72, 0x64, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03,
0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14,
0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x76,
0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0x5f, 0x0a, 0x09, 0x53, 0x74, 0x61, 0x67,
0x65, 0x44, 0x61, 0x74, 0x61, 0x12, 0x1c, 0x0a, 0x09, 0x6d, 0x61, 0x69, 0x6e, 0x65, 0x62, 0x75,
0x66, 0x66, 0x18, 0x01, 0x20, 0x03, 0x28, 0x05, 0x52, 0x09, 0x6d, 0x61, 0x69, 0x6e, 0x65, 0x62,
0x75, 0x66, 0x66, 0x12, 0x1c, 0x0a, 0x09, 0x65, 0x6e, 0x65, 0x6d, 0x79, 0x62, 0x75, 0x66, 0x66,
0x18, 0x02, 0x20, 0x03, 0x28, 0x05, 0x52, 0x09, 0x65, 0x6e, 0x65, 0x6d, 0x79, 0x62, 0x75, 0x66,
0x66, 0x12, 0x16, 0x0a, 0x06, 0x72, 0x6f, 0x6f, 0x6d, 0x69, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28,
0x05, 0x52, 0x06, 0x72, 0x6f, 0x6f, 0x6d, 0x69, 0x64, 0x22, 0xa8, 0x01, 0x0a, 0x0b, 0x44, 0x42,
0x53, 0x74, 0x6f, 0x6e, 0x65, 0x42, 0x6f, 0x73, 0x73, 0x12, 0x39, 0x0a, 0x09, 0x62, 0x6f, 0x73,
0x73, 0x73, 0x74, 0x61, 0x67, 0x65, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x44,
0x42, 0x53, 0x74, 0x6f, 0x6e, 0x65, 0x42, 0x6f, 0x73, 0x73, 0x2e, 0x42, 0x6f, 0x73, 0x73, 0x73,
0x74, 0x61, 0x67, 0x65, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x09, 0x62, 0x6f, 0x73, 0x73, 0x73,
0x74, 0x61, 0x67, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x72, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x02, 0x20,
0x01, 0x28, 0x03, 0x52, 0x05, 0x72, 0x74, 0x69, 0x6d, 0x65, 0x1a, 0x48, 0x0a, 0x0e, 0x42, 0x6f,
0x73, 0x73, 0x73, 0x74, 0x61, 0x67, 0x65, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03,
0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x20,
0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0a, 0x2e,
0x53, 0x74, 0x61, 0x67, 0x65, 0x44, 0x61, 0x74, 0x61, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65,
0x3a, 0x02, 0x38, 0x01, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72,
0x6f, 0x74, 0x6f, 0x33,
0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x05, 0x76,
0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x1a, 0x3c, 0x0a, 0x0e, 0x41, 0x64, 0x64, 0x77,
0x65, 0x69, 0x67, 0x68, 0x74, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65,
0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05,
0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x76, 0x61, 0x6c,
0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0x5f, 0x0a, 0x09, 0x53, 0x74, 0x61, 0x67, 0x65, 0x44,
0x61, 0x74, 0x61, 0x12, 0x1c, 0x0a, 0x09, 0x6d, 0x61, 0x69, 0x6e, 0x65, 0x62, 0x75, 0x66, 0x66,
0x18, 0x01, 0x20, 0x03, 0x28, 0x05, 0x52, 0x09, 0x6d, 0x61, 0x69, 0x6e, 0x65, 0x62, 0x75, 0x66,
0x66, 0x12, 0x1c, 0x0a, 0x09, 0x65, 0x6e, 0x65, 0x6d, 0x79, 0x62, 0x75, 0x66, 0x66, 0x18, 0x02,
0x20, 0x03, 0x28, 0x05, 0x52, 0x09, 0x65, 0x6e, 0x65, 0x6d, 0x79, 0x62, 0x75, 0x66, 0x66, 0x12,
0x16, 0x0a, 0x06, 0x72, 0x6f, 0x6f, 0x6d, 0x69, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52,
0x06, 0x72, 0x6f, 0x6f, 0x6d, 0x69, 0x64, 0x22, 0xa8, 0x01, 0x0a, 0x0b, 0x44, 0x42, 0x53, 0x74,
0x6f, 0x6e, 0x65, 0x42, 0x6f, 0x73, 0x73, 0x12, 0x39, 0x0a, 0x09, 0x62, 0x6f, 0x73, 0x73, 0x73,
0x74, 0x61, 0x67, 0x65, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x44, 0x42, 0x53,
0x74, 0x6f, 0x6e, 0x65, 0x42, 0x6f, 0x73, 0x73, 0x2e, 0x42, 0x6f, 0x73, 0x73, 0x73, 0x74, 0x61,
0x67, 0x65, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x09, 0x62, 0x6f, 0x73, 0x73, 0x73, 0x74, 0x61,
0x67, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x72, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28,
0x03, 0x52, 0x05, 0x72, 0x74, 0x69, 0x6d, 0x65, 0x1a, 0x48, 0x0a, 0x0e, 0x42, 0x6f, 0x73, 0x73,
0x73, 0x74, 0x61, 0x67, 0x65, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65,
0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x20, 0x0a, 0x05,
0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0a, 0x2e, 0x53, 0x74,
0x61, 0x67, 0x65, 0x44, 0x61, 0x74, 0x61, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02,
0x38, 0x01, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74,
0x6f, 0x33,
}
var (
@ -469,35 +483,37 @@ func file_stonehenge_stonehenge_db_proto_rawDescGZIP() []byte {
return file_stonehenge_stonehenge_db_proto_rawDescData
}
var file_stonehenge_stonehenge_db_proto_msgTypes = make([]protoimpl.MessageInfo, 10)
var file_stonehenge_stonehenge_db_proto_msgTypes = make([]protoimpl.MessageInfo, 11)
var file_stonehenge_stonehenge_db_proto_goTypes = []interface{}{
(*RoomData)(nil), // 0: RoomData
(*DBStonehenge)(nil), // 1: DBStonehenge
(*StageData)(nil), // 2: StageData
(*DBStoneBoss)(nil), // 3: DBStoneBoss
nil, // 4: RoomData.EventidEntry
nil, // 5: DBStonehenge.UserbuffEntry
nil, // 6: DBStonehenge.HeroEntry
nil, // 7: DBStonehenge.RewardEntry
nil, // 8: DBStonehenge.AddweightEntry
nil, // 9: DBStoneBoss.BossstageEntry
(*BattleRole)(nil), // 10: BattleRole
nil, // 5: RoomData.BoxEntry
nil, // 6: DBStonehenge.UserbuffEntry
nil, // 7: DBStonehenge.HeroEntry
nil, // 8: DBStonehenge.RewardEntry
nil, // 9: DBStonehenge.AddweightEntry
nil, // 10: DBStoneBoss.BossstageEntry
(*BattleRole)(nil), // 11: BattleRole
}
var file_stonehenge_stonehenge_db_proto_depIdxs = []int32{
4, // 0: RoomData.eventid:type_name -> RoomData.EventidEntry
0, // 1: DBStonehenge.rooms:type_name -> RoomData
5, // 2: DBStonehenge.userbuff:type_name -> DBStonehenge.UserbuffEntry
6, // 3: DBStonehenge.hero:type_name -> DBStonehenge.HeroEntry
7, // 4: DBStonehenge.reward:type_name -> DBStonehenge.RewardEntry
8, // 5: DBStonehenge.addweight:type_name -> DBStonehenge.AddweightEntry
9, // 6: DBStoneBoss.bossstage:type_name -> DBStoneBoss.BossstageEntry
10, // 7: DBStonehenge.HeroEntry.value:type_name -> BattleRole
2, // 8: DBStoneBoss.BossstageEntry.value:type_name -> StageData
9, // [9:9] is the sub-list for method output_type
9, // [9:9] is the sub-list for method input_type
9, // [9:9] is the sub-list for extension type_name
9, // [9:9] is the sub-list for extension extendee
0, // [0:9] is the sub-list for field type_name
5, // 1: RoomData.box:type_name -> RoomData.BoxEntry
0, // 2: DBStonehenge.rooms:type_name -> RoomData
6, // 3: DBStonehenge.userbuff:type_name -> DBStonehenge.UserbuffEntry
7, // 4: DBStonehenge.hero:type_name -> DBStonehenge.HeroEntry
8, // 5: DBStonehenge.reward:type_name -> DBStonehenge.RewardEntry
9, // 6: DBStonehenge.addweight:type_name -> DBStonehenge.AddweightEntry
10, // 7: DBStoneBoss.bossstage:type_name -> DBStoneBoss.BossstageEntry
11, // 8: DBStonehenge.HeroEntry.value:type_name -> BattleRole
2, // 9: DBStoneBoss.BossstageEntry.value:type_name -> StageData
10, // [10:10] is the sub-list for method output_type
10, // [10:10] is the sub-list for method input_type
10, // [10:10] is the sub-list for extension type_name
10, // [10:10] is the sub-list for extension extendee
0, // [0:10] is the sub-list for field type_name
}
func init() { file_stonehenge_stonehenge_db_proto_init() }
@ -562,7 +578,7 @@ func file_stonehenge_stonehenge_db_proto_init() {
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
RawDescriptor: file_stonehenge_stonehenge_db_proto_rawDesc,
NumEnums: 0,
NumMessages: 10,
NumMessages: 11,
NumExtensions: 0,
NumServices: 0,
},

View File

@ -343,9 +343,9 @@ type StonehengeEventReq struct {
unknownFields protoimpl.UnknownFields
Eventid int32 `protobuf:"varint,1,opt,name=eventid,proto3" json:"eventid"` //事件id
Param1 int32 `protobuf:"varint,2,opt,name=param1,proto3" json:"param1"`
Param2 int32 `protobuf:"varint,3,opt,name=param2,proto3" json:"param2"`
Param3 int32 `protobuf:"varint,4,opt,name=param3,proto3" json:"param3"`
Param1 string `protobuf:"bytes,2,opt,name=param1,proto3" json:"param1"`
Param2 string `protobuf:"bytes,3,opt,name=param2,proto3" json:"param2"`
Param3 string `protobuf:"bytes,4,opt,name=param3,proto3" json:"param3"`
Report *BattleReport `protobuf:"bytes,5,opt,name=report,proto3" json:"report"` //战报
}
@ -388,25 +388,25 @@ func (x *StonehengeEventReq) GetEventid() int32 {
return 0
}
func (x *StonehengeEventReq) GetParam1() int32 {
func (x *StonehengeEventReq) GetParam1() string {
if x != nil {
return x.Param1
}
return 0
return ""
}
func (x *StonehengeEventReq) GetParam2() int32 {
func (x *StonehengeEventReq) GetParam2() string {
if x != nil {
return x.Param2
}
return 0
return ""
}
func (x *StonehengeEventReq) GetParam3() int32 {
func (x *StonehengeEventReq) GetParam3() string {
if x != nil {
return x.Param3
}
return 0
return ""
}
func (x *StonehengeEventReq) GetReport() *BattleReport {
@ -834,10 +834,10 @@ var file_stonehenge_stonehenge_msg_proto_rawDesc = []byte{
0x6e, 0x67, 0x65, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x12, 0x18, 0x0a, 0x07, 0x65,
0x76, 0x65, 0x6e, 0x74, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x65, 0x76,
0x65, 0x6e, 0x74, 0x69, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x31, 0x18,
0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x31, 0x12, 0x16, 0x0a,
0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x32, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x70,
0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x31, 0x12, 0x16, 0x0a,
0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x32, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x70,
0x61, 0x72, 0x61, 0x6d, 0x32, 0x12, 0x16, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x33, 0x18,
0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x33, 0x12, 0x25, 0x0a,
0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x33, 0x12, 0x25, 0x0a,
0x06, 0x72, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0d, 0x2e,
0x42, 0x61, 0x74, 0x74, 0x6c, 0x65, 0x52, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x52, 0x06, 0x72, 0x65,
0x70, 0x6f, 0x72, 0x74, 0x22, 0x84, 0x03, 0x0a, 0x13, 0x53, 0x74, 0x6f, 0x6e, 0x65, 0x68, 0x65,