i cant work out, how to prevent the charachter from jumping more than the amount of times i want them to.
any advice?
if(jump==1)
{
yvelocity-=15; //or any value you want
jump=0;
}
jump=1;
if(jump>0)
{
yvelocity-=15;
jump--;
}
jump=2; //2 for double jump, 3 for triple jump, etc...
Users browsing this forum: No registered users and 1 guest