unity test object exist code example
Example 1: unity if gameobject exists
if (GameObject.Find("WhateverItsCalled") != null){ //it exists}
Example 2: Unity if object doens't exist
if(!Object) //If GameObject doesn't exist (! == not)
{
//Do Something
}