C# scripting question

So I have a cs script that I’m having a tad bit of difficulty with.
I’m attaching something to my avatars hand. Code that works is:

attachment.transform.parent = requiredAttachmentPoint; 
attachment.transform.localRotation = Quaternion.identity; 
attachment.transform.localPosition = new Vector3(0,0,0);

The thing is that I don’t want it to be (0,0,0). I want it to be (-.1, -.05, -.1).
Problem is I get the following error:
“The best overloaded method match for `UnityEngine.Vector3.Vector3(float, float, float)’ has some invalid arguments”

How can I do this?

Thanks!

Try doing it like this:

attachment.transform.localPosition = new Vector3(-.1f, -.05f, -.1f);

Notice the “f” after each number to signify a float.

You just need to put "f"s in your numbers to indicate that they’re floats.

so:

attachment.transform.localPosition = new Vector3(-0.1f, -0.05f, -0.1f);