1
0
Fork 0
mirror of https://github.com/ninjamuffin99/Funkin.git synced 2025-03-28 12:59:52 +00:00

format a few files

This commit is contained in:
Abnormal 2025-02-06 22:26:17 -06:00 committed by Eric
parent f3ea19ec31
commit 9b774e3264
9 changed files with 119 additions and 59 deletions

View file

@ -508,8 +508,32 @@ class SongRegistry extends BaseRegistry<Song, SongMetadata>
public function listBaseGameSongIds():Array<String>
{
return [
"tutorial", "bopeebo", "fresh", "dadbattle", "spookeez", "south", "monster", "pico", "philly-nice", "blammed", "satin-panties", "high", "milf", "cocoa",
"eggnog", "winter-horrorland", "senpai", "roses", "thorns", "ugh", "guns", "stress", "darnell", "lit-up", "2hot", "blazin"
"tutorial",
"bopeebo",
"fresh",
"dadbattle",
"spookeez",
"south",
"monster",
"pico",
"philly-nice",
"blammed",
"satin-panties",
"high",
"milf",
"cocoa",
"eggnog",
"winter-horrorland",
"senpai",
"roses",
"thorns",
"ugh",
"guns",
"stress",
"darnell",
"lit-up",
"2hot",
"blazin"
];
}

View file

@ -93,8 +93,22 @@ class StageRegistry extends BaseRegistry<Stage, StageData>
public function listBaseGameStageIds():Array<String>
{
return [
"mainStage", "mainStageErect", "spookyMansion", "phillyTrain", "phillyTrainErect", "limoRide", "limoRideErect", "mallXmas", "mallXmasErect", "mallEvil",
"school", "schoolEvil", "tankmanBattlefield", "phillyStreets", "phillyStreetsErect", "phillyBlazin",
"mainStage",
"mainStageErect",
"spookyMansion",
"phillyTrain",
"phillyTrainErect",
"limoRide",
"limoRideErect",
"mallXmas",
"mallXmasErect",
"mallEvil",
"school",
"schoolEvil",
"tankmanBattlefield",
"phillyStreets",
"phillyStreetsErect",
"phillyBlazin",
];
}

View file

