From 2eaa1c0235835e027e7c9e126eb73de2bd1fb8fa Mon Sep 17 00:00:00 2001
From: Salted <44394537+xian18@users.noreply.github.com>
Date: Sun, 23 Oct 2022 22:04:49 +0800
Subject: [PATCH] =?UTF-8?q?=E5=8A=A0=E8=BD=BD=20ogg=20=E9=9F=B3=E9=A2=91?=
=?UTF-8?q?=E6=96=87=E4=BB=B6=20#10?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
Readme.md | 3 ++-
js/plugins.js | 1 +
js/plugins/SF_LoadOgg.js | 27 +++++++++++++++++++++++++++
3 files changed, 30 insertions(+), 1 deletion(-)
create mode 100644 js/plugins/SF_LoadOgg.js
diff --git a/Readme.md b/Readme.md
index a2a9647..249f152 100644
--- a/Readme.md
+++ b/Readme.md
@@ -22,6 +22,7 @@
## 更新记录
+- **2022/10/23**;**咸鱼**;加载 ogg 音频文件 #10
- **2022/10/17**;**不明枪兵**;彩蛋完成
- **2022/10/16**;**不明枪兵**;推进剧情
- **2022/10/16**;**乐子人**;优化地图,确认内容丢失情况
@@ -51,4 +52,4 @@
- **2022/7/31**;**面具**;写入狗莉技能,等
- **2022/7/24**;**面具**;写入老王父女技能,等
- **2022/7/24**;**咸鱼**;添加`Test_Quests.json`来能启动测试。
-- 2022/7/23;面具;写入南宫三八技能,优化旧技能并整理装备类型
\ No newline at end of file
+- 2022/7/23;面具;写入南宫三八技能,优化旧技能并整理装备类型
diff --git a/js/plugins.js b/js/plugins.js
index ca4aeeb..adcda89 100644
--- a/js/plugins.js
+++ b/js/plugins.js
@@ -11,6 +11,7 @@ var $plugins =
{"name":"SF_Windows","status":true,"description":"window base for salted fish plugins","parameters":{}},
{"name":"SF_Scenes","status":true,"description":"scenes lib for salted fish plugins","parameters":{}},
{"name":"--------------------","status":true,"description":"------------------------------------------------------------","parameters":{}},
+{"name":"SF_LoadOgg","status":true,"description":"强制加载 ogg 音频文件","parameters":{}},
{"name":"SF_SkipLoadError","status":true,"description":"try to skip load errors","parameters":{}},
{"name":"SF_AutoUpdate","status":false,"description":"v1.0.0 - Automatically update the game.","parameters":{}},
{"name":"SF_WindowScrollCommand","status":true,"description":"v1.0 Allows you to scroll text in selected commands.","parameters":{}},
diff --git a/js/plugins/SF_LoadOgg.js b/js/plugins/SF_LoadOgg.js
new file mode 100644
index 0000000..0424c34
--- /dev/null
+++ b/js/plugins/SF_LoadOgg.js
@@ -0,0 +1,27 @@
+//=============================================================================
+// SaltedFish Plugins - Load Ogg Audio File
+// SF_LoadOgg.js
+//=============================================================================
+"use strict";
+var Imported = Imported || {};
+Imported.SF_LoadOgg = true;
+
+var SF_Plugins = SF_Plugins || {};
+
+//=============================================================================
+/*:
+ * @plugindesc force load ogg audio file
+ * @author SaltedFish
+ *
+ * @help
+ * just enable this plugin.
+ */
+//=============================================================================
+
+SF_Plugins.SF_LoadOgg = SF_Plugins.SF_LoadOgg || {};
+SF_Plugins.SF_LoadOgg.version = 1.0;
+
+SF_Plugins.SF_LoadOgg.AudioManager_audioFileExt = AudioManager.audioFileExt;
+AudioManager.audioFileExt = function () {
+ return ".ogg";
+};