This commit is contained in:
2024-09-11 18:00:43 +08:00
parent ef4e502adf
commit 4501876c37
44 changed files with 518 additions and 4634 deletions

View File

@@ -48,6 +48,8 @@ export class BoxRangComp extends CCComp {
// console.log(this.node.name+"onEndContact: seft:"+selfCollider.group+"|other:"+otherCollider.group+"| tag: seft:"+selfCollider.tag+"|other:"+otherCollider.tag);
this.MonViewComp.is_atking = false;
this.MonViewComp.enemy = null;
this.MonViewComp.as.change_default("move");
this.MonViewComp.as.move();
}
}
onPreSolve (selfCollider: Collider2D, otherCollider: Collider2D, contact: IPhysics2DContact | null) {
@@ -66,6 +68,8 @@ export class BoxRangComp extends CCComp {
if(Math.abs(other_pos.x-self_pos.x) < this.MonViewComp.atk_dis){
this.MonViewComp.is_atking = true;
this.MonViewComp.stop_cd = 0.1
this.MonViewComp.as.change_default("idle");
}
}