Search results

  1. BL Coding Help initializing a battle of my own

    Hello everyone, I need to initialize a field battle within my campaign and, while searching for how native starts its battles I found how it started its custom battle. It uses the function "OpenCustomBattleMission" which can be found in the class "BannerlordMissions". This is the function which...
  2. BL Coding I am having some difficulty creating a dropdown menu

    Hey everyone, I am working on a GUI for my mod and I need to create a dropdown menu. I am having some difficulties doing it though and the mod I am using as an example is not helping. I am looking for other mod examples which have dropdown menus I can take inspiration from. Thank you in advance
  3. BL Coding How are orders issued to your own troops?

    Hello everyone, I already know how the enemy AI fights against the player, it uses the classes Tactics which give Behaviors to each formation. What I need to learn is how the player gives orders to their owns troops. Using the default controls, when I press "1" it selects infantry and when I...
  4. BL Coding Is there a way to create new Behaviors from BehaviorComponent?

    Hello @Kazet,
    Thank you so much for your answer. It actually worked and I managed to get a behavior working. Thank you so much. I am a little frustrated because your solution is quite similar to a solution I originally tried but was unsuccessful. Turns out I only had to change a little detail in my original solution to get to yours and have it working. Thank you so very much for your help! I've been having this issue for weeks now.
  5. BL Coding Is there a way to create new Behaviors from BehaviorComponent?

    Hey thanks for the response. That was more or less what I've been trying to do but the problem is the internal keyword exactly. In other classes which extend BehaviorComponent, they always extend the base class with reference to the formation such as:
    public BehaviorCharge(Formation formation)
    : base(formation)
    {
    CalculateCurrentOrder();
    base.BehaviorCoherence = 0.5f;

    }
    But, since we are not working on the taleworlds.mountandblade.dll we cannot access both the behaviorComponent(Formation formation) constructor and the base.formation. I have tried what you sugested but my IDE doesn't even recognize those methods. It says there is no constructor which takes one argument for BehaviorComponent.
    erL2C9T.png
  6. BL Coding Is there a way to create new Behaviors from BehaviorComponent?

    Hello everyone, I am currently working on a mod that aims to overhaul the battle AI currently implemented on Bannerlord. I am using Harmony and I already know what I need to do in order to change the AI during a battle. I have created my own tactics which use the behaviors already implemented by...
  7. Is there a way to create new Behaviors from BehaviorComponent?

    Hello everyone, I am currently working on a mod that aims to overhaul the battle AI currently implemented on Bannerlord. I am using Harmony and I already know what I need to do in order to change the AI during a battle. I have created my own tactics which use the behaviors already implemented by...
  8. BL Coding Battle AI and formations

    Greetings, I am currently working on a mod that aims to improve battle planning and battle AI for NPC lords as well as defining formations prior to battle. I have been reading Bannerlord's source code and managed to find, with some help from this forum, where troops are stored and managed...
  9. BL Coding Help finding party information an respective GUI

    Hello everyone, I am starting to learn how to mod Bannerlord in order to try and build a mod focused on army placement before battles. I've been reading the game's source code but I would like to have some help finding what I need: - When you encounter an hostile party a GUI appears asking if...
Top Bottom