private void saveTileBehaviors() { ByteArrayOutputStream file = new ByteArrayOutputStream(); for (int i = 0; i < TileBehaviors.Length; i++) { file.writeUInt(TileBehaviors[i]); } if (TilesetNumber == 0) { ROM.ReplaceInlineFile(ROM.Data.File_Jyotyu_CHK, file.getArray()); } else if (TilesetNumber == 1 || TilesetNumber == 2) { TileBehaviorFile.replace(file.getArray(), this); } }
public void write(ByteArrayOutputStream outp, ByteArrayOutputStream cam, int camID) { outp.writeUShort((ushort)X); outp.writeUShort((ushort)Y); outp.writeUShort((ushort)Width); outp.writeUShort((ushort)Height); outp.writeByte((byte)Number); outp.writeByte((byte)camID); outp.writeByte((byte)Music); outp.writeByte((byte)Unknown1); outp.writeByte((byte)Unknown2); outp.writeByte((byte)Unknown3); outp.writeByte((byte)Lighting); outp.writeByte((byte)FlagpoleID); cam.writeInt(CameraTop); cam.writeInt(CameraBottom); cam.writeInt(CameraTopSpin); cam.writeInt(CameraBottomSpin); cam.writeUShort((ushort)camID); cam.writeUShort((ushort)CameraBottomStick); cam.writeUInt(0); //This seems just padding. }
private void saveTileBehaviors() { ByteArrayOutputStream file = new ByteArrayOutputStream(); for (int i = 0; i < TileBehaviors.Length; i++) file.writeUInt(TileBehaviors[i]); if (TilesetNumber == 0) { ROM.ReplaceInlineFile(ROM.Data.File_Jyotyu_CHK, file.getArray()); } else if (TilesetNumber == 1 || TilesetNumber == 2) { TileBehaviorFile.replace(file.getArray(), this); } }