|
| 12 Sep 2016 04:34 PM |
I need this line of code:
BodyVelocity.Velocity = (torso.Poisition - mouse.Hit.p)
to depend on the Mouse's location on screen instead of the 3D space. This is to avoid the torso from going backwards (while pointing on something high on the y axis) when the mouse is on the upper side of the screen.
How can I achieve that? Thanks.
|
|
|
| Report Abuse |
|
|
| |
|
vivivio
|
  |
| Joined: 23 Jan 2012 |
| Total Posts: 707 |
|
| |
|
Egzekiel
|
  |
| Joined: 10 Jan 2011 |
| Total Posts: 1079 |
|
|
| 12 Sep 2016 05:19 PM |
int X [readonly] The X component of the position of the Mouse. This is the position of the Mouse on the screen.
int Y [readonly] The Y component of the position of the Mouse. This is the position of the Mouse on the screen.
|
|
|
| Report Abuse |
|
|
GGGGG14
|
  |
| Joined: 29 Jan 2012 |
| Total Posts: 25344 |
|
|
| 12 Sep 2016 06:22 PM |
| Mouse.X, Mouse.Y & WorldToScreenPoint might be some helpful tips... there's also ScreenToWorldPoint I believe. |
|
|
| Report Abuse |
|
|