Skip to content

Commit

Permalink
added kalguur notification sound
Browse files Browse the repository at this point in the history
  • Loading branch information
zmilla93 committed Aug 9, 2024
1 parent f030f20 commit e909b76
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 2 deletions.
3 changes: 2 additions & 1 deletion src/main/java/com/slimtrade/core/managers/AudioManager.java
Original file line number Diff line number Diff line change
Expand Up @@ -50,10 +50,11 @@ public static void rebuildSoundList() {
private static void addDefaultSoundFiles() {
soundFiles.add(new Sound("Ping 1", Sound.SoundType.INBUILT));
soundFiles.add(new Sound("Ping 2", Sound.SoundType.INBUILT));
soundFiles.add(new Sound("Ping 3", Sound.SoundType.INBUILT));
soundFiles.add(new Sound("Blip 1", Sound.SoundType.INBUILT));
soundFiles.add(new Sound("Blip 2", Sound.SoundType.INBUILT));
soundFiles.add(new Sound("Blip 3", Sound.SoundType.INBUILT));
pingCount = 5;
pingCount = 6;

soundFiles.add(new Sound("Loot 1", Sound.SoundType.INBUILT));
soundFiles.add(new Sound("Loot 2", Sound.SoundType.INBUILT));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,7 @@ public class SettingsSaveFile extends AbstractSaveFile {
public SoundComponent outgoingSound = new SoundComponent(new Sound("Ping 1", Sound.SoundType.INBUILT), 50);
public SoundComponent itemIgnoredSound = new SoundComponent(new Sound("Blip 2", Sound.SoundType.INBUILT), 50);
public SoundComponent chatScannerSound = new SoundComponent(new Sound("Ping 2", Sound.SoundType.INBUILT), 50);
public SoundComponent kalguurSound = new SoundComponent(new Sound("Ping 3", Sound.SoundType.INBUILT), 50);
public SoundComponent playerJoinedAreaSound = new SoundComponent(new Sound("Blip 1", Sound.SoundType.INBUILT), 50);
public SoundComponent updateSound = new SoundComponent(new Sound("Blip 3", Sound.SoundType.INBUILT), 50);
public ArrayList<PriceThresholdData> priceThresholds = new ArrayList<>();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@ public void addScannerMessage(ChatScannerEntry entry, PlayerMessage playerMessag
}

public void addKalguurMessage() {
AudioManager.playSoundComponent(SaveManager.settingsSaveFile.data.incomingSound);
AudioManager.playSoundComponent(SaveManager.settingsSaveFile.data.kalguurSound);
addMessageMutual(new KalguurMessagePanel());
}

Expand Down
4 changes: 4 additions & 0 deletions src/main/java/com/slimtrade/gui/options/AudioOptionPanel.java
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ public class AudioOptionPanel extends AbstractOptionPanel implements ISavable {
private final AudioRowControls incomingTradeControls;
private final AudioRowControls outgoingTradeControls;
private final AudioRowControls chatScannerControls;
private final AudioRowControls kalguurControls;
private final AudioRowControls playerJoinedAreaControls;
private final AudioRowControls ignoredItemControls;
private final AudioRowControls updateAlertControls;
Expand All @@ -47,6 +48,7 @@ public AudioOptionPanel() {
incomingTradeControls = addRow("Incoming Trade");
outgoingTradeControls = addRow("Outgoing Trade");
chatScannerControls = addRow("Chat Scanner");
kalguurControls = addRow("Kalguur Shipments");
playerJoinedAreaControls = addRow("Player Joined Area");
ignoredItemControls = addRow("Ignored Item");
updateAlertControls = addRow("Update Alert");
Expand Down Expand Up @@ -147,6 +149,7 @@ public void save() {
SaveManager.settingsSaveFile.data.incomingSound = incomingTradeControls.getSoundComponent();
SaveManager.settingsSaveFile.data.outgoingSound = outgoingTradeControls.getSoundComponent();
SaveManager.settingsSaveFile.data.chatScannerSound = chatScannerControls.getSoundComponent();
SaveManager.settingsSaveFile.data.kalguurSound = kalguurControls.getSoundComponent();
SaveManager.settingsSaveFile.data.playerJoinedAreaSound = playerJoinedAreaControls.getSoundComponent();
SaveManager.settingsSaveFile.data.itemIgnoredSound = ignoredItemControls.getSoundComponent();
SaveManager.settingsSaveFile.data.updateSound = updateAlertControls.getSoundComponent();
Expand All @@ -158,6 +161,7 @@ public void load() {
incomingTradeControls.setSoundComponent(SaveManager.settingsSaveFile.data.incomingSound);
outgoingTradeControls.setSoundComponent(SaveManager.settingsSaveFile.data.outgoingSound);
chatScannerControls.setSoundComponent(SaveManager.settingsSaveFile.data.chatScannerSound);
kalguurControls.setSoundComponent(SaveManager.settingsSaveFile.data.kalguurSound);
playerJoinedAreaControls.setSoundComponent(SaveManager.settingsSaveFile.data.playerJoinedAreaSound);
ignoredItemControls.setSoundComponent(SaveManager.settingsSaveFile.data.itemIgnoredSound);
updateAlertControls.setSoundComponent(SaveManager.settingsSaveFile.data.updateSound);
Expand Down
Binary file added src/main/resources/audio/ping3.wav
Binary file not shown.

0 comments on commit e909b76

Please sign in to comment.