/**
  * Translate every entities with the given offset.
  *
  * @param p_offset
  * @param p_translateZildo TRUE=Translate Zildo too / FALSE=Don't touch him
  */
 public void translateEntities(Point p_offset, boolean p_translateZildo) {
   for (SpriteEntity entity : spriteEntities) {
     if (!entity.clientSpecific && (!entity.isZildo() || p_translateZildo)) {
       if (entity.getEntityType().isElement()) {
         Element e = (Element) entity;
         if (e.getLinkedPerso() != null && e.getLinkedPerso().isZildo()) {
           continue;
         }
       }
       entity.x += p_offset.x;
       entity.y += p_offset.y;
       entity.setAjustedX(entity.getAjustedX() + p_offset.x);
       entity.setAjustedY(entity.getAjustedY() + p_offset.y);
     }
   }
 }
  /**
   * Spawn a sprite with minimal requirements:
   *
   * <ul>
   *   <li>build an entity with given parameters
   *   <li>add it to the sprite engine
   *
   * @param x
   * @param y
   * @param p_foreground TRUE=above the other sprites (GUI) / FALSE=in-game sprite
   * @param p_reverse reverse flag
   * @param p_adjustPos TRUE=center the element / FALSE=no location adjustment
   */
  public SpriteEntity spawnSprite(
      SpriteDescription desc,
      int x,
      int y,
      boolean p_foreground,
      Reverse p_reverse,
      boolean p_adjustPos) {

    int nBank = desc.getBank();
    int nSpr = desc.getNSpr();

    if (desc.isPushable()) { // || nSpr == 179) {
      // Particular sprite (Block that Zildo can move, chest...)
      return spawnElement(
          nBank, nSpr, x, y, 0, Reverse.NOTHING, Rotation.NOTHING); // + spr.getTaille_y() / 2 - 3,
      // 0);
    }

    // SpriteEntity informations
    SpriteEntity entity;
    ElementDescription elemDesc = null;
    if (desc instanceof ElementDescription) {
      elemDesc = (ElementDescription) desc;
    }
    boolean weapon = false;
    if (elemDesc != null) {
      ItemKind kind = ItemKind.fromDesc(elemDesc);
      weapon = kind != null && kind.isWeapon();
    }
    if (!p_foreground && weapon) {
      entity = new ElementWeapon(x, y);
    } else if (desc == ElementDescription.LAUNCHER1) {
      entity = new ElementLauncher(x, y);
      entity.setAjustedX(x);
      entity.setAjustedY(y);
    } else if (desc.getBank() == SpriteBank.BANK_GEAR) {
      entity = new ElementGear(x, y);
      entity.setAjustedX(x);
      entity.setAjustedY(y);
    } else if (desc == ElementDescription.QUAD1) {
      EngineZildo.multiplayerManagement.spawnQuad(x, y);
      return null;
    } else {
      entity = new SpriteEntity(x, y, true);
      int adjustX = 0;
      int adjustY = 0;
      SpriteModel spr = getSpriteBank(desc.getBank()).get_sprite(nSpr);
      adjustX = -(spr.getTaille_x() >> 1);
      if (p_adjustPos) {
        adjustY = -(spr.getTaille_y() >> 1);
      } else {
        adjustY = -spr.getTaille_y();
      }
      entity.setAjustedX(x + adjustX);
      entity.setAjustedY(y + adjustY);
    }

    entity.setNSpr(nSpr);
    entity.setNBank(nBank);
    entity.setForeground(p_foreground);

    entity.reverse = p_reverse;

    spawnSprite(entity);

    // Store walkable entities
    if (ElementDescription.isPlatform(desc)) {
      entity.initMover();
      walkableEntities.add(entity);
    }

    return entity;
  }