ng release and blank controls
This commit is contained in:
@ -17,6 +17,10 @@ class Alphabet extends FlxSpriteGroup
|
||||
public var delay:Float = 0.05;
|
||||
public var paused:Bool = false;
|
||||
|
||||
// for menu shit
|
||||
public var targetY:Float = 0;
|
||||
public var isMenuItem:Bool = false;
|
||||
|
||||
public var text:String = "";
|
||||
|
||||
var _finalText:String = "";
|
||||
@ -207,6 +211,14 @@ class Alphabet extends FlxSpriteGroup
|
||||
|
||||
override function update(elapsed:Float)
|
||||
{
|
||||
if (isMenuItem)
|
||||
{
|
||||
var scaledY = FlxMath.remapToRange(targetY, 0, 1, 0, 1.3);
|
||||
|
||||
y = FlxMath.lerp(y, (scaledY * 120) + (FlxG.height * 0.48), 0.16);
|
||||
x = FlxMath.lerp(x, (targetY * 20) + 90, 0.16);
|
||||
}
|
||||
|
||||
super.update(elapsed);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user