Zitat:
Zitat von emericaska8r
1. you dont need the "0" in the parenthesis. just put:
2. put this:Code:damage = math.random(6)
at the VERY top of you code. it will give you different numbers now.Code:math.randomseed(os.time())
Printable View
Zitat:
Zitat von emericaska8r
1. you dont need the "0" in the parenthesis. just put:
2. put this:Code:damage = math.random(6)
at the VERY top of you code. it will give you different numbers now.Code:math.randomseed(os.time())
I had the same exact problem, emericaska8r.
Doing what Grimfate126 said (put: -math.randomseed(os:time() )- ) will fix that. I still dont know how it works though...but it does.
Yes im serious. Maybe your file was too big. Like I said, mine was pretty small. Its because its just repeating itself. So yeah i could just make it blit tiles, but when i started, this was the easiest and I just kept using it. But it is possible, my first release of REDaLUA can proof it.Zitat:
Zitat von Grimfate126
Does anyone know of any strategy (doesnt necessarily have to be Advance Wars.) game? I something to give me a nudge forward in the game I'm making.
THat worked;, thanks GrimFate.
think about it... a tree grows from a seed no? So your random numbers shall grow from a seed too... If you dont put a puesdo seed in there then youll keep getting the same numbers since the seed is the same... but with this, your setting the seed to be the PSPs internal time/clock which is always changing, thus giving you a random number.Zitat:
Zitat von EminentJonFrost
oohhh.Zitat:
Zitat von SG57
now I feel stupid. lol
thanks for the good explanation, SG57.
can someone PLEASE comipile a luaplayer script for me?? for some reason, it only works on luaplayer .17 dk2. PM me if you want to try compiling it. i cant do it, cause my comp cant handle cygwin, and im leaving for a month on vacation in about an hour.
How do you make text stay there if you press X, and you would need to hold it for teh text to stay there. I want it so the text appears and stays when I press X. I tried:
I tried screen.flip OR screen.waitVblankStart(), neither worked. Help :(Code:if pad:cross() then
screen:print(10,10,"TEST TEST TEST", red)
screen.flip() --I also tried screen.waitVblankStart()
end
Thank you :icon_smil :icon_smil :icon_smil :icon_smil :icon_smil :icon_smil
--PSPduh
you have to make it into a looping thing
(dont ask me about it though, i only program a little bit)
but here is the problem, your program runs, and doesnt check again, you have to get it to run and check
code: (im not sure if this is right)
while 1
if pad:cross() then
screen:print(10,10,"TEST TEST TEST", red)
screen.flip()
end