/** @format */ import {ComType, EntityIndex} from '../lib/Const' import {ECSComponent} from '../lib/ECSComponent' import {cObject} from '../../collision/Object' import {IBulletConfig} from '../../config/BulletConfig' import {ComRole} from './ComRole' import {IFightData} from '../core/GameInterface' @ECSComponent(ComType.ComBullet) export class ComBullet { public bulletCfg: IBulletConfig //初始赋值,防止预制体创建中人死了创建不出来 public group: number public cObject: cObject public hitEnemies: EntityIndex[] = [] public ejectionEnemy: EntityIndex public ejectionEnemies: EntityIndex[] = [] public ejectionAnis: EntityIndex[] = [] //是否暴击 public isCrit: boolean //攻击参数对象 fightData: IFightData }