Use tags to check which object has been hit instead of null check