Показать сообщение отдельно
Старый 30.06.2012, 14:40   #1
Okay
Знающий
 
Регистрация: 21.11.2011
Сообщений: 284
Написано 17 полезных сообщений
(для 74 пользователей)
Гравитация в 2D

Вот сам прыжок
If KeyHit(82) Then

    nplayer1
\vely = 100
    nplayer1
\jumping = True
    
EndIf  



If 
nplayer1\jumping = True

    
If nplayer1\vely > -100   
             nplayer1
\vely = nplayer1\vely - nplayer1\accel
             nplayer1
\cory = nplayer1\cory - nplayer1\vely
    
EndIf

EndIf 
Выставление значений
nplayer1\vely = 0
nplayer1
\accel = 10
nplayer1
\jumping = False 
(Offline)
 
Ответить с цитированием