unity editor UIElements disable button code example Example: unity rigidbody2d disable //you can't :( //you can delete it with Destroy(RigidBody2D);