1
0
Fork 0
mirror of https://github.com/ninjamuffin99/Funkin.git synced 2025-07-04 01:36:24 +00:00

cutscenes, menu, story shit

This commit is contained in:
Cameron Taylor 2021-04-09 16:37:54 -04:00
parent d9612ebb2b
commit 1f45a072c0
6 changed files with 48 additions and 17 deletions

View file

@ -82,6 +82,8 @@ class GameOverSubstate extends MusicBeatSubstate
if (controls.BACK) if (controls.BACK)
{ {
PlayState.deathCounter = 0;
PlayState.seenCutscene = false;
FlxG.sound.music.stop(); FlxG.sound.music.stop();
if (PlayState.isStoryMode) if (PlayState.isStoryMode)

View file

@ -96,7 +96,8 @@ class MainMenuState extends MusicBeatState
// addMenuItem('options', function () startExitState(new OptionMenu())); // addMenuItem('options', function () startExitState(new OptionMenu()));
#if CAN_OPEN_LINKS #if CAN_OPEN_LINKS
var hasPopupBlocker = #if web true #else false #end; var hasPopupBlocker = #if web true #else false #end;
menuItems.createItem('donate', selectDonate, hasPopupBlocker); menuItems.createItem('kickstarter', selectDonate, hasPopupBlocker);
// menuItems.createItem('donate', selectDonate, hasPopupBlocker);
#end #end
menuItems.createItem('options', function() startExitState(new OptionsState())); menuItems.createItem('options', function() startExitState(new OptionsState()));
// #if newgrounds // #if newgrounds
@ -150,9 +151,12 @@ class MainMenuState extends MusicBeatState
function selectDonate() function selectDonate()
{ {
#if linux #if linux
Sys.command('/usr/bin/xdg-open', ["https://ninja-muffin24.itch.io/funkin", "&"]); // Sys.command('/usr/bin/xdg-open', ["https://ninja-muffin24.itch.io/funkin", "&"]);
Sys.command('/usr/bin/xdg-open', ["https://www.kickstarter.com/projects/funkin/", "&"]);
#else #else
FlxG.openURL('https://ninja-muffin24.itch.io/funkin'); // FlxG.openURL('https://ninja-muffin24.itch.io/funkin');
FlxG.openURL('https://www.kickstarter.com/projects/funkin/');
#end #end
} }
#end #end

View file

@ -25,6 +25,7 @@ class MenuCharacter extends FlxSprite
animation.addByPrefix('mom', "Mom Idle BLACK LINES", 24); animation.addByPrefix('mom', "Mom Idle BLACK LINES", 24);
animation.addByPrefix('parents-christmas', "Parent Christmas Idle", 24); animation.addByPrefix('parents-christmas', "Parent Christmas Idle", 24);
animation.addByPrefix('senpai', "SENPAI idle Black Lines", 24); animation.addByPrefix('senpai', "SENPAI idle Black Lines", 24);
animation.addByPrefix('tankman', "Tankman Menu BLACK", 24);
// Parent Christmas Idle // Parent Christmas Idle
animation.play(character); animation.play(character);

View file

@ -168,6 +168,7 @@ class PauseSubState extends MusicBeatSubstate
case "Restart Song": case "Restart Song":
FlxG.resetState(); FlxG.resetState();
case "Exit to menu": case "Exit to menu":
PlayState.seenCutscene = false;
PlayState.deathCounter = 0; PlayState.deathCounter = 0;
if (PlayState.isStoryMode) if (PlayState.isStoryMode)
FlxG.switchState(new StoryMenuState()); FlxG.switchState(new StoryMenuState());

View file

@ -102,6 +102,8 @@ class PlayState extends MusicBeatState
var dialogue:Array<String> = ['blah blah blah', 'coolswag']; var dialogue:Array<String> = ['blah blah blah', 'coolswag'];
public static var seenCutscene:Bool = false;
var halloweenBG:FlxSprite; var halloweenBG:FlxSprite;
var isHalloween:Bool = false; var isHalloween:Bool = false;
@ -149,6 +151,8 @@ class PlayState extends MusicBeatState
var detailsPausedText:String = ""; var detailsPausedText:String = "";
#end #end
var camPos:FlxPoint;
override public function create() override public function create()
{ {
if (FlxG.sound.music != null) if (FlxG.sound.music != null)
@ -632,7 +636,7 @@ class PlayState extends MusicBeatState
dad = new Character(100, 100, SONG.player2); dad = new Character(100, 100, SONG.player2);
var camPos:FlxPoint = new FlxPoint(dad.getGraphicMidpoint().x, dad.getGraphicMidpoint().y); camPos = new FlxPoint(dad.getGraphicMidpoint().x, dad.getGraphicMidpoint().y);
switch (SONG.player2) switch (SONG.player2)
{ {
@ -841,8 +845,10 @@ class PlayState extends MusicBeatState
// cameras = [FlxG.cameras.list[1]]; // cameras = [FlxG.cameras.list[1]];
startingSong = true; startingSong = true;
if (isStoryMode) if (isStoryMode && !seenCutscene)
{ {
seenCutscene = true;
switch (curSong.toLowerCase()) switch (curSong.toLowerCase())
{ {
case "winter-horrorland": case "winter-horrorland":
@ -881,6 +887,13 @@ class PlayState extends MusicBeatState
case 'thorns': case 'thorns':
schoolIntro(doof); schoolIntro(doof);
case 'ugh':
ughIntro();
case 'stress':
stressIntro();
case 'guns':
gunsIntro();
default: default:
startCountdown(); startCountdown();
} }
@ -889,12 +902,9 @@ class PlayState extends MusicBeatState
{ {
switch (curSong.toLowerCase()) switch (curSong.toLowerCase())
{ {
case 'ugh': // REMOVE THIS LATER
ughIntro();
case 'stress': case 'stress':
stressIntro(); stressIntro();
case 'guns':
gunsIntro();
default: default:
startCountdown(); startCountdown();
@ -968,6 +978,8 @@ class PlayState extends MusicBeatState
function gunsIntro() function gunsIntro()
{ {
camFollow.setPosition(camPos.x, camPos.y);
camHUD.visible = false; camHUD.visible = false;
FlxG.sound.playMusic(Paths.music('DISTORTO'), 0); FlxG.sound.playMusic(Paths.music('DISTORTO'), 0);
@ -1013,6 +1025,9 @@ class PlayState extends MusicBeatState
function stressIntro() function stressIntro()
{ {
// for story mode shit
camFollow.setPosition(camPos.x, camPos.y);
for (i in 0...7) for (i in 0...7)
{ {
var dummyLoader:FlxSprite = new FlxSprite(); var dummyLoader:FlxSprite = new FlxSprite();
@ -1487,7 +1502,8 @@ class PlayState extends MusicBeatState
else else
vocals = new FlxSound(); vocals = new FlxSound();
vocals.onComplete = function(){ vocals.onComplete = function()
{
vocalsFinished = true; vocalsFinished = true;
}; };
FlxG.sound.list.add(vocals); FlxG.sound.list.add(vocals);
@ -1775,14 +1791,14 @@ class PlayState extends MusicBeatState
function resyncVocals():Void function resyncVocals():Void
{ {
if (_exiting) if (_exiting)
return ; return;
vocals.pause(); vocals.pause();
FlxG.sound.music.play(); FlxG.sound.music.play();
Conductor.songPosition = FlxG.sound.music.time; Conductor.songPosition = FlxG.sound.music.time;
if (vocalsFinished) if (vocalsFinished)
return ; return;
vocals.time = Conductor.songPosition; vocals.time = Conductor.songPosition;
vocals.play(); vocals.play();
@ -2152,6 +2168,7 @@ class PlayState extends MusicBeatState
function endSong():Void function endSong():Void
{ {
seenCutscene = false;
deathCounter = 0; deathCounter = 0;
canPause = false; canPause = false;
FlxG.sound.music.volume = 0; FlxG.sound.music.volume = 0;

View file

@ -29,11 +29,12 @@ class StoryMenuState extends MusicBeatState
['Pico', 'Philly', "Blammed"], ['Pico', 'Philly', "Blammed"],
['Satin-Panties', "High", "Milf"], ['Satin-Panties', "High", "Milf"],
['Cocoa', 'Eggnog', 'Winter-Horrorland'], ['Cocoa', 'Eggnog', 'Winter-Horrorland'],
['Senpai', 'Roses', 'Thorns'] ['Senpai', 'Roses', 'Thorns'],
['Ugh', 'Guns', 'Stress']
]; ];
var curDifficulty:Int = 1; var curDifficulty:Int = 1;
public static var weekUnlocked:Array<Bool> = [true, true, true, true, true, true, true]; public static var weekUnlocked:Array<Bool> = [true, true, true, true, true, true, true, true];
var weekCharacters:Array<Dynamic> = [ var weekCharacters:Array<Dynamic> = [
['dad', 'bf', 'gf'], ['dad', 'bf', 'gf'],
@ -42,7 +43,8 @@ class StoryMenuState extends MusicBeatState
['pico', 'bf', 'gf'], ['pico', 'bf', 'gf'],
['mom', 'bf', 'gf'], ['mom', 'bf', 'gf'],
['parents-christmas', 'bf', 'gf'], ['parents-christmas', 'bf', 'gf'],
['senpai', 'bf', 'gf'] ['senpai', 'bf', 'gf'],
['tankman', 'bf', 'gf']
]; ];
var weekNames:Array<String> = [ var weekNames:Array<String> = [
@ -52,7 +54,8 @@ class StoryMenuState extends MusicBeatState
"PICO", "PICO",
"MOMMY MUST MURDER", "MOMMY MUST MURDER",
"RED SNOW", "RED SNOW",
"hating simulator ft. moawling" "hating simulator ft. moawling",
"cock Joke"
]; ];
var txtWeekTitle:FlxText; var txtWeekTitle:FlxText;
@ -112,7 +115,7 @@ class StoryMenuState extends MusicBeatState
add(grpLocks); add(grpLocks);
trace("Line 70"); trace("Line 70");
#if discord_rpc #if discord_rpc
// Updating Discord Rich Presence // Updating Discord Rich Presence
DiscordClient.changePresence("In the Menus", null); DiscordClient.changePresence("In the Menus", null);
@ -419,6 +422,9 @@ class StoryMenuState extends MusicBeatState
case 'dad': case 'dad':
grpWeekCharacters.members[0].offset.set(120, 200); grpWeekCharacters.members[0].offset.set(120, 200);
grpWeekCharacters.members[0].setGraphicSize(Std.int(grpWeekCharacters.members[0].width * 1)); grpWeekCharacters.members[0].setGraphicSize(Std.int(grpWeekCharacters.members[0].width * 1));
case 'tankman':
grpWeekCharacters.members[0].offset.set(60, -20);
grpWeekCharacters.members[0].setGraphicSize(Std.int(grpWeekCharacters.members[0].width * 1));
default: default:
grpWeekCharacters.members[0].offset.set(100, 100); grpWeekCharacters.members[0].offset.set(100, 100);