Fixes AbstractPolyList::addBox(). Complete each face with missing 2nd triangle. #1782

Merged
merged 1 commit into from Oct 8, 2016

Conversation

Projects
None yet
3 participants
@pacomont
Contributor

pacomont commented Sep 21, 2016

Hi all,

This is a minefield, which is a class inherited from Trigger.
image

Ok, and because Military intelligence should work, enemies (Tanks) must avoid go across it, because it's his own minefield! Then I added the minefield to NavMesh. Then I realized that I had to add a buildPolyList function to my class, which uses AbstractPolyList::addBox().

And as you can see, the edges of the box is not completely etched from the NavMesh.
Looking at AbstractPolyList::addBox() I saw that only add one triangle per face, so I fix it and that the result:

image

With this PR it's added the second triangle to the face, but I can't say If this was originally made by design, or if breaks something else...

@Areloch Areloch added the Bugfix label Sep 21, 2016

@Areloch

This comment has been minimized.

Show comment
Hide comment
@Areloch

Areloch Sep 21, 2016

Contributor

Thanks! I'll definitely check on this.

Contributor

Areloch commented Sep 21, 2016

Thanks! I'll definitely check on this.

@Lopuska

This comment has been minimized.

Show comment
Hide comment
@Lopuska

Lopuska Oct 8, 2016

Member

Yes, this is probably an issue introduced during DX11 port because we had to remove fan topology from the renderer.

Member

Lopuska commented Oct 8, 2016

Yes, this is probably an issue introduced during DX11 port because we had to remove fan topology from the renderer.

plane(v1, v2, v3);
end();
+ // Second triangle

This comment has been minimized.

@Lopuska

Lopuska Oct 8, 2016

Member

We could also use 4 vertices strip, but anyway nothing really change in practice.
Thank you @pacomont !

@Lopuska

Lopuska Oct 8, 2016

Member

We could also use 4 vertices strip, but anyway nothing really change in practice.
Thank you @pacomont !

@Lopuska Lopuska added this to the 3.10 milestone Oct 8, 2016

@Lopuska Lopuska self-assigned this Oct 8, 2016

@Lopuska Lopuska merged commit 98b52d1 into GarageGames:development Oct 8, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment