OSP Kit Combat Form Ranks! - A formation kit[Version1.32][Minor update: multi bug fixes]

Users who are viewing this thread

hmm. I did something wrong  :shock: When I compile, it gives these erros, global variable never used $formation_vector, $formation_temp_vector etc... So where did I mess up :/
 
Those are fine, they're not errors they're just warnings that some old variables are unused. It shouldn't cause any trouble.
 
mr.master said:
hmm. But the kit aint working  :shock: Im sure I updated all the files :???: I can't see no options in action menu nor before the battle

The kit does work...at least in warband but not 100%.  I was able to implement the menus, scripting, battle arrays and the formations were working.

The problem I had (primarily) was some of the "charge" features of the kit don't work properly in warband and I need to investigate further...but regardless the scripting does indeed work at a certain level.

My suggestion is to basically start over and try again...perhaps you missed something during implementation.
 
I was able to implement the menus, scripting, battle arrays and the formations were working.

Care to share? I've only gotten the menus and party scripting to work, but it's not working in battle at all... at least not that I can see.
 
Well, I'm back after a long hiatus and I would love to see this ported to Warband. I'm wondering if anyone can give me a quick answer as to what the status on that is - is anyone working on it? I'd be glad to help, I did a lot of work with this kit a while back.
 
I have all the dialogues and menus and EVERYTHING except for when i go to a battle and actually want to use them.
I press "x" and it doesn't work :/ (not only X, all of the commands)

PLEASe can someone give me a solution to this
 
Hello, I recently wanted to learn how to make mods so I pretty much read all there is to read about making a mod. My first attempt was making new units, np. However, when I tried to use winmerge and combine Form Ranks with native Warband, I ran into a lot of errors and weird gameplay, like random conversations and comments coming out of nowhere.

This is my module.bat attempt. I copied all the Form Ranks sources onto the Warband Native Source.

Traceback (most recent call last):
  File "process_init.py", line 2, in <module>
    from process_operations import *
  File "C:\Documents and Settings\Paul Scherer\Desktop\New Folder\mb_warband_mod
ule_system_1125\Module_system 1.125\process_operations.py", line 20, in <module>

    from module_scripts import *
  File "C:\Documents and Settings\Paul Scherer\Desktop\New Folder\mb_warband_mod
