SebLague / Solar-System

Simple solar system experiment
https://www.youtube.com/watch?v=7axImc1sxa0
MIT License
1.16k stars 317 forks source link

Mesh disappears when you press play #38

Open Firesceleton33 opened 2 years ago

Firesceleton33 commented 2 years ago

Hi, when I hit play the mesh for the TerainMesh program just disappears, but in the editing mode(When play hasn't been hit) everything looks great. Most of the time in play mode it doesn't display anything. If anyone has an idea please let me know how to fix this, I have tried a lot of things, but I'm new to game development and not too familiar with coding... especially to c#

Screenshot 2022-01-02 224802 Screenshot 2022-01-02 224828

.

Delofon commented 2 years ago

You use this in a new scene with a new game object. The mesh generating is really involved and complicated, I believe each body has a BodyPlaceholder script and then SolarSystemSpawner manager goes through each object and creates mesh for it. Only then you have a usable mesh in the play mode.

r0levrai commented 1 month ago

For those who use the default Planet scene, see #50