PDA

View Full Version : Snowboard - LUA



hankvonhelvete
July 9th, 2006, 08:56
Hey i tryinmg to port my own game i made in shockwave a couple of years ago....

http://www.maclabbet.com/badmongo/game

I have managed to get the player to move.
and a lot of stuffs but i have problems with image collision.

can some one please help me with image collision.
and randomizing the trees and stones.?


here is the game .
http://www.maclabbet.com:16080/badmongo/upload/filer/sdhlua.zip

yaustar
July 9th, 2006, 13:25
Image collision: See several threads down for my box collision snippet.

Random Scenery: Use/Create a random number generator to choose between a tree/rock and place it on the slope (off screen) at a random position.

hankvonhelvete
July 9th, 2006, 21:10
i looked at your box collision snippet.. but to hard to implent in my game... but i managed to fix it anyway.

a bit simpler but its working...

anyway now i have an other question. can you call an php script on an webserver....

like this. http://domain.com/luahighscore.php?name=xxxxxx&score =xxxxx

and can i then read the highscore from a TXT file stored on a webserver?

dalejrrocks
July 10th, 2006, 02:03
i don't think you can do a php script. but take a look at netlib 2.0. it might help. why would you want it on a server? you can make a file that stores it.

yaustar
July 10th, 2006, 15:51
If you want to keep the high score, then there are functions in Luaplayer that can read and write to files on the memory card.

hankvonhelvete
July 10th, 2006, 15:56
ok i eill try to make some kind of highscore. .. but i think it will be cool. to have an higscore for everyone online.