Merge branch 'dev' of http://git.legu.cc/liwei_3d/go_dreamfactory into dev
This commit is contained in:
commit
346e775a4e
@ -526,7 +526,15 @@ func (this *MapData) SkillUp(pos int32, color int32, skillid int32, value int32,
|
||||
|
||||
switch skillid {
|
||||
case 1:
|
||||
ids = utils.RandomNumbers(0, Total-1, int(value))
|
||||
randNum := utils.RandomNumbers(0, Total-1, int(value)*2)
|
||||
for _, v := range randNum {
|
||||
if this.Plat[v].Special > 0 {
|
||||
ids = append(ids, v)
|
||||
if len(ids) >= int(value) {
|
||||
break
|
||||
}
|
||||
}
|
||||
}
|
||||
case 2:
|
||||
for i := 0; i < Height; i++ {
|
||||
ids = append(ids, 3*Width+i)
|
||||
|
Loading…
Reference in New Issue
Block a user