1
This commit is contained in:
parent
5fe6c934e1
commit
4e29f94d64
@ -1,8 +1,10 @@
|
|||||||
package mt
|
package mt
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
"q5"
|
||||||
"f5"
|
"f5"
|
||||||
"main/mtb"
|
"main/mtb"
|
||||||
|
"strings"
|
||||||
)
|
)
|
||||||
|
|
||||||
type MapGridRewardItem struct {
|
type MapGridRewardItem struct {
|
||||||
@ -20,7 +22,14 @@ type MapGridTable struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func (this *MapGrid) Init1() {
|
func (this *MapGrid) Init1() {
|
||||||
|
tmpStrs := strings.Split(this.MapGrid.GetReward(), "|")
|
||||||
|
for _, tmpStr := range(tmpStrs) {
|
||||||
|
tmpStrs2 := strings.Split(tmpStr, ":")
|
||||||
|
p := new(MapGridRewardItem)
|
||||||
|
p.ItemId = q5.ToInt32(tmpStrs2[0])
|
||||||
|
p.ItemNum = q5.ToInt32(tmpStrs2[1])
|
||||||
|
q5.AppendSlice(&this.rewardItems, p)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (this *MapGrid) GetRewardItems() *[]*MapGridRewardItem {
|
func (this *MapGrid) GetRewardItems() *[]*MapGridRewardItem {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user