Author Topic: [Bug?] validate throw and calculate throw are off by 1 voxel (OXC and OXCE)  (Read 284 times)

Offline Meridian

  • Global Moderator
  • Commander
  • *****
  • Posts: 8887
    • View Profile
ea1cce5375c7d5deacccad435279162eeb88f4f1

Code: [Select]
# throw calculation
# targetVoxel = _action.target.toVoxel() + Position(8,8, (1 + -targetTile->getTerrainLevel()));

#vs

# example of throw validation
# Position targetVoxel = targetTile.toVoxel() + Position(8,8, (2 + -_save->getTile(targetTile)->getTerrainLevel()));
# // are we within range?
# if (_save->getTileEngine()->validateThrow(action, originVoxel, targetVoxel, _save->getDepth()))


Probably unintentional side effect of arcing shot functionality.

To be investigated...
« Last Edit: August 15, 2024, 12:09:48 pm by Meridian »