mirror of
https://github.com/ninjamuffin99/Funkin.git
synced 2024-09-12 05:07:06 +00:00
tween in fixed
This commit is contained in:
parent
9571eb70e0
commit
84f908fbde
|
@ -494,7 +494,8 @@ class FreeplayState extends MusicBeatSubState
|
|||
|
||||
for (i in 0...tempSongs.length)
|
||||
{
|
||||
var funnyMenu:SongMenuItem = new SongMenuItem(FlxG.width, (i * 150) + 160, tempSongs[i].songName);
|
||||
var funnyMenu:SongMenuItem = new SongMenuItem(FlxG.width, 0, tempSongs[i].songName);
|
||||
funnyMenu.y = funnyMenu.intendedY(i + 1) + 10;
|
||||
funnyMenu.targetPos.x = funnyMenu.x;
|
||||
funnyMenu.ID = i;
|
||||
funnyMenu.alpha = 0.5;
|
||||
|
@ -974,7 +975,7 @@ class FreeplayState extends MusicBeatSubState
|
|||
|
||||
capsule.selected = false;
|
||||
|
||||
capsule.targetPos.y = ((index - curSelected) * ((capsule.height * capsule.realScaled) + 10)) + 160;
|
||||
capsule.targetPos.y = capsule.intendedY(index - curSelected);
|
||||
capsule.targetPos.x = 270 + (60 * (Math.sin(index - curSelected)));
|
||||
// capsule.targetPos.x = 320 + (40 * (index - curSelected));
|
||||
|
||||
|
|
|
@ -38,7 +38,7 @@ class SongMenuItem extends FlxSpriteGroup
|
|||
// capsule.animation
|
||||
add(capsule);
|
||||
|
||||
songText = new FlxText(capsule.width * 0.1, 40, 0, songTitle, Std.int(40 * realScaled));
|
||||
songText = new FlxText(capsule.width * 0.23, 40, 0, songTitle, Std.int(40 * realScaled));
|
||||
songText.font = "5by7";
|
||||
songText.color = 0xFF43C1EA;
|
||||
add(songText);
|
||||
|
@ -114,6 +114,11 @@ class SongMenuItem extends FlxSpriteGroup
|
|||
super.update(elapsed);
|
||||
}
|
||||
|
||||
public function intendedY(index:Int):Float
|
||||
{
|
||||
return (index * ((height * realScaled) + 10)) + 160;
|
||||
}
|
||||
|
||||
function set_selected(value:Bool):Bool
|
||||
{
|
||||
// trace(value);
|
||||
|
|
Loading…
Reference in a new issue