rotation?

Questions, comments and discussion about the Game Editor development.

rotation?

Postby travisabyss » Wed Oct 14, 2009 8:19 pm

is there any way with game editor ot make an actor rotate?
travisabyss
 
Posts: 6
Joined: Sat Jan 31, 2009 6:46 am
Score: 0 Give a positive score

Re: rotation?

Postby krenisis » Fri Nov 06, 2009 9:44 pm

yes ok using ur paint program draw ur actor as if he is rotating frame by frame...insert ur actor and make sure u have the right amount of horozontal and verticule frames
Tutorial Database for all beginners click this link
viewtopic.php?f=4&t=8680
krenisis
 
Posts: 606
Joined: Sat Jul 25, 2009 3:27 pm
Score: 51 Give a positive score

Re: rotation?

Postby Fojam » Sun Nov 08, 2009 8:22 pm

double newangle = (animpos/nframes)*360;
vectoradd(&angle, &directional_velocity, newangle, 0.5001);
1.) put this in ^ after you make an animated gif of the object turning 360 to the left starting from it facing to the right.
(sorry, I can't remember what event you put it in... I think someone else can help you there, though)I think that it is a script editor in the left and right arrow key events, but I am not sure. it might also be in draw actor... tell me which one works.

2.) do key down: left arrow key>change animation to object turning left direction: no change and have repeat enable and immediate action.

3.) then do key up: left arrow key> change animation direction to stopped, immediate action

4.) do a key down: right arrow key>change animation direction to backwards and do immediate action

5.) then do key up: right arrow key> change animation direction to stopped, immediate action

Moving forwards and backwards

1.) Make a key down: up arrow key> In script editor, write:
directional_velocity = directional_velocity + whatever speed you want it to go forwards;

2.) Make a key up: up arrow key> in script editor, write:
directional velocity = 0;

3.) Make a key down: down arrow key> in script editor, write:
directional_velocity = directional_velocity - Whatever speed you want it to go backwards;

4.) Make a key up: down arrow key> in script editor write:
directional_velocity = 0;


you should be able to do it if you follow these instructions exactly.
if you have any problems, tell me.

There are a couple of sprite rotation programs out there. One of them is rotsprite, which is made with game editor.
I am not sure where to download it, but i think that it is somewhere out on the forums.


Good Luck with your game!


Edit: I found the link on the forums: viewtopic.php?f=8&t=6218
CLICK TO GIVE ME POINTS

My Latest Projects:
Super Smash Bros: viewtopic.php?f=6&t=12307 PLEASE help by making sprites!
User avatar
Fojam
 
Posts: 513
Joined: Thu Mar 19, 2009 10:02 pm
Location: under your bed!!!
Score: 69 Give a positive score


Return to General

Who is online

Users browsing this forum: No registered users and 1 guest

cron