抽卡按钮调整

onepiece_demo_arena
xiejun 2024-01-30 19:05:11 +08:00
parent b6b1e7affe
commit aa25e510cf
1 changed files with 4 additions and 4 deletions

View File

@ -35,7 +35,7 @@ function RecruitMainPanel:InitComponent()
this.moveWidth = this.grid:GetComponent("RectTransform").rect.width
this.itemWidth = this.item:GetComponent("RectTransform").rect.width
this.off = 51
this.pos0 = Vector3.New(this.off * (0 - 2) + (0 - 1) * this.itemWidth - 30,0,0)
this.pos0 = Vector3.New(this.off * (0 - 2) + (0 - 1) * this.itemWidth - 186,28,0)
self.lastPage,self.curPage,self.nextPage = 0,0,0
this.trigger = Util.GetEventTriggerListener(this.gameObject) --触摸事件
end
@ -390,9 +390,9 @@ function this:RefreshTabData()
if #self.dicData==1 then
vec.x=this.off * (#this.itemList - 1) + (#this.itemList) * this.itemWidth - 30
else
vec.x = this.off * (i - 2) + (i - 1) * this.itemWidth - 30
vec.x = this.off * (i - 2) + (i - 1) * this.itemWidth - 100
end
vec.y = 0
vec.y = 28
this.itemList[i].tran.anchoredPosition = vec
this.itemList[i].pos = this.itemList[i].tran.anchoredPosition
this.itemList[i].index = i
@ -424,7 +424,7 @@ function this:RefreshTabData()
redPointTypeList[self.dicData[i].RpType] = this.itemList[i].redpot
end
end
this.pos4 = Vector3.New(this.off * (#this.itemList - 1) + (#this.itemList) * this.itemWidth - 30,0,0)
this.pos4 = Vector3.New(this.off * (#this.itemList - 1) + (#this.itemList) * this.itemWidth - 186,0,0)
--print(tostring(this.pos4))
LogError(tostring(this.pos4))
end