|
-
May 16th, 2000, 06:08 AM
#1
hello,
i am currently working on a mario like game, and i was wondering how to get a jump thing. where you can jump a certain height from your starting position, but you fall back down after.
also, if anyone can help me with scenario scrolling, i would be gratefull. thanks
-thanks
-t_dawolf
-
May 16th, 2000, 06:33 AM
#2
Put the following code into a module. To use it, place an Image or Picture on Form1 and also place a CommandButton. In the CommandButton's Click() event place the code Jump(Form1.Image1)
Code:
Function Jump(VarVal As Control)
tmpTop = VarVal.Top
PauseTime = 0.2
Start = Timer
Do While Timer < Start + PauseTime
VarVal.Top = VarVal.Top - 1
Loop
Finish = Timer
Pausetimer = 0.2
Start = Timer
Do While Timer < Start + PauseTime
VarVal.Top = VarVal.Top + 1
Loop
Finish = Timer
Pausetimer = 0.1
Start = Timer
Do While Timer < Start + PauseTime
VarVal.Top = tmpTop
Loop
Finish = Timer
End Function
-
May 16th, 2000, 10:58 AM
#3
PowerPoster
See my website for a scrolling demo... also you'll find BitBlt and animation demos
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|