Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

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

Merged
1 commit merged into from Oct 8, 2016

Conversation

pacomont
Copy link
Contributor

@pacomont 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
Copy link
Contributor

Areloch commented Sep 21, 2016

Thanks! I'll definitely check on this.

@ghost
Copy link

ghost 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
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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

@ghost ghost added this to the 3.10 milestone Oct 8, 2016
@ghost ghost self-assigned this Oct 8, 2016
@ghost ghost merged commit 98b52d1 into GarageGames:development Oct 8, 2016
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants