|
-
Oct 4th, 2000, 09:39 PM
#1
Thread Starter
Frenzied Member
I know I will have abosolultly no problem doing this in VB but in VB Script how do I make it so that the left and right key board keys move the character left and right, then food is flying at the character, and it tries to eat the food, and it gets points everytime it eats something.
is this even possible to do in vb script?
thanks in advance
NXSupport - Your one-stop source for computer help
-
Oct 5th, 2000, 12:15 AM
#2
Frenzied Member
Hmmm..... possible maybe, but not exactly easy. Usually this kind of thing is done with a Java Applet. I am pretty sure you can move images around and stuff, but I'm not sure if you can get keypresses like you can in VB.
Harry.
"From one thing, know ten thousand things."
-
Oct 6th, 2000, 05:24 AM
#3
New Member
Use DHTML and VBscript you can no problem.
Look forthe events onKeypress() as it returns a keycode that you can translate for the arrow keys.
to move an image around the screen, use DHTML.
<div id="sprite" style="position:absolute; left:10; top:10;">
<img src="piccy.gif">
</div>
and script like so:
document.all["sprite"].style.pixelLeft = 30;
document.all["sprite"].style.pixelTop = 100;
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
|