骑马与砍杀中文站论坛

 找回密码
 注册(Register!)

QQ登录

只需一步,快速开始

搜索
购买霸主CDKEY 购买战帆CDKEY
查看: 56161|回复: 46

[其他] 教你如何加入各种破盾武器,还可得到可以拿盾牌带破盾的弩哦~~~~

[复制链接]

58

主题

671

回帖

3859

积分

骑士领主

Rank: 6Rank: 6

UID
8971
第纳尔
3019
精华
10
互助
154
荣誉
187
贡献
30
魅力
1
注册时间
2007-2-19

骑士美德之正义勋章[杰出会员荣誉勋章]骑士美德之仁慈勋章[杰出会员互助勋章]骑士美德之忠诚勋章[杰出会员精华勋章]

鲜花(2) 鸡蛋(0)
发表于 2007-3-28 23:12:53 | 显示全部楼层
楼主是直接改txt文件么,还是研究过py代码.

破盾加成在header_items.py中有定义:
itp_bonus_against_shield = 0x20000000
注意:破盾加成的含义只有这一个,不是不同的武器有不同的破盾加成!

例子:
如果是用py代码:
["arrows","Arrows", [("arrow",0),("flying_missile",ixmesh_flying_ammo),("quiver", ixmesh_carry)], itp_type_arrows|itp_merchandise, itcf_carry_quiver_back, 72,weight(3)|abundance(160)|weapon_length(95)|thrust_damage(1,pierce)|max_ammo(24),imodbits_missile],
改成:
["arrows","Arrows", [("arrow",0),("flying_missile",ixmesh_flying_ammo),("quiver", ixmesh_carry)], itp_bonus_against_shield|itp_type_arrows|itp_merchandise, itcf_carry_quiver_back, 72,weight(3)|abundance(160)|weapon_length(95)|thrust_damage(1,pierce)|max_ammo(24),imodbits_missile],
就可以了.

如果要直接修改txt代码:
itm_arrows Arrows Arrows 3  arrow 0  flying_missile 2305843009213693952  quiver 3458764513820540928  65541 2147483648 72 8388616 3.000000 160 0 0 0 0 0 0 0 94 24 257 0
0
65541就是 itp_type_arrows|itp_merchandise的意思
在header_items.py文件中定义了itp_type_arrows=  0x00000005,itp_merchandise  = 0x00010000,"|"运算符是"按位或"的意思
含义见:http://bbs.mountblade.com.cn/vie ... &extra=page%3D1
其实因为位数是错开的,其实我们也可以直接加
5+10000=10005,十六进制的10005即是10进制的65541
如果还要加上破盾属性,那么:
用计算器的16进制计算:
20000000+5+10000=20010005,即是10进制的536936453

itm_arrows Arrows Arrows 3  arrow 0  flying_missile 2305843009213693952  quiver 3458764513820540928  65541 2147483648 72 8388616 3.000000 160 0 0 0 0 0 0 0 94 24 257 0
0
改成
itm_arrows Arrows Arrows 3  arrow 0  flying_missile 2305843009213693952  quiver 3458764513820540928  536936453 2147483648 72 8388616 3.000000 160 0 0 0 0 0 0 0 94 24 257 0
0
就可以了.

其他物品类似.

[ 本帖最后由 kanesunny 于 2007-3-28 23:16 编辑 ]
您需要登录后才可以回帖 登录 | 注册(Register!)

本版积分规则

Archiver|手机版|小黑屋|骑马与砍杀中文站

GMT+8, 2025-12-19 16:15 , Processed in 0.073971 second(s), 18 queries , Gzip On, MemCached On.

Powered by Discuz! X3.4 Licensed

© 2001-2023 Discuz! Team.

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