骑马与砍杀中文站论坛

标题: 在维京征服的scripts.txt里发现的get_item_modifier_effects如何修改 [打印本页]

作者: Hugehugecat    时间: 2023-2-21 13:02
标题: 在维京征服的scripts.txt里发现的get_item_modifier_effects如何修改
如题,这可能是涉及前缀效果修改的途径,但是全都是数字看不太懂

  1. get_item_modifier_effects -1
  2. 251 23 2 1224979098644774912 1 23 2 1224979098644774913 2 2133 2 1224979098644774914 0 2133 2 1224979098644774915 0 2133 2 1224979098644774916 0 2133 2 1224979098644774917 0 2133 2 1224979098644774918 0 2133 2 1224979098644774919 100 4 0 31 2 1224979098644774912 1 4 0 31 2 1224979098644774913 30 2133 2 1224979098644774915 -10 2133 2 1224979098644774919 40 2320 2 0 1585267068834416918 5 0 31 2 1224979098644774913 31 2133 2 1224979098644774915 -4 2133 2 1224979098644774919 60 2320 2 0 1585267068834416919 5 0 31 2 1224979098644774913 33 2133 2 1224979098644774915 2 2133 2 1224979098644774919 120 2320 2 0 1585267068834416920 5 0 31 2 1224979098644774913 34 2133 2 1224979098644774915 2 2133 2 1224979098644774919 120 2320 2 0 1585267068834416921 5 0 31 2 1224979098644774913 32 2133 2 1224979098644774917 5 2133 2 1224979098644774918 1 2133 2 1224979098644774919 90 2320 2 0 1585267068834416922 5 0 31 2 1224979098644774913 18 2133 2 1224979098644774914 4 2133 2 1224979098644774916 3 2133 2 1224979098644774917 10 2133 2 1224979098644774919 150 2320 2 0 1585267068834416923 5 0 31 2 1224979098644774913 35 2133 2 1224979098644774914 1 2133 2 1224979098644774915 2 2133 2 1224979098644774919 160 2320 2 0 1585267068834416924 5 0 31 2 1224979098644774913 36 2133 2 1224979098644774914 2 2133 2 1224979098644774915 4 2133 2 1224979098644774918 2 2133 2 1224979098644774919 170 2320 2 0 1585267068834416925 3 0 5 0 31 2 1224979098644774912 7 4 0 31 2 1224979098644774913 1 2133 2 1224979098644774916 -4 2133 2 1224979098644774917 -56 2133 2 1224979098644774919 50 2320 2 0 1585267068834416926 5 0 31 2 1224979098644774913 5 2133 2 1224979098644774916 -2 2133 2 1224979098644774917 -26 2133 2 1224979098644774919 75 2320 2 0 1585267068834416927 5 0 31 2 1224979098644774913 25 2133 2 1224979098644774916 2 2133 2 1224979098644774917 47 2133 2 1224979098644774919 120 2320 2 0 1585267068834416928 5 0 31 2 1224979098644774913 27 2133 2 1224979098644774916 4 2133 2 1224979098644774917 63 2133 2 1224979098644774919 150 2320 2 0 1585267068834416929 3 0 5 0 30 2 1224979098644774912 12 2147483680 2 1224979098644774912 15 4 0 31 2 1224979098644774913 1 2133 2 1224979098644774916 -4 2133 2 1224979098644774919 50 2320 2 0 1585267068834416926 5 0 31 2 1224979098644774913 2 2133 2 1224979098644774916 -3 2133 2 1224979098644774919 55 2320 2 0 1585267068834416930 5 0 31 2 1224979098644774913 21 2133 2 1224979098644774916 -3 2133 2 1224979098644774919 40 2320 2 0 1585267068834416931 5 0 31 2 1224979098644774913 22 2133 2 1224979098644774916 -2 2133 2 1224979098644774919 60 2320 2 0 1585267068834416932 5 0 31 2 1224979098644774913 5 2133 2 1224979098644774916 -2 2133 2 1224979098644774919 75 2320 2 0 1585267068834416927 5 0 31 2 1224979098644774913 7 2133 2 1224979098644774916 -1 2133 2 1224979098644774919 83 2320 2 0 1585267068834416933 5 0 31 2 1224979098644774913 24 2133 2 1224979098644774916 1 2133 2 1224979098644774919 120 2320 2 0 1585267068834416934 5 0 31 2 1224979098644774913 25 2133 2 1224979098644774916 2 2133 2 1224979098644774919 140 2320 2 0 1585267068834416928 5 0 31 2 1224979098644774913 26 2133 2 1224979098644774916 3 2133 2 1224979098644774919 160 2320 2 0 1585267068834416935 5 0 31 2 1224979098644774913 27 2133 2 1224979098644774916 4 2133 2 1224979098644774919 180 2320 2 0 1585267068834416929 5 0 31 2 1224979098644774913 29 2133 2 1224979098644774916 5 2133 2 1224979098644774919 400 2320 2 0 1585267068834416936 3 0 5 0 1073741855 2 1224979098644774912 2 1073741855 2 1224979098644774912 3 1073741855 2 1224979098644774912 4 1073741855 2 1224979098644774912 8 1073741855 2 1224979098644774912 9 1073741855 2 1224979098644774912 16 31 2 1224979098644774912 17 4 0 31 2 1224979098644774913 41 2133 2 1224979098644774914 -20 2133 2 1224979098644774919 5 2320 2 0 1585267068834416937 5 0 31 2 1224979098644774913 1 2133 2 1224979098644774914 -5 2133 2 1224979098644774919 40 2320 2 0 1585267068834416926 5 0 31 2 1224979098644774913 2 2133 2 1224979098644774914 -3 2133 2 1224979098644774919 55 2320 2 0 1585267068834416930 5 0 31 2 1224979098644774913 3 2133 2 1224979098644774914 -3 2133 2 1224979098644774915 -3 2133 2 1224979098644774919 60 2320 2 0 1585267068834416938 5 0 31 2 1224979098644774913 4 2133 2 1224979098644774914 -1 2133 2 1224979098644774919 72 2320 2 0 1585267068834416939 5 0 31 2 1224979098644774913 18 2133 2 1224979098644774914 2 2133 2 1224979098644774915 -2 2133 2 1224979098644774918 1 2133 2 1224979098644774919 120 2320 2 0 1585267068834416923 5 0 31 2 1224979098644774913 19 2133 2 1224979098644774914 3 2133 2 1224979098644774915 -3 2133 2 1224979098644774918 2 2133 2 1224979098644774919 150 2320 2 0 1585267068834416940 5 0 31 2 1224979098644774913 13 2133 2 1224979098644774914 3 2133 2 1224979098644774915 3 2133 2 1224979098644774919 165 2320 2 0 1585267068834416941 5 0 31 2 1224979098644774913 14 2133 2 1224979098644774914 4 2133 2 1224979098644774919 180 2320 2 0 1585267068834416942 5 0 31 2 1224979098644774913 17 2133 2 1224979098644774914 5 2133 2 1224979098644774915 1 2133 2 1224979098644774918 4 2133 2 1224979098644774919 400 2320 2 0 1585267068834416943 5 0 31 2 1224979098644774913 7 2133 2 1224979098644774914 -2 2133 2 1224979098644774919 83 3 0 5 0 1073741855 2 1224979098644774912 5 1073741855 2 1224979098644774912 6 1073741855 2 1224979098644774912 18 31 2 1224979098644774912 10 4 0 31 2 1224979098644774913 42 2133 2 1224979098644774919 110 2320 2 0 1585267068834416944 5 0 31 2 1224979098644774913 3 2133 2 1224979098644774914 -3 2133 2 1224979098644774919 65 2320 2 0 1585267068834416938 5 0 31 2 1224979098644774913 1 2133 2 1224979098644774914 -5 2133 2 1224979098644774919 50 2320 2 0 1585267068834416926 5 0 31 2 1224979098644774913 18 2133 2 1224979098644774914 2 2133 2 1224979098644774919 130 2320 2 0 1585267068834416923 5 0 31 2 1224979098644774913 13 2133 2 1224979098644774914 3 2133 2 1224979098644774919 150 2320 2 0 1585267068834416941 3 0 3 0 2133 2 72057594037927936 1224979098644774914 2133 2 72057594037927937 1224979098644774915 2133 2 72057594037927938 1224979098644774916 2133 2 72057594037927939 1224979098644774917 2133 2 72057594037927940 1224979098644774918 2133 2 72057594037927941 1224979098644774919
