Spidy wrote:yeh bee-ant is great he will help ya
you'll be great too...just need more time...
Oops, I know you mean on second question...maybe like this:
"If I press RightArrow the effect is move right, but if I press RightArrow+UpArrow the effect is Jump to right(diagonally). If I press LeftArrow the effect is move left, but if I press LeftArrow+UpArrow the effect is Jump to left(diagonally), with removing the move effect"..isn't it???
OK...
First, make some variables (the name is up to you) :
1. canjump (integer, actor variable))
2. moveright (integer, actor variable)
3. moveleft (integer, actor variable)
On Collision of top side of Platform(ground), put this code :
- Code: Select all
canjump=1;
On CollisionFinish of Platform, put this code :
- Code: Select all
canjump=0;
On Keydown of LeftArrow, put this code :
- Code: Select all
if(canjump==1)
{
x=x-3;
ChangeAnimation("EventActor", "WalkLeft", FORWARD);
}
moveleft=1;
On Keydown of RightArrow, put this code :
- Code: Select all
if(canjump==1)
{
x=x+3;
ChangeAnimation("EventActor", "WalkRight", FORWARD);
}
moveright=1;
On Keydown of UpArrow, put this code :
- Code: Select all
if(moveleft==1)
{
if(canjump==1)
{
yvelocity=yvelocity-10;
xvelocity=xvelocity-5;
ChangeAnimation("EventActor", "JumpLeft", FORWARD);
canjump=0;
}
}
if(moveright==1)
{
if(canjump==1)
{
yvelocity=yvelocity-10;
xvelocity=xvelocity+5;
ChangeAnimation("EventActor", "JumpRight", FORWARD);
canjump=0;
}
}
On KeyUp of LeftArrow
- Code: Select all
moveleft=0;
On KeyUp of RightArrow
- Code: Select all
moveright=0;
Ummm...I hope will help...
Thanks,