Search found 74 matches

by surtic
Sun Nov 23, 2008 11:17 pm
Forum: Support and Development
Topic: Proper random number generation and radian/degree.
Replies: 22
Views: 25600

Re: Proper random number generation and radian/degree.

Subrime, as I showed in my output a few message back, the first number is the same but the rest of the sequence isn't. I think Kaze showed that the reason is that "similar" seeds give a "similar" first number in the sequence (but the rest of the sequence is different). Just to pr...
by surtic
Sun Nov 23, 2008 12:28 pm
Forum: Support and Development
Topic: Proper random number generation and radian/degree.
Replies: 22
Views: 25600

Re: Proper random number generation and radian/degree.

In my example I set the random seed every time and still get the number 3 at the beginning of every sequence.
It could be a problem with the C function, but it's still a problem.

You can check my post again to see what I mean. I am calling math.randomseed(os.time()) every time.
by surtic
Sat Nov 22, 2008 7:46 pm
Forum: Support and Development
Topic: Proper random number generation and radian/degree.
Replies: 22
Views: 25600

Re: Proper random number generation and radian/degree.

I think the problem was originally reported on Win2K and OS X. I see it on WinXP, so I got into the habit of always "popping" the first few random numbers.
by surtic
Sat Nov 22, 2008 5:12 pm
Forum: Support and Development
Topic: Proper random number generation and radian/degree.
Replies: 22
Views: 25600

Re: Proper random number generation and radian/degree.

c:\programming>lua Lua 5.1.2 Copyright (C) 1994-2007 Lua.org, PUC-Rio > math.randomseed(os.time()) > =math.random(0,100) 3 > =math.random(0,100) 54 > =math.random(0,100) 52 > =math.random(0,100) 100 > ^Z c:\programming>lua Lua 5.1.2 Copyright (C) 1994-2007 Lua.org, PUC-Rio > math.randomseed(os.time...
by surtic
Fri Nov 21, 2008 10:53 pm
Forum: General
Topic: LÖVE Formats
Replies: 32
Views: 35489

Re: LÖVE Formats

In my (humble) opinion, file formats should only be included if 1. The format itself is popular 2. It has advantages that other formats don't 3. It cannot be easily converted to other formats Taking image formats as an example, I see a point in having PNG (transparency, lossless) and JPG (small file...
by surtic
Fri Nov 21, 2008 3:10 pm
Forum: Support and Development
Topic: Proper random number generation and radian/degree.
Replies: 22
Views: 25600

Re: Proper random number generation and radian/degree.

Just a quick note - Lua's random number generator has problems with the first few numbers.

I suggest using

Code: Select all

math.random()
math.random()
math.random()
at the beginning of a program to get rid of these "bad" values.
by surtic
Thu Nov 06, 2008 9:50 pm
Forum: Support and Development
Topic: Couple Suggestions
Replies: 20
Views: 16046

Re: Couple Suggestions

I like the idea of a command line option. That really solves a big problem. Regarding fused files, I don't think it's that important. After all, I could write a program in my favourite language and claim that it's a fused LÖVE program. You can't protect against that (whatever protection you use I ca...
by surtic
Thu Oct 30, 2008 10:36 pm
Forum: General
Topic: Performance problem
Replies: 14
Views: 17648

Re: Performance problem

My monitor's refresh rate is 75Hz (yes, a CRT). I'm getting 76 fps.
I am guessing that LCDs with their 60Hz get 60 fps for a reason.

If I add game.conf with vsync=false I get between 976 and 2090 fps.
by surtic
Wed Oct 22, 2008 10:44 pm
Forum: Support and Development
Topic: Two questions...
Replies: 8
Views: 7274

Re: Two questions...

If you use PNG files for bitmaps, they support transparency (and semi-transparency) and LÖVE presents them correctly.

Many of the examples, tutorials and demos contain such bitmaps, have a look in http://love2d.org/docs/ExampleList.html, you can use the example browser to see the examples.
by surtic
Fri Oct 17, 2008 8:50 pm
Forum: Support and Development
Topic: Couple Suggestions
Replies: 20
Views: 16046

Re: Couple Suggestions

When you build lualib.lib (or liblualib.a) you decide what goes in there. If you don't put in the io library (liolib.c), it just won't be there. Of course, it's possible to require() anything and provide evil functionality in a DLL or .so, but then you can remove require() as well (just remove it fr...