Question by
aaronheth · Feb 12, 2016 at 01:43 PM ·
scripting beginnereasythis
Does "this." inherit all properties that "gameObject" would?
I understand that "this" is referencing the script and "gameObject" references the object the script is attached too. I also know that this.transform.position and gameObject.transform.position both accomplish changing the position of the gameObject. Is that true for all properties of the gameObject? Will referencing this instead accomplish the same thing? Is it better to just always use gameObject instead of "this." for clarity?
Comment