Yeah, it's just some cutscene thingy that i need to know
top of page
Website Created by fabr with logo by Logined Guest and inspired by Requiem and Psych News. Support Friday Night Funkin' on Newgrounds and Itch.io All characters and original Friday Night Funkin' game material belong to The Funkin Crew
bottom of page
Chest tattoos are such a bold and personal choice! They can really showcase someone's personality and style. Love seeing the creativity that goes into these designs.
Bài viết này thật sự rất hay và bổ ích! Mình đã học được rất nhiều điều về bài viết này. Cảm ơn tác giả vì đã chia sẻ bài viết này.
Nếu bạn quan tâm đến chủ đề cá cược, hãy truy cập trang web của mình để xem thêm nhiều bài viết hay khác: https://bk8vn.blog/
The specific steps involved in implementing cutscenes before or after a song will depend on the game engine or retro bowl software you're using.
To include a cutscene before or after a song in your game or application, you can follow these general steps following uno online guides:
Prepare the Cutscene Assets: Create or obtain the necessary assets for your cutscene, such as character animations, background images, dialogues, or any other visual and audio elements you want to include.
Design the Cutscene Sequence: Plan the sequence of events for your cutscene. Determine the order of the visuals, dialogues, and actions that will take place. Consider the timing and pacing to ensure it aligns with the song and creates the desired effect.
Implement the Cutscene Logic: Use your chosen game or application development framework or engine to implement the cutscene logic. This typically involves scripting or programming. You'll need to write code that triggers the cutscene to play at the appropriate time, controls the sequence of events, and handles any user interactions or input during the cutscene.
Play the Cutscene: When the conditions are met (e.g., before or after the song), start playing the cutscene by activating the necessary assets and triggering the scripted sequence. This may involve animating characters, displaying text or images, and synchronizing them with the song.
Transition to or from the Song: Once the cutscene is complete, transition smoothly to the song by fading in the audio or applying any other audiovisual effects you desire. Alternatively, if the cutscene is intended to follow the song, trigger the cutscene to play after the song finishes.
Test and Iterate: Test the cutscene functionality thoroughly to ensure it works as intended. Make any necessary adjustments or refinements to improve the timing, visual effects, or user experience.
what kind of cutscene we talking about? mp4 or scripted?
it doesnt change where you have to put the code really but definetly what code, on psych playing MP4's is as simple as doing
startVideo("yourVideoName");
however its obviously a bit harder with scripted ones.
where you put this code depends on when you want the cutscene to play
before the song itd be in the
if (isStoryMode && !seenCutscene)
conditional in PlayState.hx's create function. Which is where stuff before the countdown starts happens n shit
you then just add your song into the daSong switch (make sure its in lowercase and has all spaces replaced with a '-')
and then add the startVideo command (or script your cutscene )
like this:
switch (daSong) //mp4 cutscene example { case "scarySong": startVideo("scaryCutscene"); }.. switch (daSong) //scripted example { case "scarySong": FlxG.sound.play(Paths.soundRandom('thunder_', 1, 2)); boyfriend.playAnim('scared', true); boyfriend.animation.finishCallback = function(name:String) //plays upon bf finishing his animation { if(name == 'scared' && !startedCountdown) { startCountdown(); //starts the song } }; }..
if you want a cutscene after a song its only a tiny bit more complicated
firstly, search for "public function endSong():Void"
then above the function, add the following variable:
"public var seenEndCutscene = false;"
we will use this variable to determine if an end cutscene has already been played or not, so the code wont be stuck in a loop of playing the cutscene forever.
afterwards search for:
"if(ret != FunkinLua.Function_Stop && !transitioning)"
and make a new switch inside the conditional above the
"if (SONG.validScore) " conditional,
like this:
if (!seenEndCutscene){ //mp4 example switch(curSong.toLowerCase()){ case 'scarySong': seenEndCutscene = true; startVideo("scaryCutscene"); //no need to put endSong(); because startVideo automatically does that after finishing default: //if there is no custom cutscene seenEndCutscene = true; endSong(); //repeats the function but now skips this segment } }.. practically the same for the scripted example (dont forget to add the default case here aswell!!) switch (curSong.toLowerCase()) //scripted example { if (!seenEndCutscene){ case "scarySong": FlxG.sound.play(Paths.soundRandom('thunder_', 1, 2)); boyfriend.playAnim('scared', true); boyfriend.animation.finishCallback = function(name:String) { if(name == 'scared') { seenEndCutscene = true; endSong(); } }; }
finally, we will put the entire rest of the code from the
"if(ret != FunkinLua.Function_Stop && !transitioning)" conditional into an else argument, so it wont execute until the endCutscene has been played/seenEndCutscene is true, like this:
else{ if (SONG.validScore) { #if !switch var percent:Float = ratingPercent; if(Math.isNaN(percent)) percent = 0; Highscore.saveScore(SONG.song, songScore, storyDifficulty, percent); #end } //add all the other code below SONG.validScore here aswell, everything up to "transitioning = true;" }
That should be it!
Sounds a lot more complex than it is but i wanted to make sure to explain everything in most detail so the chance of you running into a problem is low (plus i wanted to at least explain what the code does and why you have to do it so you can learn from it aswell :) )
one small note though i havent actually tested this code myself since i did all of that basically freestyle-ish, and i dont quite have time to check rn, so if theres any issues feel free to tell me, good luck!