Package com.fluidsimulator.gameobjects.fluid

Examples of com.fluidsimulator.gameobjects.fluid.Particle


    // On Android populate directly
    if (!IS_DESKTOP) {
      for (float j = INITIAL_HEIGHT + hpadding + 2; j < WORLD_HEIGHT - 2; j += 1.0f) {
        for (float i = -WORLD_WIDTH / 3; i < WORLD_WIDTH / 3; i += 1.0f) {
          particles.add(new Particle(i, j));
          tempParticle = particles.get(particles.size() - 1);
          tempParticle.type = (emitType);
          if (particles.size() >= ANDROID_SIZE)
            return;
        }
View Full Code Here


        isRepulsing = false;
        if (particles.size() < SIZE - 1) {
          if ((testPoint2D.x < (-WORLD_WIDTH / 2 + wpadding) || testPoint2D.x > (WORLD_WIDTH / 2 - wpadding))
              || (testPoint2D.y < (INITIAL_HEIGHT + hpadding) || testPoint2D.y > (WORLD_HEIGHT - hpadding)))
            return false;
          particles.add(new Particle(testPoint2D));
          particles.get(particles.size() - 1).type = (emitType);
          if (viscoElasticityEnabled)
            springPresenceTable.put(
                particles.get(particles.size() - 1).hashCode(),
                new ArrayList<Integer>(SIZE));
View Full Code Here

          || (testPoint2D.y < (INITIAL_HEIGHT + hpadding) || testPoint2D.y > (WORLD_HEIGHT - hpadding)))
        return false;
      for (float i = -5; i < 5; i += 0.5f) {
        if (particles.size() >= SIZE - 1)
          break;
        particles.add(new Particle(testPoint2D.x + i, testPoint2D.y));
        tempParticle = particles.get(particles.size() - 1);
        tempParticle.type = (emitType);
        if (viscoElasticityEnabled)
          springPresenceTable.put(tempParticle.hashCode(),
              new ArrayList<Integer>(SIZE));
View Full Code Here

TOP

Related Classes of com.fluidsimulator.gameobjects.fluid.Particle

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.