Modify "Mount" location on horse?

Users who are viewing this thread

Revanstein

Regular
Does anyone know how to modify the "place" where you "mount" a "horse"? 

This seems very useful for those of us working on creating unorthodox mounts, and need to sit further down or up the length of the creature.
 
Revanstein said:
Does anyone know how to modify the "place" where you "mount" a "horse"? 

This seems very useful for those of us working on creating unorthodox mounts, and need to sit further down or up the length of the creature.

You can change Horse mount animation (ani_stand_onhorse.brf/stand_onhorse and ani_human_mounted.brf/anim_human_02).. then in mission_templates you have to switch between the standard animation and your custom, in depends what creature you mount. (http://forums.taleworlds.com/index.php?topic=6575.msg7456285#msg7456285)


mission_templates.py said:
# Event: mount palanquin / Событие: посадка в паланкин. Выполняется, если вместо лошади паланкин.
palanquin_mount = (
    ti_on_agent_mount, 0, 0,
  [
    (store_trigger_param_2, ":horse"), # взять номер агента лошади на сцене
    (agent_get_item_id, ":horse_id", ":horse"), # взять id ее итема
    (eq, ":horse_id", "itm_palanquin"), # продолжить, если это паланкин
  ],
  [
    (store_trigger_param_1, ":agent"),
    (store_trigger_param_2, ":palanquin"),
   
      # Hide weapons before mount / Cнять все оружие перед посадкой в паланкин чтобы не торчало через стенки.
    (call_script, "script_palaquin_agent_unequip_weapon", ":agent"),
    # Mount palanquin / Сесть в паланкин
    (agent_set_animation, ":agent", "anim_mount_palanquin"),#(display_message, "@Palanquin mount ."), # next anim  => anim_ride_0 = 125 TODO: anim_palanquin_ride
    # Activate movement / Разрешить движение

    (agent_set_no_dynamics,  ":palanquin", 0),
    # TODO: изменить анимацию паланкина => поднять на плечи носильщиков
  ])

# Event: dismount palanquin / Событие: высадка из паланкина. Выполняется, если вместо лошади паланкин.
palanquin_dismount = (
    ti_on_agent_dismount, 0, 0,
  [
    (store_trigger_param_2, ":horse"), # взять номер агента лошади на сцене
    (agent_get_item_id, ":horse_id", ":horse"), # взять id ее итема
    (eq, ":horse_id", "itm_palanquin"), # продолжить, если это паланкин
  ],
  [
    # TODO: изменить анимацию паланкина => опустить на землю
    # Forbid movements to avoid wild horse behavior / Запретить движения, чтобы паланкин не убежал как дикая лошадь

    (store_trigger_param_2, ":horse"),
    (agent_set_no_dynamics, ":horse", 1),
    # Dismount / Слезть с паланкина
    (store_trigger_param_1, ":agent"),
    (agent_set_animation, ":agent", "anim_dismount_palanquin"), #(display_message, "@Palanquin dismount."), # next anim  => anim_stand_man = 1
    # Equip weapon unequiped before / Одеть снятое оружие. Пройтись по слотам 0-4 (agent_unequiped_weapon_slot_0 -_5), если значения больше 0 => одеть снятое оружие

    (try_for_range, ":agent_unequiped_weapon_slot_no", agent_weapon_slot_0, agent_weapon_slot_5),
        (agent_get_slot, ":item_id", ":agent", ":agent_unequiped_weapon_slot_no"),
        (gt, ":item_id", 0),
        (agent_equip_item, ":agent", ":item_id", ":agent_unequiped_weapon_slot_no"),
    (try_end),
  ])

module_animation.py said:
# Mount / Dismount palanquin
  ["mount_palanquin", acf_enforce_all, amf_priority_die|amf_play|amf_client_prediction,
    [1.3, "mount_palanquin", horse_move+0, horse_move+5,  arf_blend_in_1, 0, (0.0,0,0.0)],
  ],
  ["dismount_palanquin", acf_enforce_lowerbody|acf_displace_position, amf_priority_die|amf_play|amf_accurate_body|amf_client_prediction,
    [1.1, "dismount_palanquin", horse_move+0, horse_move+5,  arf_blend_in_1, 0, (-0.5,0,0)],
  ],
 
Back
Top Bottom