A
A
Andrey Titov2017-04-19 21:09:08
C++ / C#
Andrey Titov, 2017-04-19 21:09:08

What is the bug in Unity3d?

When running a project using - SRTS Pack - https://www.assetstore.unity3d.com/en/#!/content/21370 - in Unity 5.6 an error appears:

Assets/Other packs/RTS Pack/Standard Assets/Scripts/Utility Scripts/MeshCombineUtility.cs(27,39):
error CS1061: Type `UnityEngine.Mesh' does not contain a definition for `GetTriangleStrip' and
no extension method `GetTriangleStrip' of type `UnityEngine.Mesh' could be found.
Are you missing an assembly reference?

The line itself:
int curStripCount = combine.mesh.GetTriangleStrip(combine.subMeshIndex).Length;

What to correct in the code?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
Denis Gaydak, 2017-04-19
@titov_andrei

MeshCombineUtility is an old old script.
there it has a checkmark/setting associated with TriangleStrip - this gluing option is irrelevant and pointless)
and so all this (the code that is executed with this flag) can be safely removed from the script and used as if this flag is not inserted. and you will be happy.
And in general, if you do not need to glue the models on the runtime, you can generally remove the entire script and its dependencies.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question