Smoke Particle

    This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

    • Hi,

      I've been searching my local library and googling for some guidance on this, but the only thing I've been finding is theory, theory and theory. No real or solid help.


      You don't lex the entire file and then parse it..

      For clarity, what your saying is don't make a list (vector) of tokens then process it, but rather make a single token THEN then process it, right?

      My way:
      1) Create token.
      2) insert token into list
      3) goto 1
      4) if done goto "5"
      5) pass list off to the Parser
      6) check if it meets our lanugage specifications.

      Here's what I think your saying:
      1) Create Token
      2) pass token to Parser
      6) check if it meets our lanugage specifications.
      3) goto 1

      Is that right?

      (Maybe I sould start a new thread here. (!) )
      Me.
    • Exactly. I guess my thumb nail wasn't as clear as I'd hoped for, sorry. for a language spec as simple as this one single token should be fine. Larger languages like the C's and Java require token look a head and fall back.

      Have you been here? compilers.iecc.com/crenshaw/

      This tutorial is more than you need but it is lighter on theory and jargon and heavier on the doing of lexers, parsers and compilers. Hope this helps

      good luck

      gb
    • Sabrina - two books to look for at your library:

      Game Scripting Mastery and Constructing Language Processors for Little Languages.

      Of course, even between them they're not the Dragon Book, but they will give you a good idea of how to get all of this tied together.
      "Your job is not to die for your country. Your job is to make some other poor sod die for his."
    • Be very careful with any code you may use from Constructing Language Processors for Little Languages. I have the first edition of that book, i don't know if there have been anymore editions, and i found a ton of errors in the sample code. almost every memory allocation was off by one
    • Hey guys/gals

      Firstly: a 'Sprite' is just a fancy word for a bitmap that moves around the screen... Usually used in old 2D game context, but I used it to imply that the smoke particles are all 2D bitmaps...

      Secondly: Yea that's my messy Smoke Stack code alright :P, programmed in *shock horror* Delphi...

      Thirdly: About the position, velocity, acceleration:

      Source Code

      1. Position = Position + Velocty
      2. Velocity = Velocity + Acceleration

      Thats all you need to do each frame to get position, velocity and acceleration. Simple!


      Lastly: I think the one thing that made the most difference with that smoke effect was a) the animated particles since the animation I acquired was really realistic looking (from a game) and b) the blending between frames of animation.. Now this required drawing each particle twice which WILL kill your framerate on a slow pc, maybe multitexturing is a better solution...


      Oh, and Sabrina I want to see your smoke but that link... She no working no more ?(

      The post was edited 3 times, last by Nitrogen ().

    • Pretty sure we got the definition of sprite down.... lol Though technically they're screen-aligned planes textured with bitmaps. Your smoke looks very good!

      I remember hand-coding sprites using POKE commands in Applesoft BASIC. It was the only way to really get good use from the high res mode.

      I like the multitexturing idea, or combining it with multi-pass rendering to do motion blur-like blending.

      Delphi is very nice to work in, too - though I stopped fiddling around with graphics programming in it some time ago. Pascal is a nice language, especially with the addition of OO constructs.

      And, yes, the code from those books I mentioned is not very good - but it's the concepts that are important, and they are fairly sound.
      "Your job is not to die for your country. Your job is to make some other poor sod die for his."

      The post was edited 2 times, last by Nebuchadnezzar ().

    • Hi Nitorgen!

      I *REALY* like your site! You have some very nice work. (I'm soooo jealous :) ) I like your smoke, Lightning and I love the "Font Testbed", that is really impressive effect. I have been trying to pattern my particle system after your project. :D I'm keeping an eye on your web site for more cool stuff. As far as my site, here it is. I take it down periodical to prevent my poor computer from crashing. Anyway, Theres a movie demostrating the particle effect. I did'nt want to upload the program, until I know for certain its stable. I think Garbob ran one of my programs and it crashed on him so I want to be very sure its safe for public release. Once its tested and deemed "safe for public consumption" I'll upload the exe and source.

      Nebuchadnezzar: I will look for the two books. The "Dragon Book" is NOT FOR ME! Yes, I did look at it and just about had a..."cow man"! WOW!! Ok, for the record, I did read it. I got to sections in the book that made no sence to me! Imagine the "Whushing" sound going over your head, thats what happend to me. I came really close to going into a comatose state! (I think you guys are playing a bad prank on me... I wont mention names.) I'd like to write a book review, but I would'nt know where to start! Any body up for "The Dragon Book for Dummies" series? Anyway, I'm back on track now with the particle script thingys.


      Sabrina
      "Ambassador of good will, nail polish and toe jam."