aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorstonedDiscord <10584181+stonedDiscord@users.noreply.github.com>2020-09-07 19:43:11 +0200
committerstonedDiscord <10584181+stonedDiscord@users.noreply.github.com>2020-09-07 19:43:11 +0200
commit2c3e9fa5c310e25d67b0227e849e4b98572296e5 (patch)
tree900f413c2467b1056e9f85699f1b702e770a5290
parentc78c998a91d57fd5c80c4ac23753ffccd931c9cd (diff)
stop the CH spam and have a music list
-rw-r--r--webAO/client.js15
-rw-r--r--webAO/music.js60
2 files changed, 71 insertions, 4 deletions
diff --git a/webAO/client.js b/webAO/client.js
index 7f9b394..64bdd38 100644
--- a/webAO/client.js
+++ b/webAO/client.js
@@ -10,6 +10,7 @@ import { escapeChat, encodeChat, prepChat, safe_tags } from './encoding.js';
// Load some defaults for the background and evidence dropdowns
import character_arr from "./characters.js";
+import music_arr from "./music.js";
import background_arr from "./backgrounds.js";
import evidence_arr from "./evidence.js";
import sfx_arr from "./sounds.js";
@@ -402,7 +403,8 @@ class Client extends EventEmitter {
this.sendServer(`HI#${hdid}#%`);
this.sendServer(`ID#webAO#webAO#%`);
- this.checkUpdater = setInterval(() => this.sendCheck(), 5000);
+ if (mode !== "replay")
+ this.checkUpdater = setInterval(() => this.sendCheck(), 5000);
}
/**
@@ -1383,7 +1385,7 @@ class Client extends EventEmitter {
* @param {Array} args packet arguments
*/
handleRM(_args) {
- this.sendSelf("SM#stop.mp3#%");
+ this.sendSelf("SM#" + music_arr.join("#") + "#%");
}
/**
@@ -1391,9 +1393,14 @@ class Client extends EventEmitter {
* @param {Array} args packet arguments
*/
handleRD(_args) {
+ this.sendSelf("BN#gs4#%");
this.sendSelf("DONE#%");
- document.getElementById("client_ooclog").innerHTML = "";
-
+ const ooclog = document.getElementById("client_ooclog");
+ ooclog.innerHTML = "";
+ ooclog.readOnly = false;
+
+ document.getElementById("client_oocinput").style.display = "none";
+ document.getElementById("client_replaycontrols").style.display = "inline-block";
}
}
diff --git a/webAO/music.js b/webAO/music.js
new file mode 100644
index 0000000..7f961dd
--- /dev/null
+++ b/webAO/music.js
@@ -0,0 +1,60 @@
+export default [
+ "01_Turnabout_Courtroom_-_Prologue.Mp3",
+ "113 Confrontation ~ Presto 2009.Mp3",
+ "114 Pursuit(Miles).Mp3",
+ "3Dkh.Mp3",
+ "Announce The Truth (Aa).Mp3",
+ "Announce The Truth (Aj).Mp3",
+ "Announce The Truth (Jfa).Mp3",
+ "Announce The Truth (Miles).Mp3",
+ "Announce The Truth (T&T).Mp3",
+ "Crises Of Fate.Mp3",
+ "Forgotten Legend.Mp3",
+ "Ghost Trick - 4 Minutes Before Death.Mp3",
+ "Ghost Trick - Countdown.Mp3",
+ "Ghost Trick - The World Of The Dead.Mp3",
+ "Godot - The Fragrance Of Dark Coffee.Mp3",
+ "Great Revival ~ Franziska Von Karma.Mp3",
+ "Great Revival ~ Miles Edgeworth.Mp3",
+ "Hotline Of Fate.Mp3",
+ "Interesting People.Mp3",
+ "Logic_And_Trick.Mp3",
+ "Luke Atmey ~ I Just Want Love.Mp3",
+ "Mystery Skulls - Ghost.Mp3",
+ "Mystery Skulls - Money.Mp3",
+ "Noisy People.Mp3",
+ "Objectiom(Aj).Mp3",
+ "Objection (Aa).Mp3",
+ "Objection (Jfa).Mp3",
+ "Objection (Miles).Mp3",
+ "Objection (T&T).Mp3",
+ "Others ~ Guilty Love.Mp3",
+ "Prelude(Aa).Mp3",
+ "Prelude(Aj).Mp3",
+ "Pursuit (Aa) - Variation.Mp3",
+ "Pursuit (Aa).Mp3",
+ "Pursuit (Aj).Mp3",
+ "Pursuit (Ds).Mp3",
+ "Pursuit (Jfa) - Variation.Mp3",
+ "Pursuit (Jfa).Mp3",
+ "Pursuit (T&T) - Variation.Mp3",
+ "Pursuit (T&T).Mp3",
+ "Pursuit ~ I Want To Find The Truth (Orchestra).Mp3",
+ "Questioning Aa (Allegro).Mp3",
+ "Questioning Aa (Moderato).Mp3",
+ "Questioning Aj (Allegro).Mp3",
+ "Questioning Aj (Moderato).Mp3",
+ "Questioning Jfa (Allegro).Mp3",
+ "Questioning Jfa (Moderato).Mp3",
+ "Questioning T&T (Allegro).Mp3",
+ "Questioning T&T (Moderato).Mp3",
+ "Sin.Mp3",
+ "Speak Up, Pup!.Mp3",
+ "Suspense (Aa).Mp3",
+ "The Great Truth Burglar.Mp3",
+ "Trans.Mp3",
+ "Trial (Aa).Mp3",
+ "Trial (Aj).Mp3",
+ "Trial (Miles).Mp3",
+ "~Stop.Mp3",
+];