project-navigation
Personal tools

Author Topic: Line of sight Vs Line of Fire  (Read 21795 times)

Offline Coconut Jonlan

  • Rookie
  • ***
  • Posts: 49
    • View Profile
Re: Line of sight Vs Line of Fire
« Reply #30 on: February 18, 2009, 01:30:44 am »
How do you get a FPS view like that... are you in game or the map editor?

And yes I agree, I mean it is unfair that an alien in a window can shoot at you but you can't shoot at him because of the ledge...  Someone was saying that you can use Shift to move the target up?... what is that about, would that solve the problem?

press V to toggle from the isometric view to the FPS view in the battlescape

The shift key works sometimes, but it seems to just change the angle that the weapon is held at - rather than change the elevation of the weapon - so it didn't make any difference in the screenshot I last posted

Offline Coconut Jonlan

  • Rookie
  • ***
  • Posts: 49
    • View Profile
Re: Line of sight Vs Line of Fire
« Reply #31 on: February 18, 2009, 01:42:10 am »
That's the thing though. It ISN'T as simple as that. The game doesn't think in terms of "if there is an obvious LOS..." or "straightforward killshot". It uses routines to trace lines from one point to another, and it can detect if that line is interrupted by geometry or not. That's all we have to work with, basically. You don't seem to realize that computers don't work like humans.

You can press V for first person view. Bear in mind though that this feature is scheduled to be axed and replaced by something else.

No, it only shifts the target height, not the source height.

BTA - I meant simple as compared to building in the ability to target individual body parts - not neccesarily developing routines to determine critical hit areas on the body - I'm with you 100% on keeping things asa simple as possible.

But you have raised an important point - if the ability to change the angle of the shot can be adjusted by the player - is it such a massive stretch to make the originating point of the shot adjustable too? a simple up/down control on the vertical axis would do it
« Last Edit: February 18, 2009, 01:43:54 am by Coconut Jonlan »

Offline BTAxis

  • Administrator
  • PHALANX Commander
  • *******
  • Posts: 2607
    • View Profile
Re: Line of sight Vs Line of Fire
« Reply #32 on: February 18, 2009, 01:59:28 am »
BTA - I meant simple as compared to building in the ability to target individual body parts - not neccesarily developing routines to determine critical hit areas on the body - I'm with you 100% on keeping things asa simple as possible.

I think you misunderstood me on this. I wasn't saying I want to keep things simple. I do, it's just not what I meant. What I'm saying is, it's NOT POSSIBLE, codewise, to know what an "obvious LOS" or a "straightforward shot" is. It's not even possible to tell the LOF is being interrupted by an object no higher than the soldier's waist. All you know is that the line is interrupted. You don't know by what, or what shape the offending object has. This makes it impossible to do what you're suggesting.

Quote
But you have raised an important point - if the ability to change the angle of the shot can be adjusted by the player - is it such a massive stretch to make the originating point of the shot adjustable too? a simple up/down control on the vertical axis would do it

I already answered this. Yes, it is possible, it's a matter of changing a value somewhere in the code. The reason why we're not doing this is, as stated, that the point of origin should match up with the model. It's not a strict necessity, but it's a hard requirement we're making, take it or leave it. Ergo, we are going to need a character animation that shows the soldier firing from the shoulder. Provide us with this, and you shall have your fix.

On a side note, don't expect that to solve everything, either. No matter what point of origin you choose, there will always be objects that are inconveniently JUST in the way when they wouldn't be if the soldier had [insert very small change here]. I remind you that it is not possible to detect this in the code, and as such impossible to avoid.


CapnKill

  • Guest
Re: Line of sight Vs Line of Fire
« Reply #33 on: February 18, 2009, 02:37:01 am »
Please excuse my ignorance in advance, since I know very little of code, but what if you made the hit box for a player to always be the head?   So when you target a bad guy you basically are aiming at their head....

I haven't played through much of the game yet, so I'm not familiar with all the scenarios you can encounter, but I can't imagine many where the head is not visible yet other parts of the body are...   

Once again, excuse my ignorance :)

« Last Edit: February 18, 2009, 02:55:59 am by CapnKill »

Offline Coconut Jonlan

  • Rookie
  • ***
  • Posts: 49
    • View Profile
Re: Line of sight Vs Line of Fire
« Reply #34 on: February 18, 2009, 03:27:45 am »
I think you misunderstood me on this. I wasn't saying I want to keep things simple. I do, it's just not what I meant. What I'm saying is, it's NOT POSSIBLE, codewise, to know what an "obvious LOS" or a "straightforward shot" is. It's not even possible to tell the LOF is being interrupted by an object no higher than the soldier's waist. All you know is that the line is interrupted. You don't know by what, or what shape the offending object has. This makes it impossible to do what you're suggesting.

I already answered this. Yes, it is possible, it's a matter of changing a value somewhere in the code. The reason why we're not doing this is, as stated, that the point of origin should match up with the model. It's not a strict necessity, but it's a hard requirement we're making, take it or leave it. Ergo, we are going to need a character animation that shows the soldier firing from the shoulder. Provide us with this, and you shall have your fix.

On a side note, don't expect that to solve everything, either. No matter what point of origin you choose, there will always be objects that are inconveniently JUST in the way when they wouldn't be if the soldier had [insert very small change here]. I remind you that it is not possible to detect this in the code, and as such impossible to avoid.



