Quantcast
Channel: Questions in topic: "error"
Viewing all articles
Browse latest Browse all 7934

Making a 2D Game, Flipping Textures ERROR

$
0
0
var X : float; function Start () {
//Gathering normal object scale x
X = transform.localScale.x;
} X = transform.localScale.x; } function Update () {
if(Input.GetKey(“a”)){ //Gamer pushes a key
//Set texture to normal position.
transform.localScale.x = X;
}else if(Input.GetKey(“d”)){ //Push d
//Flip the texture
transform.localScale.x = -X;
} if(Input.GetKey("a")) { transform.localScale.x = -X; }else if(Input.GetKey("d")){transform.localScale.x = X; } } So I have that. And I am getting this error: Assets/Scripts/TextureFlip.js(6,20): BCE0044: unexpected char: 0x2028. I have no idea what this means; I cant find those numbers anywhere. Please help me!

Viewing all articles
Browse latest Browse all 7934

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>