# Vector3 assignment query..

**URL:** <https://discussions.unity.com/t/vector3-assignment-query/439917>\
**Category:** Scripting\
**Tags:** Scripting\
**Created:** [March 19, 2011, 3:50pm UTC](https://discussions.unity.com/t/vector3-assignment-query/439917 "2011-03-19T15:50:30Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![AntLewis](https://dub1.discourse-cdn.com/unity/user_avatar/discussions.unity.com/antlewis/32/899957_2.png) [@AntLewis](https://discussions.unity.com/u/AntLewis)\
**Post date:** [March 19, 2011, 3:50pm UTC](https://discussions.unity.com/t/vector3-assignment-query/439917/1 "2011-03-19T15:50:30Z")

</div>

Hi, can anyone advise me why I can’t do this:

```auto
inputThreshold = Vector3(0.0f,0.0f,0.0f);

```

…as it complains that “UnityEngine.Vector3 is a ‘type’ but is used like a variable”. But strangely I can do this:

```auto
inputThreshold = Vector3.zero;

```

…firstly dont understand why the first code snippet wouldnt work, but also then dont understand why the second would - I thought the second was shorthand for the first!?

Thanks!

---

<div class="post-metadata">

**Author:** ![Dreamora](https://dub1.discourse-cdn.com/unity/user_avatar/discussions.unity.com/dreamora/32/91058_2.png) [@Dreamora](https://discussions.unity.com/u/Dreamora)\
**Post date:** [March 19, 2011, 3:51pm UTC](https://discussions.unity.com/t/vector3-assignment-query/439917/2 "2011-03-19T15:51:04Z")

</div>

its new Vector3(…) as with every other object creation in C#

and Vector3.zero is just a variable that leads to a precreated vector3

---

<div class="post-metadata">

**Author:** ![AntLewis](https://dub1.discourse-cdn.com/unity/user_avatar/discussions.unity.com/antlewis/32/899957_2.png) [@AntLewis](https://discussions.unity.com/u/AntLewis)\
**Post date:** [March 19, 2011, 3:54pm UTC](https://discussions.unity.com/t/vector3-assignment-query/439917/3 "2011-03-19T15:54:10Z")

</div>

ah…of course - thanks (hits head against table)
