public HeroUnitController( EntityController.Select entityControllerSelect, HeroViewPresentor unitViewPresenter, BaseUnit.UnitCharacteristics unitCharacteristics, EntityController.GetTarget getTarget, EntityController.Faction faction, DeathDestroy updateDeath, EntityController.HeroResurrect heroResurrect, BaraksModel.SetUpdeteCharacteristicsDelegate setUpdeteCharacteristicsDelegate ) : base(entityControllerSelect, unitViewPresenter, unitCharacteristics, getTarget, faction, updateDeath, setUpdeteCharacteristicsDelegate) { this.updateDeath = updateDeath; EffectsController effectsController = new EffectsController(); this.heroResurrect = heroResurrect; unitBehaviour.CallDeathFSMEvent(); unitBehaviour = new HeroBehaviour( getTarget, faction, unitViewPresenter, animationController ); unitModel = new HeroUnit( "Unit", unitCharacteristics, SpellInit( effectsController ), faction, effectsController, _UpdateCharacteristics, UpdateDeath, LevelUpEffect, setUpdeteCharacteristicsDelegate, DeleteVisualEffect ); unitView = new HeroView( unitViewPresenter, Selected, GetDamage, ((HeroUnit)unitModel).GetXp ); }
public BaseUnitController( EntityController.Select entityControllerSelect, UnitViewPresenter unitViewPresenter, BaseUnit.UnitCharacteristics unitCharacteristics, EntityController.GetTarget getTarget, EntityController.Faction faction, DeathDestroy updateDeath, BaraksModel.SetUpdeteCharacteristicsDelegate setUpdeteCharacteristicsDelegate ) { this.updateDeath = updateDeath; animationController = new AnimationController( unitViewPresenter._animation ); EffectsController effectsController = new EffectsController(); tempNavMeshAgent = unitViewPresenter.navMeshAgent; this.entityControllerSelect = entityControllerSelect; unitBehaviour = new BaseUnitBehaviour( getTarget, faction, unitViewPresenter, animationController ); unitModel = new BaseUnit(unitCharacteristics, faction, effectsController, _UpdateCharacteristics, UpdateDeath, setUpdeteCharacteristicsDelegate, DeleteVisualEffect ); unitView = new BaseUnitView( unitViewPresenter, Selected, GetDamage ); }
public BuildController( EntityController.Select entityControllerSelect, BuildViewPresenter unitViewPresenter, BaseUnit.UnitCharacteristics unitCharacteristics, EntityController.GetTarget getTarget, EntityController.Faction faction, DeathDestroy updateDeath, BaraksModel.SetUpdeteCharacteristicsDelegate setUpdeteCharacteristicsDelegate ) : base(entityControllerSelect, unitViewPresenter, unitCharacteristics, getTarget, faction, updateDeath, setUpdeteCharacteristicsDelegate) { this.updateDeath = updateDeath; EffectsController effectsController = new EffectsController(); unitBehaviour.CallDeathFSMEvent(); unitBehaviour = new BuildBehaviour( getTarget, faction, unitViewPresenter, animationController ); unitModel = new BuildUnit( unitCharacteristics, faction, effectsController, _UpdateCharacteristics, UpdateDeath, setUpdeteCharacteristicsDelegate, DeleteVisualEffect ); BuildView unitView = new BuildView( unitViewPresenter, Selected, ((BuildUnit)unitModel).GetDamage ); this.unitView = unitView; }