复制代码


作者: Hugehugecat    时间: 2023-2-21 13:03
而且我想如何将这段代码送到战团里应用
作者: lq95928    时间: 2023-2-21 17:01
本帖最后由 lq95928 于 2023-2-21 17:08 编辑

去下个维京的源代码看啊,看TXT肯定看不懂啊

https://bbs.mountblade.com.cn/thread-2066886-1-1.html

我找出来给你贴下面了
[spoiler=源代码]
  1.   # script_get_item_modifier_effects moto chief
  2.   # Input: itp_*, imod_*
  3.   # Output: reg0 damage effect
  4.   #         reg1 speed effect
  5.   #         reg2 armor effect
  6.   #         reg3 hit points effect
  7.   #         reg4 difficulty effect
  8.   #         reg5 price factor
  9.   #         s0 descriptor string
  10.   ("get_item_modifier_effects", [(store_script_param, ":type", 1),
  11.       (store_script_param, ":imod", 2),
  12.       
  13.       (assign, ":damage", 0),
  14.       (assign, ":speed", 0),
  15.       (assign, ":armor", 0),
  16.       (assign, ":hit_points", 0),
  17.       (assign, ":difficulty", 0),
  18.       (assign, ":price_factor", 100),
  19.       
  20.       (try_begin),
  21.         (eq, ":type", itp_type_horse),
  22.         (try_begin),
  23.           (eq, ":imod", imod_lame),
  24.           (assign, ":speed", -10),
  25.           (assign, ":price_factor", 40),
  26.           (str_store_string, s0, "@Lame"),
  27.         (else_try),
  28.           (eq, ":imod", imod_swaybacked),
  29.           (assign, ":speed", -4),
  30.           (assign, ":price_factor", 60),
  31.           (str_store_string, s0, "@Swaybacked"),
  32.         (else_try),
  33.           (eq, ":imod", imod_timid),
  34.           (assign, ":speed", 2),
  35.           (assign, ":price_factor", 120),
  36.           (str_store_string, s0, "@Timid"),
  37.         (else_try),
  38.           (eq, ":imod", imod_meek),
  39.           (assign, ":speed", 2),
  40.           (assign, ":price_factor", 120),
  41.           (str_store_string, s0, "@Meek"),
  42.         (else_try),
  43.           (eq, ":imod", imod_stubborn),
  44.           (assign, ":hit_points", 5),
  45.           (assign, ":difficulty", 1),
  46.           (assign, ":price_factor", 90),
  47.           (str_store_string, s0, "@Stubborn"),
  48.         (else_try),
  49.           (eq, ":imod", imod_heavy),
  50.           (assign, ":damage", 4),
  51.           (assign, ":armor", 3),
  52.           (assign, ":hit_points", 10),
  53.           (assign, ":price_factor", 150),
  54.           (str_store_string, s0, "@Heavy"),
  55.         (else_try),
  56.           (eq, ":imod", imod_spirited),
  57.           (assign, ":damage", 1),
  58.           (assign, ":speed", 2),
  59.           (assign, ":price_factor", 160),
  60.           (str_store_string, s0, "@Spirited"),
  61.         (else_try),
  62.           (eq, ":imod", imod_champion),
  63.           (assign, ":damage", 2),
  64.           (assign, ":speed", 4),
  65.           (assign, ":difficulty", 2),
  66.           (assign, ":price_factor", 170),
  67.           (str_store_string, s0, "@Champion"),
  68.         (try_end),
  69.         
  70.       (else_try),
  71.         (eq, ":type", itp_type_shield),
  72.         (try_begin),
  73.           (eq, ":imod", imod_cracked),
  74.           (assign, ":armor", -4),
  75.           (assign, ":hit_points", -56),
  76.           (assign, ":price_factor", 50),
  77.           (str_store_string, s0, "@Cracked"),
  78.         (else_try),
  79.           (eq, ":imod", imod_battered),
  80.           (assign, ":armor", -2),
  81.           (assign, ":hit_points", -26),
  82.           (assign, ":price_factor", 75),
  83.           (str_store_string, s0, "@Battered"),
  84.         (else_try),
  85.           (eq, ":imod", imod_thick),
  86.           (assign, ":armor", 2),
  87.           (assign, ":hit_points", 47),
  88.           (assign, ":price_factor", 120),
  89.           (str_store_string, s0, "@Thick"),
  90.         (else_try),
  91.           (eq, ":imod", imod_reinforced),
  92.           (assign, ":armor", 4),
  93.           (assign, ":hit_points", 63),
  94.           (assign, ":price_factor", 150),
  95.           (str_store_string, s0, "@Reinforced"),
  96.         (try_end),
  97.         
  98.       (else_try),
  99.         (ge, ":type", itp_type_head_armor),
  100.         (le, ":type", itp_type_hand_armor),
  101.         (try_begin),
  102.           (eq, ":imod", imod_cracked),
  103.           (assign, ":armor", -4),
  104.           (assign, ":price_factor", 50),
  105.           (str_store_string, s0, "@Cracked"),
  106.         (else_try),
  107.           (eq, ":imod", imod_rusty),
  108.           (assign, ":armor", -3),
  109.           (assign, ":price_factor", 55),
  110.           (str_store_string, s0, "@Rusty"),
  111.         (else_try),
  112.           (eq, ":imod", imod_tattered),
  113.           (assign, ":armor", -3),
  114.           (assign, ":price_factor", 40),
  115.           (str_store_string, s0, "@Tattered"),
  116.         (else_try),
  117.           (eq, ":imod", imod_ragged),
  118.           (assign, ":armor", -2),
  119.           (assign, ":price_factor", 60),
  120.           (str_store_string, s0, "@Ragged"),
  121.         (else_try),
  122.           (eq, ":imod", imod_battered),
  123.           (assign, ":armor", -2),
  124.           (assign, ":price_factor", 75),
  125.           (str_store_string, s0, "@Battered"),
  126.         (else_try),
  127.           (eq, ":imod", imod_crude),
  128.           (assign, ":armor", -1),
  129.           (assign, ":price_factor", 83),
  130.           (str_store_string, s0, "@Crude"),
  131.         (else_try),
  132.           (eq, ":imod", imod_sturdy),
  133.           (assign, ":armor", 1),
  134.           (assign, ":price_factor", 120),
  135.           (str_store_string, s0, "@Sturdy"),
  136.         (else_try),
  137.           (eq, ":imod", imod_thick),
  138.           (assign, ":armor", 2),
  139.           (assign, ":price_factor", 140),
  140.           (str_store_string, s0, "@Thick"),
  141.         (else_try),
  142.           (eq, ":imod", imod_hardened),
  143.           (assign, ":armor", 3),
  144.           (assign, ":price_factor", 160),
  145.           (str_store_string, s0, "@Hardened"),
  146.         (else_try),
  147.           (eq, ":imod", imod_reinforced),
  148.           (assign, ":armor", 4),
  149.           (assign, ":price_factor", 180),
  150.           (str_store_string, s0, "@Reinforced"),
  151.         (else_try),
  152.           (eq, ":imod", imod_lordly),
  153.           (assign, ":armor", 5),
  154.           (assign, ":price_factor", 400),
  155.           (str_store_string, s0, "@Lordly"),
  156.         (try_end),
  157.         
  158.       (else_try),
  159.         (this_or_next | eq, ":type", itp_type_one_handed_wpn),
  160.         (this_or_next | eq, ":type", itp_type_two_handed_wpn),
  161.         (this_or_next | eq, ":type", itp_type_polearm),
  162.         (this_or_next | eq, ":type", itp_type_bow),
  163.         (this_or_next | eq, ":type", itp_type_crossbow),
  164.         (this_or_next | eq, ":type", itp_type_pistol),
  165.         (eq, ":type", itp_type_musket),
  166.         
  167.         (try_begin),
  168.           (eq, ":imod", imod_rotten),                #idea is to use this for a completly broken weapon
  169.           (assign, ":damage", -20),
  170.           (assign, ":price_factor", 5),
  171.           (str_store_string, s0, "@Broken"),
  172.         (else_try),
  173.           (eq, ":imod", imod_cracked),
  174.           (assign, ":damage", -5),
  175.           (assign, ":price_factor", 40),
  176.           (str_store_string, s0, "@Cracked"),
  177.         (else_try),
  178.           (eq, ":imod", imod_rusty),
  179.           (assign, ":damage", -3),
  180.           (assign, ":price_factor", 55),
  181.           (str_store_string, s0, "@Rusty"),
  182.         (else_try),
  183.           (eq, ":imod", imod_bent),
  184.           (assign, ":damage", -3),
  185.           (assign, ":speed", -3),
  186.           (assign, ":price_factor", 60),
  187.           (str_store_string, s0, "@Bent"),
  188.         (else_try),
  189.           (eq, ":imod", imod_chipped),
  190.           (assign, ":damage", -1),
  191.           (assign, ":price_factor", 72),
  192.           (str_store_string, s0, "@Chipped"),
  193.         (else_try),
  194.           (eq, ":imod", imod_heavy),
  195.           (assign, ":damage", 2),
  196.           (assign, ":speed", -2),
  197.           (assign, ":difficulty", 1),
  198.           (assign, ":price_factor", 120),
  199.           (str_store_string, s0, "@Heavy"),
  200.         (else_try),
  201.           (eq, ":imod", imod_strong),
  202.           (assign, ":damage", 3),
  203.           (assign, ":speed", -3),
  204.           (assign, ":difficulty", 2),
  205.           (assign, ":price_factor", 150),
  206.           (str_store_string, s0, "@Strong"),
  207.         (else_try),
  208.           (eq, ":imod", imod_balanced),
  209.           (assign, ":damage", 3),
  210.           (assign, ":speed", 3),
  211.           (assign, ":price_factor", 165),
  212.           (str_store_string, s0, "@Balanced"),
  213.         (else_try),
  214.           (eq, ":imod", imod_tempered),
  215.           (assign, ":damage", 4),
  216.           (assign, ":price_factor", 180),
  217.           (str_store_string, s0, "@Tempered"),
  218.         (else_try),
  219.           (eq, ":imod", imod_masterwork),
  220.           (assign, ":damage", 5),
  221.           (assign, ":speed", 1),
  222.           (assign, ":difficulty", 4),
  223.           (assign, ":price_factor", 400),
  224.           (str_store_string, s0, "@Masterwork"),
  225.         (else_try),
  226.           (eq, ":imod", imod_crude),
  227.           (assign, ":damage", -2),
  228.           (assign, ":price_factor", 83),
  229.         (try_end),
  230.         
  231.       (else_try),
  232.         (this_or_next | eq, ":type", itp_type_arrows),
  233.         (this_or_next | eq, ":type", itp_type_bolts),
  234.         (this_or_next | eq, ":type", itp_type_bullets),
  235.         (eq, ":type", itp_type_thrown),
  236.         
  237.         (try_begin),
  238.           (eq, ":imod", imod_large_bag),
  239.           #       (assign, ":damage", 1), #just make better than plain
  240.           (assign, ":price_factor", 110),
  241.           (str_store_string, s0, "@Large Bag of"),
  242.         (else_try),
  243.           (eq, ":imod", imod_bent),
  244.           (assign, ":damage", -3),
  245.           (assign, ":price_factor", 65),
  246.           (str_store_string, s0, "@Bent"),
  247.         (else_try),
  248.           (eq, ":imod", imod_cracked),
  249.           (assign, ":damage", -5),
  250.           (assign, ":price_factor", 50),
  251.           (str_store_string, s0, "@Cracked"),
  252.         (else_try),
  253.           (eq, ":imod", imod_heavy),
  254.           (assign, ":damage", 2),
  255.           (assign, ":price_factor", 130),
  256.           (str_store_string, s0, "@Heavy"),
  257.         (else_try),
  258.           (eq, ":imod", imod_balanced),
  259.           (assign, ":damage", 3),
  260.           (assign, ":price_factor", 150),
  261.           (str_store_string, s0, "@Balanced"),
  262.         (try_end),
  263.       (try_end),
  264.       
  265.       (assign, reg0, ":damage"),
  266.       (assign, reg1, ":speed"),
  267.       (assign, reg2, ":armor"),
  268.       (assign, reg3, ":hit_points"),
  269.       (assign, reg4, ":difficulty"),
  270.       (assign, reg5, ":price_factor"),]),
复制代码

[/spoiler]

作者: Hugehugecat    时间: 2023-2-27 23:10
本帖最后由 Hugehugecat 于 2023-2-27 23:11 编辑
lq95928 发表于 2023-2-21 17:01
去下个维京的源代码看啊,看TXT肯定看不懂啊

https://bbs.mountblade.com.cn/thread-2066886-1-1.html

这我倒是看懂了,但是我想添加子弹速度咋办<br>
感叹啊,还是砍2更友好啊,xml文件随便看






欢迎光临 骑马与砍杀中文站论坛 (https://bbs.mountblade.com.cn/) Powered by Discuz! X3.4