exit construction when mesh variable is empty

If the static meshes are in an array you can just loop through it and do a isValid test on the iterated mesh. If an element fails break the loop.