DRL > Requests For Features

Speed and reaction

<< < (2/2)

TFoN:

--- Quote ---I rather think that everything has a 50% miss chance when firing at things out of LOS, as even with the arena's current allowance for enemies to see the second 'you' and fire at the real you, they don't hit nearly as often as they do when shooting at you from within LOS.
--- End quote ---
I'm not sure if this is a good example and actual evidence. On these arena levels you're moving around a lot (whether to run away or to find a target), which increases your dodge rate. Also, you're likely to be doing this on Coward, no matter your strategy while fighting, because you have no target anyway. So 50% miss rate or not, you're bound to be hit a lot less often than when you're on a normal level, standing and shooting. Actually, with the 50% miss rate, coward tactics, long ranges and moving around, you're likely to hardly ever be hit, which isn't likely to be the case on these levels, where players die so very often :)

From my experience, LOS is asymmetric, and should be the only reason for why some monsters fire at you from what seems like out of LOS (AFAIK, this never happens in open spaces, where LOS boundries are the only reason for being out of LOS). This makes most sense where it has been complained about most: on maze levels, chances are very good that what Rabiat described on his last paragraph will happen, i.e. you'll have to vacuum clean a hallway, and somewhere on the path something will see you when you can't see it and'll take that "blind" shot at you.


--- Quote ---There is a slight asymmetry in the way the targeting cursor works.  However, it has nothing to do with who is using it AFAICT, and everything to do with where the user is standing and where they're aiming.  Try pointing at a square two squares down and one to the right, then moving to the place you just targeted and pointing at the square you just moved from.  Notice a difference in the choice of the middle square?  It's rather annoying, but fortunately it's possible most of the time to overcome it by simply aiming at a slightly different position (instead of double 'f'ing) so as to avoid walls/barrels.
--- End quote ---
Targeting corrections work fine with targeting, as you have mostly full control over the intended target. But that's exactly the problem with LOS - you get what the algorithm gives you, and you have to live with it. Any case where you can't hit your target, directly or indirectly, is likely to be a case where you can't see it. But just like this doesn't mean that your target can't hit you, it doesn't mean he can't see you, either. It gets real bad when you can't see him due to algorithm behaviour (and not too short a LOS), but do have line-of-fire. Therefore, I doubt the same algorithm is used for both, although it seems they have the same type of quirks.

Also, I'm sure you've all encountered a monster blowing itself to bits by hitting a barrel. I'm almost certain this happens for the smae reason the targeting line sometimes shows green when it should be red and vice versa. I.e. sometimes an imp fires at you, hitting a barrel even though its AI normally refuses to fire without having a clear shot. My guess is that as far as the AI knew, it did.

Rabiat:

--- Quote from: BDR on May 14, 2007, 15:25 ---There is a slight asymmetry in the way the targeting cursor works.  However, it has nothing to do with who is using it AFAICT, and everything to do with where the user is standing and where they're aiming.  Try pointing at a square two squares down and one to the right, then moving to the place you just targeted and pointing at the square you just moved from.  Notice a difference in the choice of the middle square?  It's rather annoying, but fortunately it's possible most of the time to overcome it by simply aiming at a slightly different position (instead of double 'f'ing) so as to avoid walls/barrels.
--- End quote ---

I'm afraid my question wasn't clear. I'm aware of the fact that the targeting quirk is overcome by firing at a location past a target. I intended to point out that the trace from the player's location to the target's location could be different from the trace to the target's location to the player's (hence, asymmetric).

What if the player aiming at a former foo would return the following trace (left), while the former foo aiming at the player would return another trace (right):

--- Code: ---@***             @**
    **h             ***h

--- End code ---

If either one of the center tiles is a wall, the player would be able to hit the former foo, while the former foo would not be able to hit the player (or vice versa).

It is very likely that a similar ray tracing technique is used for calculating FOV (one can tell by the gaps). If the above example were valid for FOV, and one of the center tiles were a wall, the former foo could be able to see the player (left) without the player being able to see the former foo (right):

--- Code: ---@***             @**
   #**h             #  h

--- End code ---

This of course only happens if the program actually calculates the FOV for the former foo. A more effective implementation would be to calculate the player's FOV once, and if you need to know whether an enemy can see the player, just check if the player can see the enemy (this at least guarantees symmetric FOV).


--- Quote from: TFoN ---But that's exactly the problem with LOS - you get what the algorithm gives you, and you have to live with it. (...) It gets real bad when you can't see him due to algorithm behaviour (and not too short a LOS), but do have line-of-fire. Therefore, I doubt the same algorithm is used for both, although it seems they have the same type of quirks.
--- End quote ---

It's likely that line of fire and field of view use the same ray tracing algorithm (i.e. FOV is nothing but of bunch of clockwise LOS calculations). In that case LOS and FOV would suffer from the same quirks. If that's true, a problem rounding angles or gaps should be the same for LOS and FOV (so a player can't target what they can't see, and can always target what they see). That's why I thought the actual problem could be caused by directional asymmetry (from player to enemy, and from enemy to player).

Navigation

[0] Message Index

[*] Previous page

Go to full version