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

Project1

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

[有事请教] 请教大佬SV模式的情况如何调整角色Y轴的间隔【已解决】

[复制链接]

Lv2.观梦者

梦石
0
星屑
478
在线时间
50 小时
注册时间
2023-3-4
帖子
22
跳转到指定楼层
1
发表于 2023-7-16 12:45:31 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式

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

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

x
本帖最后由 rmmzxs 于 2023-7-16 16:40 编辑

角色与角色之间的上下间隔,请教各位大佬,应该怎么调整,有使用VS全家桶插件,只找到一个调整整体XY坐标的设置,没有找到角色之间间隔调整的设置

Lv3.寻梦者

梦石
0
星屑
4280
在线时间
1084 小时
注册时间
2014-5-9
帖子
163
2
发表于 2023-7-16 15:31:13 | 只看该作者
Visu_1_BattleCore 中 Actor Battler Settings 选项中 JS:Home Position
// Declare Constants
const sprite = this;
const actor = this._actor;
const index = arguments[0];

// Make Calculations
let x = Math.round((Graphics.width / 2) + 192)
x -= Math.floor((Graphics.width - Graphics.boxWidth) / 2);
x += index * 32;
let y = (Graphics.height - 200) - ($gameParty.maxBattleMembers() * 48);
y -= Math.floor((Graphics.height - Graphics.boxHeight) / 2);
y += index * 48;

// Home Position Offsets
const offsetNote = /<SIDEVIEW HOME OFFSET:[ ]([\+\-]\d+),[ ]([\+\-]\d+)>/i;
const xOffsets = actor.traitObjects().map((obj) => (obj && obj.note.match(offsetNote) ? Number(RegExp.$1) : 0));
const yOffsets = actor.traitObjects().map((obj) => (obj && obj.note.match(offsetNote) ? Number(RegExp.$2) : 0));
x = xOffsets.reduce((r, offset) => r + offset, x);
y = yOffsets.reduce((r, offset) => r + offset, y) - 800;

// Set Home Position
// 设置角色位置
if(index == 0){x=640,y=750};
if(index == 1){x=450,y=750};
if(index == 2){x=450,y=900};
if(index == 3){x=450,y=600};
if(index == 4){x=600,y=280};
this.setHome(x, y);
回复 支持 反对

使用道具 举报

Lv2.观梦者

梦石
0
星屑
478
在线时间
50 小时
注册时间
2023-3-4
帖子
22
3
 楼主| 发表于 2023-7-16 16:39:49 | 只看该作者
a965645462 发表于 2023-7-16 15:31
Visu_1_BattleCore 中 Actor Battler Settings 选项中 JS:Home Position
// Declare Constants
const spri ...

非常感谢大佬,明白了
回复 支持 反对

使用道具 举报

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

本版积分规则

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

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

GMT+8, 2024-5-19 11:09

Powered by Discuz! X3.1

© 2001-2013 Comsenz Inc.

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