@876加几 发布了一个 多货币脚本,但是细心的小小周发现,这里并没有提供Window_Gold的
修改,导致在对话框中使用\g功能跳出的界面无法显示另一个货币,于是就有了这个小补丁~如果有人发布过就请无视掉吧~ - #==============================================================================# ■ Window_Gold#------------------------------------------------------------------------------# 显示金钱的窗口。#==============================================================================class Window_Gold < Window_Base #-------------------------------------------------------------------------- # ● 初始化窗口 #-------------------------------------------------------------------------- def initialize super(0, 0, 160, 64+32) self.contents = Bitmap.new(width - 32, height - 32) @gold_sp = $game_variables[8] @gold_sp_name = "灵魄" refresh end #-------------------------------------------------------------------------- # ● 刷新 #-------------------------------------------------------------------------- def refresh self.contents.clear cx = contents.text_size($data_system.words.gold).width cx_sp = contents.text_size(@gold_sp_name).width self.contents.font.color = normal_color self.contents.draw_text(4, 0, 120-cx-2, 32, $game_party.gold.to_s, 2) self.contents.font.color = system_color self.contents.draw_text(124-cx, 0, cx, 32, $data_system.words.gold, 2) self.contents.font.color = normal_color self.contents.draw_text(4, 0, 120-cx_sp-2, 64+32, @gold_sp.to_s, 2) self.contents.font.color = system_color self.contents.draw_text(124-cx_sp, 0, cx_sp, 64+32, @gold_sp_name.to_s, 2) endend复制代码
复制代码相信大家都看得懂吧...在@gold_sp = $game_variables[]中的数字“8”代表着第二货币的对应变量,而下面一行的@gold_sp_name = “”则代表着第二货币的名字...
本帖来自P1论坛作者天地有正气,因Project1站服务器在国外有时候访问缓慢不方便作者交流学习,经联系P1站长fux2同意署名转载一起分享游戏制作经验,共同为国内独立游戏作者共同创造良好交流环境,原文地址: https://rpg.blue/forum.php?mod=viewthread&tid=340834 若有侵权,发帖作者可联系底部站长QQ在线咨询功能删除,谢谢。 |