Author Topic: bool ProjectileFlyBState::createNewProjectile() just swallows bad throws.  (Read 2251 times)

Offline Xilmi

  • Moderator
  • Commander
  • ***
  • Posts: 641
    • View Profile
There's an inconsistency with the evaluation of the result of calculateThrow.

calculateThrow returns V_OUTOFBOUNDS when the throw is not possible.

When it is possible, it returns what kind of object would be hit.

However, the method receiving that result also considers hitting a wall as a failure and then simply does nothing.

While the player can just click again, the AI is fucked when that happens because it thinks it tried something invalid.

It is particularly unfair in favor of the player because all throws that would be really bad duds, simply aren't executed and the player is allowed to try again.
The alternative solution would be to internally let it try again until unit, floor or object are hit. But I think that's worse as it makes throwing just stronger than it should be.

I'll fix it like this in my source-fork and recommend other source-forks to do something similar.

Offline Xilmi

  • Moderator
  • Commander
  • ***
  • Posts: 641
    • View Profile
Before: Floater just skipped it's turn because the engine thought it tried something invalid.

Now: The grenade can hit a wall, bounce off and explore where it landed. (floater died to reaction-fire)