Project1

标题: 求VA默认战斗改进脚本:选人物行动时显示头像和播放声效 [打印本页]

作者: 迷糊的安安    时间: 2012-2-5 12:59
标题: 求VA默认战斗改进脚本:选人物行动时显示头像和播放声效
效果图如下

战斗界面轮到选择某一人物时,显示当前人物的画像,并播放声效。
声效从3~5个声效文件里随机选取。
也就是想造成轮到该人物选择行动时,人物会说话一样的效果,类似零之轨迹……
求此脚本制作……
作者: wyongcan2008    时间: 2012-2-5 12:59
本帖最后由 wyongcan2008 于 2012-2-5 14:58 编辑

楼主,你要的东西。。
角色脸图放在Graphics/Faces/face目录下,
命名为"face角色ID.png" ,比如"face1.png"就是一号角色战斗时显示的脸图

范例下载:点我下载
  1. $se名 = [*"A".."E"]
  2. class Scene_Battle < Scene_Base
  3.         alias start_actor_command_selection_old start_actor_command_selection
  4.         def start_actor_command_selection
  5.     start_actor_command_selection_old
  6.                 Audio.se_play("Audio/SE/" + BattleManager.actor.id.to_s + $se名[rand(4)] + ".ogg")
  7.                 @actorface = Sprite.new
  8.                 @actorface.bitmap = Bitmap.new("Graphics/Faces/face" + BattleManager.actor.id.to_s + ".png")
  9.                 @actorface.y = Graphics.height - @actor_command_window.height - @actorface.bitmap.height
  10.         end
  11.         alias prior_command_old prior_command
  12.         def prior_command
  13.                 @actorface.dispose if @actorface != nil && @actorface.disposed? != true
  14.                 prior_command_old
  15.         end
  16.         alias next_command_old next_command
  17.         def next_command
  18.                 @actorface.dispose if @actorface != nil && @actorface.disposed? != true
  19.                 next_command_old
  20.         end
  21. end
复制代码

作者: 迷糊的安安    时间: 2012-2-5 20:31
本帖最后由 迷糊的安安 于 2012-2-5 20:31 编辑

http://player.youku.com/player.php/sid/XMzQ5MjM3Nzg0/v.swf
= = 试用下来感觉真不错的说…… 只是录像软件太渣电脑又卡……
作者: huianda    时间: 2012-2-9 23:10
wyongcan2008 发表于 2012-2-5 12:59
楼主,你要的东西。。
角色脸图放在Graphics/Faces/face目录下,
命名为"face角色ID.png" ,比如"face1.png ...

试了一下,效果很不错。
作者: 流云伤逝    时间: 2012-2-10 11:03
这个滴。。。战斗会提示“未找到文件Audio/SE/1D.ogg”云云。。。这是怎么一回事呢= =。。。


‘‘

了解了~~感谢~~受益匪浅~~


──流云伤逝于2012-2-10 11:11补充以上内容’’
作者: 792377608    时间: 2012-2-10 19:59
这个脚本不错啊~赞{:nm_4:}
作者: 流云伤逝    时间: 2012-2-12 06:04
流云伤逝 发表于 2012-2-10 11:03
这个滴。。。战斗会提示“未找到文件Audio/SE/1D.ogg”云云。。。这是怎么一回事呢= =。。。

哦哦~~受教~~
作者: lijunli    时间: 2012-2-25 18:12
小白想问下,取消声效的播放得删掉哪几行
有个头像就够了
作者: xiaoshun23    时间: 2012-4-5 14:01
受教~~!!喜欢这样的模式!{:2_280:}
作者: 箭芒    时间: 2012-5-5 19:31
问问,怎样改变头像所处位置,图片太小漂了起来
作者: q854240045    时间: 2012-5-5 20:24
本帖最后由 q854240045 于 2012-5-5 20:25 编辑

这样改进
$se名 = [*"A".."E"]
class Scene_Battle < Scene_Base
        alias start_actor_command_selection_old start_actor_command_selection
        def start_actor_command_selection
    start_actor_command_selection_old
                Audio.se_play("Audio/SE/xyj")#xyj为音效名称,是固定的,可以自己换
                @actorface = Sprite.new
                @actorface.bitmap = Bitmap.new("Graphics/Faces/face" + BattleManager.actor.id.to_s + ".png")
                @actorface.y = Graphics.height - @actor_command_window.height - @actorface.bitmap.height + @actor_command_window.height - 25
        end
        alias prior_command_old prior_command
        def prior_command
                @actorface.dispose if @actorface != nil && @actorface.disposed? != true
                prior_command_old
        end
        alias next_command_old next_command
        def next_command
                @actorface.dispose if @actorface != nil && @actorface.disposed? != true
                next_command_old
        end
