public void OnIdle() { foreach (UsableEquipment ActiveEquipment in ArrayEquipment) { ActiveEquipment.OnIdle(); } }
public void OnJetpackRest(GameTime gameTime) { foreach (UsableEquipment ActiveEquipment in ArrayEquipment) { ActiveEquipment.OnJetpackRest(gameTime); } }
public void Update(GameTime gameTime) { foreach (UsableEquipment ActiveEquipment in ArrayEquipment) { ActiveEquipment.Update(gameTime); } }
public void Move(MovementInputs MovementInput) { foreach (UsableEquipment ActiveEquipment in ArrayEquipment) { ActiveEquipment.Move(MovementInput); } }
public void OnWallCollision(List <Tuple <PolygonCollisionResult, Polygon> > ListWallCollidingPolygon) { foreach (UsableEquipment ActiveEquipment in ArrayEquipment) { ActiveEquipment.OnWallCollision(ListWallCollidingPolygon); } }
public void OnStopJump() { foreach (UsableEquipment ActiveEquipment in ArrayEquipment) { ActiveEquipment.OnStopJump(); } }
protected override ActiveEquipment ActualCreateActiveEquipmentInstance(int equipmentIdentifier) { var item = InjectEquipmentSupport.GetEquipmentTypeById(equipmentIdentifier); var result = new ActiveEquipment(item) { InstanceId = Guid.NewGuid(), EquipmentId = equipmentIdentifier }; EngineKitList.Add(result.InstanceId, result); return(result); }
public double CalculateToHitPercent(Guid owningBotId, int tempScanKey, ActiveEquipment activeEquip) { var owner = GetMappedBotByPublicId(owningBotId); Point sourceLoc = owner.Position; Point destLoc = GetMappedBotById(activeData.GetEngineIdFromScanId(owner.EngineId, tempScanKey)).Position; if (!combatCore.Calcs.CanMountPointHitTarget(owner.Heading, MountPoint.Forward, sourceLoc, destLoc)) { return(0); } if (!this.activeWorld.IsLOSBetween(sourceLoc, destLoc)) { return(0); } return(1); }
protected override EquipmentUseResult ActualUseEquipmentItem(BoonBotBase targetBot, EquipmentUseDetails eud) { lastUsages.Push(eud); ActiveEquipment ae = EngineKitList[eud.InstanceIdentity]; if (ae == null) { throw new BdBaseException("That kit is not installed"); } switch (ae.EquipmentId) { case KnownEquipmentIds.MOCKSCANNER: return(PerformMockScan()); case KnownEquipmentIds.MOCKINSTALLEVERYWHERE: return(PerformDefaultEquipmentUse()); case KnownEquipmentIds.MOCKINSTALLINTERNALONLY: return(PerformDefaultEquipmentUse()); case KnownEquipmentIds.MOCKPROJECTILEWEAPON: return(PerformWeaponUsage(eud)); default: throw new BdBaseException("That equipment is not known - internal error "); } }