Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: Thor & Particle Effects  (Read 2079 times)

0 Members and 1 Guest are viewing this topic.

Valleriani

  • Newbie
  • *
  • Posts: 13
    • View Profile
Thor & Particle Effects
« on: July 23, 2015, 09:33:58 pm »
Hello!

I am interested in using particle effects, but have not done so yet before. I have setup SFML and Thor now and it does work fine for basic effects, but I'm trying to aim to make a 'hard thrust' rather then a smoke particle thrust.

The example image (first image) is what I have. It's a basic thrust that fades out largely, when the ship rotates though, it looks more of a smoke trail because it doesn't 'stick' with the ship rotation like a real thrust would. (Check example2 to see what I mean by that.)

What I want is more of a turbine type thrust, like this one here:
http://forum.unity3d.com/attachments/unity-2013-10-16-21-41-01-37-jpg.71190/


Does anyone have any tips or examples on this? Is there a good guide to particle effects and thor or something similar? Thanks!

zsbzsb

  • Hero Member
  • *****
  • Posts: 1409
  • Active Maintainer of CSFML/SFML.NET
    • View Profile
    • My little corner...
    • Email
Re: Thor & Particle Effects
« Reply #1 on: July 23, 2015, 10:22:58 pm »
I don't have much experience with creating particles, but it would seem that as the ship moves faster you would want to increase the speed particles are generated and decrease the lifetime of each particle.
Motion / MotionNET - Complete video / audio playback for SFML / SFML.NET

NetEXT - An SFML.NET Extension Library based on Thor

shadowmouse

  • Sr. Member
  • ****
  • Posts: 302
    • View Profile
Re: Thor & Particle Effects
« Reply #2 on: July 23, 2015, 10:38:23 pm »
Alternatively you want to think about emulating local space. Image 0,0 as the origin of the ship and set the position of the emitter to be where the booster would be if the origin of the ship was 0,0. Then combine the transform of the ship with that of the emitter before drawing.

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
Re: Thor & Particle Effects
« Reply #3 on: July 23, 2015, 10:41:02 pm »
Quote
it looks more of a smoke trail because it doesn't 'stick' with the ship rotation like a real thrust would. (Check example2 to see what I mean by that.)
This looks more like a simple sprite attached to the back of the ship. What you want (from your description) doesn't really look like a particle system, more a fixed effect that follows its emitter.
Laurent Gomila - SFML developer

Valleriani

  • Newbie
  • *
  • Posts: 13
    • View Profile
Re: Thor & Particle Effects
« Reply #4 on: July 24, 2015, 04:58:57 pm »
Ah okay, so not really a particle system that does what I want. So you think that a sprite (I'm guessing with a shader to give it a nice effect) could do this well then?

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
Re: Thor & Particle Effects
« Reply #5 on: July 24, 2015, 05:33:36 pm »
Yes. You don't even need a shader, just an alpha-blended sprite, that you scale according to the thrust.
Laurent Gomila - SFML developer