- Online Community Forums » Programming Questions » Partical systems

This thread is locked; no one can reply to it. rss feed Print
Partical systems
Member #7,943
November 2006


Can anyone please point me to a tutorial on particle systems using allegro I have tried this one:
( but for some reason it wont compile )

Member #7,167
April 2006

what exactly is the problem?

Democracy in Sweden? Not since 2008-Jun-18.
<someone> The lesbians next door bought me a rolex for my birthday.
<someone> I think they misunderstood when I said I wanna watch...

Member #8,543
April 2007

Hi meinaW,

it would be nice, if you could post the compiler errors. I think you had just minor mistake in you code.

greetz ;)

--- Where the german seems to dwell... ---

Member #7,943
November 2006

Sorry that i hvnt answered in a while (i got tight school work heading into exams)

anyways these are the compiler errors that i get:

tmp->x = float(rand()%(SCREEN_W+40))-20;
conversion from `double' to non-scalar type `fix' requested

tmp->dx = r*sin(direction);
conversion from `double' to non-scalar type `fix' requested

i use dev-c++ on windows

Johan Peitz
Member #9
April 2000

I'd write the first one like this instead (but I don't know if that solves the problem):

tmp->x = (float)(rand()%(SCREEN_W + 40)) - 20;

The second one should be solved by including math.h.

johan peitz :: things I made

Member #7,943
November 2006

Thanks Johan Peitz

adding math.h solved both errors

Go to: