Quantcast
Channel: Unity Forum
Viewing all articles
Browse latest Browse all 1466670

if statements not executing even condition is true! help please.

$
0
0
my if condition is-
if ((mouseX >= width - 10)) {
rigidbody.velocity = transform.forward * speed;
}


View attachment 125355

the condition is true as shown in the screenshot.
but my body doesn't move. (the move function is correct as i can move it by key press but it doesn't move by this statement)

Viewing all articles
Browse latest Browse all 1466670

Trending Articles



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