Procedural Mesh Generation Question

Hi,

I followed the wiki page for ‘Procedural Mesh Generation’ and I can get it rendering via a blueprint and a spawn actor in the editor, however is there any wiki pages or tutorials that will show me how I can spawn these procedural meshes in code? As in, make the spawn actor / mesh on the fly in code and add it to the scene? I ask as I am generating terrain tiles myself and I want to make these into meshes at run time (they change depending on how far away the camera is etc).

Secondly, is there a any links related to the concept of a ‘game loop’, or some kind of callback so I can write game logic, send updates a 3rd party lib etc?

Any help would be much appreciated.
Thanks.

For game loop create AActor inherited class using your 3rd party lib and override AActor’s Tick() function to execute your code every frame and put this object to your persistent level.
I did that to implement Photon Network lib functions in my project.



		FActorSpawnParameters sp;
		sp.Name = designName;
		sp.bNoCollisionFail = true;
		CurrentShipDesign = GetWorld()->SpawnActor<AGameShipActor>(sp);