修改道具排序顺序
parent
33acb35f82
commit
b0c02a7ff0
|
@ -92,10 +92,14 @@ function this.GetAllItemsData()
|
|||
table.insert(list,data)
|
||||
end
|
||||
table.sort(list,function(a,b)
|
||||
if a.property == b.property then
|
||||
return a.id < b.id
|
||||
if a.Quantity == b.Quantity then
|
||||
if a.property == b.property then
|
||||
return a.id < b.id
|
||||
end
|
||||
return a.property < b.property
|
||||
else
|
||||
return a.Quantity > b.Quantity
|
||||
end
|
||||
return a.property < b.property
|
||||
end)
|
||||
return list
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue