# M4 modconfig example — a small, tasteful gameplay tweak (no ROM bytes).
#
# This is a "modconfig.txt-only" mod: it ships no ROM patch, no textures, no
# models. It carries only the gameplay-config section that the PC runtime
# applies into the game's own tables over the vanilla base (D991 data core,
# D992 Rule-2 hooks, D993 config-only import). Load it with:
#
#   python tools_pc/modprepare.py --name m4example --config-only \
#       --modconfig tools_pc/mods-example/modconfig.txt
#   ./build-pc/ge007.x86_64.exe --mod m4example        (or F10  Game.Mod=m4example)
#
# The import writes the cache under data/mods/m4example/.import/mod.json
# (gitignored); the tracked source is this file.
#
# --- Grammar (Dab-style: one block per line, '{' opens, '}' closes) -----
#   weapon <itemID> { field value [ field value ... ] }
#   ammo   <ammoType> { max N }
#   damage { global X }
#   pickupqty { <ammoType> <qty> [ <ammoType> <qty> ... ] }
#   unlocks { all }
#
# Weapon fields (any subset):
#   magSize autoFiringRate singleFiringRate objectsShootThrough
#   destructionAmount inaccuracy zoom crosshairSpeed aimLockSpeed
#   sway forceOfImpact ammoType
#
# IDs may be written as a number OR as the enum name, and the import echoes
# the name it resolved ("modconfig: weapon 13 = ITEM_M16") -- check that line,
# because a wrong id is applied to a different weapon and the mod then looks
# like it does nothing in game (D994).
#
# Both enums have a zero slot you do NOT want (src/bondconstants.h):
#   ITEM_IDS starts at ITEM_UNARMED=0, so: PP7=4 (ITEM_WPPK),
#     SILENCED PP7=5 (ITEM_WPPKSIL -- what you spawn holding on the Dam),
#     KF7=8, Klobb=7, M16=13, Sniper=17, Goldengun=19, Laser=22,
#     Grenadelauncher=24.
#   AMMOTYPE starts at AMMO_NONE=0, so: 9mm=1, 9mm(2)=2, Rifle=3, Shotgun=4,
#     Grenade=5, Rockets=6, Magnum=12, Goldengun=13.

# --- The tweak: a "Moonraker-style" retune ------------------------------
# Bigger magazine on the M16, roomier rifle-ammo carry, 25% more damage
# against the AI, and pickups that top you up faster. These numbers are
# deliberately plain and readable, not a tuning you'd necessarily ship --
# edit them to taste. (Firing-rate / inaccuracy / sway fields are also
# available if you want to retune feel; their polarity is set by the game.)

weapon ITEM_M16 { magSize 36 }       # M16: 36-round magazine
ammo   AMMO_RIFLE { max 200 }        # rifle ammo: carry up to 200
damage { global 1.25 }               # x1.25 damage vs the AI/autogun scalars
pickupqty { AMMO_RIFLE 120 AMMO_9MM 60 }   # rifle pickup -> 120; 9mm -> 60
# unlocks { all }                    # (optional) start with every weapon unlocked
