Jump to content

How do you calculate the LOS when a squad is not in the same 8*8m grid?


popllt

Recommended Posts

Yep. Tough crowd around here.

In anticipation of Steve's reply, I should note that I wasn't necessarily criticizing CM's modeling of LOS & LOF with the above, just noting that it is, in fact, quite possible to have LOF, but not LOS, and that the engine already models this in at least some respects.

Cheers,

YD

Link to comment
Share on other sites

  • Replies 67
  • Created
  • Last Reply

Top Posters In This Topic

At a guess I'd say the LOS calculations are probably done independent of concealment, then the LOF calcs take it into account with a randomiser for accuracy - at least that's one method that *cough* would work.

The HE effect meaning a unit can fire "in the vicinity" is a good question - I don't see any reason other than TacAI why it couldn't happen, I'd be interested to see if it does.

I guess behind both of these questions is; is the TacAI clever enough to take into account the fact it can hurt without direct LOS but with LOF.

Good questions all.

Link to comment
Share on other sites

Heh... C'Rogers hit the nail on the head smile.gif Sure, ricochets, indirect fire, and unexpected (or expected) "pass through" shots are of course simulated in CMx2. But technically there is no LOF involved because the direct line between shooter and target doesn't exist. Something is in the way or the angle required is provided by something else.

But this is just getting beyond what people care about. It is true that in CM:SF you can punch a round through something and hit something on the other side even if you can't see it. Just the other day Charles put an Abrams round through the side of a BTR and KO'd it *and* the BTR that was on the other side. Even he thought that was cool :D

Steve

Link to comment
Share on other sites

Hi Steve,

Maybe the picture below can explain myself a bit more. According to the picture, obviously, Action Spot "A" has LOS with Action Spot "B".Could you tell me, whether or not, the soldiers in the "blue area" of both the Action Spot could spot each other?

Thanks!

popllt

pic:

roasm_cmsf-liu4.JPG

Link to comment
Share on other sites

Oooh, I'll guess: The units are SPOTTED (because Action Spot to Action Spot is clear).

The LOS is BLOCKED (because of the wall, presumably high enough to block each unit).

Because the LOS is BLOCKED, the LOF is also BLOCKED.

Of course, I admit that I'm still fuzzy on when LOS is clear and LOF is not.

Now that my guesses are on record, let's sit back and see what the REAL answers are.

Regards,

Ken

Link to comment
Share on other sites

I think of it like this, there is a 2D array specified that is the map:

A1 B1 C1 D1 E1 F1

A2 B2 C2 D2 E2 F2

A3 B3 C3 D3 E3 F3

A4 B4 C4 D4 E4 F4

A5 B5 C5 D5 E5 F5

A6 B6 C6 D6 E6 F6

A7 B7 C7 D7 E7 F7

A8 B8 C8 D8 E8 F8

A9 B9 C9 D9 E9 F9

Each element in the map array has values assigned to it that specifies what action spots can be seen from that position:

e.g. A1 LOS = B1, C1, D1, E1, F1, A2, B2, C2, D2, E2, F2...etc

Therefore if a unit is in action spot A1, he can theoretically see all the units in the action spots specified in his array.

Therefore the unit in A1 checks it's array and for an occupied action spot. If one is occupied it starts the LOF calulation, which I think are a lot more granular and include spotting rules etc.

So to a great extent the LOS table and underlying "grid" really doesn't matter, it's a shortcut, nothing else.

It's a way to stop each individual unit trying to check every single pixel that doesn't have a unit in; they only check LOF when there's a unit in an action spot it could possibly see.

In popllt's example the LOS array for each point would include the other point, so a unit in each point would check LOF. If they were in the shaded area the LOF code would return "blocked LOF" and so they wouldn't fire on each other.

I reckon.

Link to comment
Share on other sites

Originally posted by Adam1:

Do the finer checks stop the soldiers from *spotting* one another? If they CAN spot one another, even though they don't have "LOF" can they toss grenades? (Will they?)

Why not just test it?

You mean, if a soldier has possible LOS but no LOF, due to concealment?

Still a good question smile.gif

One thing I'd like to see is ballistic weapon LOF modelled, so e.g. mortars or grenades could be called in on a spot with no LOS, but with LOF. But I reckon that'll be WWII before we could see it.

Link to comment
Share on other sites

Please keep in mind what I said on the previous page about the differences between LOS, LOF, and Spotting. When each unit is down to 1 man this means the chance of him spotting a unit, any unit, is very much reduced from when the unit had more men. So in theory the two units may be able to spot each other in Popllt's example, but they will not be able to shoot each other if they are in the shaded blue sections.

As Other Means said, the Action Spot system is there to make sure you can run the game on a regular PC and not need a super computer. LOS checks for spotting are probably the single biggest consumer of CPU cycles of any single function in a game like this. If we could get rid of it we would, but like many other things it just isn't technically possible to do at this point.

We hope that over time we can reduce the Action Map grid size (say, 4x4m) but we have no idea when this will be practical. Each decrease in size means an increase in the overall grid and the fidelity of the checks. A 4x4m grid means a four fold increase in every calculation and resource involved with that grid. Things like LOS, LOF, spotting, TacAI movement, etc. So we'll just have to see.

Steve

Link to comment
Share on other sites

Steve,

So in theory the two units may be able to spot each other in Popllt's example, but they will not be able to shoot each other if they are in the shaded blue sections.

So there are only two kinds of contacts(entirety LOS or no LOS) between two Action Spots, right?

Are there other kinds of contacts between two Action Spots? For example, two Action Spots have partial LOS between each other, etc.

Regard!

popllt

Link to comment
Share on other sites

Originally posted by popllt:

Steve,

</font><blockquote>quote:</font><hr /> So in theory the two units may be able to spot each other in Popllt's example, but they will not be able to shoot each other if they are in the shaded blue sections.

So there are only two kinds of contacts(entirety LOS or no LOS) between two Action Spots, right?

Are there other kinds of contacts between two Action Spots? For example, two Action Spots have partial LOS between each other, etc.

Regard!

popllt </font>

Link to comment
Share on other sites

Popllt,

I am not sure why there is still a misunderstanding, so I will try to clarify this again:

So there are only two kinds of contacts(entirety LOS or no LOS) between two Action Spots, right?
No, there is only one type of LOS... either it is inherently possible for two Action Spots to see each other or it isn't. There can be degrees of LOS quality, depending on what the terrain is like, the number of guys spotting, Morale, etc. but inherently either two Action Spots can see each other or they can not.

Completely separate from this is LOF. LOF is drawn from the specific spot of the shooter to the specific spot of the target. If there is something inbetween them, even if it is within an Action Spot, then LOF will be blocked EVEN IF THERE IS LOS between the two Action Spots.

To use your example (in the screenshot above), it is inherently possible for ANYBODY in Action Spot A to see ANYBODY in Action Spot B, regardless of where they are within the Action Spots. However, anybody in the blue shaded areas will not be able to shoot at anybody in the other Action Spot because the wall is in the way.

Steve

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...