本篇教程由作者设定使用 CC BY-NC-SA 协议。
一、概况
基于1.20.1版本,没用扩展。不是我不想用,扩展都还在1.19.2
(一)效果展示
先向地上插几支箭,然后副手算盘调节威力(影响伤害、消耗),主手持造物(或另外俩施法物品)连续右键两次目标,将地上的箭拔起、射出,造成伤害。
(二)基本原理
箭的伤害与其飞行速度成正比,箭插到地上后,第一次右键施法,闪现使其腾空,在箭落地前第二次右键施法,多次(副手算盘数即次数)驱动将箭加速,即可造成大量伤害。
(三)我对原理不感兴趣,直接告诉我怎么用
请安装Ducky Peripherals或HexParse,将法术导入到核心,具体方法请查阅对应模组说明,此处不赘述。
Ducky Perihperals版:
[{"startDir":"NORTH_EAST","angles":"qaq"},{"startDir":"NORTH_EAST","angles":"dd"},{"startDir":"SOUTH_EAST","angles":"aqaae"},{"startDir":"NORTH_EAST","angles":"eeeeewaqaawd"},{"startDir":"SOUTH_EAST","angles":"aqaa"},{"startDir":"NORTH_WEST","angles":"deeed"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"EAST","angles":"aadaa"},{"startDir":"EAST","angles":"wq"},{"startDir":"NORTH_EAST","angles":"wqaqw"},{"startDir":"SOUTH_EAST","angles":"aqaawawaaawawaaawaaaaeddddddddddddddddd"},{"startDir":"SOUTH_EAST","angles":"e"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"WEST","angles":"qqq"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"EAST","angles":"aadaa"},{"startDir":"EAST","angles":"adeeed"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"EAST","angles":"aawdd"},{"startDir":"NORTH_EAST","angles":"dd"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"NORTH_EAST","angles":"qaq"},{"startDir":"EAST","angles":"aa"},{"startDir":"NORTH_EAST","angles":"qaq"},{"startDir":"EAST","angles":"wa"},{"startDir":"EAST","angles":"weaqa"},{"startDir":"EAST","angles":"aa"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"NORTH_WEST","angles":"wddw"},{"startDir":"EAST","angles":"aadaa"},{"startDir":"NORTH_EAST","angles":"wqaqw"},{"startDir":"NORTH_EAST","angles":"wdedw"},{"startDir":"NORTH_EAST","angles":"deddw"},{"startDir":"SOUTH_EAST","angles":"waqaw"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_WEST","angles":"edqde"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"EAST","angles":"aqqqqq"},{"startDir":"SOUTH_WEST","angles":"edqde"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"NORTH_WEST","angles":"eqqwawqaaw"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"WEST","angles":"qqq"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"NORTH_EAST","angles":"qeewdweddw"},{"startDir":"SOUTH_EAST","angles":"aqaawa"},{"startDir":"NORTH_WEST","angles":"deeed"},{"startDir":"SOUTH_EAST","angles":"aqaawd"},{"startDir":"SOUTH_EAST","angles":"e"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"WEST","angles":"qqq"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"NORTH_EAST","angles":"qeewdweddw"},{"startDir":"SOUTH_EAST","angles":"aqaa"},{"startDir":"NORTH_WEST","angles":"deeed"},{"startDir":"NORTH_EAST","angles":"qeewdweddw"},{"startDir":"SOUTH_EAST","angles":"aqaaw"},{"startDir":"NORTH_WEST","angles":"deeed"},{"startDir":"SOUTH_WEST","angles":"awqqqwaqw"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"NORTH_EAST","angles":"qeewdweddw"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"EAST","angles":"aadaa"},{"startDir":"SOUTH_EAST","angles":"aqaawa"},{"startDir":"NORTH_WEST","angles":"deeed"},{"startDir":"SOUTH_EAST","angles":"aqaaw"},{"startDir":"NORTH_WEST","angles":"wddw"},{"startDir":"SOUTH_EAST","angles":"aqaawa"},{"startDir":"EAST","angles":"aawdd"},{"startDir":"NORTH_WEST","angles":"wqaeaqw"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"NORTH_WEST","angles":"eqqwawqaaw"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"EAST","angles":"aadaa"},{"startDir":"SOUTH_EAST","angles":"deaqq"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"EAST","angles":"eee"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"WEST","angles":"qqq"},{"startDir":"SOUTH_WEST","angles":"aqdee"},{"startDir":"EAST","angles":"eee"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"awdd"},{"startDir":"SOUTH_EAST","angles":"deaqq"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"EAST","angles":"eee"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"EAST","angles":"aadaa"},{"startDir":"SOUTH_EAST","angles":"deaqq"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"EAST","angles":"eee"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"WEST","angles":"qqq"},{"startDir":"SOUTH_EAST","angles":"aqaawa"},{"startDir":"SOUTH_WEST","angles":"awqqqwaq"},{"startDir":"EAST","angles":"eee"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"awdd"},{"startDir":"SOUTH_EAST","angles":"deaqq"}]
HexParse版:
get_caster, entity_pos/eye, num_10, zone_entity/not_living, num_0, index, comment_getNearestArrow
duplicate, get_entity_velocity, abs, num_0.05, greater, comment_checkIfArrowInAir
(
duplicate,singleton, comment_formList:arrow_0
swap,entity_pos/foot, comment_arrowPosition
get_caster, entity_pos/eye, get_caster, get_entity_look, raycast/entity, entity_pos/eye, comment_targetPosition
sub, duplicate, abs, div, num_-1, mul, comment_calculateIdentityVector
append, comment_formList:arrow_0.identityVector_1
read, append, comment_formList:arrow_0.identityVector_1.counter_2.readFromAbacus
write/local, comment_cacheList:arrow_0.identityVector_1.counter_2
(
read/local, num_2, index, num_0.5, greater comment_checkCounterValue
(
read/local, num_0, index, read/local, num_1, index, add_motion, comment_impulse
read/local,
duplicate, num_2, index, num_1, sub, num_2, swap, replace,
write/local, comment_counterDecrement
duplicate, eval comment_selfDuplicateAndLoop
) comment_runTheseWhenCounterWithinLimit
(halt) comment_exitWhenCounterReachLimit
if, eval
)
duplicate, eval comment_duplicateOnce
) comment_runTheseWhenArrowInAir
(num_2, blink) comment_blinkWhenArrowNotInAir
if, eval
导入后将核心写入施法物品。算盘调数字后放副手,数字越大伤害越高;脚边插箭;主手拿施法物品,右键双击敌人即可攻击。
二、具体实现:
有的地方照顾新手讲得细一点,很多是我自己整了好久弄明白的,老手跳过即可。
强烈建议使用HexParse进行法术的编辑、调试,十分方便!下面以HexParse格式的代码进行说明(为便于观看,以下代码去掉了注释,想看注释见上面这坨):
(一)获取箭实体
get_caster, entity_pos/eye, num_10, zone_entity/not_living, num_0, index,
此处要注意使用entity_pos/eye,不要用entity_pos/foot。第一次施法时,箭向上闪现2格,更接近眼睛的位置。此处会获取最近的箭实体,当有多支箭插在脚边时,如果用eneity_pos/foot会导致第二次施法再获取脚边的箭,而不是空中的箭。
(二)判断箭是否在空中
duplicate, get_entity_velocity, abs, num_0.05, greater,
(
...
)
(num_2, blink)
if, eval
一个三元运算符,如果箭的速度大于0.05,执行第一个括号里的语句,否则闪现2格。
关于闪现2格:F3+B观察可知,箭竖直插到地上后,其“视线”是向上的,斜插在地上的箭,视线也是斜向上的。闪现只能指定距离无法指定方向,直接向实体视线方向闪,箭的这一特性正好适用,即使斜插在地上,闪两格也足够拔出来了。
关于速度判断:箭向上闪现2格后,本tick速度为(0, 0, 0),然后会因悬空开始受重力影响,有0.05的竖直向下的加速度,即(如果没有其他外力)1gt后速度变为(0, -0.05, 0),并向下位移0.05单位长度,2gt后速度为(0, -0.1, 0)……
又由模组配置文件:
[Cooldowns]
#Cooldown in ticks of a cypher
#Range: > 0
cypherCooldown = 8
#Cooldown in ticks of a trinket
#Range: > 0
trinketCooldown = 5
#Cooldown in ticks of a artifact
#Range: > 0
artifactCooldown = 3
可知两次使用施法物品至少要等待3ticks,哪怕改了配置文件,再考虑人类手速极限,大概率极少有人能在0.05秒内连续按两次右键进行施法,这个数值应该足够小了。
综上,如果箭的速度大于0.05,则认为箭在空中,进而运行循环驱动,否则,闪现2格。
关于此判断的必要性:箭闪现后直接驱动似乎是一个更简洁直观的方案,将箭插到地上后,直接右键一次敌人,完成攻击。但经测试,这么做会导致在箭的闪现和驱动在同一个tick里,在这1gt的时间里,或许对箭进行驱动时,箭还没有完全闪现出来(此处是个人猜测),驱动3轴方向产生的驱动力(Motion)会减少相当大部分,且各轴减少的量、比例都随机且相互独立,导致箭几乎完全没有准头(除非箭与敌人的x轴或z轴很接近),又因驱动力大量丢失,实质上也浪费了大量水晶粉。理论上,让闪现和驱动间有1gt的间隔就够了,但咒法学本体似乎并没有这个功能,于是此处将闪现与驱动手动间隔开,即第一次施法闪现,第二次施法驱动,也就需要进行这个判断了。
(三)必要数据写入缓存(渡鸦之思)
duplicate,singleton,
swap,entity_pos/foot,
get_caster, entity_pos/eye, get_caster, get_entity_look, raycast/entity, entity_pos/eye,
sub, duplicate, abs, div, num_-1, mul,
append,
read, append,
write/local,
这几句实现了将以下列表,共3个变量,写入缓存(渡鸦之思),以备后续循环中调用:
[箭实体,从箭的坐标指向攻击目标头部坐标的单位向量,计数器(从副手算盘读取)]
渡鸦之思能存变量,数组也是变量,所以渡鸦之思可以通过保存一个数组很方便地保存一堆全局变量。
(四)驱动循环
为便于理解,此处使用【1】【2】代表括号及其内部的内容
(
read/local, num_2, index, num_0.5, greater
(
read/local, num_0, index, read/local, num_1, index, add_motion,
read/local,
duplicate, num_2, index, num_1, sub, num_2, swap, replace,
write/local,
duplicate, eval
) // 【2】
(halt)
if, eval
) // 【1】
duplicate, eval
逐层分析:
1. 先看最外层,结构如下:
【1】
duplicate, eval
duplicate将【1】中的内容复制一份,此时栈中内容如下:
【1】
【1】
eval运行了栈顶的【1】,此时栈中只剩一个【1】。
2. 再看eval运行过程:
【1】包含内容如下:
read/local, num_2, index, num_0.5, greater
【2】
(halt)
if, eval
逻辑很简单:如果计数器大于0.5,运行【2】,否则退出
3. 再看【2】:
read/local, num_0, index, read/local, num_1, index, add_motion, //【2.1】
read/local,
duplicate, num_2, index, num_1, sub, num_2, swap, replace, //【2.2】
write/local,
duplicate, eval //【2.3】
【2.1】:从渡鸦之思读取箭,读取单位向量,驱动一次
【2.2】:从渡鸦之思读取计数器,减一,写回渡鸦之思
【2.3】:复制,执行。运行此“复制”时,栈中只有一个【1】,所以运行后栈中又变为:
【1】
【1】
“执行”会执行第一个【1】,由此进行循环:栈顶的【1】因被执行而出栈,此时栈内又只有一个【1】,执行过程中,如果计数器仍大于0.5,继续复制栈顶的【1】,执行……
关于使用单位向量进行驱动:根据计算,使用单位向量循环驱动是最省水晶粉的,简证如下:
不妨设我们所需驱动力总量为n,根据官方说明书计算耗魔,可选方案如下:
驱动一次,驱动力为n,耗魔n^2
驱动n次,驱动力为1,耗魔n*1 + 1^2*n = 2n(其实是2n-1,为便于计算忽略,下同)
驱动m次,驱动力为n/m,耗魔m*1+(n/m)^2*m = m + n^2 / m
第一个方案直接放弃,供不起
第三个方案,根据(x+y)/2 >= √xy, m, n^2/m 分别带入 x, y, 解得 m + n^2/m >= 2n
综上,选第二个方案,即单位向量驱动n次
三、要点:
(一)使用建议
计算好伤害的话,打BOSS一支箭就够了。算盘数值、消耗与伤害表:
算盘数值 | 紫水晶粉消耗 | 无力量 | 力量I | 力量II | 力量III | 力量IV | 力量V |
1 | 6 | 2点() | 3点() | 3.5点() | 4点() | 4.5点() | 5点() |
2 | 7 | 4点() | 6点() | 7点() | 8点() | 9点() | 10点() |
10 | 15 | 20点() | 30点( × 15) | 35点( × 17.5) | 40点( × 20) | 45点( × 22.5) | 50点( × 25) |
100 | 105 | 200点( × 100) | 300点( × 150) | 350点( × 175) | 400点( × 200) | 450点( × 225) | 500点( × 250) |
1000 | 1005 | 2000点( × 1000) | 3000点( × 1500) | 3500点( × 1750) | 4000点( × 2000) | 4500点( × 2250) | 5000点( × 2500) |
n | n+5 | 2n | 3n | 3.5n | 4n | 4.5n | 5n |
谁说咱们咒法学法师没伤害?
射出的箭吃所用弓的力量、火失、冲击加成,并被视作玩家射出的。强烈建议力量V,同等消耗造成的伤害是白板的2.5倍(参考:力量附魔)。
关于伤害:实际测试下来,伤害很稳定,还没出现低于表中伤害的情况。比如秒500生命的监守者,算盘数值100,力量V的弓恰好可以秒掉,造成的伤害通常是500或501,运气好暴击了是750,从未出现过低于500的情况。
关于紫水晶粉消耗:实际消耗要比表中高0.01左右,比如算盘数值1000时,实际紫水晶粉消耗可能是1005.01或1005.02,可忽略不计。
无限附魔也最好带上,避免刚把箭射在地上,又被自己捡起来。
(二)注意事项
严格遵守安全规范:施法时请务必不要站在箭和攻击目标中间,如果插到地上的箭不是竖直的,离这箭再远一点。猜我怎么知道的?
施法时,确保插到地上的箭和玩家在同一水平面。
较高的算盘数值对电脑性能有一定的要求,I7-12650H+16G游戏本,分配8G内存,测试1000的算盘数值,即将箭驱动1000次,能明显感受到掉帧、卡顿。
(三)其他
此法术实际能耗并不少,个人使用定位是打BOSS之类的高血量目标,所以箭的速度会很快,再加上模组本身的施法距离就32格,且箭瞄准的是目标的眼部,即使受重力影响下降一些也没关系……总之,并没有做抵消箭飞行过程中重力的部分。如果想完善这部分,请自行研究参考资料中实体运动相关内容。
参考资料
如果你想用驱动做出各种骚操作,强烈建议参看Sinofuma的驱动详解,弄清楚原理:
https://www.bilibili.com/video/BV16T411f7gP
实体运动相关原理,可参考:
https://lovexyn0827.space/mcdocs/docs/
分支、循环的写法,可参考这篇,注意作者所用的版本还没有三元运算符:
https://www.bilibili.com/opus/755322904611127351
关于“箭”的数据、特性等,可参考:
https://minecraft.fandom.com/zh/wiki/%E7%AE%AD
附,1.19.2
考虑很多人还在用1.19.2,又写了个1.19.2版本的,没严格测试,仅供交流参考:
Ducky Perihperals版:
[{"startDir":"NORTH_EAST","angles":"qaq"},{"startDir":"EAST","angles":"aa"},{"startDir":"NORTH_WEST","angles":"qqqqqew"},{"startDir":"NORTH_EAST","angles":"waaw"},{"startDir":"SOUTH_EAST","angles":"aqaae"},{"startDir":"NORTH_EAST","angles":"eeeeewaqaawd"},{"startDir":"SOUTH_EAST","angles":"aqaa"},{"startDir":"NORTH_WEST","angles":"deeed"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"EAST","angles":"aadaa"},{"startDir":"EAST","angles":"aa"},{"startDir":"EAST","angles":"qeeeee"},{"startDir":"SOUTH_EAST","angles":"a"},{"startDir":"EAST","angles":"aawdd"},{"startDir":"SOUTH_EAST","angles":"a"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"NORTH_EAST","angles":"qaq"},{"startDir":"EAST","angles":"aa"},{"startDir":"EAST","angles":"qeeeee"},{"startDir":"SOUTH_EAST","angles":"a"},{"startDir":"EAST","angles":"aawdd"},{"startDir":"SOUTH_EAST","angles":"a"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"e"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"WEST","angles":"qqq"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"EAST","angles":"aadaa"},{"startDir":"EAST","angles":"adeeed"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"EAST","angles":"aawdd"},{"startDir":"NORTH_EAST","angles":"dd"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"NORTH_EAST","angles":"qaq"},{"startDir":"EAST","angles":"aa"},{"startDir":"NORTH_EAST","angles":"qaq"},{"startDir":"EAST","angles":"wa"},{"startDir":"EAST","angles":"weaqa"},{"startDir":"EAST","angles":"aa"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"NORTH_WEST","angles":"wddw"},{"startDir":"EAST","angles":"aadaa"},{"startDir":"NORTH_EAST","angles":"wqaqw"},{"startDir":"NORTH_EAST","angles":"wdedw"},{"startDir":"NORTH_EAST","angles":"deddw"},{"startDir":"SOUTH_EAST","angles":"waqaw"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_WEST","angles":"edqde"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"EAST","angles":"aqqqqq"},{"startDir":"SOUTH_WEST","angles":"edqde"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"NORTH_WEST","angles":"eqqwawqaaw"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"WEST","angles":"qqq"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"NORTH_EAST","angles":"qeewdweddw"},{"startDir":"SOUTH_EAST","angles":"aqaawa"},{"startDir":"NORTH_WEST","angles":"deeed"},{"startDir":"SOUTH_EAST","angles":"aqaawd"},{"startDir":"SOUTH_EAST","angles":"e"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"WEST","angles":"qqq"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"NORTH_EAST","angles":"qeewdweddw"},{"startDir":"SOUTH_EAST","angles":"aqaa"},{"startDir":"NORTH_WEST","angles":"deeed"},{"startDir":"NORTH_EAST","angles":"qeewdweddw"},{"startDir":"SOUTH_EAST","angles":"aqaaw"},{"startDir":"NORTH_WEST","angles":"deeed"},{"startDir":"SOUTH_WEST","angles":"awqqqwaqw"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"NORTH_EAST","angles":"qeewdweddw"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"EAST","angles":"aadaa"},{"startDir":"SOUTH_EAST","angles":"aqaawa"},{"startDir":"NORTH_WEST","angles":"deeed"},{"startDir":"SOUTH_EAST","angles":"aqaaw"},{"startDir":"NORTH_WEST","angles":"wddw"},{"startDir":"SOUTH_EAST","angles":"aqaawa"},{"startDir":"EAST","angles":"aawdd"},{"startDir":"NORTH_WEST","angles":"wqaeaqw"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"NORTH_WEST","angles":"eqqwawqaaw"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"EAST","angles":"aadaa"},{"startDir":"SOUTH_EAST","angles":"deaqq"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"EAST","angles":"eee"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"WEST","angles":"qqq"},{"startDir":"SOUTH_WEST","angles":"aqdee"},{"startDir":"EAST","angles":"eee"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"awdd"},{"startDir":"SOUTH_EAST","angles":"deaqq"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"EAST","angles":"eee"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"EAST","angles":"aadaa"},{"startDir":"SOUTH_EAST","angles":"deaqq"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"EAST","angles":"eee"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"WEST","angles":"qqq"},{"startDir":"SOUTH_EAST","angles":"aqaawaa"},{"startDir":"SOUTH_WEST","angles":"awqqqwaq"},{"startDir":"EAST","angles":"eee"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"adadaqadadaaww"},{"startDir":"SOUTH_EAST","angles":"awdd"},{"startDir":"SOUTH_EAST","angles":"deaqq"}]
HexParse版:
get_caster, entity_pos/eye, const/vec/py, add, num_10, zone_entity/not_living, num_0, index, comment_getNearestArrow
duplicate, entity_pos/eye, deconstruct_vec, mask_v, swap, mask_v
get_caster, entity_pos/eye, deconstruct_vec, mask_v, swap, mask_v
greater, comment_checkIfArrowInAir
(
duplicate,singleton, comment_formList:arrow_0
swap,entity_pos/foot, comment_arrowPosition
get_caster, entity_pos/eye, get_caster, get_entity_look, raycast/entity, entity_pos/eye, comment_targetPosition
sub, duplicate, abs, div, num_-1, mul, comment_calculateIdentityVector
append, comment_formList:arrow_0.identityVector_1
read, append, comment_formList:arrow_0.identityVector_1.counter_2.readFromAbacus
write/local, comment_cacheList:arrow_0.identityVector_1.counter_2
(
read/local, num_2, index, num_0.5, greater comment_checkCounterValue
(
read/local, num_0, index, read/local, num_1, index, add_motion, comment_impulse
read/local,
duplicate, num_2, index, num_1, sub, num_2, swap, replace,
write/local, comment_counterDecrement
duplicate, eval comment_selfDuplicateAndLoop
) comment_runTheseWhenCounterWithinLimit
(halt) comment_exitWhenCounterReachLimit
if, eval
)
duplicate, eval comment_duplicateOnce
) comment_runTheseWhenArrowInAir
(num_4, blink) comment_blinkWhenArrowNotInAir
if, eval
版本区别:
1.19.2中,箭插到地上还是有速度的神奇!,所以改为通过比较Y轴上箭是否高于角色眼睛位置确定箭是否在空中。另外,施法物品连续右键使用的冷却明显比1.20.1长一些,也就是说需要确保箭在空中停留更长时间,为确保这一点,将箭闪现的距离由2格改为4格。
不过既然都用1.19.2了,直接用扩展模组实现一次施法直接拔箭、射箭就好了……