Search Unity

Transforms don't have a C# example

Discussion in 'Documentation' started by Deeeds, Apr 28, 2018.

  1. Deeeds

    Deeeds

    Joined:
    Mar 15, 2018
    Posts:
    739
    https://docs.unity3d.com/ScriptReference/Transform.html

    At a guess: this is the most fundamental and significant part of Unity. And foundational, at its core, so to speak.

    If it's not, it probably is for new users. A welcoming and insightful example would go a long way to helping them see how to access and move things... which (and I'm still guessing) might be imperative to games.
     
  2. NicBischoff

    NicBischoff

    Joined:
    Mar 19, 2014
    Posts:
    131
    I’m not sure you are reading the script reference correctly.
     
  3. Deeeds

    Deeeds

    Joined:
    Mar 15, 2018
    Posts:
    739
    Please, go on...
     
  4. NicBischoff

    NicBischoff

    Joined:
    Mar 19, 2014
    Posts:
    131
  5. Deeeds

    Deeeds

    Joined:
    Mar 15, 2018
    Posts:
    739
    argh, I see the problem. You've missed the part in bold:

    " how to access and move things..."
     
  6. NicBischoff

    NicBischoff

    Joined:
    Mar 19, 2014
    Posts:
    131
    The example on the page outlines this.
     
  7. Deeeds

    Deeeds

    Joined:
    Mar 15, 2018
    Posts:
    739
    No, it outlines accessing the transform of the object 'self'. That's akin to accessing a component, not a thing. Components being parts of things as opposed to things in their own right.

    Within Unity, as I understand it, Transforms, like GameObjects, are unique identifiers of things. Hence the point of the post.

    But also because Transforms can be nested.
     
  8. TJHeuvel-net

    TJHeuvel-net

    Joined:
    Jul 31, 2012
    Posts:
    403
    Transforms are components, like any other. A GameObject is indeed a unique identifier, and a list of Components.

    You can see in the manual that Transform inherits from Component, its nothing special.
     
  9. Deeeds

    Deeeds

    Joined:
    Mar 15, 2018
    Posts:
    739
    Congratulations.

    You win the irrelevant and obtuse commentator of the month award. From me. Pat yourself on the back.