1
0
Fork 0
mirror of https://github.com/ninjamuffin99/Funkin.git synced 2024-09-17 15:38:52 +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)
{
PlayState.deathCounter = 0;
PlayState.seenCutscene = false;
FlxG.sound.music.stop();
if (PlayState.isStoryMode)

View file

@ -96,7 +96,8 @@ class MainMenuState extends MusicBeatState
// addMenuItem('options', function () startExitState(new OptionMenu()));
#if CAN_OPEN_LINKS
var hasPopupBlocker = #if web true #else false #end;
menuItems.createItem('donate', selectDonate, hasPopupBlocker);
menuItems.createItem('kickstarter', selectDonate, hasPopupBlocker);
// menuItems.createItem('donate', selectDonate, hasPopupBlocker);
#end
menuItems.createItem('options', function() startExitState(new OptionsState()));
// #if newgrounds
@ -150,9 +151,12 @@ class MainMenuState extends MusicBeatState
function selectDonate()
{
#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
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

View file

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

View file

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

View file

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

View file

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