C Board  

Go Back   C Board > General Programming Boards > Game Programming

Reply
 
LinkBack Thread Tools Display Modes
Old 07-20-2002, 10:32 AM   #1
some dude
Guest
 
Posts: n/a
particle systems

hi,

i want to have some more algorithims, for manipulating the paths of particles, any one care to help me out?
  Reply With Quote
Old 07-20-2002, 01:20 PM   #2
Has a Masters in B.S.
 
Join Date: Aug 2001
Posts: 2,267
for what API?

look around at these places.

http://www.flipcode.com
http://www.gamedev.net
http://www.gametutorials.com

check their tutorials and ask on thier forums.
__________________
ADVISORY: This users posts are rated CP-MA, for Mature Audiences only.
no-one is offline   Reply With Quote
Old 07-20-2002, 07:03 PM   #3
Registered User
 
Join Date: Aug 2001
Posts: 403
http://nehe.gamedev.net/tutorials/lesson.asp?l=19
cozman is offline   Reply With Quote
Old 07-20-2002, 09:10 PM   #4
Pursuing knowledge
 
confuted's Avatar
 
Join Date: Jun 2002
Posts: 1,916
well, for a basic fountain type thing, with gravity, you could do this...

x=velocity*cos(angle)
y=velocity*sin(angle)*-16(t*t)

where t = time...those might be wrong, I haven't tested them, I just did it from memory, but they look right...
confuted is offline   Reply With Quote
Old 07-21-2002, 07:57 AM   #5
some dude
Guest
 
Posts: n/a
i am using OpenGL

i want to know, things like how do i make effects like those on Ms Media Player, specifically "flame", but i want to make that sort of effect in my program.

(thanks for the gravity thing, i needed that for something else)
  Reply With Quote
Old 07-21-2002, 06:47 PM   #6
Pursuing knowledge
 
confuted's Avatar
 
Join Date: Jun 2002
Posts: 1,916
well, for things like fire you will need particles to have a varying lifespan (within certain ranges), perhaps basing the life span partially on the angle they are projected at and part random. You'll need to change the color of the particle based on how long it's been in existence, and you'll need to alter the coefficient for the gravity (-16(t*t) is real world gravity, but it would make fire look strange) You could add some random fluxuations in the x component to add some distortion or turbulence type things, or a constant multiplied by t for wind... you'll need a lot of particles for the fire, but in a way, all particle systems are variations on the same principles.

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Some of my best thoughts have ended in a semi-colon.
confuted is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
[OGL] Particle class wanted! ahluka Game Programming 2 02-17-2006 07:44 AM
APIs for windowing in other systems sean Tech Board 5 08-23-2004 11:45 AM
What's a job as a systems administrator like? Terrance A Brief History of Cprogramming.com 3 05-09-2004 08:37 AM
OpenGL Particle Engine Demo frenchfry164 A Brief History of Cprogramming.com 3 11-25-2003 09:10 AM


All times are GMT -6. The time now is 06:11 PM.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.3.2

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22