Exemple #1
0
  /** {@inheritDoc} */
  @Override
  public void writeContent(DISOutputStream dos) throws IOException {
    super.writeContent(dos);

    dos.writeUI32(fireMissionIndex);
    locationInWorld.write(dos);
    burstDescriptor.write(dos);
    velocity.write(dos);
    dos.writeFloat(range);
  }
Exemple #2
0
  /** {@inheritDoc} */
  @Override
  public void readContent(DISInputStream dis) throws IOException {
    super.readContent(dis);

    fireMissionIndex = dis.readUI32();
    locationInWorld.read(dis);
    burstDescriptor.read(dis);
    velocity.read(dis);
    range = dis.readFloat();
  }
Exemple #3
0
  /** {@inheritDoc} */
  @Override
  public int getContentLength() {
    int size = super.getContentLength();
    size += DISSizes.UI32_SIZE; // Fire Mission Index
    size += locationInWorld.getByteLength();
    size += burstDescriptor.getByteLength();
    size += velocity.getByteLength();
    size += DISSizes.FLOAT32_SIZE; // Range

    return size;
  }