万年素人からHackerへの道

万年素人がHackerになれるまで殴り書きするぜ。

  • ・資産運用おすすめ
    10万円は1000円くらい利益
    資産運用ブログ アセマネ
    • ・寄付お願いします
      YENTEN:YYzNPzdsZWqr5THWAdMrKDj7GT8ietDc2W
      BitZenny:ZfpUbVya8MWQkjjGJMjA7P9pPkqaLnwPWH
      c0ban:8KG95GXdEquNpPW8xJAJf7nn5kbimQ5wj1
      Skycoin:KMqcn7x8REwwzMHPi9fV9fbNwdofYAWKRo

    Transform Unity

    C#でエラーになる理由。

    transform.localPosition.x = 1.0f;
    

    はエラーになる、
    このlocalPositionの部分がVector3なので、

    URL: http://docs.unity3d.com/ScriptReference/Vector3.html

    This structure is used throughout Unity to pass 3D positions and directions around. It also contains functions for doing common vector operations.

    にあるように、

    ・参照型のクラスではない
    ・構造体の値型である