|
@@ -25,13 +25,14 @@ import { MailManager } from '../../manager/MailManager';
|
|
|
import { ViewID } from '../../../framework/config/LayerConf';
|
|
|
import { MailData } from '../../data/MailData';
|
|
|
import { RoleManager } from '../../manager/RoleManager';
|
|
|
-import { FightRole, RoleData } from '../../data/RoleData';
|
|
|
+import { RoleData } from '../../data/RoleData';
|
|
|
import { BattleData, BattleLayoutPos, BattleLayoutScale, BattleOptsBase, BattleOptsKill, BattleOptsMerge, BattleOptsMove, BattleOptsNew, BattleOptsRemove, BattleOptsType } from '../../data/BattleData';
|
|
|
import { BattleManager } from '../../manager/BattleManager';
|
|
|
import { UserData } from '../../data/UserData';
|
|
|
import { ResultUI } from './node/ResultUI';
|
|
|
import { ChangeChapter } from './node/ChangeChapter';
|
|
|
import { RewardChapter } from './node/RewardChapter';
|
|
|
+import { FightRole } from '../../common/InterfaceAddEnum';
|
|
|
|
|
|
//地图比例尺 1:70
|
|
|
let mapScale = 72;
|
|
@@ -744,7 +745,7 @@ export class TowerUI extends BaseView {
|
|
|
bagPos.hero.position = bagPos.pos;
|
|
|
let hero = bagPos.hero.getComponent(Hero);
|
|
|
|
|
|
- heroData.init(battleLayoutData.typeID,battleLayoutData.level,-1)
|
|
|
+ heroData.init(RoleData.getRoleDataByID(battleLayoutData.typeID),battleLayoutData.level,-1)
|
|
|
hero.resetData(heroData);
|
|
|
}
|
|
|
}
|
|
@@ -786,7 +787,7 @@ export class TowerUI extends BaseView {
|
|
|
posData.hero.position = posData.pos;
|
|
|
let hero = posData.hero.getComponent(Hero);
|
|
|
|
|
|
- heroData.init(battleLayoutData.typeID,battleLayoutData.level,posNumber)
|
|
|
+ heroData.init(RoleData.getRoleDataByID(battleLayoutData.typeID),battleLayoutData.level,posNumber)
|
|
|
hero.resetData(heroData);
|
|
|
}
|
|
|
}
|
|
@@ -903,7 +904,7 @@ export class TowerUI extends BaseView {
|
|
|
}
|
|
|
}
|
|
|
let heroData = HeroDataPool.getObject();
|
|
|
- heroData.init(heroID,1,1)
|
|
|
+ heroData.init(RoleData.getRoleDataByID(heroID),1,1)
|
|
|
|
|
|
let node:Node = null;
|
|
|
if(this.heroPool[heroID] == null){
|
|
@@ -968,7 +969,7 @@ export class TowerUI extends BaseView {
|
|
|
// let heroIndex = Math.floor(Math.random() * this.loadHeroModelNum)%this.loadHeroModelNum;
|
|
|
let heroID = typeID;
|
|
|
let heroData = HeroDataPool.getObject();
|
|
|
- heroData.init(heroID,level,1)
|
|
|
+ heroData.init(RoleData.getRoleDataByID(heroID),level,1)
|
|
|
|
|
|
let posData = this.bagPosList[posIndex];
|
|
|
|
|
@@ -1009,7 +1010,7 @@ export class TowerUI extends BaseView {
|
|
|
|
|
|
posData.hero = node;
|
|
|
|
|
|
- let scale = posIndex > BattleUtil.BagListSize ? 1.2 : 1;
|
|
|
+ let scale = posIndex > BattleUtil.BagListSize-1 ? 1.2 : 1;
|
|
|
node.scale = v3(scale,scale,1);
|
|
|
|
|
|
node.position = posData.pos;
|