Skip to content

Commit ba34d8f

Browse files
committed
Fork Flixel Animate to Fix frameOffsetAngle, layer
1 parent 9c96f88 commit ba34d8f

2 files changed

Lines changed: 7 additions & 24 deletions

File tree

building/libs.xml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,17 +5,17 @@
55

66
<!-- Hxcpp & OpenFL & Lime (Required for Flixel) -->
77
<git name="hxcpp" url="https://github.com/CodenameCrew/cne-hxcpp"/>
8-
<git name="openfl" url="https://github.com/CodenameCrew/cne-openfl" ref="develop"/>
9-
<git name="lime" url="https://github.com/CodenameCrew/cne-lime" ref="develop"/>
8+
<git name="openfl" url="https://github.com/CodenameCrew/cne-openfl" ref="develop" skipDeps="true"/>
9+
<git name="lime" url="https://github.com/CodenameCrew/cne-lime" ref="develop" skipDeps="true"/>
1010

1111
<!-- Flixel -->
12-
<git name="flixel" url="https://github.com/CodenameCrew/cne-flixel" ref="feat/update-to-5.9.0"/>
13-
<git name="flixel-addons" url="https://github.com/CodenameCrew/cne-flixel-addons" ref="dev"/>
12+
<git name="flixel" url="https://github.com/CodenameCrew/cne-flixel" ref="feat/update-to-5.9.0" skipDeps="true"/>
13+
<git name="flixel-addons" url="https://github.com/CodenameCrew/cne-flixel-addons" ref="dev" skipDeps="true"/>
1414

1515
<!-- CNE Core Libraries -->
16-
<git name="flixel-animate" url="https://github.com/MaybeMaru/flixel-animate/" skipDeps="true"/>
16+
<git name="flixel-animate" url="https://github.com/CodenameCrew/cne-flixel-animate/" skipDeps="true"/>
1717
<git name="hscript-improved" url="https://github.com/CodenameCrew/hscript-improved" ref="codename-dev"/>
18-
<git name="away3d" url="https://github.com/CodenameCrew/away3d"/>
18+
<git name="away3d" url="https://github.com/CodenameCrew/away3d" skipDeps="true"/>
1919

2020
<!-- Other Libraries -->
2121
<git name="hxdiscord_rpc" url="https://github.com/CodenameCrew/cne-hxdiscord_rpc" skipDeps="true"/>

source/funkin/backend/FunkinSprite.hx

Lines changed: 1 addition & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -366,26 +366,9 @@ class FunkinSprite extends FlxAnimate implements IBeatReceiver implements IOffse
366366
}
367367

368368
override function prepareDrawMatrix(matrix:FlxMatrix, camera:FlxCamera):Void {
369-
matrix.translate(-origin.x, -origin.y);
370-
371-
if (frameOffsetAngle != null && frameOffsetAngle != angle)
372-
{
373-
var angleOff = (frameOffsetAngle - angle) * FlxAngle.TO_RAD;
374-
var cos = Math.cos(angleOff);
375-
var sin = Math.sin(angleOff);
376-
// cos doesnt need to be negated
377-
matrix.rotateWithTrig(cos, -sin);
378-
matrix.translate(-frameOffset.x, -frameOffset.y);
379-
matrix.rotateWithTrig(cos, sin);
380-
}
381-
else
382-
matrix.translate(-frameOffset.x, -frameOffset.y);
383-
384-
matrix.translate(origin.x, origin.y);
385-
386369
super.prepareDrawMatrix(matrix, camera);
387370

388-
if(__shouldDoZoomFactor()) {
371+
if (__shouldDoZoomFactor()) {
389372
__prepareZoomFactor(_rect2, camera);
390373
matrix.setTo(
391374
matrix.a * _rect2.width, matrix.b * _rect2.height,

0 commit comments

Comments
 (0)