【寻宝密宗】提交
parent
d10879ae57
commit
edc728227c
|
@ -7183,7 +7183,7 @@ MonoBehaviour:
|
|||
m_HorizontalOverflow: 0
|
||||
m_VerticalOverflow: 0
|
||||
m_LineSpacing: 1
|
||||
m_Text: " \u5956\u52B1\u9884\u89C8"
|
||||
m_Text:
|
||||
LanguageIndex: 0
|
||||
--- !u!1 &4374406624893575674
|
||||
GameObject:
|
||||
|
@ -14657,7 +14657,7 @@ GameObject:
|
|||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
m_IsActive: 0
|
||||
--- !u!224 &6122998974980818414
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
|
|
|
@ -2452,6 +2452,80 @@ MonoBehaviour:
|
|||
m_FillClockwise: 1
|
||||
m_FillOrigin: 0
|
||||
m_UseSpriteMesh: 0
|
||||
--- !u!1 &8354368336256223909
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
serializedVersion: 6
|
||||
m_Component:
|
||||
- component: {fileID: 5129594450607036895}
|
||||
- component: {fileID: 7553823967711619773}
|
||||
- component: {fileID: 5406762803771860736}
|
||||
m_Layer: 5
|
||||
m_Name: Image (1)
|
||||
m_TagString: Untagged
|
||||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
--- !u!224 &5129594450607036895
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 8354368336256223909}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||
m_LocalScale: {x: 1.3, y: 1.3, z: 1.49}
|
||||
m_Children: []
|
||||
m_Father: {fileID: 4939864880710507093}
|
||||
m_RootOrder: 1
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||
m_AnchorMax: {x: 0.5, y: 0.5}
|
||||
m_AnchoredPosition: {x: 156, y: 46}
|
||||
m_SizeDelta: {x: 30, y: 30}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!222 &7553823967711619773
|
||||
CanvasRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 8354368336256223909}
|
||||
m_CullTransparentMesh: 0
|
||||
--- !u!114 &5406762803771860736
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 8354368336256223909}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: -765806418, guid: f70555f144d8491a825f0804e09c671c, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_Material: {fileID: 0}
|
||||
m_Color: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_RaycastTarget: 1
|
||||
m_OnCullStateChanged:
|
||||
m_PersistentCalls:
|
||||
m_Calls: []
|
||||
m_TypeName: UnityEngine.UI.MaskableGraphic+CullStateChangedEvent, UnityEngine.UI,
|
||||
Version=1.0.0.0, Culture=neutral, PublicKeyToken=null
|
||||
m_Sprite: {fileID: 21300000, guid: f9ea4c4aff328ff4abcc21aae0a4fa10, type: 3}
|
||||
m_Type: 0
|
||||
m_PreserveAspect: 0
|
||||
m_FillCenter: 1
|
||||
m_FillMethod: 4
|
||||
m_FillAmount: 1
|
||||
m_FillClockwise: 1
|
||||
m_FillOrigin: 0
|
||||
m_UseSpriteMesh: 0
|
||||
--- !u!1 &8529354479638272063
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
|
@ -2933,6 +3007,7 @@ RectTransform:
|
|||
m_LocalScale: {x: 0.9, y: 0.9, z: 1}
|
||||
m_Children:
|
||||
- {fileID: 4163742444588845871}
|
||||
- {fileID: 5129594450607036895}
|
||||
m_Father: {fileID: 2670508066893046162}
|
||||
m_RootOrder: 5
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
|
|
|
@ -693,6 +693,7 @@ RedPointType = {
|
|||
FuXingGaoZhao = 2027,--福星高照
|
||||
FifteenDayGift = 2028,--十五日登录
|
||||
FifteenDayGift_1 = 20281,--十五日登录领取按钮
|
||||
XunBaoMiZong = 2029,--寻宝迷踪
|
||||
---聊天相关-----
|
||||
Chat = 207,
|
||||
Chat_Friend = 2070,
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -557,6 +557,9 @@ CHECKBUYGOODSREQUEST = protobuf.Descriptor();
|
|||
CHECKBUYGOODSREQUEST_GOODSID_FIELD = protobuf.FieldDescriptor();
|
||||
CHECKBUYGOODSRESPONSE = protobuf.Descriptor();
|
||||
CHECKBUYGOODSRESPONSE_ORDERID_FIELD = protobuf.FieldDescriptor();
|
||||
XUNBAOMIZONGENTERREQUEST = protobuf.Descriptor();
|
||||
XUNBAOMIZONGENTERRESPONSE = protobuf.Descriptor();
|
||||
XUNBAOMIZONGENTERRESPONSE_ISENTER_FIELD = protobuf.FieldDescriptor();
|
||||
|
||||
ERRORMSGRESPONSE_MSG_FIELD.name = "msg"
|
||||
ERRORMSGRESPONSE_MSG_FIELD.full_name = ".rpc.protocols.ErrorMsgResponse.msg"
|
||||
|
@ -5630,6 +5633,30 @@ CHECKBUYGOODSRESPONSE.enum_types = {}
|
|||
CHECKBUYGOODSRESPONSE.fields = {CHECKBUYGOODSRESPONSE_ORDERID_FIELD}
|
||||
CHECKBUYGOODSRESPONSE.is_extendable = false
|
||||
CHECKBUYGOODSRESPONSE.extensions = {}
|
||||
XUNBAOMIZONGENTERREQUEST.name = "XunBaoMiZongEnterRequest"
|
||||
XUNBAOMIZONGENTERREQUEST.full_name = ".rpc.protocols.XunBaoMiZongEnterRequest"
|
||||
XUNBAOMIZONGENTERREQUEST.nested_types = {}
|
||||
XUNBAOMIZONGENTERREQUEST.enum_types = {}
|
||||
XUNBAOMIZONGENTERREQUEST.fields = {}
|
||||
XUNBAOMIZONGENTERREQUEST.is_extendable = false
|
||||
XUNBAOMIZONGENTERREQUEST.extensions = {}
|
||||
XUNBAOMIZONGENTERRESPONSE_ISENTER_FIELD.name = "isEnter"
|
||||
XUNBAOMIZONGENTERRESPONSE_ISENTER_FIELD.full_name = ".rpc.protocols.XunBaoMiZongEnterResponse.isEnter"
|
||||
XUNBAOMIZONGENTERRESPONSE_ISENTER_FIELD.number = 1
|
||||
XUNBAOMIZONGENTERRESPONSE_ISENTER_FIELD.index = 0
|
||||
XUNBAOMIZONGENTERRESPONSE_ISENTER_FIELD.label = 1
|
||||
XUNBAOMIZONGENTERRESPONSE_ISENTER_FIELD.has_default_value = false
|
||||
XUNBAOMIZONGENTERRESPONSE_ISENTER_FIELD.default_value = false
|
||||
XUNBAOMIZONGENTERRESPONSE_ISENTER_FIELD.type = 8
|
||||
XUNBAOMIZONGENTERRESPONSE_ISENTER_FIELD.cpp_type = 7
|
||||
|
||||
XUNBAOMIZONGENTERRESPONSE.name = "XunBaoMiZongEnterResponse"
|
||||
XUNBAOMIZONGENTERRESPONSE.full_name = ".rpc.protocols.XunBaoMiZongEnterResponse"
|
||||
XUNBAOMIZONGENTERRESPONSE.nested_types = {}
|
||||
XUNBAOMIZONGENTERRESPONSE.enum_types = {}
|
||||
XUNBAOMIZONGENTERRESPONSE.fields = {XUNBAOMIZONGENTERRESPONSE_ISENTER_FIELD}
|
||||
XUNBAOMIZONGENTERRESPONSE.is_extendable = false
|
||||
XUNBAOMIZONGENTERRESPONSE.extensions = {}
|
||||
|
||||
ActiveUserMountRequest = protobuf.Message(ACTIVEUSERMOUNTREQUEST)
|
||||
ActiveUserMountResponse = protobuf.Message(ACTIVEUSERMOUNTRESPONSE)
|
||||
|
@ -5812,6 +5839,8 @@ WorkTechnologyLevelResponse = protobuf.Message(WORKTECHNOLOGYLEVELRESPONSE)
|
|||
WorkTechnologyResetRequest = protobuf.Message(WORKTECHNOLOGYRESETREQUEST)
|
||||
WorkTechnologyResetResponse = protobuf.Message(WORKTECHNOLOGYRESETRESPONSE)
|
||||
WorldLevelIndication = protobuf.Message(WORLDLEVELINDICATION)
|
||||
XunBaoMiZongEnterRequest = protobuf.Message(XUNBAOMIZONGENTERREQUEST)
|
||||
XunBaoMiZongEnterResponse = protobuf.Message(XUNBAOMIZONGENTERRESPONSE)
|
||||
ZeroPlayerUpdateIndication = protobuf.Message(ZEROPLAYERUPDATEINDICATION)
|
||||
blessChooseRequest = protobuf.Message(BLESSCHOOSEREQUEST)
|
||||
blessChooseResponse = protobuf.Message(BLESSCHOOSERESPONSE)
|
||||
|
|
|
@ -141,7 +141,7 @@ function this.InitActivityServerData(msg, isUpdate)
|
|||
this.CheckMoneyProgress(v)
|
||||
this.mission[v.activityId] = v
|
||||
|
||||
LogYellow("刷新活动数据activityId:" .. v.activityId .. " value:" .. v.value)
|
||||
-- LogYellow("刷新活动数据activityId:" .. v.activityId .. " value:" .. v.value)
|
||||
for n, m in ipairs(v.mission) do
|
||||
--LogGreen(" 刷新活动数据missionId:" .. m.missionId .. " state:" .. m.state .. " progress:" .. m.progress)
|
||||
if (v.activityId == ActivityTypeDef.OnlineGift) then
|
||||
|
|
|
@ -708,4 +708,17 @@ function this.RecrutDetailData(actType)
|
|||
end
|
||||
end
|
||||
|
||||
--寻宝迷踪红点检测
|
||||
function this.XunBaoMiZongRedCheck()
|
||||
local actData = CommonActPageManager.GetData(ActivityTypeDef.XunBaoMiZong)
|
||||
if not actData then return false end
|
||||
local configData = ConfigManager.GetConfigDataByKey(ConfigName.LotterySetting,"ActivityId",actData.activityId)
|
||||
local itemNum = configData.CostItem[1]
|
||||
if BagManager.GetTotalItemNum(itemNum[1]) >= itemNum[2] then
|
||||
return true
|
||||
else
|
||||
return false
|
||||
end
|
||||
end
|
||||
|
||||
return this
|
|
@ -9,6 +9,7 @@ function this:InitComponent(gameObject)
|
|||
|
||||
self.scroll = Util.GetGameObject(gameObject,"Grid")
|
||||
self.itemPre = Util.GetGameObject(gameObject,"itemPre")
|
||||
self.timeText = Util.GetGameObject(gameObject,"Content/bottom/Text"):GetComponent("Text")
|
||||
-- 设置循环滚动,万一内容不停地加
|
||||
local rootHight = self.scroll.transform.rect.height
|
||||
local width = self.scroll.transform.rect.width
|
||||
|
@ -34,6 +35,7 @@ function this:OnShow(_parent,...)
|
|||
self.sortingOrder = _parent.sortingOrder
|
||||
local args = {...}
|
||||
self.actData = args[1]
|
||||
self.timeText.text = string.format("%s——%s",GetTimeStrBySeconds(self.actData.startTime),GetTimeStrBySeconds(self.actData.endTime))
|
||||
this:Refresh(true,true)
|
||||
end
|
||||
|
||||
|
|
|
@ -5462,4 +5462,18 @@ function NetManager.IsCrossRequert(func)
|
|||
end)
|
||||
end
|
||||
|
||||
--获取寻宝迷踪进入地图许可
|
||||
function this.XunBaoMiZongEnterMap(func)
|
||||
local data = PlayerInfoProto_pb.XunBaoMiZongEnterRequest()
|
||||
local msg = data:SerializeToString()
|
||||
Network:SendMessageWithCallBack(MessageTypeProto_pb.XUN_BAO_MI_ZONG_ENTER_REQUEST, MessageTypeProto_pb.XUN_BAO_MI_ZONG_ENTER_RESPONSE, msg , function(buffer)
|
||||
local data = buffer:DataByte()
|
||||
local msg = PlayerInfoProto_pb.XunBaoMiZongEnterResponse()
|
||||
msg:ParseFromString(data)
|
||||
if func then
|
||||
func(msg)
|
||||
end
|
||||
end)
|
||||
end
|
||||
|
||||
return this
|
|
@ -538,6 +538,8 @@ function this.RegisterRedCheckFunc()
|
|||
|
||||
RPData:AddCheckFunc(RedPointType.jijin128,ActivityGiftManager.CheckRedpointUpperMonthCard)
|
||||
RPData:AddCheckFunc(RedPointType.jijin328,ActivityGiftManager.CheckRedpointUpperMonthCard)
|
||||
--寻宝迷踪
|
||||
RPData:AddCheckFunc(RedPointType.XunBaoMiZong,DynamicActivityManager.XunBaoMiZongRedCheck)
|
||||
end
|
||||
|
||||
|
||||
|
|
|
@ -567,12 +567,20 @@ function RewardItemPopup:OnClose()
|
|||
isOpenGeiSSRAvtivityTime:Stop()
|
||||
isOpenGeiSSRAvtivityTime = nil
|
||||
end
|
||||
|
||||
self:RedCheckFuns()
|
||||
end
|
||||
|
||||
--一些等到物品后的红点检测
|
||||
function RewardItemPopup:RedCheckFuns()
|
||||
--检测是否需要弹每日任务飘窗
|
||||
TaskManager.RefreshShowDailyMissionTipPanel()
|
||||
|
||||
-- 检测月卡激活是否需要拍脸
|
||||
OperatingManager.CheckMonthCardPatFace()
|
||||
--寻宝迷踪红点检测
|
||||
DynamicActivityManager.XunBaoMiZongRedCheck()
|
||||
end
|
||||
|
||||
--界面销毁时调用(用于子类重写)
|
||||
function RewardItemPopup:OnDestroy()
|
||||
this.spLoader:Destroy()
|
||||
|
|
|
@ -28,9 +28,14 @@ function XunBaoMiZongMap:BindEvent()
|
|||
end)
|
||||
Util.AddClick(self.btnGet.gameObject, function()
|
||||
local distance = math.distanceXY(self.rewardPos,self.oldPos)
|
||||
if distance <= 100 then
|
||||
PopupTipPanel.ShowTip("成功领取奖励")
|
||||
self:ClosePanel()
|
||||
local banjing = ConfigManager.GetConfigData(ConfigName.SpecialConfig,125).Value
|
||||
if distance <= tonumber(banjing) then
|
||||
local Id = ConfigManager.GetConfigDataByKey(ConfigName.LotterySetting,"ActivityId",self.actData.activityId).Id
|
||||
NetManager.RecruitRequest(Id,function (msg)
|
||||
UIManager.OpenPanel(UIName.RewardItemPopup,msg.drop,1,function()
|
||||
self:ClosePanel()
|
||||
end)
|
||||
end)
|
||||
else
|
||||
PopupTipPanel.ShowTip("请根据箭头找到宝藏!")
|
||||
end
|
||||
|
@ -39,7 +44,8 @@ end
|
|||
function XunBaoMiZongMap:OnSortingOrderChange()
|
||||
end
|
||||
--界面打开时调用(用于子类重写)
|
||||
function XunBaoMiZongMap:OnOpen(smallFightId,_isPlayAni,_func)
|
||||
function XunBaoMiZongMap:OnOpen(_data,_func)
|
||||
self.actData = _data
|
||||
func = _func
|
||||
SoundManager.PlaySound(SoundConfig.Sound_WorldMap)
|
||||
end
|
||||
|
@ -100,7 +106,7 @@ function XunBaoMiZongMap:LoadMapData()
|
|||
self.oldPos = Vector3.New(2487,-2536,10)
|
||||
self:SelectRenPos(Util.GetTransform(self.mapRoot, "uiObj#"),self.oldPos)
|
||||
self.curRewardPointData = ConfigManager.GetConfigData(ConfigName.MainLevelSettingConfig,math.random(1,15))
|
||||
LogGreen("当前奖励点名字:"..tostring(self.curRewardPointData.Name))
|
||||
Log("当前奖励点名字:"..tostring(self.curRewardPointData.Name))
|
||||
self.rewardPos = Vector2.New(self.curRewardPointData.ChapterCenterPosition[1],self.curRewardPointData.ChapterCenterPosition[2])
|
||||
end
|
||||
|
||||
|
|
|
@ -39,11 +39,17 @@ function XunBaoMiZong:BindEvent()
|
|||
end)
|
||||
|
||||
Util.AddOnceClick(self.btnShop,function ()
|
||||
JumpManager.GoJump(40021)
|
||||
JumpManager.GoJump(40025)
|
||||
end)
|
||||
|
||||
Util.AddOnceClick(self.btnGO,function ()
|
||||
UIManager.OpenPanel(UIName.XunBaoMiZongMapPanel)
|
||||
NetManager.XunBaoMiZongEnterMap(function (msg)
|
||||
if msg.isEnter then
|
||||
UIManager.OpenPanel(UIName.XunBaoMiZongMapPanel,self.actData)
|
||||
else
|
||||
PopupTipPanel.ShowTip("宝图碎片不足,无法开启寻宝!")
|
||||
end
|
||||
end)
|
||||
end)
|
||||
end
|
||||
|
||||
|
@ -76,11 +82,13 @@ end
|
|||
--刷新
|
||||
function XunBaoMiZong:Refresh()
|
||||
self.actData = CommonActPageManager.GetData(ActivityTypeDef.XunBaoMiZong)
|
||||
-- if self.actData.endTime - GetTimeStamp() <= 0 then self.parent:ClosePanel() end
|
||||
self.clipNum = BagManager.GetTotalItemNum(1229)
|
||||
self.tips.text = string.format("拥有宝图碎片:%s/9",self.clipNum)
|
||||
self.ImagePic3:SetActive(self.actData.state == 1)
|
||||
self.btnGO:SetActive(self.clipNum >= 9)
|
||||
if self.actData.endTime - GetTimeStamp() <= 0 then self.parent:ClosePanel() end
|
||||
local configData = ConfigManager.GetConfigDataByKey(ConfigName.LotterySetting,"ActivityId",self.actData.activityId)
|
||||
local itemNum = configData.CostItem[1]
|
||||
self.clipNum = BagManager.GetTotalItemNum(itemNum[1])
|
||||
self.tips.text = string.format("拥有宝图碎片:%s/%s",self.clipNum,itemNum[2])
|
||||
self.ImagePic3:SetActive(self.actData.value == 1)
|
||||
self.btnGO:SetActive(self.clipNum >= itemNum[2])
|
||||
self:SetMap()
|
||||
self:SetTime()
|
||||
end
|
||||
|
@ -100,22 +108,31 @@ function XunBaoMiZong:SetTime()
|
|||
end
|
||||
local time = self.actData.endTime - GetTimeStamp()
|
||||
self.timeText.text = string.format("剩余时间:%s",TimeToFelaxible(time))
|
||||
-- self.timer = Timer.New(function ()
|
||||
-- if time <= 0 then
|
||||
-- self:Refresh()
|
||||
-- end
|
||||
-- time = time - 1
|
||||
-- self.timeText.text = string.format("剩余时间:%s",TimeToFelaxible(time))
|
||||
-- end,1,-1)
|
||||
-- self.timer:Start()
|
||||
self.timer = Timer.New(function ()
|
||||
if time <= 0 then
|
||||
self:Refresh()
|
||||
end
|
||||
time = time - 1
|
||||
self.timeText.text = string.format("剩余时间:%s",TimeToFelaxible(time))
|
||||
end,1,-1)
|
||||
self.timer:Start()
|
||||
end
|
||||
|
||||
--界面关闭时调用(用于子类重写)
|
||||
function XunBaoMiZong:OnClose()
|
||||
if self.timer then
|
||||
self.timer:Stop()
|
||||
self.timer = nil
|
||||
end
|
||||
end
|
||||
|
||||
--界面销毁时调用(用于子类重写)
|
||||
function XunBaoMiZong:OnDestroy()
|
||||
if self.timer then
|
||||
self.timer:Stop()
|
||||
self.timer = nil
|
||||
end
|
||||
self.mapList= {}
|
||||
end
|
||||
|
||||
return XunBaoMiZong
|
Loading…
Reference in New Issue