BAR modding tweakdef basics: weapons, shields, and custom defs

How BAR modders use tweak definition files to create custom units, weapons, and visual effects.

Tags: bar modding, tweakdefs, unit editing, weapon defs, shield weapons, beyond all reason

What are tweakdefs in BAR

Tweak definitions are the main way modders change existing units or build entirely custom ones. A tweakdef file lets you override specific fields of a base unit definition without touching core game files. You tweak the weapon list, swap armor classes, add custom projectile behavior, or change what shows up on screen.

The system works through inheritance. You reference a parent unit, then list only the fields you want to change. Everything else carries over. That keeps mod files small and easy to manage.

The noweapon field

Setting a weapon slot to noweapon is the standard way to remove firing capability from a unit. Modders use this when building purely decorative units, transport variants, or when creating units that serve a specific mechanical role without combat output.

You can strip one weapon slot while keeping others active. That gives fine control over exactly what the unit can and cannot fire.

Making shields fire projectiles

A frequent modder question involves whether shield generators can also output weapon fire. The engine treats shield definitions as a separate subsystem from weapon definitions. Shield generators create protective barriers and damage mitigation zones. Weapons output projectiles and damage.

Modders who want a unit that both projects a shield and fires weapons need to define both systems. You cannot simply "fire a shield" by pointing a weapon slot at a shield definition. The workaround is to attach an actual weapon alongside the shield component in the unit definition.

Where modders run into errors

The most common mistakes come from incomplete definitions. Referencing a parent unit and then overriding fields incorrectly can produce units with broken weapon slots, missing collision volumes, or visual artifacts.

Always test custom units in an empty lobby match before deploying. Look at the game log for warnings about missing definitions or invalid references. The engine will load a unit with errors but the behavior will be unpredictable.

Useful modding workflow

  • Start with the base unit definition you want to modify
  • Create a new tweakdef file referencing that parent
  • Override only the fields you need to change
  • Set unwanted weapon slots to noweapon
  • Test in a controlled match with a friendly player
  • Check the game log for warnings each time

Join a modding-friendly community

BAR modding is easier when you have people to bounce questions off of. Creed of Champions keeps things focused and respectful while players learn. One member put it this way:

Crd is the first really comfortable community I have been a part of. Everyone is nice and kind, the atmosphere is relaxed, and I am not getting yelled at for not being optimal.

Watch BAR gameplay videos from the community here.

Advertisement