particles question

jnica23jnica23 Member Posts: 47
edited March 2012 in Working with GS (Mac)
I'm working on a runner game and was wondering if there was a way to make the particles on the actor move in an arch when he's jumping from platform to platform? Right now when he jumps the particles only move up and down. Is there a way to do this even though the actor is in the same position? you can see what I mean in the video...

Comments

  • SlickZeroSlickZero Houston, TexasMember, Sous Chef Posts: 2,870
    You need to play with all the settings in the particles behavior. Try setting the particles to spawn to the left, and play around with adding velocity to it. That will get the result you are looking for, but you will need to play with the numbers to get the exact results that you want.
  • jnica23jnica23 Member Posts: 47
    Got it, looks very cool now. will post video later on. thanks for the help!
  • tatiangtatiang Member, Sous Chef, PRO, Senior Sous-Chef Posts: 11,949
    One idea is to constrain another actor to your main character and have that actor emit particles. You'd probably use a trig function (which someone else can help with better than me) to get it to move in an arc.

    New to GameSalad? (FAQs)   |   Tutorials   |   Templates   |   Greenleaf Games   |   Educator & Certified GameSalad User

  • jnica23jnica23 Member Posts: 47
    The particles work great (you can see in the video). Having some trouble with the score though. I want to interpolate the score for example when I destroy something but it interpolates it too much. I want only 500 points and it gives me like 1500+... not sure what I'm doing wrong... If I just have the score change without interpolate there's no problem but with it doesn't seem to work right. Is there something in the duration or something that I'm missing? Any help would be much appreciated!

  • JohnPapiomitisJohnPapiomitis Member Posts: 6,256
    Its because the interpolate is constantly changing when triggered, so if you try to interpolate an attribute to attribute+something, the number it goes to keeps rising.

    Heres a video

    http://www.youtube.com/watch?feature=player_embedded&v=2DcnWnZWCfI
  • jnica23jnica23 Member Posts: 47
    The video did give me a better understanding of how to use interpolate but in the end I decided to do something simpler. Because this is going to be a runner game I decided to make every second add 10 points to the score. I did that by having a timer and putting every .01 second to change (game.score) to (game.score+1). Then if I want to add more points for things collected or destroyed it's a lot easier and it still looks like the score is interpolating because every .01 second 1 point is being added. But I do appreciate the response. Thanks.
Sign In or Register to comment.