Space Clouds

You need to place your drone in a clear place

Most of us have experienced “You need to place your drone in a clear place” at some point in the middle of combat. You’re fighting, you want to get some drones down for defense, but there are ships swarming all over the place, and you just can’t get a clear spot. All you can do is Spam your hot key repeatedly, hoping for a brief opening.

You Need To Place Your Drone In A Clear Place
Since the main point of this retriction on drone placement is to keep them visually separate so they can be selected and targeted properly, it doesn’t necessarily make sense for such quick moving things as ships and mobile drones to block the placement of drones. It was also the case that you could deploy a mobile drone on top of a normal drone, but not the other way around.

I was up in the mountains, looking for something quick to code on my laptop and decided to rewrite the function that determines non-mobile, non-attached drone placement. The new code will not block drone placement from ships or from mobile drones. Since both of these types of objects move around a lot, it makes sense to me that they shouldn’t block normal drones from being placed.

Here’s the new code, just for fun. This should be appearing on live in a patch sometime soon.

// make sure nothing is underneath or it's a special drone
if (!bSuperItem && !IsMobile() && !GetSpec()->bEthereal )
{
  sobit_ALL it;
  for (it = husk->getGal()->sobs.begin(sobmap::PARSE_ALL); it != husk->getGal()->sobs.end(sobmap::PARSE_ALL); it++)
  {
    SpaceObject *sob = it->second;
    if (sob == husk   // The ship deploying the drone won't block it
      || !sob->Corporeal()  // Non-corporeal things will not block it
      || sob->SobType() == SOB_SPACESHIP) // Spaceships will not block it
      continue;
    Pillbox * sobPillbox = dynamic_cast<Pillbox *>(sob);
    if (sobPillbox && sobPillbox->IsMobile())
      continue; // Mobile drones won't block normal drones
    if (sob->WithinRange(husk, (sob->sizex * 0.5) + (GetSpec()->diameter * 0.5)))
      throw string("You need to place your drone in a clear place.");
  }
}
Discuss in the Forum