github page which has code to give your procedurally generated mesh collision.
I have no idea what to do or where to start. I’ve already made a .cpp and .h file which are customMesh classes called
GenertatedMeshComponent
My project is called
TriKakei
when I try to copy the respective .cpp and .h files found on the github page, into my .h and .cpp files I get tons of errors. What am I suppose to rename/ include/replace etc.?
Please forgive my lack of knowledge, I have absolutely no knowledge of C++ coding with UE4.
EDIT WITH MORE INFORMATION:
I know the basics of coding, not much about C++, since blueprints have been doing it for me fine until now.
The github link has both the .proceduralmeshcomponent.cpp and .proceduralmeshcomponent.h.
If you click ‘view’ in the top right of each you get to these two pages:
(That’s the .h and .cpp I’m directly copying)
After doing Test>Debug>All tests I get a these errors:
Maybe I’m suppose to rename some stuff and delete it? Not sure…
First of all you can forget about the Error List tab it is used by intel sense which is completely messed up thanks fully to the precompiler headers. =(
Go look at the Output tab if you need errors and warning messages.
You only need these files:
ProceduralMeshComponent.h
ProceduralMeshComponent.cpp
Secondly:
Replace all occurrence of
#include "ProceduralMesh.h"
to
#include "TriKakei.h"
Also find your TriKakei.Build.cs file and make sure it looks like something this:
using UnrealBuildTool;
public class TriKakei : ModuleRules
{
public TriKakei(TargetInfo Target)
{
PublicDependencyModuleNames.AddRange(new string[] { "Core", "CoreUObject", "Engine", "InputCore" });
PublicDependencyModuleNames.AddRange(new string[] { "RHI", "RenderCore", "ShaderCore" });
PrivateDependencyModuleNames.AddRange(new string[] { });
}
}
I think that’s all. Now you should be able to compile your code without errors
If not, let me know i update my post.
Proceduralmesh.h
At least when I ctrl + f I don’t find any. I have multiple
ProceduralMeshComponent
And other functions involving ProceduralMesh such as
ClearProceduralMeshTriangles(); OR SetProceduralMeshTeriangle($SomeArgs)
Basic blueprints are created from the C++ Procedural Actor classes. This help demonstrating how they can be spawned manually in the level at construction time
Also, when I type in ‘generatedMesh’ which is the class name, nothing appears :\