技能动画调试 继续
This commit is contained in:
@@ -175,7 +175,7 @@ export class HeroViewComp extends CCComp {
|
||||
var prefab: Prefab = oops.res.get(path, Prefab)!;
|
||||
var node = instantiate(prefab);
|
||||
node.setScale(node.scale.x * scale, node.scale.y);
|
||||
node.setPosition(this.node.position.x, this.node.position.y + 30, this.node.position.z);
|
||||
node.setPosition(this.node.position.x, this.node.position.y+8, this.node.position.z);
|
||||
node.parent = this.node.parent;
|
||||
}
|
||||
|
||||
@@ -204,7 +204,7 @@ export class HeroViewComp extends CCComp {
|
||||
/** 技能提示 */
|
||||
private tooltip(type: number = 1, value: string = "", s_uuid: number = 1001, y: number = 90) {
|
||||
let tip = ecs.getEntity<Tooltip>(Tooltip);
|
||||
let pos = v3(0, 10);
|
||||
let pos = v3(0, 60);
|
||||
pos.y = pos.y + y;
|
||||
tip.load(pos, type, value, s_uuid, this.node);
|
||||
}
|
||||
@@ -213,7 +213,7 @@ export class HeroViewComp extends CCComp {
|
||||
private hp_tip(type: number = 1, value: string = "", s_uuid: number = 1001, y: number = 90) {
|
||||
let tip = ecs.getEntity<Tooltip>(Tooltip);
|
||||
let x = this.node.position.x;
|
||||
let ny = this.node.getComponent(UITransform).height + 20;
|
||||
let ny = this.node.getComponent(UITransform).height + 60;
|
||||
let pos = v3(x, ny, 0);
|
||||
tip.load(pos, type, value, s_uuid, this.node.parent);
|
||||
}
|
||||
|
||||
@@ -109,7 +109,7 @@ export class SACastSystem extends ecs.ComblockSystem implements ecs.ISystemUpdat
|
||||
heroView.playSkillEffect(s_uuid);
|
||||
|
||||
// 2. 延迟创建技能实体(等待动画)
|
||||
const delay = 0.1
|
||||
const delay = 0.3
|
||||
heroView.scheduleOnce(() => {
|
||||
this.createSkill(s_uuid, heroView);
|
||||
}, delay);
|
||||
|
||||
Reference in New Issue
Block a user