using angle?

Game Editor comments and discussion.

using angle?

Postby jagheera nex » Sat Sep 08, 2007 8:44 pm

hey, i downlaoded game editor like 6 months ago and when i did i knew nothig about game making, or scripts, ive learned a lot from the forums and i was wondering how to use the angle variable.
User avatar
jagheera nex
 
Posts: 46
Joined: Sat Jul 28, 2007 4:13 pm
Location: dik
Score: 1 Give a positive score

Re: using angle?

Postby Troodon » Sun Sep 09, 2007 5:47 pm

Angle is the direction of movement.
Quoted from http://www.game-editor.com/tutorials

Code: Select all
angle = direction(xscreen, yscreen, xmouse, ymouse);
directional_velocity = 20;


This makes the actor follow mouse.

Quoting again from the page:
Image
As the coordinates xmouse and ymouse are given related to the screen, we have to use xscreen and yscreen; these are the coordinates of the actor related to the screen.


What would you like to do with the angle variable?
I can't die, I already tried
~on the forums since GE 1.3.3~
User avatar
Troodon
 
Posts: 1539
Joined: Thu Jan 12, 2006 3:29 pm
Location: HELL
Score: 56 Give a positive score

Re: using angle?

Postby jagheera nex » Sun Sep 09, 2007 6:22 pm

idk i just wanted to know, thanks 4 the code :D
User avatar
jagheera nex
 
Posts: 46
Joined: Sat Jul 28, 2007 4:13 pm
Location: dik
Score: 1 Give a positive score


Return to GE - General

Who is online

Users browsing this forum: No registered users and 1 guest

cron