Jump to content

ME 2.7 - Quad Zones written to mission correctly only after ALL vertices have been modified at least once


Recommended Posts

Posted

After some work with the new quad zones, I've discovered that the vertex points that define the quad are only written correctly after you edit every single point. If you don't, any vertex point you did not edit contains a random (well, specific but wrong, i.e. outside the zone) point

 

here's the vertex data of a freshly placed quad, the quad shows as a square on the map 

 

                ["verticies"] = 
                {
                    [1] = 
                    {
                        ["y"] = 631717.17725421,
                        ["x"] = -299709.38098138,
                    }, -- end of [1]
                    [2] = 
                    {
                        ["y"] = 637717.17725421,
                        ["x"] = -299709.38098138,
                    }, -- end of [2]
                    [3] = 
                    {
                        ["y"] = 637717.17725421,
                        ["x"] = -293709.38098138,
                    }, -- end of [3]
                    [4] = 
                    {
                        ["y"] = 631717.17725421,
                        ["x"] = -293709.38098138,
                    }, -- end of [4]
                }, -- end of ["verticies"]
            }, -- end of [6]

 

Note

  1. all vertices have the same value for x and y
  2. (x,y) is not inside the quad

 

Due to the vertex points inside the data, it's effectively empty. It seems that ME can detect this issue and during an Editor Session internally replaces that point with a point that would be displayed in the default square

 

Now I proceeded to edit vertex 3 only, and saved the mission

                ["verticies"] = 
                {
                    [1] = 
                    {
                        ["y"] = 631717.17725421,
                        ["x"] = -299709.38098138,
                    }, -- end of [1]
                    [2] = 
                    {
                        ["y"] = 637717.17725421,
                        ["x"] = -299709.38098138,
                    }, -- end of [2]
                    [3] = 
                    {
                        ["y"] = 636363.76477456,
                        ["x"] = -294394.76398402,
                    }, -- end of [3]
                    [4] = 
                    {
                        ["y"] = 631717.17725421,
                        ["x"] = -293709.38098138,
                    }, -- end of [4]
                }, -- end of ["verticies"]
            }, -- end of [6]

 

Note that only point 3 has been correctly placed, all other points are still uninitialized. 

 

What this probably means (until confirmed by ED)

If you read this data from mission or env, your quad zones will not work correctly until you have touched all vertex points in editor at least once. I do not know if/how this affects the ME's own unitInZone condition.

 

 

Posted (edited)

Apologies, I'm an idiot. Obviously, the vertex data was updated for more than one vertex after editing a vertex

 

It was a looong night.

 

The issue seems to be still that you need to edit at least one vertex.

 

Edited by cfrag
Posted

Further analysis indicates that this happens when you copy and paste a quad region. Moving the region by dragging it will cause an update off vertext points.

 

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...