Mirathei
Sergeant Knight
For now, its just for looks. I'll work on making things actually light up.
In any appropriate mission template:
In module_items:
In module_parties:
Screenie:
In any appropriate mission template:
Code:
(ti_before_mission_start, 0, 0, [], [
(try_for_range,":slot",0,500),
(party_set_slot,"p_fire_arrows",":slot",-1),
(end_try),]),
(0.005, 0, 0, [],[
(try_for_agents,":agent"),
(party_get_slot,":fire","p_fire_arrows",":agent"),
(ge,":fire",0),
(party_get_slot,":x","p_x_coordinate",":agent"),
(party_get_slot,":y","p_y_coordinate",":agent"),
(party_get_slot,":z","p_z_coordinate",":agent"),
(party_get_slot,":xvel","p_x_velocity",":agent"),
(party_get_slot,":yvel","p_y_velocity",":agent"),
(party_get_slot,":zvel","p_z_velocity",":agent"),
(val_add,":x",":xvel"),
(val_add,":y",":yvel"),
(val_add,":z",":zvel"),
(position_set_x,pos1,":x"),
(position_set_y,pos1,":y"),
(position_set_z,pos1,":z"),
(particle_system_burst, "psys_torch_fire", pos1, 15),
(position_set_z_to_ground_level,pos1),
(position_get_z,":zground",pos1),
(try_begin),
(le,":z",":zground"),
(particle_system_burst,"psys_torch_fire",pos1, 1000),
(party_set_slot,"p_fire_arrows",":agent",-1),
(else_try),
(party_set_slot,"p_x_coordinate",":agent",":x"),
(party_set_slot,"p_y_coordinate",":agent",":y"),
(party_set_slot,"p_z_coordinate",":agent",":z"),
(val_sub,":zvel",1),
(party_set_slot,"p_z_velocity",":agent",":zvel"),
(end_try),
(end_try),]),
In module_items:
Code:
["fire_bow", "Bow with fire arrows", [("strong_bow",0),("strong_bow_case", ixmesh_carry)], itp_type_bow |itp_merchandise|itp_primary|itp_two_handed ,itcf_shoot_bow|itcf_carry_bowcase_left|itcf_show_holster_when_drawn, 337 , weight(1.25)|difficulty(3)|spd_rtng(94) | shoot_speed(55) | thrust_damage(46 ,pierce),imodbits_bow,
[(ti_on_weapon_attack, [(assign,":chosen",-1),(assign,":mindist",99999),
(try_for_agents,":agent"),
(agent_get_position,pos2,":agent"),
(get_distance_between_positions,":dist",pos1,pos2),
(lt,":dist",":mindist"),
(assign,":mindist",":dist"),
(assign,":chosen",":agent"),
(end_try),
(gt,":chosen",-1),
(agent_get_look_position,pos1,":chosen"),
(position_move_z,pos1,120),
(position_get_x,":x",pos1),
(position_get_y,":y",pos1),
(position_get_z,":z",pos1),
(party_set_slot,"p_x_coordinate",":chosen",":x"),
(party_set_slot,"p_y_coordinate",":chosen",":y"),
(party_set_slot,"p_z_coordinate",":chosen",":z"),
(position_move_y,pos1,110),
(position_get_x,":xnew",pos1),
(position_get_y,":ynew",pos1),
(position_get_z,":znew",pos1),
(val_sub,":xnew",":x"),
(val_sub,":ynew",":y"),
(val_sub,":znew",":z"),
(party_set_slot,"p_x_velocity",":chosen",":xnew"),
(party_set_slot,"p_y_velocity",":chosen",":ynew"),
(party_set_slot,"p_z_velocity",":chosen",":znew"),
(party_set_slot,"p_fire_arrows",":chosen",1),])]],
In module_parties:
Code:
("fire_arrows" ,"You shouldn't be seeing me", pf_disabled|pf_is_static, no_menu, pt_none, fac_commoners,0,ai_bhvr_hold,0,(0., 0),[(trp_looter,15,0)]),
("x_coordinate" ,"You shouldn't be seeing me", pf_disabled|pf_is_static, no_menu, pt_none, fac_commoners,0,ai_bhvr_hold,0,(0., 0),[(trp_looter,15,0)]),
("y_coordinate" ,"You shouldn't be seeing me", pf_disabled|pf_is_static, no_menu, pt_none, fac_commoners,0,ai_bhvr_hold,0,(0., 0),[(trp_looter,15,0)]),
("z_coordinate" ,"You shouldn't be seeing me", pf_disabled|pf_is_static, no_menu, pt_none, fac_commoners,0,ai_bhvr_hold,0,(0., 0),[(trp_looter,15,0)]),
("x_velocity" ,"You shouldn't be seeing me", pf_disabled|pf_is_static, no_menu, pt_none, fac_commoners,0,ai_bhvr_hold,0,(0., 0),[(trp_looter,15,0)]),
("y_velocity" ,"You shouldn't be seeing me", pf_disabled|pf_is_static, no_menu, pt_none, fac_commoners,0,ai_bhvr_hold,0,(0., 0),[(trp_looter,15,0)]),
("z_velocity" ,"You shouldn't be seeing me", pf_disabled|pf_is_static, no_menu, pt_none, fac_commoners,0,ai_bhvr_hold,0,(0., 0),[(trp_looter,15,0)]),
Screenie: