设为首页收藏本站|繁體中文

Project1

 找回密码
 注册会员
搜索
查看: 1183|回复: 2
打印 上一主题 下一主题

[有事请教] 请问如何完全禁止音乐音效播放

[复制链接]

Lv3.寻梦者

梦石
0
星屑
2065
在线时间
209 小时
注册时间
2018-4-23
帖子
119
跳转到指定楼层
1
发表于 2023-3-4 12:53:43 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式
10星屑
请问如何完全禁止音乐音效播放  就是让程序跳过这一步 不执行

最佳答案

查看完整内容

下面的代码位于rpg_objects.js第10000行,它们是【事件指令】中那些音频控制的实现。 只要在任何一个函数开头用if()语句判定变量、开关等条件就能做到【满足/不满足某些条件时该指令才执行】。 注意这里只给出了事件指令,而“切换地图、战斗、乘降载具、菜单操作声效”等不受控制,如有需要请进一步修改AudioManager下的四个playXxx函数。 // Play BGM Game_Interpreter.prototype.command241 = function() { AudioManager.pl ...

Lv4.逐梦者

梦石
0
星屑
5637
在线时间
411 小时
注册时间
2021-12-4
帖子
447
2
发表于 2023-3-4 12:53:44 | 只看该作者
下面的代码位于rpg_objects.js第10000行,它们是【事件指令】中那些音频控制的实现。
只要在任何一个函数开头用if()语句判定变量、开关等条件就能做到【满足/不满足某些条件时该指令才执行】。
注意这里只给出了事件指令,而“切换地图、战斗、乘降载具、菜单操作声效”等不受控制,如有需要请进一步修改AudioManager下的四个playXxx函数。
JAVASCRIPT 代码复制
  1. // Play BGM
  2. Game_Interpreter.prototype.command241 = function() {
  3.     AudioManager.playBgm(this._params[0]);
  4.     return true;
  5. };
  6.  
  7. // Fadeout BGM
  8. Game_Interpreter.prototype.command242 = function() {
  9.     AudioManager.fadeOutBgm(this._params[0]);
  10.     return true;
  11. };
  12.  
  13. // Save BGM
  14. Game_Interpreter.prototype.command243 = function() {
  15.     $gameSystem.saveBgm();
  16.     return true;
  17. };
  18.  
  19. // Resume BGM
  20. Game_Interpreter.prototype.command244 = function() {
  21.     $gameSystem.replayBgm();
  22.     return true;
  23. };
  24.  
  25. // Play BGS
  26. Game_Interpreter.prototype.command245 = function() {
  27.     AudioManager.playBgs(this._params[0]);
  28.     return true;
  29. };
  30.  
  31. // Fadeout BGS
  32. Game_Interpreter.prototype.command246 = function() {
  33.     AudioManager.fadeOutBgs(this._params[0]);
  34.     return true;
  35. };
  36.  
  37. // Play ME
  38. Game_Interpreter.prototype.command249 = function() {
  39.     AudioManager.playMe(this._params[0]);
  40.     return true;
  41. };
  42.  
  43. // Play SE
  44. Game_Interpreter.prototype.command250 = function() {
  45.     AudioManager.playSe(this._params[0]);
  46.     return true;
  47. };
  48.  
  49. // Stop SE
  50. Game_Interpreter.prototype.command251 = function() {
  51.     AudioManager.stopSe();
  52.     return true;
  53. };
回复

使用道具 举报

Lv3.寻梦者

梦石
0
星屑
2065
在线时间
209 小时
注册时间
2018-4-23
帖子
119
3
 楼主| 发表于 2023-3-5 20:44:47 | 只看该作者
谢谢 大哥
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册会员

本版积分规则

拿上你的纸笔,建造一个属于你的梦想世界,加入吧。
 注册会员
找回密码

站长信箱:[email protected]|手机版|小黑屋|无图版|Project1游戏制作

GMT+8, 2024-5-21 19:17

Powered by Discuz! X3.1

© 2001-2013 Comsenz Inc.

快速回复 返回顶部 返回列表