diff --git a/bin/json/game_herostrategy.json b/bin/json/game_herostrategy.json index 96b31fbcb..db73383f1 100644 --- a/bin/json/game_herostrategy.json +++ b/bin/json/game_herostrategy.json @@ -10,7 +10,7 @@ 101091 ], "FormatList": [ - 101091 + 101062 ], "award": [ { @@ -27,7 +27,7 @@ 101091 ], "FormatList": [ - 101091 + 101062 ], "award": [ { @@ -44,7 +44,7 @@ 101091 ], "FormatList": [ - 101091 + 101062 ], "award": [ { @@ -61,7 +61,7 @@ 101091 ], "FormatList": [ - 101091 + 101062 ], "award": [ { @@ -78,7 +78,7 @@ 101091 ], "FormatList": [ - 101091 + 101062 ], "award": [ { @@ -95,7 +95,7 @@ 101091 ], "FormatList": [ - 101091 + 101062 ], "award": [ { @@ -112,7 +112,7 @@ 101091 ], "FormatList": [ - 101091 + 101062 ], "award": [ { @@ -129,7 +129,7 @@ 101091 ], "FormatList": [ - 101091 + 101062 ], "award": [ { @@ -146,7 +146,7 @@ 101091 ], "FormatList": [ - 101091 + 101062 ], "award": [ { @@ -163,7 +163,7 @@ 101091 ], "FormatList": [ - 101091 + 101062 ], "award": [ { diff --git a/bin/json/game_teaching.json b/bin/json/game_teaching.json index 6854cdd80..b52747614 100644 --- a/bin/json/game_teaching.json +++ b/bin/json/game_teaching.json @@ -33,14 +33,18 @@ "id": 10002, "suittype": 1, "desc": { - "key": "", - "text": "" + "key": "mainline_desc_10001", + "text": "在实战中学习能够影响攻击力和防御力的技能作用" }, "tips": { - "key": "", - "text": "" + "key": "mainline_desc_10001", + "text": "在实战中学习能够影响攻击力和防御力的技能作用" }, - "task": [], + "task": [ + 1, + 2, + 11 + ], "us_FormatList": [ 101091 ], @@ -59,14 +63,18 @@ "id": 10003, "suittype": 1, "desc": { - "key": "", - "text": "" + "key": "mainline_desc_10001", + "text": "在实战中学习能够影响攻击力和防御力的技能作用" }, "tips": { - "key": "", - "text": "" + "key": "mainline_desc_10001", + "text": "在实战中学习能够影响攻击力和防御力的技能作用" }, - "task": [], + "task": [ + 1, + 2, + 11 + ], "us_FormatList": [ 101091 ], @@ -89,10 +97,14 @@ "text": "在实战中学习能够影响攻击力和防御力的技能作用" }, "tips": { - "key": "", - "text": "" + "key": "mainline_desc_10001", + "text": "在实战中学习能够影响攻击力和防御力的技能作用" }, - "task": [], + "task": [ + 1, + 2, + 11 + ], "us_FormatList": [ 101091 ], @@ -111,14 +123,18 @@ "id": 20002, "suittype": 2, "desc": { - "key": "", - "text": "" + "key": "mainline_desc_10001", + "text": "在实战中学习能够影响攻击力和防御力的技能作用" }, "tips": { - "key": "", - "text": "" + "key": "mainline_desc_10001", + "text": "在实战中学习能够影响攻击力和防御力的技能作用" }, - "task": [], + "task": [ + 1, + 2, + 11 + ], "us_FormatList": [ 101091 ], @@ -137,14 +153,18 @@ "id": 20003, "suittype": 2, "desc": { - "key": "", - "text": "" + "key": "mainline_desc_10001", + "text": "在实战中学习能够影响攻击力和防御力的技能作用" }, "tips": { - "key": "", - "text": "" + "key": "mainline_desc_10001", + "text": "在实战中学习能够影响攻击力和防御力的技能作用" }, - "task": [], + "task": [ + 1, + 2, + 11 + ], "us_FormatList": [ 101091 ], @@ -167,10 +187,14 @@ "text": "在实战中学习能够影响攻击力和防御力的技能作用" }, "tips": { - "key": "", - "text": "" + "key": "mainline_desc_10001", + "text": "在实战中学习能够影响攻击力和防御力的技能作用" }, - "task": [], + "task": [ + 1, + 2, + 11 + ], "us_FormatList": [ 101091 ], @@ -189,14 +213,18 @@ "id": 30002, "suittype": 3, "desc": { - "key": "", - "text": "" + "key": "mainline_desc_10001", + "text": "在实战中学习能够影响攻击力和防御力的技能作用" }, "tips": { - "key": "", - "text": "" + "key": "mainline_desc_10001", + "text": "在实战中学习能够影响攻击力和防御力的技能作用" }, - "task": [], + "task": [ + 1, + 2, + 11 + ], "us_FormatList": [ 101091 ], @@ -215,14 +243,18 @@ "id": 30003, "suittype": 3, "desc": { - "key": "", - "text": "" + "key": "mainline_desc_10001", + "text": "在实战中学习能够影响攻击力和防御力的技能作用" }, "tips": { - "key": "", - "text": "" + "key": "mainline_desc_10001", + "text": "在实战中学习能够影响攻击力和防御力的技能作用" }, - "task": [], + "task": [ + 1, + 2, + 11 + ], "us_FormatList": [ 101091 ], @@ -245,10 +277,14 @@ "text": "在实战中学习能够影响攻击力和防御力的技能作用" }, "tips": { - "key": "", - "text": "" + "key": "mainline_desc_10001", + "text": "在实战中学习能够影响攻击力和防御力的技能作用" }, - "task": [], + "task": [ + 1, + 2, + 11 + ], "us_FormatList": [ 101091 ], @@ -267,14 +303,18 @@ "id": 40002, "suittype": 4, "desc": { - "key": "", - "text": "" + "key": "mainline_desc_10001", + "text": "在实战中学习能够影响攻击力和防御力的技能作用" }, "tips": { - "key": "", - "text": "" + "key": "mainline_desc_10001", + "text": "在实战中学习能够影响攻击力和防御力的技能作用" }, - "task": [], + "task": [ + 1, + 2, + 11 + ], "us_FormatList": [ 101091 ], @@ -293,14 +333,18 @@ "id": 40003, "suittype": 4, "desc": { - "key": "", - "text": "" + "key": "mainline_desc_10001", + "text": "在实战中学习能够影响攻击力和防御力的技能作用" }, "tips": { - "key": "", - "text": "" + "key": "mainline_desc_10001", + "text": "在实战中学习能够影响攻击力和防御力的技能作用" }, - "task": [], + "task": [ + 1, + 2, + 11 + ], "us_FormatList": [ 101091 ], @@ -323,10 +367,14 @@ "text": "在实战中学习能够影响攻击力和防御力的技能作用" }, "tips": { - "key": "", - "text": "" + "key": "mainline_desc_10001", + "text": "在实战中学习能够影响攻击力和防御力的技能作用" }, - "task": [], + "task": [ + 1, + 2, + 11 + ], "us_FormatList": [ 101091 ], @@ -345,14 +393,18 @@ "id": 50002, "suittype": 5, "desc": { - "key": "", - "text": "" + "key": "mainline_desc_10001", + "text": "在实战中学习能够影响攻击力和防御力的技能作用" }, "tips": { - "key": "", - "text": "" + "key": "mainline_desc_10001", + "text": "在实战中学习能够影响攻击力和防御力的技能作用" }, - "task": [], + "task": [ + 1, + 2, + 11 + ], "us_FormatList": [ 101091 ], @@ -371,14 +423,18 @@ "id": 50003, "suittype": 5, "desc": { - "key": "", - "text": "" + "key": "mainline_desc_10001", + "text": "在实战中学习能够影响攻击力和防御力的技能作用" }, "tips": { - "key": "", - "text": "" + "key": "mainline_desc_10001", + "text": "在实战中学习能够影响攻击力和防御力的技能作用" }, - "task": [], + "task": [ + 1, + 2, + 11 + ], "us_FormatList": [ 101091 ], diff --git a/comm/const.go b/comm/const.go index e57ce1bb0..cf32503ea 100644 --- a/comm/const.go +++ b/comm/const.go @@ -74,6 +74,7 @@ const ( ModulePrivilege core.M_Modules = "privilege" //特权 ModuleGrowtask core.M_Modules = "growtask" //成长任务 ModuleWorldtask core.M_Modules = "worldtask" //世界任务 + ModuleReddot core.M_Modules = "reddot" //红点 ) //数据表名定义处 diff --git a/modules/reddot/api.go b/modules/reddot/api.go new file mode 100644 index 000000000..ab454cbb6 --- /dev/null +++ b/modules/reddot/api.go @@ -0,0 +1,29 @@ +package reddot + +import ( + "go_dreamfactory/modules" + + "go_dreamfactory/lego/core" +) + +/* +装备模块 API +*/ +type apiComp struct { + modules.MCompGate + service core.IService + module *Reddot +} + +//组件初始化接口 +func (this *apiComp) Init(service core.IService, module core.IModule, comp core.IModuleComp, options core.IModuleOptions) (err error) { + this.MCompGate.Init(service, module, comp, options) + this.module = module.(*Reddot) + this.service = service + return +} + +func (this *apiComp) Start() (err error) { + err = this.MCompGate.Start() + return +} diff --git a/modules/reddot/module.go b/modules/reddot/module.go new file mode 100644 index 000000000..cde7586b8 --- /dev/null +++ b/modules/reddot/module.go @@ -0,0 +1,51 @@ +package reddot + +import ( + "go_dreamfactory/comm" + "go_dreamfactory/lego/base" + "go_dreamfactory/lego/core" + "go_dreamfactory/modules" +) + +/* +模块名:红点系统 +描述:统一获取红点信息 +开发:李伟 +*/ +func NewModule() core.IModule { + m := new(Reddot) + return m +} + +type Reddot struct { + modules.ModuleBase + service base.IRPCXService + api_comp *apiComp +} + +//模块名 +func (this *Reddot) GetType() core.M_Modules { + return comm.ModuleReddot +} + +//模块初始化接口 注册用户创建角色事件 +func (this *Reddot) Init(service core.IService, module core.IModule, options core.IModuleOptions) (err error) { + err = this.ModuleBase.Init(service, module, options) + this.service = service.(base.IRPCXService) + return +} +func (this *Reddot) Start() (err error) { + err = this.ModuleBase.Start() + // var module core.IModule + // if module, err = this.service.GetModule(comm.ModuleEquipment); err != nil { + // return + // } + // this.equip = module.(comm.IEquipment) + return +} + +//装备组件 +func (this *Reddot) OnInstallComp() { + this.ModuleBase.OnInstallComp() + this.api_comp = this.RegisterComp(new(apiComp)).(*apiComp) +} diff --git a/pb/reddot_msg.pb.go b/pb/reddot_msg.pb.go new file mode 100644 index 000000000..eeb8ec7df --- /dev/null +++ b/pb/reddot_msg.pb.go @@ -0,0 +1,184 @@ +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.28.0 +// protoc v3.20.0 +// source: reddot/reddot_msg.proto + +package pb + +import ( + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + reflect "reflect" + sync "sync" +) + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +//红点信息请求 +type ReddotInfoReq struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *ReddotInfoReq) Reset() { + *x = ReddotInfoReq{} + if protoimpl.UnsafeEnabled { + mi := &file_reddot_reddot_msg_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ReddotInfoReq) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ReddotInfoReq) ProtoMessage() {} + +func (x *ReddotInfoReq) ProtoReflect() protoreflect.Message { + mi := &file_reddot_reddot_msg_proto_msgTypes[0] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use ReddotInfoReq.ProtoReflect.Descriptor instead. +func (*ReddotInfoReq) Descriptor() ([]byte, []int) { + return file_reddot_reddot_msg_proto_rawDescGZIP(), []int{0} +} + +type ReddotInfoResp struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *ReddotInfoResp) Reset() { + *x = ReddotInfoResp{} + if protoimpl.UnsafeEnabled { + mi := &file_reddot_reddot_msg_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ReddotInfoResp) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ReddotInfoResp) ProtoMessage() {} + +func (x *ReddotInfoResp) ProtoReflect() protoreflect.Message { + mi := &file_reddot_reddot_msg_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use ReddotInfoResp.ProtoReflect.Descriptor instead. +func (*ReddotInfoResp) Descriptor() ([]byte, []int) { + return file_reddot_reddot_msg_proto_rawDescGZIP(), []int{1} +} + +var File_reddot_reddot_msg_proto protoreflect.FileDescriptor + +var file_reddot_reddot_msg_proto_rawDesc = []byte{ + 0x0a, 0x17, 0x72, 0x65, 0x64, 0x64, 0x6f, 0x74, 0x2f, 0x72, 0x65, 0x64, 0x64, 0x6f, 0x74, 0x5f, + 0x6d, 0x73, 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x0f, 0x0a, 0x0d, 0x52, 0x65, 0x64, + 0x64, 0x6f, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x65, 0x71, 0x22, 0x10, 0x0a, 0x0e, 0x52, 0x65, + 0x64, 0x64, 0x6f, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x65, 0x73, 0x70, 0x42, 0x06, 0x5a, 0x04, + 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +} + +var ( + file_reddot_reddot_msg_proto_rawDescOnce sync.Once + file_reddot_reddot_msg_proto_rawDescData = file_reddot_reddot_msg_proto_rawDesc +) + +func file_reddot_reddot_msg_proto_rawDescGZIP() []byte { + file_reddot_reddot_msg_proto_rawDescOnce.Do(func() { + file_reddot_reddot_msg_proto_rawDescData = protoimpl.X.CompressGZIP(file_reddot_reddot_msg_proto_rawDescData) + }) + return file_reddot_reddot_msg_proto_rawDescData +} + +var file_reddot_reddot_msg_proto_msgTypes = make([]protoimpl.MessageInfo, 2) +var file_reddot_reddot_msg_proto_goTypes = []interface{}{ + (*ReddotInfoReq)(nil), // 0: ReddotInfoReq + (*ReddotInfoResp)(nil), // 1: ReddotInfoResp +} +var file_reddot_reddot_msg_proto_depIdxs = []int32{ + 0, // [0:0] is the sub-list for method output_type + 0, // [0:0] is the sub-list for method input_type + 0, // [0:0] is the sub-list for extension type_name + 0, // [0:0] is the sub-list for extension extendee + 0, // [0:0] is the sub-list for field type_name +} + +func init() { file_reddot_reddot_msg_proto_init() } +func file_reddot_reddot_msg_proto_init() { + if File_reddot_reddot_msg_proto != nil { + return + } + if !protoimpl.UnsafeEnabled { + file_reddot_reddot_msg_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ReddotInfoReq); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_reddot_reddot_msg_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ReddotInfoResp); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: file_reddot_reddot_msg_proto_rawDesc, + NumEnums: 0, + NumMessages: 2, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_reddot_reddot_msg_proto_goTypes, + DependencyIndexes: file_reddot_reddot_msg_proto_depIdxs, + MessageInfos: file_reddot_reddot_msg_proto_msgTypes, + }.Build() + File_reddot_reddot_msg_proto = out.File + file_reddot_reddot_msg_proto_rawDesc = nil + file_reddot_reddot_msg_proto_goTypes = nil + file_reddot_reddot_msg_proto_depIdxs = nil +}