I have a lot of colliders in my game. And they all move. The main object (the player) is a Rigid Body with isKinematic checked. None of the other objects have a Rigid Body, just a collider (atm a Mesh collider but I’m considering punting and using basics).
Everything is a Trigger.
ALL GameObjects that are colliders (excluding the player) are contained in another empty GameObject so I can transform their locations based on a grid system. Meaning, I do not manually move each Collider itself, I just move its empty parent GameObject.
And due to me moving everything, I do not use any physics in my game.
I have read many conflicting sources that say either:
- Many RigidBody’s produce heavy
- Many moving objects with collision
should have a RigidBody with
I am currently having iOS performance issues and I need to see if I can squeeze as much out of my code as possible.
- Can I turn off Physics completely?
Or at least enough such that only
Trigger collision detection is
- Should I keep all collider’s as basic colliders or
should I put RigidBody’s on them
with isKinematic enabled?
- All colliders fall within 1 of 8 or so basic mesh’s (think circle, oval, triangle, hexagon, 4-point star etc) with as few triangles as possible. I currently have “mesh collider” on each of them so that that specific shape is used for collision. Since I have as few triangles as possible, is this ok? Or should I actually just punt and use one of the 3 built-in primitive colliders (Box, Sphere or Capsule)?
Thanks so much!