Good answer - thanks

Offline BTAxis

  • Administrator
  • PHALANX Commander
  • *******
  • Posts: 2607
    • View Profile
Re: Line of sight Vs Line of Fire
« Reply #35 on: February 18, 2009, 03:29:57 am »
Please excuse my ignorance in advance, since I know very little of code, but what if you made the hit box for a player to always be the head?   So when you target a bad guy you basically are aiming at their head....

Hit box? There's no hit box. Or, if you will, the model is the hit box. The accuracy percentage is calculated based on a statistical probability of hitting the model given a gaussian random spread.

CapnKill

  • Guest
Re: Line of sight Vs Line of Fire
« Reply #36 on: February 18, 2009, 04:54:53 am »
Hit box? There's no hit box. Or, if you will, the model is the hit box. The accuracy percentage is calculated based on a statistical probability of hitting the model given a gaussian random spread.

But how is Line of fire worked out.  The OP said that line of fire went to the models torso... is that correct?

SO couldn't it be changed so the models torso is really the models head?   

CapnKill

  • Guest
Re: Line of sight Vs Line of Fire
« Reply #37 on: February 18, 2009, 04:58:12 am »
I already answered this. Yes, it is possible, it's a matter of changing a value somewhere in the code. The reason why we're not doing this is, as stated, that the point of origin should match up with the model. It's not a strict necessity, but it's a hard requirement we're making, take it or leave it. Ergo, we are going to need a character animation that shows the soldier firing from the shoulder. Provide us with this, and you shall have your fix.

So what would need to be done for this... you guys want the animation and you can take care of the code part separately?  And how many levels of animation do you need and so on and so forth?  My roomate is a good artist and all that nad he's interested in helping with this, but that's where our knowledge starts.  What 3d rendering app should we use etc...etc... Basically I'm saying that we'd like to take a crack at it (as long as no coding is required) and if that's the case, what do we need to have?


Offline vedrit

  • Sergeant
  • *****
  • Posts: 438
    • View Profile
Re: Line of sight Vs Line of Fire
« Reply #38 on: February 18, 2009, 06:22:29 am »
Im willing to help, I just need to know what file type the models are in, and the raw models

Offline BTAxis

  • Administrator
  • PHALANX Commander
  • *******
  • Posts: 2607
    • View Profile
Re: Line of sight Vs Line of Fire
« Reply #39 on: February 18, 2009, 11:53:40 am »
But how is Line of fire worked out.  The OP said that line of fire went to the models torso... is that correct?

SO couldn't it be changed so the models torso is really the models head?   

If you had a weapon with no accuracy penalties, the line would go to the torso, yes. You can change this with the SHIFT button to go to the head or feet. However, weapons do have accuracy penalties, and this results in spread. So basically you're aiming at the center of a disc (oval really) of hit probability. If you shift the center of this disc to the model's head, more of it will fall in empty space, lowering the overall chance to hit.

Not to mention that not all models HAVE a head...
« Last Edit: February 18, 2009, 11:55:35 am by BTAxis »

Offline BTAxis

  • Administrator
  • PHALANX Commander
  • *******
  • Posts: 2607
    • View Profile
Re: Line of sight Vs Line of Fire
« Reply #40 on: February 18, 2009, 11:54:26 am »
Modelling information can be found here: http://ufoai.ninex.info/wiki/index.php/Modelling

CapnKill

  • Guest
Re: Line of sight Vs Line of Fire
« Reply #41 on: February 18, 2009, 07:28:48 pm »
Not to mention that not all models HAVE a head...

Ah yes, aliens... I forget :)  Thanks for the clarification

Offline BTAxis

  • Administrator
  • PHALANX Commander
  • *******
  • Posts: 2607
    • View Profile
Re: Line of sight Vs Line of Fire
« Reply #42 on: February 22, 2009, 01:54:28 pm »
I've split this topic. The remainder, which is about model animation, has been moved here.

Offline Salvo

  • Rookie
  • ***
  • Posts: 37
    • View Profile
Re: Line of sight Vs Line of Fire
« Reply #43 on: March 10, 2009, 12:04:56 am »
It'd be nice to be able to shoot down from rooftops without having to walk all the way to the edge just because the edge is blocking the LOF but not your LOS :(
Then again, aliens should be able to do exactly the same. Also, if players were able to shoot when the soldier's head is visible, wouldn't that create more annoyances with line of fire? Right now, you're pretty much forced to step out of the cover, just so that your waist-high cover doesn't block your LOF. Much like the aliens, I assume. And how would it affect reaction fire? Either lot less of firing, since the soldiers and the aliens wouldn't be able to get a clear shot, or lot more misses, since you'd see lot more heads peeking behind cover. You would have to be able to tell the soldier when it's ok to shoot. 10% to hit? 20?

Changing the LOF to your LOS seems like a nice idea... at first. But there are further complications and potential annoyances involved, as you can see.
« Last Edit: March 10, 2009, 12:21:30 am by Salvo »

Offline vedrit

  • Sergeant
  • *****
  • Posts: 438
    • View Profile
Re: Line of sight Vs Line of Fire
« Reply #44 on: March 11, 2009, 05:41:21 am »
This has been covered, and is, I should hope, being taken care of. The fire-from-shoulder animation has been found.
I agree on being able to tell the soldier when to shoot. Many times have I not taken the shot because it wasnt good.