end

图像会在左下方,紧贴状态栏
角色的脸谱名称必须为 face角色ID.ogg



‘‘──q854240045于2012-5-5 20:26补充以下内容

$se名 = [*"A".."E"]
class Scene_Battle < Scene_Base
        alias start_actor_command_selection_old start_actor_command_selection
        def start_actor_command_selection
    start_actor_command_selection_old
                Audio.se_play("Audio/SE/xyj")
                @actorface = Sprite.new
                @actorface.bitmap = Bitmap.new("Graphics/Faces/face" + BattleManager.actor.id.to_s + ".png")
                @actorface.y = Graphics.height - @actor_command_window.height - @actorface.bitmap.height + @actor_command_window.height - 25
        end
        alias prior_command_old prior_command
        def prior_command
                @actorface.dispose if @actorface != nil && @actorface.disposed? != true
                prior_command_old
        end
        alias next_command_old next_command
        def next_command
                @actorface.dispose if @actorface != nil && @actorface.disposed? != true
                next_command_old
        end
end

这样改进
图像就不会飘了
改进脚本中 xyj 为音效名称 可以自己换
’’


‘‘──q854240045于2012-5-5 21:10补充以下内容

不想飘起来就这样  注:xyj为一音效,是固定的,自己改

$se名 = [*"A".."E"]
class Scene_Battle < Scene_Base
        alias start_actor_command_selection_old start_actor_command_selection
        def start_actor_command_selection
    start_actor_command_selection_old
                Audio.se_play("Audio/SE/xyj")
                @actorface = Sprite.new
                @actorface.bitmap = Bitmap.new("Graphics/Faces/face" + BattleManager.actor.id.to_s + ".png")
                @actorface.y = Graphics.height - @actor_command_window.height - @actorface.bitmap.height + @actor_command_window.height - 25
        end
        alias prior_command_old prior_command
        def prior_command
                @actorface.dispose if @actorface != nil && @actorface.disposed? != true
                prior_command_old
        end
        alias next_command_old next_command
        def next_command
                @actorface.dispose if @actorface != nil && @actorface.disposed? != true
                next_command_old
        end
end
’’
作者: 箭芒    时间: 2012-5-6 05:35
q854240045 发表于 2012-5-5 20:24
这样改进
$se名 = [*"A".."E"]
class Scene_Battle < Scene_Base

啊!成功了,多谢多谢
作者: 和风一人    时间: 2012-5-17 23:22
好东西。
作者: 紫菜豆腐煲    时间: 2012-7-22 02:39
撤退以后图会残留@q854240045
作者: coolmic    时间: 2012-12-13 04:22
同上啊,结束会残留怎么办啊?
作者: j433463    时间: 2012-12-13 06:26
有没有试过 LNX11 XPstylebattle for RPG Maker VX Ace 这个战斗系统脚本?
作者: Sion    时间: 2012-12-13 09:46
本帖最后由 Sion 于 2012-12-13 11:09 编辑

这个贴出来的脚本怎么复制老出错……脚本我放到附件里好了
这个音效脚本挺强大,技能物品的音效都可以自己添加的。
图像显示效果如图,坐标可以自己设置。
两个脚本的使用方法我已经让谷哥帮大家翻译好了……
范例下载 http://www.atelier-rgss.com/RGSS/Demos/ACE_Master_Demo.zip   
范例里有很多其他脚本,大家不需要的话无视就好了        

QQ截图20121213110731.png (258.22 KB, 下载次数: 24)

QQ截图20121213110731.png

QQ截图20121213110751.png (285.75 KB, 下载次数: 26)

QQ截图20121213110751.png

MOG_Actor_Picture_CM.rar

2.21 KB, 下载次数: 141

显示图像

MOG_Battle_Cry.rar

3.34 KB, 下载次数: 132

战斗音效






欢迎光临 Project1 (https://rpg.blue/) Powered by Discuz! X3.1