Documentation

Unity Engine


User Manual

Script Reference

Unity Engine


SetVector2

Use this method to set the value of a Vector2 with the name you pass in.
Read time 1 minuteLast updated 5 days ago

Definition

SetVector2(int, Vector2)

Use this method to set the value of a Vector2 with the name you pass in.
public void SetVector2(int nameID, Vector2 v)

Parameters

nameID

The ID of the property. This is the same ID that Shader.PropertyToID returns.

The new Vector2 value.

SetVector2(string, Vector2)

Use this method to set the value of a Vector2 with the name you pass in.
public void SetVector2(string name, Vector2 v)

Parameters

name

The name of the property.

The new Vector2 value.