- 好友
- 16
- 在线时间
- 4372 小时
- 最后登录
- 2024-12-6
骑士
高级术士
- UID
- 242416
- 第纳尔
- 7359
- 精华
- 0
- 互助
- 38
- 荣誉
- 9
- 贡献
- 0
- 魅力
- 113
- 注册时间
- 2010-4-27
鲜花( 568) 鸡蛋( 0)
|
楼主 |
发表于 2014-10-5 12:12:50
|
显示全部楼层
171597188 发表于 2014-10-5 08:44
可问题是我不会PY啊……简单的把PY代码加到开源MOD里我倒(应该)还是会,但是我真的看不懂PY代码啊……
...
只在开始执行一次===========================================================================================================================================================================
(try_for_agents, ":agent_no"),
(agent_is_human, ":agent_no"),
(agent_is_alive, ":agent_no"),
(agent_get_troop_id, ":troop_no", ":agent_no"),
(try_begin),
(eq, ":troop_no", "trp_player"),
(troop_get_inventory_slot, ":helmet_item", ":troop_no", ek_head),
(assign, ":continue", 1),
(assign, ":is_sneak", 0),
(try_begin),
(agent_has_item_equipped, ":agent_no", "itm_pilgrim_hood"),
(agent_has_item_equipped, ":agent_no", "itm_pilgrim_disguise"),
(assign, ":is_sneak", 1),
(try_end),
(try_begin),
(gt, ":helmet_item", 0),
(agent_get_item_slot, ":helmet", ":agent_no", ek_head),
(le, ":helmet", 0),
(assign, ":continue", 0),
(try_end),
(eq, ":continue", 1),
(agent_get_wielded_item, ":weapon", ":agent_no", 0),
(this_or_next|eq, ":is_sneak", 1),
(le, ":weapon", 0),
(store_skill_level, ":max_bodygurad", "skl_leadership"),
(val_div, ":max_bodygurad", 10),
(val_add, ":max_bodygurad", 1),
(party_get_num_companion_stacks, ":num_of_stacks", "p_main_party"),
(agent_get_team, ":team", ":agent_no"),
(set_show_messages, 0),
(assign, ":num_bodygurad", 0),
(agent_get_position, pos25, ":agent_no"),
(try_for_range, ":i", 0, ":num_of_stacks"),
(lt, ":num_bodygurad", ":max_bodygurad"),
(party_stack_get_troop_id, ":troop_id", "p_main_party", ":i"),
(neq, ":troop_id", "trp_player"),
(troop_is_hero, ":troop_id"),
(neg|troop_is_wounded, ":troop_id"),
(val_add, ":num_bodygurad", 1),
(copy_position,pos26 ,pos25),
(store_random_in_range, ":rand", -50, 51),
(position_move_x, pos26, ":rand"),
(store_random_in_range, ":rand", -50, 51),
(position_move_y, pos26, ":rand"),
(set_spawn_position, pos26),
(agent_get_horse, ":horse_agent", ":agent_no"),
(try_begin),
(gt, ":horse_agent", -1),
(spawn_agent, ":troop_id"),
(else_try),
(troop_get_inventory_slot, ":horse_item", ":troop_id", ek_horse),
(troop_get_inventory_slot_modifier, ":horse_item_modifier", ":troop_id", ek_horse),
(troop_set_inventory_slot, ":troop_id", ek_horse, -1),
(spawn_agent,":troop_id"),
(troop_set_inventory_slot, ":troop_id", ek_horse, ":horse_item"),
(troop_set_inventory_slot_modifier, ":troop_id", ek_horse, ":horse_item_modifier"),
(try_end),
(assign,":spawn_agent",reg0),
(agent_set_slot, ":spawn_agent", 506, 3),
(agent_set_team, ":spawn_agent", ":team"),
(agent_get_division, ":division", ":spawn_agent"),
(agent_set_is_alarmed, ":spawn_agent", 1),
(agent_set_wielded_item, ":spawn_agent", -1),
(agent_add_relation_with_agent, ":spawn_agent", ":agent_no", 1),
(team_give_order, ":team", ":division", 1),
(try_begin),
(eq, ":is_sneak", 1),
(agent_equip_item, ":spawn_agent", "itm_pilgrim_hood"),
(agent_equip_item, ":spawn_agent", "itm_pilgrim_disguise"),
(agent_equip_item, ":spawn_agent", "itm_leather_gloves"),
(try_end),
(try_end),
(set_show_messages, 1),
(try_end),
(try_end),
|
鲜花鸡蛋171597188 在2014-10-5 15:00 送朵鲜花 并说:太感谢了先给花~~~不过话说放哪个PY文件?……
|