Page 1 of 1

how do i make a bullet move towards the mouse

PostPosted: Sun Jul 10, 2011 10:24 pm
by master0500
how do i make a bullet move towards the mouse

Re: how do i make a bullet move towards the mouse

PostPosted: Sun Jul 10, 2011 11:21 pm
by skydereign
Do you mean homing towards the mouse? Or it will move in the direction the mouse was in? I assume the latter, and to do that, do this.
bullet -> Create Actor -> Script Editor
Code: Select all
directional_velocity=10;
angle=direction(xscreen, yscreen, xmouse, ymouse);