ule_system_1125\Module_system 1.125\module_scripts.py", line 40598
    ("debug_variables",
    ^
IndentationError: unexpected indent
Traceback (most recent call last):
  File "process_global_variables.py", line 8, in <module>
    from module_presentations import *
  File "C:\Documents and Settings\Paul Scherer\Desktop\New Folder\mb_warband_mod
ule_system_1125\Module_system 1.125\module_presentations.py", line 2372
    ("game_multiplayer_admin_panel", prsntf_manual_end_only, 0, [
    ^
IndentationError: unexpected indent
Exporting strings...
Exporting skills...
Exporting tracks...
Exporting animations...
Exporting meshes...
Exporting sounds...
Exporting skins...
Traceback (most recent call last):
  File "process_map_icons.py", line 6, in <module>
    from process_operations import *
  File "C:\Documents and Settings\Paul Scherer\Desktop\New Folder\mb_warband_mod
ule_system_1125\Module_system 1.125\process_operations.py", line 20, in <module>

    from module_scripts import *
  File "C:\Documents and Settings\Paul Scherer\Desktop\New Folder\mb_warband_mod
ule_system_1125\Module_system 1.125\module_scripts.py", line 40598
    ("debug_variables",
    ^
IndentationError: unexpected indent
Exporting faction data...
Exporting item data...
Traceback (most recent call last):
  File "process_items.py", line 66, in <module>
    from process_operations import *
  File "C:\Documents and Settings\Paul Scherer\Desktop\New Folder\mb_warband_mod
ule_system_1125\Module_system 1.125\process_operations.py", line 20, in <module>

    from module_scripts import *
  File "C:\Documents and Settings\Paul Scherer\Desktop\New Folder\mb_warband_mod
ule_system_1125\Module_system 1.125\module_scripts.py", line 40598
    ("debug_variables",
    ^
IndentationError: unexpected indent
Exporting scene data...
Traceback (most recent call last):
  File "process_scenes.py", line 15, in <module>
    from process_operations import *
  File "C:\Documents and Settings\Paul Scherer\Desktop\New Folder\mb_warband_mod
ule_system_1125\Module_system 1.125\process_operations.py", line 20, in <module>

    from module_scripts import *
  File "C:\Documents and Settings\Paul Scherer\Desktop\New Folder\mb_warband_mod
ule_system_1125\Module_system 1.125\module_scripts.py", line 40598
    ("debug_variables",
    ^
IndentationError: unexpected indent
Exporting troops data
Exporting particle data...
Traceback (most recent call last):
  File "process_scene_props.py", line 7, in <module>
    from process_operations import *
  File "C:\Documents and Settings\Paul Scherer\Desktop\New Folder\mb_warband_mod
ule_system_1125\Module_system 1.125\process_operations.py", line 20, in <module>

    from module_scripts import *
  File "C:\Documents and Settings\Paul Scherer\Desktop\New Folder\mb_warband_mod
ule_system_1125\Module_system 1.125\module_scripts.py", line 40598
    ("debug_variables",
    ^
IndentationError: unexpected indent
Traceback (most recent call last):
  File "process_tableau_materials.py", line 8, in <module>
    from process_operations import *
  File "C:\Documents and Settings\Paul Scherer\Desktop\New Folder\mb_warband_mod
ule_system_1125\Module_system 1.125\process_operations.py", line 20, in <module>

    from module_scripts import *
  File "C:\Documents and Settings\Paul Scherer\Desktop\New Folder\mb_warband_mod
ule_system_1125\Module_system 1.125\module_scripts.py", line 40598
    ("debug_variables",
    ^
IndentationError: unexpected indent
Traceback (most recent call last):
  File "process_presentations.py", line 4, in <module>
    from module_presentations import *
  File "C:\Documents and Settings\Paul Scherer\Desktop\New Folder\mb_warband_mod
ule_system_1125\Module_system 1.125\module_presentations.py", line 2372
    ("game_multiplayer_admin_panel", prsntf_manual_end_only, 0, [
    ^
IndentationError: unexpected indent
Exporting party_template data...
Traceback (most recent call last):
  File "process_parties.py", line 4, in <module>
    from module_game_menus import *
  File "C:\Documents and Settings\Paul Scherer\Desktop\New Folder\mb_warband_mod
ule_system_1125\Module_system 1.125\module_game_menus.py", line 13572
    (
    ^
IndentationError: unexpected indent
Exporting quest data...
Exporting info_page data...
Traceback (most recent call last):
  File "process_scripts.py", line 4, in <module>
    from module_scripts import *
  File "C:\Documents and Settings\Paul Scherer\Desktop\New Folder\mb_warband_mod
ule_system_1125\Module_system 1.125\module_scripts.py", line 40598
    ("debug_variables",
    ^
IndentationError: unexpected indent
Traceback (most recent call last):
  File "process_mission_tmps.py", line 8, in <module>
    from process_operations import *
  File "C:\Documents and Settings\Paul Scherer\Desktop\New Folder\mb_warband_mod
ule_system_1125\Module_system 1.125\process_operations.py", line 20, in <module>

    from module_scripts import *
  File "C:\Documents and Settings\Paul Scherer\Desktop\New Folder\mb_warband_mod
ule_system_1125\Module_system 1.125\module_scripts.py", line 40598
    ("debug_variables",
    ^
IndentationError: unexpected indent
Traceback (most recent call last):
  File "process_game_menus.py", line 5, in <module>
    from module_game_menus import *
  File "C:\Documents and Settings\Paul Scherer\Desktop\New Folder\mb_warband_mod
ule_system_1125\Module_system 1.125\module_game_menus.py", line 13572
    (
    ^
IndentationError: unexpected indent
Traceback (most recent call last):
  File "process_simple_triggers.py", line 5, in <module>
    from process_operations import *
  File "C:\Documents and Settings\Paul Scherer\Desktop\New Folder\mb_warband_mod
ule_system_1125\Module_system 1.125\process_operations.py", line 20, in <module>

    from module_scripts import *
  File "C:\Documents and Settings\Paul Scherer\Desktop\New Folder\mb_warband_mod
ule_system_1125\Module_system 1.125\module_scripts.py", line 40598
    ("debug_variables",
    ^
IndentationError: unexpected indent
Traceback (most recent call last):
  File "process_dialogs.py", line 9, in <module>
    from process_operations import *
  File "C:\Documents and Settings\Paul Scherer\Desktop\New Folder\mb_warband_mod
ule_system_1125\Module_system 1.125\process_operations.py", line 20, in <module>

    from module_scripts import *
  File "C:\Documents and Settings\Paul Scherer\Desktop\New Folder\mb_warband_mod
ule_system_1125\Module_system 1.125\module_scripts.py", line 40598
    ("debug_variables",
    ^
IndentationError: unexpected indent
Traceback (most recent call last):
  File "process_global_variables_unused.py", line 3, in <module>
    from process_operations import *
  File "C:\Documents and Settings\Paul Scherer\Desktop\New Folder\mb_warband_mod
ule_system_1125\Module_system 1.125\process_operations.py", line 20, in <module>

    from module_scripts import *
  File "C:\Documents and Settings\Paul Scherer\Desktop\New Folder\mb_warband_mod
ule_system_1125\Module_system 1.125\module_scripts.py", line 40598
    ("debug_variables",
    ^
IndentationError: unexpected indent
Exporting postfx_params...

______________________________

Script processing has ended.
Press any key to exit. . .

I would greatly appreciate any help. I didn't know anything about computer programing until yesterday, when I did an all nighter learning about the basics of modding Mount&Blade. I still don't know much, and I am overwhelmed. Also, I'm confused a little from all the old source codes from earlier M&B tutorials.
 
One thing I'm having trouble with - A companion was the leader of one of my squads, and he left the party. It still shows him as the leader of the squad, but he is not in my party list, and I cannot talk to him to "demote" him to not lead the squad. He also shows up in battles, but I cannot find him in any of the taverns. So is this an instance where I should restart the game or what?

Also, whenever the opportunity to recruit people from battles into my army arises and I don't take them, my "companion" will automatically take them. Pretty neat but IDK.
 
Hello I have added this great source code in my Warband but I have several problems, not at compile time, otherwise when I'm in the game. It says something about "... no group leader" or similar.

Besides that I also got problems when I give orders to form.
I do not understand the reason that this does not work.

So I wonder if u would be very difficult to explain how Warband pass without problems.
This is a great source code and I would love to use in Warband.

That is all. Thank you for creating this excellent code!

P/D: Please excuse my bad english.
 
I've been trying to combine this with Diplomacy, and I've gotten it pretty close to working. I have a few problems though. I can assign a companion to lead a Rank, and then assign men to it. However, when I get into battle the Rank of troops aren't considered mine, when I press X to bring up the Ranks, they are all empty and any orders I give are ignored. They also don't have my banner on their shields, they instead have the default red/black. At the end of the battle, the casualties are shown as "ally" casualties. Also there seems to be a huge amount of lag from something, like a script firing a million times a second. I'm getting about 10 FPS with about 50 soldiers in-game. And yes, my PC can handle the game, I usually have battle-sizer set to 600 or so, and unless I'm jammed in the middle of all 600 my FPS doesn't get that low usually.

I'm not sure what I did wrong, can someone more experienced point me in the right direction?

P.S.

When I use the formation orders and such on my Main Battle with no troops in the other Ranks everything works. I'm pretty sure the problem is that they aren't considered "my troops" and I'm trying to figure out where my mistake is, but I'm new at this and half the stuff I didn't understand I just looked at what was in the ##Form Ranks## comments, found where it was in the file and added it to where it was supposed to go in my file.

P.S.S.


Form Ranks Script:
  # script_update_agent_position_on_map
  # Input: arg1 = agent_no, pos2 = map_size_pos
  # Output: none
  ("update_agent_position_on_map",
  [(store_script_param_1, ":agent_no"),
    (agent_get_slot, ":agent_overlay", ":agent_no", slot_agent_map_overlay_id),

    (get_player_agent_no, ":player_agent"),
    (try_begin),
      (le, ":agent_overlay", 0),
      (set_fixed_point_multiplier, 1000),
      (try_begin),
        (eq, ":agent_no", ":player_agent"),
        (create_mesh_overlay, reg1, "mesh_player_dot"),
        (position_set_x, pos1, 500),
        (position_set_y, pos1, 500),
        (overlay_set_size, reg1, pos1),
      (else_try),
        (create_mesh_overlay, reg1, "mesh_white_dot"),
        (position_set_x, pos1, 200),
        (position_set_y, pos1, 200),
        (overlay_set_size, reg1, pos1),
      (try_end),
      (overlay_set_alpha, reg1, 0x8:cool:,
      (agent_set_slot, ":agent_no", slot_agent_map_overlay_id, reg1),
      (assign, ":agent_overlay", reg1),
    (try_end),

    (try_begin),
      (neq, ":agent_no", ":player_agent"),
      (agent_get_party_id, ":agent_party", ":agent_no"),
      ###############################
      # Changed by Form Ranks kit
      #
      (try_begin),
        (assign, ":continue", 0),
        (try_for_range, ":i", 1, "$formation_max_array_no"),
                (store_add, ":slot", slot_party_array_parties_begin, ":i"),
                (party_get_slot, ":array_party", formation_global_vector, ":slot"),
                (eq, ":array_party", ":agent_party"),
                (assign, ":continue", 1),
        (try_end),
        (this_or_next|eq, ":agent_party", "p_main_party"),
        (eq, ":continue", 1),
      #
      # Change of Form Ranks kit end
      ###############################
        (agent_get_class, ":agent_class", ":agent_no"),
        (try_begin),
          (eq, ":agent_class", grc_archers),
          (overlay_set_color, ":agent_overlay", 0x34c6e4),
        (else_try),
          (eq, ":agent_class", grc_cavalry),
          (overlay_set_color, ":agent_overlay", 0x569619),
      (else_try),
          #grc_infantry
          (overlay_set_color, ":agent_overlay", 0x8d5220),
        (try_end),
      (else_try),
        (agent_is_ally, ":agent_no"),
        (overlay_set_color, ":agent_overlay", 0x5555FF),
      (else_try),
        (overlay_set_color, ":agent_overlay", 0xFF0000),
      (try_end),
    (try_end),

    (try_begin),
      (eq, ":agent_no", ":player_agent"),
      (agent_get_look_position, pos1, ":agent_no"),
      (position_get_rotation_around_z, ":rot", pos1),
      (init_position, pos10),
      (position_rotate_z, pos10, ":rot"),
      (overlay_set_mesh_rotation, ":agent_overlay", pos10),
      (call_script, "script_convert_3d_pos_to_map_pos"),
    (else_try),
      (agent_get_position, pos1, ":agent_no"),
      (call_script, "script_convert_3d_pos_to_map_pos"),
    (try_end),
    (overlay_set_position, ":agent_overlay", pos0),
  ]),

Diplomacy Script:
  # script_update_agent_position_on_map
  # Input: arg1 = agent_no, pos2 = map_size_pos
  # Output: none
  ("update_agent_position_on_map",
  [(store_script_param_1, ":agent_no"),
    (agent_get_slot, ":agent_overlay", ":agent_no", slot_agent_map_overlay_id),

    (get_player_agent_no, ":player_agent"),
    (try_begin),
      (le, ":agent_overlay", 0),
      (set_fixed_point_multiplier, 1000),
      (try_begin),
        (eq, ":agent_no", ":player_agent"),
        (create_mesh_overlay, reg1, "mesh_player_dot"),
        (position_set_x, pos1, 500),
        (position_set_y, pos1, 500),
        (overlay_set_size, reg1, pos1),
      (else_try),
        (create_mesh_overlay, reg1, "mesh_white_dot"),
        (position_set_x, pos1, 200),
        (position_set_y, pos1, 200),
        (overlay_set_size, reg1, pos1),
      (try_end),
      (overlay_set_alpha, reg1, 0x8:cool:,
      (agent_set_slot, ":agent_no", slot_agent_map_overlay_id, reg1),
      (assign, ":agent_overlay", reg1),
    (try_end),

    (try_begin),
      (neq, ":agent_no", ":player_agent"),
      (agent_get_party_id, ":agent_party", ":agent_no"),
      (try_begin),
        (eq, ":agent_party", "p_main_party"),
        (agent_get_division, ":agent_division", ":agent_no"),
        (try_begin),
          (eq, ":agent_division", 0),
          (overlay_set_color, ":agent_overlay", 0x8d5220),
        (else_try),
          (eq, ":agent_division", 1),
          (overlay_set_color, ":agent_overlay", 0x34c6e4),
        (else_try),
          (eq, ":agent_division", 2),
          (overlay_set_color, ":agent_overlay", 0x569619),
        (else_try),
          (eq, ":agent_division", 3),
          (overlay_set_color, ":agent_overlay", 0xFFE500),
        (else_try),
          (eq, ":agent_division", 4),
          (overlay_set_color, ":agent_overlay", 0x990099),
        (else_try),
          (eq, ":agent_division", 5),
          (overlay_set_color, ":agent_overlay", 0x99FE80),
        (else_try),
          (eq, ":agent_division", 6),
          (overlay_set_color, ":agent_overlay", 0x9DEFFE),
        (else_try),
          (eq, ":agent_division", 7),
          (overlay_set_color, ":agent_overlay", 0xFECB9D),
        (else_try),
          (eq, ":agent_division", :cool:,
          (overlay_set_color, ":agent_overlay", 0xB19C9C),
        (try_end),
      (else_try),
        (agent_is_ally, ":agent_no"),
        (overlay_set_color, ":agent_overlay", 0x5555FF),
      (else_try),
        (overlay_set_color, ":agent_overlay", 0xFF0000),
      (try_end),
    (try_end),

    (try_begin),
      (eq, ":agent_no", ":player_agent"),
      (agent_get_look_position, pos1, ":agent_no"),
      (position_get_rotation_around_z, ":rot", pos1),
      (init_position, pos10),
      (position_rotate_z, pos10, ":rot"),
      (overlay_set_mesh_rotation, ":agent_overlay", pos10),
      (call_script, "script_convert_3d_pos_to_map_pos"),
    (else_try),
      (agent_get_position, pos1, ":agent_no"),
      (call_script, "script_convert_3d_pos_to_map_pos"),
    (try_end),
    (overlay_set_position, ":agent_overlay", pos0),
  ]),



And my merger:
  # script_update_agent_position_on_map
  # Input: arg1 = agent_no, pos2 = map_size_pos
  # Output: none
  ("update_agent_position_on_map",
  [(store_script_param_1, ":agent_no"),
    (agent_get_slot, ":agent_overlay", ":agent_no", slot_agent_map_overlay_id),

    (get_player_agent_no, ":player_agent"),
    (try_begin),
      (le, ":agent_overlay", 0),
      (set_fixed_point_multiplier, 1000),
      (try_begin),
        (eq, ":agent_no", ":player_agent"),
        (create_mesh_overlay, reg1, "mesh_player_dot"),
        (position_set_x, pos1, 500),
        (position_set_y, pos1, 500),
        (overlay_set_size, reg1, pos1),
      (else_try),
        (create_mesh_overlay, reg1, "mesh_white_dot"),
        (position_set_x, pos1, 200),
        (position_set_y, pos1, 200),
        (overlay_set_size, reg1, pos1),
      (try_end),
      (overlay_set_alpha, reg1, 0x8:cool:,
      (agent_set_slot, ":agent_no", slot_agent_map_overlay_id, reg1),
      (assign, ":agent_overlay", reg1),
    (try_end),

    (try_begin),
      (neq, ":agent_no", ":player_agent"),
      (agent_get_party_id, ":agent_party", ":agent_no"),
      ###############################
      # Changed by Form Ranks kit
      #
      (try_begin),
        (assign, ":continue", 0),
        (try_for_range, ":i", 1, "$formation_max_array_no"),
                (store_add, ":slot", slot_party_array_parties_begin, ":i"),
                (party_get_slot, ":array_party", formation_global_vector, ":slot"),
                (eq, ":array_party", ":agent_party"),
                (assign, ":continue", 1),
        (try_end),
        (this_or_next|eq, ":agent_party", "p_main_party"),
        (eq, ":continue", 1),
      #
      # Change of Form Ranks kit end
      ###############################
        (agent_get_class, ":agent_class", ":agent_no"),  
      (try_begin),
        (eq, ":agent_party", "p_main_party"),
        (agent_get_division, ":agent_division", ":agent_no"),
        (try_begin),
          (eq, ":agent_division", 0),
          (overlay_set_color, ":agent_overlay", 0x8d5220),
        (else_try),
          (eq, ":agent_division", 1),
          (overlay_set_color, ":agent_overlay", 0x34c6e4),
        (else_try),
          (eq, ":agent_division", 2),
          (overlay_set_color, ":agent_overlay", 0x569619),
        (else_try),
          (eq, ":agent_division", 3),
          (overlay_set_color, ":agent_overlay", 0xFFE500),
        (else_try),
          (eq, ":agent_division", 4),
          (overlay_set_color, ":agent_overlay", 0x990099),
        (else_try),
          (eq, ":agent_division", 5),
          (overlay_set_color, ":agent_overlay", 0x99FE80),
        (else_try),
          (eq, ":agent_division", 6),
          (overlay_set_color, ":agent_overlay", 0x9DEFFE),
        (else_try),
          (eq, ":agent_division", 7),
          (overlay_set_color, ":agent_overlay", 0xFECB9D),
        (else_try),
          (eq, ":agent_division", :cool:,
          (overlay_set_color, ":agent_overlay", 0xB19C9C),
        (try_end),
      (else_try),
        (agent_is_ally, ":agent_no"),
        (overlay_set_color, ":agent_overlay", 0x5555FF),
      (else_try),
        (overlay_set_color, ":agent_overlay", 0xFF0000),
      (try_end),
    (try_end),

    (try_begin),
      (eq, ":agent_no", ":player_agent"),
      (agent_get_look_position, pos1, ":agent_no"),
      (position_get_rotation_around_z, ":rot", pos1),
      (init_position, pos10),
      (position_rotate_z, pos10, ":rot"),
      (overlay_set_mesh_rotation, ":agent_overlay", pos10),
      (call_script, "script_convert_3d_pos_to_map_pos"),
    (else_try),
      (agent_get_position, pos1, ":agent_no"),
      (call_script, "script_convert_3d_pos_to_map_pos"),
    (try_end),
    (overlay_set_position, ":agent_overlay", pos0),
  ]),

Specifically the errors I get are:
WARNING: Local variable never used: agent_class, at: update_agent_position_on_map
ERROR: Usage of unassigned local variable: :agent_party

Ingame I get slammed by update_agent_position_on_map, and update_formation_order_panel_statistics_andmap errors, once a second which seems to be what was causing the lag.


I've been working on this for over six hours now...time to take a break.

 
i keep getting this message when i try to load form ranks...

get_object failed for body: bo_seige_leadder_12m​

then it crashes, how do i fix it?
 
Back
Top Bottom