Exemple #1
0
 public override void Encode(General.Encoding.BinaryOutput stream)
 {
     base.Encode(stream);
     stream.Write(MovementBehavior);
     stream.Write(elapsed);
     stream.Write(nextMovement);
 }
Exemple #2
0
        public void Encode(General.Encoding.BinaryOutput stream)
        {
            stream.Write(Name);
            stream.Write((Int32)Gender);

            for (int i = 0; i < Party.Length; i++)
            {
                if (Party[i] != null)
                {
                    continue;
                }
                stream.Write(i);
                return;
            }
            foreach (Pokemon pokemon in Party)
            {
                pokemon.Encode(stream);
            }

            stream.Write(Flags.Length);
            for (int i = 0; i < Flags.Length; i++)
            {
                stream.Write(Flags[i]);
            }
        }
Exemple #3
0
 public virtual void Encode(General.Encoding.BinaryOutput stream)
 {
     stream.Write(id);
     stream.Write(Position);
     stream.Write(Width);
     stream.Write(Height);
 }
Exemple #4
0
 public void Encode(General.Encoding.BinaryOutput stream)
 {
     stream.Write(Templates.Count);
     foreach (EntityTemplate ob in Templates)
     {
         stream.Write(ob);
     }
 }
Exemple #5
0
        public void Encode(General.Encoding.BinaryOutput stream)
        {
            stream.Write(position);
            stream.Write(model.Name);
            stream.Write(entityIndex);

            EntityIO writer = new EntityIO(stream, null, true);

            writer.Write(worldEntity);
        }
Exemple #6
0
        public void Encode(General.Encoding.BinaryOutput stream)
        {
            stream.Write(Name);
            stream.Write(Actions.Count);
            ActionIO writer = new ActionIO(stream);

            foreach (IAction i in Actions)
            {
                writer.Write(i);
            }
        }
Exemple #7
0
        public void Encode(General.Encoding.BinaryOutput stream)
        {
            stream.Write(X);
            stream.Write(Y);
            stream.Write(Z);

            stream.Write(TilesetIndex);
            stream.Write(TileIndex);

            stream.Write(oldtilesetIndex);
            stream.Write(oldtileIndex);
        }
Exemple #8
0
        public void Encode(General.Encoding.BinaryOutput stream)
        {
            stream.Write(Name);
            stream.Write(Author);
            stream.Write(Width);
            stream.Write(Height);
            stream.Write(Tilesets.Count);
            Tilesets.ForEach(stream.Write);

            for (int x = 0; x < Width; x++)
            {
                for (int y = 0; y < Height; y++)
                {
                    for (int z = 0; z < LayerCount; z++)
                    {
                        stream.Write(Tiles[x][y][z]);
                    }
                }
            }
            stream.Write(Entities.Count);
            Entities.ForEach(e => stream.Write(e.Template));
        }
Exemple #9
0
 public void Encode(General.Encoding.BinaryOutput stream)
 {
     stream.Write(tilesheetindex);
 }
Exemple #10
0
 public void Encode(General.Encoding.BinaryOutput stream)
 {
     stream.Write(Count);
     ForEach(stream.Write);
 }