Skip to content

Commit

Permalink
fixes oops
Browse files Browse the repository at this point in the history
  • Loading branch information
Joalor64GH authored Oct 15, 2024
1 parent 454a7e6 commit 24f4a34
Show file tree
Hide file tree
Showing 6 changed files with 7 additions and 11 deletions.
4 changes: 0 additions & 4 deletions haxelibs.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,6 @@
"name": "flixel-addons",
"type": "haxelib"
},
{
"name": "flixel-ui",
"type": "haxelib"
},
{
"name": "hxcpp",
"type": "haxelib"
Expand Down
2 changes: 1 addition & 1 deletion source/backend/Utilities.hx
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,6 @@ class Utilities {
return false;
}

public static function boundTo(value:Float, min:Float, max:Float):Float
public static function boundTo(value:Float, min:Float, max:Float):Float
return Math.max(min, Math.min(max, value));
}
4 changes: 2 additions & 2 deletions source/backend/ui/UICheckbox.hx
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@ class UICheckbox extends UISprite {

// CHECKMARK HANDLING
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);
check.scale.x = Utilities.fpsLerp(check.scale.x, 1, 0.25);
check.scale.y = Utilities.fpsLerp(check.scale.y, 1, 0.25);

// POSITION HANDLING
updatePositions();
Expand Down
4 changes: 2 additions & 2 deletions source/backend/ui/UIContextMenu.hx
Original file line number Diff line number Diff line change
Expand Up @@ -109,8 +109,8 @@ class UIContextMenu extends SubStateExt {
if (FlxG.mouse.wheel != 0.0)
scroll = FlxMath.bound(scroll + (FlxG.mouse.wheel * -20.0), !flipped ? 0.0 : -Math.max(bg.bHeight - FlxG.height*0.5, 0.0), flipped ? 0.0 : Math.max(bg.bHeight - FlxG.height*0.5, 0.0));

contextCam.scroll.y = CoolUtil.fpsLerp(contextCam.scroll.y, scroll, 0.5);
contextCam.alpha = CoolUtil.fpsLerp(contextCam.alpha, 1, 0.25);
contextCam.scroll.y = Utilities.fpsLerp(contextCam.scroll.y, scroll, 0.5);
contextCam.alpha = Utilities.fpsLerp(contextCam.alpha, 1, 0.25);
}

public override function destroy() {
Expand Down
2 changes: 1 addition & 1 deletion source/backend/ui/UIWarningSubstate.hx
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ class UIWarningSubstate extends ExtendableSubState {
warnCam.zoom = 0.1;
FlxG.cameras.add(warnCam, false);

var spr = new UISliceSprite(0, 0, CoolUtil.maxInt(560, 30 + (170 * buttons.length)), 232, 'editor/ui/${isError ? "normal" : "grayscale"}-popup');
var spr = new UISliceSprite(0, 0, Utilities.maxInt(560, 30 + (170 * buttons.length)), 232, 'editor/ui/${isError ? "normal" : "grayscale"}-popup');
spr.x = (FlxG.width - spr.bWidth) / 2;
spr.y = (FlxG.height - spr.bHeight) / 2;
spr.color = isError ? 0xFFFF0000 : 0xFFFFFF00;
Expand Down
2 changes: 1 addition & 1 deletion source/states/UITestState.hx
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ class UITestState extends UIState {
null,
{
label: "Exit",
onSelect: (t) -> {ExtendableState.switchState(new MenuState();)}
onSelect: (t) -> {ExtendableState.switchState(new MenuState());}
}
]
},
Expand Down

0 comments on commit 24f4a34

Please sign in to comment.