上传代码
This commit is contained in:
parent
c4ee0e3375
commit
da5d36256a
@ -1,6 +1,8 @@
|
||||
[
|
||||
{
|
||||
"key": 1000,
|
||||
"key": 1,
|
||||
"moneystart": -1,
|
||||
"moneyend": 10000,
|
||||
"reward": [
|
||||
{
|
||||
"a": "attr",
|
||||
@ -10,7 +12,9 @@
|
||||
]
|
||||
},
|
||||
{
|
||||
"key": 2000,
|
||||
"key": 2,
|
||||
"moneystart": 10000,
|
||||
"moneyend": 20000,
|
||||
"reward": [
|
||||
{
|
||||
"a": "attr",
|
||||
@ -20,7 +24,9 @@
|
||||
]
|
||||
},
|
||||
{
|
||||
"key": 3000,
|
||||
"key": 3,
|
||||
"moneystart": 20000,
|
||||
"moneyend": 30000,
|
||||
"reward": [
|
||||
{
|
||||
"a": "attr",
|
||||
@ -30,7 +36,9 @@
|
||||
]
|
||||
},
|
||||
{
|
||||
"key": 4000,
|
||||
"key": 4,
|
||||
"moneystart": 30000,
|
||||
"moneyend": 50000,
|
||||
"reward": [
|
||||
{
|
||||
"a": "attr",
|
||||
@ -40,7 +48,9 @@
|
||||
]
|
||||
},
|
||||
{
|
||||
"key": 5000,
|
||||
"key": 5,
|
||||
"moneystart": 50000,
|
||||
"moneyend": -1,
|
||||
"reward": [
|
||||
{
|
||||
"a": "attr",
|
||||
@ -48,15 +58,5 @@
|
||||
"n": 9999
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"key": 0,
|
||||
"reward": [
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "gold",
|
||||
"n": 10
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
File diff suppressed because it is too large
Load Diff
@ -161,7 +161,7 @@
|
||||
},
|
||||
"content": {
|
||||
"key": "ruledesc_ruledesc_content_15",
|
||||
"text": "这里可以查看你获得的所有守护者们,选择守护者点击右侧按钮可以查看详细界面并且强化他们。<br>在强化界面,可以有各种方式强化守护者。<br>守护者等级强化:<br>点击守护者经验条下方的加号按钮可以进入守护者升级界面,使用护身符可以快速提升守护者等级。<br>守护者升星:<br>当守护者等级达到当前星级最大值(三星最大等级为30级,四星为40级,5星为50级),可以使用荣耀徽章提升守护者星级,并解锁最高等级上限。守护者最高为6星<br>守护者技能等级强化:<br>点击技能图标上方的按钮,可以进入守护者技能升级界面,使用不同等级的功夫卷轴可以强化不同稀有度的守护者的技能等级。<br>守护者觉醒:<br>可以在觉醒界面使用守护之心强化你的守护者。觉醒道具守护之心主要为招募重复守护者获得。<br>守护者回响:<br>可以在回响界面使用回响强化道具强化你的守护者。回响强化道具可以再狩猎与宝箱中获得。"
|
||||
"text": "这里可以查看你获得的所有守护者们,选择守护者点击右侧按钮可以查看详细界面并且强化他们。<br>在强化界面,可以有各种方式强化守护者。<br>守护者等级强化:<br>点击守护者经验条下方的加号按钮可以进入守护者升级界面,使用护身符可以快速提升守护者等级。<br>守护者升星:<br>当守护者等级达到当前星级最大值(三星最大等级为30级,四星为40级,5星为50级),可以使用荣耀徽章提升守护者星级,并解锁最高等级上限。守护者最高为6星<br>守护者技能等级强化:<br>点击技能图标上方的按钮,可以进入守护者技能升级界面,使用不同等级的功夫卷轴可以强化不同稀有度的守护者的技能等级。<br>守护者觉醒:<br>使用觉醒强化你的守护者。觉醒道具守护之心主要为招募重复守护者获得。<br>守护者回响:<br>使用回响强化你的守护者。共鸣强化道具可以再狩猎与宝箱中获得。"
|
||||
}
|
||||
},
|
||||
{
|
||||
@ -271,7 +271,7 @@
|
||||
},
|
||||
"content": {
|
||||
"key": "ruledesc_ruledesc_content_25",
|
||||
"text": "这里可以使用回响强化道具强化你的守护者。<br>回响强化道具可在狩猎与宝箱中获得。"
|
||||
"text": "这里可以使用回响强化你的守护者。<br>回响强化道具可在狩猎与宝箱中获得。"
|
||||
}
|
||||
},
|
||||
{
|
||||
@ -293,7 +293,7 @@
|
||||
},
|
||||
"content": {
|
||||
"key": "ruledesc_ruledesc_content_27",
|
||||
"text": "这里可以使用守护之心强化你的守护者。<br>觉醒道具守护之心主要为招募重复守护者获得。"
|
||||
"text": "这里可以使用觉醒强化你的守护者。<br>觉醒道具守护之心主要为招募重复守护者获得。"
|
||||
}
|
||||
},
|
||||
{
|
||||
|
@ -158,7 +158,7 @@
|
||||
},
|
||||
{
|
||||
"key": 20030,
|
||||
"opencond": "heroic_teaching",
|
||||
"opencond": "practice_ pillar1",
|
||||
"lock": 1,
|
||||
"lockend": 999,
|
||||
"ontxe": 20020,
|
||||
|
@ -33,7 +33,7 @@ type UserSession struct {
|
||||
msgqueue []*pb.UserMessage
|
||||
}
|
||||
|
||||
//重置
|
||||
// 重置
|
||||
func (this *UserSession) SetSession(ip, sessionId, stag, sid, uid string) {
|
||||
this.IP = ip
|
||||
this.SessionId = sessionId
|
||||
@ -43,7 +43,7 @@ func (this *UserSession) SetSession(ip, sessionId, stag, sid, uid string) {
|
||||
this.msgqueue = this.msgqueue[:0]
|
||||
}
|
||||
|
||||
//重置
|
||||
// 重置
|
||||
func (this *UserSession) Reset() {
|
||||
this.IP = ""
|
||||
this.SessionId = ""
|
||||
@ -52,39 +52,39 @@ func (this *UserSession) Reset() {
|
||||
this.msgqueue = this.msgqueue[:0]
|
||||
}
|
||||
|
||||
//获取用户的会话id
|
||||
// 获取用户的会话id
|
||||
func (this *UserSession) GetSessionId() string {
|
||||
return this.SessionId
|
||||
}
|
||||
|
||||
//获取用户的uid
|
||||
// 获取用户的uid
|
||||
func (this *UserSession) GetUserId() string {
|
||||
return this.UserId
|
||||
}
|
||||
|
||||
//获取用户的远程ip地址
|
||||
// 获取用户的远程ip地址
|
||||
func (this *UserSession) GetIP() string {
|
||||
return this.IP
|
||||
}
|
||||
|
||||
//会话所在集群
|
||||
// 会话所在集群
|
||||
func (this *UserSession) GetServiecTag() string {
|
||||
return this.ServiceTag
|
||||
}
|
||||
|
||||
//用户当先所在网关服务
|
||||
// 用户当先所在网关服务
|
||||
func (this *UserSession) GetGatewayServiceId() string {
|
||||
return this.GatewayServiceId
|
||||
}
|
||||
|
||||
//是否登录
|
||||
// 是否登录
|
||||
func (this *UserSession) IsLogin() bool {
|
||||
return this.UserId != ""
|
||||
}
|
||||
|
||||
///绑定uid 登录后操作
|
||||
///uid 用户id
|
||||
///wokerId 用户绑定worker服务id
|
||||
// /绑定uid 登录后操作
|
||||
// /uid 用户id
|
||||
// /wokerId 用户绑定worker服务id
|
||||
func (this *UserSession) Bind(uid string, wokerId string) (err error) {
|
||||
reply := &pb.RPCMessageReply{}
|
||||
if err = this.service.RpcCall(context.Background(), fmt.Sprintf("%s/%s", Service_Gateway, this.GatewayServiceId), string(Rpc_GatewayAgentBind), &pb.AgentBuildReq{
|
||||
@ -99,7 +99,7 @@ func (this *UserSession) Bind(uid string, wokerId string) (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
//解绑uid 注销和切换账号是处理
|
||||
// 解绑uid 注销和切换账号是处理
|
||||
func (this *UserSession) UnBind() (err error) {
|
||||
reply := &pb.RPCMessageReply{}
|
||||
if err = this.service.RpcCall(context.Background(), fmt.Sprintf("%s/%s", Service_Gateway, this.GatewayServiceId), string(Rpc_GatewayAgentUnBind), &pb.AgentUnBuildReq{
|
||||
@ -112,7 +112,7 @@ func (this *UserSession) UnBind() (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
//向用户发送消息
|
||||
// 向用户发送消息
|
||||
func (this *UserSession) SendMsg(mainType, subType string, msg proto.Message) (err error) {
|
||||
// log.Debugf("SendMsg to UserId:[%s] Data: %v", this.UserId, msg)
|
||||
data, _ := anypb.New(msg)
|
||||
@ -124,7 +124,7 @@ func (this *UserSession) SendMsg(mainType, subType string, msg proto.Message) (e
|
||||
return
|
||||
}
|
||||
|
||||
//关闭用户连接对象
|
||||
// 关闭用户连接对象
|
||||
func (this *UserSession) Close() (err error) {
|
||||
reply := &pb.RPCMessageReply{}
|
||||
if err := this.service.RpcCall(context.Background(), fmt.Sprintf("%s/%s", Service_Gateway, this.GatewayServiceId), string(Rpc_GatewayAgentSendMsg), &pb.AgentCloseeReq{
|
||||
@ -135,14 +135,14 @@ func (this *UserSession) Close() (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
//清空消息队列
|
||||
// 清空消息队列
|
||||
func (this *UserSession) Polls() []*pb.UserMessage {
|
||||
msgs := this.msgqueue
|
||||
this.msgqueue = this.msgqueue[:0]
|
||||
return msgs
|
||||
}
|
||||
|
||||
//推送消息到用户
|
||||
// 推送消息到用户
|
||||
func (this *UserSession) Push() (err error) {
|
||||
// reply := &pb.RPCMessageReply{}
|
||||
if len(this.msgqueue) > 0 {
|
||||
@ -157,7 +157,7 @@ func (this *UserSession) Push() (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
//打印日志需要
|
||||
// 打印日志需要
|
||||
func (this *UserSession) ToString() string {
|
||||
return fmt.Sprintf("SessionId:%s UserId:%s GatewayServiceId:%s", this.SessionId, this.UserId, this.GatewayServiceId)
|
||||
}
|
||||
|
@ -5,7 +5,6 @@ import (
|
||||
"go_dreamfactory/comm"
|
||||
"go_dreamfactory/lego/base"
|
||||
"go_dreamfactory/lego/core"
|
||||
"go_dreamfactory/lego/sys/event"
|
||||
"go_dreamfactory/lego/sys/log"
|
||||
"go_dreamfactory/modules"
|
||||
"go_dreamfactory/pb"
|
||||
@ -48,7 +47,7 @@ func (this *Worldtask) GetType() core.M_Modules {
|
||||
|
||||
func (this *Worldtask) Start() (err error) {
|
||||
err = this.ModuleBase.Start()
|
||||
event.Register(comm.EventBuriedComplete, this.TCondFinishNotify)
|
||||
// event.Register(comm.EventBuriedComplete, this.TCondFinishNotify)
|
||||
return
|
||||
}
|
||||
|
||||
|
@ -146,7 +146,7 @@ func (this *WTask) BuriedsNotify(uid string, condis []*pb.ConIProgress) {
|
||||
this.PutUserSession(session)
|
||||
}()
|
||||
//发送进度变化消息
|
||||
session.SendMsg(string(this.GetType()), "accepttaskchange", &pb.WTaskAcceptChangePush{Accepts: detailstasks})
|
||||
session.SendMsg(string(this.GetType()), "acceptchange", &pb.WTaskAcceptChangePush{Accepts: detailstasks})
|
||||
}
|
||||
|
||||
// 功能开启
|
||||
|
Loading…
Reference in New Issue
Block a user