- Home /
Extreme Lag
Ok, so I design a little level with SketchUp for my game. I put the 3d model in the game and place my First Person Controller inside. When I run the game I get EXTREME amounts of lag while i'm in side my level. But, When I fall out of it; It does not lag anymore. Pleas Help!
Answer by MakeCodeNow · Mar 09, 2014 at 04:29 AM
When you import from sketchup, it probably makes a gigantic mesh with tons of polygons. Unity has no choice but to always render the entire mesh, which is probably too much for your computer. If you are having Unity generate collision for you, then it could also be that physics is slow. It gets faster when you fall out of world because it can cull away that gigantic mesh.
The solution is to break your scene up into multiple meshes, or export to a format (like fbx) that preserves individual Sketchup objects.
I do export it as an FBX model, But I still get $$anonymous$$AJOR lag.
Answer by fifthknotch · Mar 09, 2014 at 04:52 AM
Your problem is as @MakeCodeNow states, but there is more than likely a second issue that is causing your FPS to drop. Sketchup does not export one-sided face by default. Because of this, your model has TWICE the amount of vertices. You can change this in the export settings (I have built models for my games using Sketchup and know my way around it if you need additional help).
When I uncheck the "Two Sided Faces" box and export it. $$anonymous$$y model loads with transparent walls and ceiling, I still get lag too!
Transparent walls and ceilings are caused by incorrectly facing normals, you can notice this with differently coloured faces inside of Sketchup, all the faces should be white, not grey, if they are grey the normal is incorrect and it will render the other side. To fix it, right click the gray faces and choose " Reverse Face " to flip it around.
@Bunnybomb7670 is correct. $$anonymous$$ake sure your faces are facing the correct directions. Also if this didn't solve your problem, there could be many issues. If you have an older computer, it can't render as much within slowing FPS down to noticeable amounts. If you use a lot of GUI elements in your scene, this can effect performance. If your model is HUGE, try @$$anonymous$$akeCodeNow 's suggestion. Hope this helps!
Answer by J-F · Mar 09, 2014 at 04:38 PM
The problem with google sketchup is that it's not really meant for game modelling.
Sketchup automatically creates 2 faces for a single surface, which is unnecessary in games.
Maybe you should try other modelling programs or checking the sketchup warehouse for some polygon tools for creating more low poly meshes.
I recommend Blender as a free alternative which is much better than Sketchup and you can do much more in that program too.
I tried blender and I found SketchUp WAY easier. Btw I'm a noob.
Yeah but, the 3D warehouse is BAD if you want to release you're game and sell it because they are copyrighted pieces of work created by other people.
SketchUp is easier to pick up for beginners. I started with SketchUp (and still use it for buildings and such because of the precision it gives you), but you will find that it is lacking in features necessary for game dev. One big feature missing is UV mapping. SketchUp has no support there. Blender, on the other hand, was built for this kind of thing (game dev) and is a great alternative if you are willing to learn a new method of modeling.
Your answer
Follow this Question
Related Questions
health using time (playerprefs) 0 Answers
How to add multiple levels? 3 Answers
Dose anyone have experience with TDTK and MAD Level manager 0 Answers
Scaling models in Unity - Bad practice? 1 Answer
3D Model is Translucent 2 Answers