Jump to content

Recommended Posts

Hey all,

 

I have been messing around with lineIntersectsSurfaces command in order to check for visibility between two units. I can't really say I had problems making it work, but even after having a look at both LOD's and command's Wikis I can't really say I have understood what LODs are exactly and how they can be utilized in various different scenarios.

 

For example, what will the difference be if I call lineIntersectsSurfaces with "VIEW" and "FIRE" (which are the default) as LOD1 and LOD2 respectively or with "GEOM" and "VIEW" for LODs?

 

I understand that this may (or may not) be quite a long subject to cover in just a forum post, so any additional information is most welcome (whether a link to a text, a short or long explanation, etc.).

 

Best to all and thanks in advance,

 

Achilles.

Share this post


Link to post
Share on other sites

You have to search for some simple requests like: Arma LOD on google

then you will have some good pages like this one.

If you need some help for your script, just send the code you're trying to make it work.

 

  • Like 1
  • Thanks 1

Share this post


Link to post
Share on other sites

Thanks for the answer pierremgi. Actually as I said, what I am trying to do works as intended (so far), but I am trying to understand how LODs can affect the lineIntersectsSurfaces. I (believe I) understand the basic concept of LOD but I am not sure I understand the functionality of lineIntersectsSurfaces in respect to the LODs.

 

Any insight would be most welcome. I can also quote the code, but it's really nothing weird. It's plain use of the lineInteserctsSurfaces which, as I said, works just fine, but after some "tests" playing with different choices for the LODs parameters, I didn't manage to see any difference. Thus, I don't really know if the script will fail at some specific moment/case.

 

Nevertheless, thanks for the help.

Share this post


Link to post
Share on other sites

You should use a specially designed checkVisibility for that, which is also affected by smoke 

  • Thanks 1

Share this post


Link to post
Share on other sites

Thanks killzone_kid, what you say sounds about right. I haven't realized there's such a command. Thanks for pointing to the right direction.

 

One more question though, if any of you could lend a hand. In checkVisibility's documentation says that the result can be affected by getTerrainGrid, but does not specify in what way that happens. Do you guys have any idea about it?

 

Once more, thank you all for the help.

Share this post


Link to post
Share on other sites

After reading setTerrainGrid I guess that terrain will obstruct an object/unit on it's Level Of Detail (LOD).

Which could mean that a distant unit which hides behind a terrain vertex which is degraded by view distance could be visible even if it is hidden on a close distance with a high LOD.

 

Just my thoughts on it...

  • Like 2
  • Thanks 1

Share this post


Link to post
Share on other sites

Thanks for your insight sarogahtyp.

 

I kinda thought of it the same way, but I was unable to find a rigorous and consistent way to either test it or draw any conclusions based on the available literature online. Unfortunately at the moment I cannot test, so I won't be able to return any test results. I will make sure to update as soon as possible though.

 

Once more, thanks for your addition.

 

P.S.: Do you think this could happen the other way around? I mean, the unit will be hidden by distant terrain instead of being visible (something like glitching inside the terrain in low LOD)?

Share this post


Link to post
Share on other sites

yes this could be the case if an unit is located on the lowest point of a trough or valley and the vertex below the unit gets degraded.

May not happen in such a simple scenario but a little trough on the hillside of a valley could get degraded completely...

  • Like 1
  • Thanks 1

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

×