List <PointFT> CreateAttackWaveDeployPoints(DeployCalculationInformation deployInfo, List <VisualObject> visuals) { var deployPoints = deployInfo.AllDeployPoints; visuals.Add(new PointsObject("AttackUnitDeployPoints", Color.FromArgb(110, Color.Black), deployPoints)); return(deployPoints); }
List <PointFT> CreateIntersectionDeployPoint(DeployCalculationInformation deployInfo, List <VisualObject> visuals) { var deployPoints = deployInfo.AllDeployPoints; var intersectionPointFt = deployInfo.IntersectionPointFT; return(new List <PointFT> { intersectionPointFt }); }
List <PointFT> CreateFunnelCreatorDeployPoints(DeployCalculationInformation deployInfo, List <VisualObject> visuals) { var intersectionPointFt = deployInfo.IntersectionPointFT; var deployPoints = deployInfo.AllDeployPoints; deployPoints = deployPoints.Where(x => x.DistanceSq(intersectionPointFt) < 240).ToList(); var extremePoints = GetMostDistantPoints(deployPoints, intersectionPointFt); extremePoints = extremePoints.Select(x => x.TransformPositionAlongAxis(3).Constrain()).ToArray(); return(extremePoints.ToList()); }
List <PointFT> CreateBalloonDeployPoints(DeployCalculationInformation deployInfo, DeployElement balloon, List <VisualObject> visuals) { var intersectionPointFt = deployInfo.IntersectionPointFT; var redlinePoints = GameGrid.RedPoints.Where(x => x.DistanceSq(intersectionPointFt) < 460).ToList(); redlinePoints = redlinePoints.OrderBy(x => x.Angle).ToList(); var deployCount = balloon.Count; var unitsPerStack = 3; var stackCount = deployCount / unitsPerStack; // We want to deploy balloons in 3 unit stacks Log.Debug($"[LavaLoon] We need to find {stackCount} deploypoints"); var stepSize = redlinePoints.Count / stackCount; var stackDeployPoints = redlinePoints.Where((x, i) => i % stepSize == 0).ToList(); var stackDeployPointsVisual = new PointsObject("balloons", Color.FromArgb(200, Color.NavajoWhite), stackDeployPoints, 1); visuals.Add(stackDeployPointsVisual); return(stackDeployPoints); }
List <PointFT> CreateLavaHoundDeployPoints(DeployCalculationInformation deployInfo, List <VisualObject> visuals) { var deployPoints = deployInfo.AllDeployPoints; var intersectionPointFt = deployInfo.IntersectionPointFT; // Don't use the most outer points for lavahounds, instead use a smaller radius deployPoints = deployPoints.Where(x => x.DistanceSq(intersectionPointFt) < 300).ToList(); // Furthest Deploypoints are supposed to be the deployspots for any tanks var mostDistantPoints = GetMostDistantPoints(deployPoints, intersectionPointFt); var furthestDeployPoint1 = mostDistantPoints.First(); var furthestDeployPoint2 = mostDistantPoints.Last(); var lavaHoundDeployPoints = new List <PointFT>(); lavaHoundDeployPoints.Add(furthestDeployPoint1); lavaHoundDeployPoints.Add(furthestDeployPoint2); visuals.Add(new PointsObject("LavaHoundDeployPoints", Color.FromArgb(200, Color.Pink), lavaHoundDeployPoints)); return(lavaHoundDeployPoints); }