Page 1 of 1

Some Code!

PostPosted: Tue Sep 17, 2013 9:34 pm
by MINEfan136
For moving and Gravity.If you can, post some more code

Well here it is :P

Code: Select all
//Movement
x = x + 5;
x = x - 5;
//Gravity
yvelocity = -8;
yvelocity = yvelocity + .5;
//Score/Text
(charname).textNumber = (charname).textNumber + 1;
(charname).textNumber = (charname).textNumber - 1;

Re: Some Code!

PostPosted: Wed Sep 18, 2013 6:30 am
by JaroodaGames
These are some of the first things a new GE user learns.
But, you asked for more code, so I'll deliver.
---------
Jumping:
Player -> Key Down -> (the key you want to use to jump with), no repeating.
Code: Select all
if(jump==1)
{
    yvelocity-=8; //Or something
    jump=0;
}

Player -> Collision with platform -> Top only
Code: Select all
jump=1;

Player -> Collision finish -> Platform actor
Code: Select all
jump=0;

Re: Some Code!

PostPosted: Sat Sep 21, 2013 1:48 am
by MINEfan136
kk thx for the code! I am a Beginner in this GE thing. Still learning! anyway, here is a point for your code :D