Particle effect or sprite following player's hand
by Holmida · in Torque Game Builder · 08/29/2011 (11:39 am) · 2 replies
I'm facing certain problem that I'm not so sure how to deal with. I've been checking the particle engine as well as TGB options such as mounting and I can't find any solution. Here's what I'm looking for:
Let's say I create a character with some magic powers, and one of that powers is something like a fireball. This fireball should be (when activated) always located at the player's hand, and when I press certain key it fires a burst. I need some tracking solution, but I'm not sure how to manage it. When the player isn't moving, the arm is static, so then there's no problem with this, I can simply link the effect to a link point located at the hand. The trouble comes with movement. The animation sprite has the player's arm go back and forth, so I'm looking for some kind of sprite tracking, or something like that, that associates the particle effect with the hand, so when it moves the fire moves with it and when it is static the fire is there.
Does someone know where to I start with this, or some other resources I can check that help me? I could use some other solution like creating the player and the arm as separate objects, and link the fire to the arm object, but that would cause us many trouble, specially when it comes to our art style (the entire game is being made with traditional animation, which means that we paint every background, texture or animation frame by frame with watercolors, then scan them, correct what needed with Photoshop, and then build the image or sprite. That's why would be insane to build characters with separated body parts).
Let's say I create a character with some magic powers, and one of that powers is something like a fireball. This fireball should be (when activated) always located at the player's hand, and when I press certain key it fires a burst. I need some tracking solution, but I'm not sure how to manage it. When the player isn't moving, the arm is static, so then there's no problem with this, I can simply link the effect to a link point located at the hand. The trouble comes with movement. The animation sprite has the player's arm go back and forth, so I'm looking for some kind of sprite tracking, or something like that, that associates the particle effect with the hand, so when it moves the fire moves with it and when it is static the fire is there.
Does someone know where to I start with this, or some other resources I can check that help me? I could use some other solution like creating the player and the arm as separate objects, and link the fire to the arm object, but that would cause us many trouble, specially when it comes to our art style (the entire game is being made with traditional animation, which means that we paint every background, texture or animation frame by frame with watercolors, then scan them, correct what needed with Photoshop, and then build the image or sprite. That's why would be insane to build characters with separated body parts).
#2
08/30/2011 (10:22 am)
Yeah, I know, that's why I was looking for some easy solution. The thing is, that's a very important mechanic of our gameplay (almost the core of it), so this is something we definitely need to solve. We are planning on creating a sprite with the fire at the hand, so when that "power" is activated, we shift sprites manually from script. It is not the same as a particle effect, but maybe it will somehow work.
Torque Owner Rpahut
You cold probably specify arm location at each frame manually and remount effect from script when animation frame changes, but it looks like too much work, and lots of time wasted on minor things like that is a sign of poor design. I mean, you probably have more important things to do there. So I would simply change the way armed fireball is indicated on a character.