Battle Brothers
0 of 0

File information

Last updated

Original upload

Created by

Adam

Uploaded by

AdamMil01

Virus scan

Safe to use

210 comments

  1. AdamMil01
    AdamMil01
    • premium
    • 51 kudos
    Locked
    Sticky
    To mod authors using mod_hooks: Please use the ::mods_queue feature (new as of mod_hooks version 15) in future versions of your mods. This lets mods declare dependencies and incompatibilities with other mods so that mod_hooks can dynamically reorder the mods to satisfy their dependencies, and I hope it will become standard. Even if you don't have any relationships to declare, using ::mods_queue ensures that your mod can participate in the dynamic ordering. See the description tab for more details. Also, this feature is new, so please let me know if you run into any problems. Converting a mod is simple. If your mod normally does:

    ::mods_registerMod("foo", 1);
    ... your hooks here ...

    Change it to:

    ::mods_registerMod("foo", 1);
    ::mods_queue(null, null, function()
    {
    ... your hooks here ...
    });

    Also, since version 16, the restrictions on mod names and versions are enforced. See the documentation for ::mods_registerMod for details.

    As of version 19, mod authors must exercise special care if they compile their own .cnut files (which is usually not necessary). See the documentation for ::mods_hookClass for details.

    As of version 20, it is now possible (usually) to hook exact classes rather than hooking a base class and trying to find a particular child. See ::mods_hookExactClass for details.

    As of version 21, 'new' hooks work more reliably (i.e. in more situations), but class-based hooks are still better if applicable.
  2. kudorgyozo
    kudorgyozo
    • member
    • 0 kudos
    Is there a version for base game only without any dlcs?
    1. AdamMil01
      AdamMil01
      • premium
      • 51 kudos
      I think it works for all game versions?
  3. Rajulio
    Rajulio
    • member
    • 0 kudos
    Does anyone know of any good youtube tutorials for using this? I'm not at all experienced in programming and looking at this makes a physical woosh sound because it just goes over my head. 
  4. koreec49
    koreec49
    • member
    • 3 kudos
    ::mods_addField("skills/skill", "skill", "CanTargetAlly", false);
    how to do it properly?
  5. Endur1el
    Endur1el
    • premium
    • 35 kudos
    This does work with the latest game version for all the people who are confused.
  6. filipmolnar
    filipmolnar
    • member
    • 1 kudos
    Is this going to get updated?
  7. ironmonkbr
    ironmonkbr
    • member
    • 0 kudos
    I'm holding myself from starting a new playthrough because I'm waiting for some mods to be updated first.

    And I'm confused about this mod been compatible or not with the current game version... and since nobody posted here recently, I don't know.

    So, is the current modhooks compatible with the new free DLC?

    If not, is there any chance we might get an updated version?
    1. gauen
      gauen
      • supporter
      • 0 kudos
      wondering this too, I've tried running this and smart recruiter and had one recurrent critical exception(crash) shortly after campaign start.
    2. Risso
      Risso
      • premium
      • 0 kudos
      People have been releasing mods for the new DLC that require this one so I think it's safe to assume it's mostly if not fully compatible
    3. Amberwarlock
      Amberwarlock
      • member
      • 0 kudos
      seems to not work for me unfortunately
    4. joffree
      joffree
      • member
      • 0 kudos
      im pretty sure it dosnt work, right now the only way i can get fantasy bros to work i if i install legend mod, i guess its script hook is more up to date. but it crashes the game
    5. Nubcookie
      Nubcookie
      • member
      • 0 kudos
      Seems to have worked for me, just started adding mods one by one - the hooks and the basic cart mod dependent on them seem to be working so far.
  8. dzkingcn
    dzkingcn
    • member
    • 1 kudos
    Hello Adam, I'm now learning how to use mod script hooks, can you give me an example of ::mods_addField()? i'd want to add variables in "m" for a skill
    for example:

    isAstray and isHit is 2 new variables i want to add. How to add it by hooks using ::mods_addField()?
    1. Flash2
      Flash2
      • member
      • 1 kudos
      I would like to know the same. Or can someone link a mod were this is used?
  9. koreec49
    koreec49
    • member
    • 3 kudos
    Hey guys maybe someone can help me?
    I'm trying to change values in 'm' of named weapon i already own.
    ::mods_hookNewObject("items/weapons/named/named_axe", function(wpn) {
    wpn.m.CritChanceBonus = this.Math.floor((wpn.m.ArmorDamageMult - 1.3) * 50);
    });
    though it takes 'm' of basic named_axe with basic 'm' values. Or it applies CritChanceBonus based on ArmorDamageMult before deserealizing? How to make it take m.ArmorDamageMult of instance of named_axe with deserealized values?
    1. koreec49
      koreec49
      • member
      • 3 kudos
      i used UpdateVariat() to make my changes and fixed it
  10. mcdaddyspanklord
    mcdaddyspanklord
    • member
    • 0 kudos
    It says Main menu screen is undefined and I dont know how to fix it.
  11. Sectopod
    Sectopod
    • member
    • 0 kudos
    Hi.
    I'd like to use this mod and Davkul rising but when I install the mod hooks as per the tutorial, the game fails to launch.
    When I remove the mod hook from my data folder it works.
    Is there any solution to this? Thanks