Finding 'suitable' horizontal and vertical speed from an angle - android
<p>im using a particle system and have it so when it creates the particle it passes a starting x and y value and from that i get an angle to where i want to shoot the particle but i need it so i have a vertical speed and a horizontal speed so what can i can?</p>

<p>hack and slash of my particle:</p>

<pre><code>Particle(int x, int y,int x2,int y2) {
  this.x = x;
  this.y = y;
  this.state = BulletParticle.STATE_ALIVE;
  this.widht = MAX_DIMENSION;//rndInt(1, MAX_DIMENSION);
  this.height = this.widht;
//  this.height = rnd(1, MAX_DIMENSION);
  this.lifetime = DEFAULT_LIFETIME;
  this.age = 0;
  this.xv = x2;//(rndDbl(0, MAX_SPEED * 2) - MAX_SPEED);
  this.yv = y2;//(rndDbl(0, MAX_SPEED * 2) - MAX_SPEED);
  // smoothing out the diagonal speed
  if (xv * xv + yv * yv &gt; MAX_SPEED * MAX_SPEED) {
   xv *= 0.7;
   yv *= 0.7;
  }
</code></pre>
