adjusted the paths of the music
added the README.txt for each music piece to state the source of the music.
This commit is contained in:
		
						parent
						
							ca57507b53
						
					
				
				
					commit
					586251b2ad
				
			@@ -21,8 +21,8 @@ public class BackgroundMusic implements GameEventListener {
 | 
			
		||||
 | 
			
		||||
    private static final String MENU_MUSIC = "Music/MainMenu/Dark_Intro.ogg";
 | 
			
		||||
    private static final String BATTLE_MUSIC = "Music/BattleTheme/boss_battle_#2_metal_loop.wav";
 | 
			
		||||
    private static final String GAME_OVER_MUSIC_L = "Music/GameOver/Lose.ogg";
 | 
			
		||||
    private static final String GAME_OVER_MUSIC_V = "Music/GameOver/Victory.wav";
 | 
			
		||||
    private static final String GAME_OVER_MUSIC_L = "Music/GameOver/Lose/Lose.ogg";
 | 
			
		||||
    private static final String GAME_OVER_MUSIC_V = "Music/GameOver/Victory/Victory.wav";
 | 
			
		||||
 | 
			
		||||
    private final AudioNode menuMusic;
 | 
			
		||||
    private final AudioNode battleMusic;
 | 
			
		||||
 
 | 
			
		||||
@@ -46,6 +46,16 @@ class ShipControl extends AbstractControl {
 | 
			
		||||
     */
 | 
			
		||||
    private final Quaternion pitch = new Quaternion();
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * the speed at which ships sink
 | 
			
		||||
     */
 | 
			
		||||
    private static final float SINKING_SPEED = -0.05f;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * the threshold when ships should be removed from the scene if they sink below the value
 | 
			
		||||
     */
 | 
			
		||||
    private static final float SHIP_SINKING_REMOVE_THRESHOLD = -0.6f;
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * The current time within the oscillation cycle, used to calculate the ship's pitch angle.
 | 
			
		||||
     */
 | 
			
		||||
@@ -82,6 +92,7 @@ public ShipControl(Battleship ship) {
 | 
			
		||||
    /**
 | 
			
		||||
     * Updates the ship's pitch oscillation each frame. The ship's pitch is adjusted
 | 
			
		||||
     * to create a continuous tilting motion, simulating the effect of waves.
 | 
			
		||||
     * And lets the ship sink if it is destroyed and removes it from the scene when it has completely sunk
 | 
			
		||||
     *
 | 
			
		||||
     * @param tpf time per frame (in seconds), used to calculate the new pitch angle
 | 
			
		||||
     */
 | 
			
		||||
@@ -90,11 +101,11 @@ protected void controlUpdate(float tpf) {
 | 
			
		||||
        // If spatial is null, do nothing
 | 
			
		||||
        if (spatial == null) return;
 | 
			
		||||
 | 
			
		||||
        if (battleship.isDestroyed() && spatial.getLocalTranslation().getY() <= -0.6f) {
 | 
			
		||||
        if (battleship.isDestroyed() && spatial.getLocalTranslation().getY() <= SHIP_SINKING_REMOVE_THRESHOLD) {
 | 
			
		||||
            LOGGER.log(Level.INFO, "Ship removed {0}", spatial.getName());
 | 
			
		||||
            spatial.getParent().detachChild(spatial);
 | 
			
		||||
        } else if (battleship.isDestroyed()) {
 | 
			
		||||
            spatial.move(0, -0.05f * tpf, 0);
 | 
			
		||||
            spatial.move(0, SINKING_SPEED * tpf, 0);
 | 
			
		||||
        } else {
 | 
			
		||||
            // Update the time within the oscillation cycle
 | 
			
		||||
            time = (time + tpf) % cycle;
 | 
			
		||||
 
 | 
			
		||||
@@ -0,0 +1,3 @@
 | 
			
		||||
based on
 | 
			
		||||
https://opengameart.org/content/boss-battle-2-symphonic-metal
 | 
			
		||||
License: CC0 (public domain)
 | 
			
		||||
										
											Binary file not shown.
										
									
								
							@@ -0,0 +1,3 @@
 | 
			
		||||
based on
 | 
			
		||||
https://opengameart.org/content/game-over-instrumental
 | 
			
		||||
License: CC0 (public domain)
 | 
			
		||||
@@ -0,0 +1,3 @@
 | 
			
		||||
based on
 | 
			
		||||
https://opengameart.org/content/victory-fanfare-short
 | 
			
		||||
License: CC0 (public domain)
 | 
			
		||||
@@ -0,0 +1,3 @@
 | 
			
		||||
based on
 | 
			
		||||
https://opengameart.org/content/dark-intro
 | 
			
		||||
License: CC0 (public domain)
 | 
			
		||||
		Reference in New Issue
	
	Block a user