blueprint

Paperboy BP_MainTheme 210260

  • Exposure: public
  • UE Version: 5.0

TobiyC

January 18, 2023, 5:16 pm

Click the button above, it will automatically copy blueprint in your clipboard. Then in Unreal Engine blueprint editor, paste it with ctrl + v

1 comment

  • TobiyC

    January 18, 2023, 5:23 pm

    This is the blueprint that handles the main theme of Paperboy. In the comment "Play music from start of play", there is a 'SpawnSound 2D' node that sets the main theme as the music in the "Main Theme" audio component variable. This makes the main theme start to play.

    In the comment "Stop playing when Paperboy finishes level" the 'Stop' node is used and plugged in with the "Main Theme" variable to make it stop playing. This is done when Paperboy finishes the level, and uses OnBeginOverlap to signal that Paperboy has reached that far in the level. The reason the main theme is a variable is because making it one allows the 'Stop' node to be used, as it requires a variable input to know what it has to stop playing.

    In the comment "Restart music if Paperboy dies" we can see an Event Dispatch binded to BP_Player. This Event Dispatch is activated when Paperboy loses a life. If this Dispatch is activated, it will use the 'Stop' node to stop playing the music, then restart it again after a 0.2 second delay, as the music restarts on death in the original Paperboy.

    Lastly, there is a second Event Dispatch binded to BP_Player. This Event Dispatch is activated when the Highscore Screen is activated. If this Dispatch is activated, it will use the 'Stop' node to stop playing the music, but will not restart it, as the Highscore theme is playing by this point.