diff --git a/CHANGELOG.md b/CHANGELOG.md index db80d3c03..4f83a08b4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -35,6 +35,7 @@ All notable changes to this project will be documented in this file. - [#2444] SVG importer - improper stroke width when using width/height with viewBox - [#2444] SVG importer - stroke width not respecting transforms - [#2415] AS3 direct editation - nested functions - prefer callstack variables over prototype chain +- AS3 - AIR float support incorrectly writes float values to output stream ## [22.0.2] - 2025-01-17 ### Added diff --git a/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/abc/ABCOutputStream.java b/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/abc/ABCOutputStream.java index f172174bb..3259eef56 100644 --- a/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/abc/ABCOutputStream.java +++ b/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/abc/ABCOutputStream.java @@ -248,7 +248,11 @@ public class ABCOutputStream extends OutputStream { * @throws IOException On I/O error */ public void writeFloat(float value) throws IOException { - writeU16(Float.floatToIntBits(value)); + int val = Float.floatToIntBits(value); + write(val & 0xFF); + write((val >> 8) & 0xFF); + write((val >> 16) & 0xFF); + write((val >> 24) & 0xFF); } /**