My racing game runs at 69/70 fps when shadows are turned off, but when turned on the stats shows that there are over 600 shadowcasters in the scene(mostly all of them in my car object) and the framerate drops from 70 to 35-42.
The car mesh has lots of child game objects/child meshes. I guess this is the reason why there are tons of shadow casters. So I guess I should combine the car object(ideally to one single mesh). However using the CombineChildren script makes one mesh per material and does’nt seem to affect this at all…
Thanks in advance
i would try another approach, instead of combine meshes,
create dummy mesh in shape of the car bottom side and make it the only shadow caster.
make sure that the rest of the car don’t receive\cast shadows so the shadows from that dummy mesh will fall on the track and not the car it self.
hide the dummy inside the car, close to track.
if this for a mobile this should do the job…
and if using real time shadows is still heavy for your game there several solutions for faking shadows. i’m using one of these and it real performance booster.
Okay, so I was able to get the bumber of shadow casters down to 143(now with a FPS of 100(!)) by joining the mesh in Blender.