@ -335,8 +335,19 @@ class PolymodHandler
{
return {
assetLibraryPaths: [
'default' => 'preload', 'shared' => 'shared', 'songs' => 'songs', 'videos' => 'videos', 'tutorial' => 'tutorial', 'week1' => 'week1',
'week2' => 'week2', 'week3' => 'week3', 'week4' => 'week4', 'week5' => 'week5', 'week6' => 'week6', 'week7' => 'week7', 'weekend1' => 'weekend1',
'default' => 'preload',
'shared' => 'shared',
'songs' => 'songs',
'videos' => 'videos',
'tutorial' => 'tutorial',
'week1' => 'week1',
'week2' => 'week2',
'week3' => 'week3',
'week4' => 'week4',
'week5' => 'week5',
'week6' => 'week6',
'week7' => 'week7',
'weekend1' => 'weekend1',
],
coreAssetRedirect: CORE_FOLDER,
}

View file

@ -50,12 +50,12 @@ class ResultScore extends FlxTypedSpriteGroup<ScoreNum>
public function animateNumbers():Void
{
for (i in group.members.length-scoreStart...group.members.length)
for (i in group.members.length - scoreStart...group.members.length)
{
// if(i.finalDigit == 10) continue;
// if(i.finalDigit == 10) continue;
new FlxTimer().start((i-1)/24, _ -> {
group.members[i].finalDelay = scoreStart - (i-1);
new FlxTimer().start((i - 1) / 24, _ -> {
group.members[i].finalDelay = scoreStart - (i - 1);
group.members[i].playAnim();
group.members[i].shuffle();
});
@ -97,10 +97,13 @@ class ScoreNum extends FlxSprite
{
if (val >= 0 && animation.curAnim != null && animation.curAnim.name != numToString[val])
{
if(glow){
if (glow)
{
animation.play(numToString[val], true, false, 0);
glow = false;
}else{
}
else
{
animation.play(numToString[val], true, false, 4);
}
updateHitbox();
@ -108,18 +111,18 @@ class ScoreNum extends FlxSprite
switch (val)
{
case 1:
// offset.x -= 15;
// offset.x -= 15;
case 5:
// set offsets
// offset.x += 0;
// offset.y += 10;
// set offsets
// offset.x += 0;
// offset.y += 10;
case 7:
// offset.y += 6;
// offset.y += 6;
case 4:
// offset.y += 5;
// offset.y += 5;
case 9:
// offset.y += 5;
// offset.y += 5;
default:
centerOffsets(false);
}
@ -144,44 +147,45 @@ class ScoreNum extends FlxSprite
"ZERO", "ONE", "TWO", "THREE", "FOUR", "FIVE", "SIX", "SEVEN", "EIGHT", "NINE", "DISABLED"
];
function finishShuffleTween():Void{
function finishShuffleTween():Void
{
var tweenFunction = function(x) {
var digitRounded = Math.floor(x);
//if(digitRounded == finalDigit) glow = true;
// if(digitRounded == finalDigit) glow = true;
digit = digitRounded;
};
finalTween = FlxTween.num(0.0, finalDigit, 23/24, {
ease: FlxEase.quadOut,
onComplete: function (input) {
new FlxTimer().start((finalDelay)/24, _ -> {
animation.play(animation.curAnim.name, true, false, 0);
});
// fuck
}
}, tweenFunction);
finalTween = FlxTween.num(0.0, finalDigit, 23 / 24,
{
ease: FlxEase.quadOut,
onComplete: function(input) {
new FlxTimer().start((finalDelay) / 24, _ -> {
animation.play(animation.curAnim.name, true, false, 0);
});
// fuck
}
}, tweenFunction);
}
function shuffleProgress(shuffleTimer:FlxTimer):Void
{
var tempDigit:Int = digit;
tempDigit += 1;
if(tempDigit > 9) tempDigit = 0;
if(tempDigit < 0) tempDigit = 0;
if (tempDigit > 9) tempDigit = 0;
if (tempDigit < 0) tempDigit = 0;
digit = tempDigit;
if (shuffleTimer.loops > 0 && shuffleTimer.loopsLeft == 0)
{
//digit = finalDigit;
// digit = finalDigit;
finishShuffleTween();
}
}
public function shuffle():Void{
var duration:Float = 41/24;
var interval:Float = 1/24;
public function shuffle():Void
{
var duration:Float = 41 / 24;
var interval:Float = 1 / 24;
shuffleTimer = new FlxTimer().start(interval, shuffleProgress, Std.int(duration / interval));
}

View file

@ -730,19 +730,22 @@ class ResultState extends MusicBeatSubState
if (controls.PAUSE)
{
if (introMusicAudio != null) {
if (introMusicAudio != null)
{
@:nullSafety(Off)
introMusicAudio.onComplete = null;
FlxTween.tween(introMusicAudio, {volume: 0}, 0.8, {
onComplete: _ -> {
if (introMusicAudio != null) {
introMusicAudio.stop();
introMusicAudio.destroy();
introMusicAudio = null;
FlxTween.tween(introMusicAudio, {volume: 0}, 0.8,
{
onComplete: _ -> {
if (introMusicAudio != null)
{
introMusicAudio.stop();
introMusicAudio.destroy();
introMusicAudio = null;
}
}
}
});
});
FlxTween.tween(introMusicAudio, {pitch: 3}, 0.1,
{
onComplete: _ -> {
@ -752,12 +755,13 @@ class ResultState extends MusicBeatSubState
}
else if (FlxG.sound.music != null)
{
FlxTween.tween(FlxG.sound.music, {volume: 0}, 0.8, {
onComplete: _ -> {
FlxG.sound.music.stop();
FlxG.sound.music.destroy();
}
});
FlxTween.tween(FlxG.sound.music, {volume: 0}, 0.8,
{
onComplete: _ -> {
FlxG.sound.music.stop();
FlxG.sound.music.destroy();
}
});
FlxTween.tween(FlxG.sound.music, {pitch: 3}, 0.1,
{
onComplete: _ -> {

View file

@ -90,7 +90,7 @@ class SustainTrail extends FlxSprite
* Whether the note will recieve custom vertex data
*/
public var customVertexData:Bool = false;
public var isPixel:Bool;
public var noteStyleOffsets:Array<Float>;
@ -176,7 +176,7 @@ class SustainTrail extends FlxSprite
this.uvtData = new DrawData<Float>(uvtData.length, false, uvtData);
}
}
/**
* Creates hold note graphic and applies correct zooming
* @param noteStyle The note style

View file

@ -36,7 +36,8 @@ class NoteStyle implements IRegistryEntry<NoteStyleData>
*/
var fallback(get, never):Null<NoteStyle>;
function get_fallback():Null<NoteStyle> {
function get_fallback():Null<NoteStyle>
{
if (_data == null || _data.fallback == null) return null;
return NoteStyleRegistry.instance.fetchEntry(_data.fallback);
}

View file

@ -101,9 +101,10 @@ class PreferencesMenu extends Page
createPrefItemCheckbox('Downscroll', 'If enabled, this will make the notes move downwards.', function(value:Bool):Void {
Preferences.downscroll = value;
}, Preferences.downscroll);
createPrefItemCheckbox('Flashing Lights', 'If disabled, it will dampen flashing effects. Useful for people with photosensitive epilepsy.', function(value:Bool):Void {
Preferences.flashingLights = value;
}, Preferences.flashingLights);
createPrefItemCheckbox('Flashing Lights', 'If disabled, it will dampen flashing effects. Useful for people with photosensitive epilepsy.',
function(value:Bool):Void {
Preferences.flashingLights = value;
}, Preferences.flashingLights);
createPrefItemCheckbox('Camera Zooms', 'If disabled, camera stops bouncing to the song.', function(value:Bool):Void {
Preferences.zoomCamera = value;
}, Preferences.zoomCamera);

View file

@ -44,6 +44,7 @@ class LevelTitle extends FlxSpriteGroup
}
public var isFlashing:Bool = false;
var flashTick:Float = 0;
final flashFramerate:Float = 20;