查看: 1454|回复: 3

[有事请教] 怎样删除菜单里的血量和技能呀

[复制链接]
梦石
0
星屑
466
在线时间
29 小时
注册时间
2023-8-12
回帖
26
发表于 2023-11-14 09:25:05 | 显示全部楼层 |阅读模式

加入我们,或者,欢迎回来。

您需要 登录 才可以下载或查看,没有账号?注册会员

×
想做一个横版2D解谜游戏,但是菜单不知道怎么改,想把没有用的血量和技能删掉。
或者有什么可以商用的菜单UI插件也可以,可以改一下菜单的样子
梦石
2
星屑
8479
在线时间
463 小时
注册时间
2021-12-4
回帖
486

MZ评测员

发表于 2023-11-14 10:11:05 | 显示全部楼层
Window_Base.prototype.drawActorSimpleStatus = function(actor, x, y, width) {
    var lineHeight = this.lineHeight();
    var x2 = x + 180;
    var width2 = Math.min(200, width - 180 - this.textPadding());
    this.drawActorName(actor, x, y); // 角色名
    this.drawActorLevel(actor, x, y + lineHeight * 1); // 角色等级
    this.drawActorIcons(actor, x, y + lineHeight * 2); // 角色状态图标
    this.drawActorClass(actor, x2, y); // 角色职业
    this.drawActorHp(actor, x2, y + lineHeight * 1, width2); // 角色生命
    this.drawActorMp(actor, x2, y + lineHeight * 2, width2); // 角色魔力
}; // 以上所有 this.drawActorXxx 都可以整行删掉来取消绘制部分内容

Window_MenuCommand.prototype.needsCommand = function(name) {
    var flags = $dataSystem.menuCommands;
    if (flags) {
        switch (name) {
        case 'item': return flags[0];
        case 'skill': return false; // false表示无视数据库设置强制删掉某个按钮,true表示无视数据库设置强制显示某个按钮
        case 'equip': return flags[2];
        case 'status': return flags[3];
        case 'formation': return flags[4];
        case 'save': return flags[5];
        }
    }
    return true;
};
回复

使用道具 举报

梦石
0
星屑
466
在线时间
29 小时
注册时间
2023-8-12
回帖
26
 楼主| 发表于 2023-11-14 10:38:06 | 显示全部楼层
小秋橙 发表于 2023-11-14 10:11
Window_Base.prototype.drawActorSimpleStatus = function(actor, x, y, width) {
    var lineHeight = th ...

谢谢,但这个该怎么用哇,是脚本吗?

点评

另存为js文件塞到plugins文件夹里然后在编辑器里作为插件开启应该就好了?  发表于 2023-11-14 22:24
回复

使用道具 举报

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

本版积分规则

Powered by Discuz! X5.0 © 2001-2026 Discuz! Team.

在本版发帖返回顶部