diff --git a/buildnumber.txt b/buildnumber.txt index 09397688..b2ae9591 100644 --- a/buildnumber.txt +++ b/buildnumber.txt @@ -1 +1 @@ -2495 \ No newline at end of file +2498 \ No newline at end of file diff --git a/source/funkin/editors/UIDebugState.hx b/source/funkin/editors/UIDebugState.hx index edd91d44..3e522d16 100644 --- a/source/funkin/editors/UIDebugState.hx +++ b/source/funkin/editors/UIDebugState.hx @@ -4,6 +4,12 @@ import funkin.editors.ui.*; class UIDebugState extends UIState { public override function create() { + var bg = new FlxSprite().makeGraphic(0xFF888888); + bg.scale.set(FlxG.width, FlxG.height); + bg.updateHitbox(); + bg.scrollFactor.set(); + add(bg); + super.create(); add(new UICheckbox(10, 10, "Test unchecked", false)); add(new UICheckbox(10, 40, "Test checked", true)); diff --git a/source/funkin/editors/ui/UICheckbox.hx b/source/funkin/editors/ui/UICheckbox.hx index 52c237a0..a2c6d597 100644 --- a/source/funkin/editors/ui/UICheckbox.hx +++ b/source/funkin/editors/ui/UICheckbox.hx @@ -33,7 +33,7 @@ class UICheckbox extends UISprite { pressed = false; // CHECKMARK HANDLING - check.visible = checked; + check.alpha = checked ? 1 : 0; check.scale.x = CoolUtil.fpsLerp(check.scale.x, 1, 0.25); check.scale.y = CoolUtil.fpsLerp(check.scale.y, 1, 0.25); @@ -44,6 +44,8 @@ class UICheckbox extends UISprite { } public inline function updatePositions() { + check.cameras = field.cameras = cameras; + field.setPosition(x + 30, y); check.setPosition(x, y); }