From 4f26f4d4251e2e1918c702c078f661082e1fd1c9 Mon Sep 17 00:00:00 2001 From: Leonard Jonathan Oh Date: Sat, 21 Jan 2023 07:24:33 +0000 Subject: [PATCH] Fix (development): Add `bf2` server and Gamespy server in `docker-compose.yml` to setup a full development stack simply by `docker-compose up` - `docker-compose up` now spins up a full development BF2 stack. The client only has to spoof Gamespy DNS in their hosts file, and create a new account on the first time if using the included gamespy server. - `traefik`, the web reverse proxy, is added in `docker-compose.yml` only for the BF2 client BFHQ to work properly (i.e. access the `ASP` via `http://bf2web.gamespy.com`) - BF2 server debug logging is turned on in `BF2StatisticsConfig.py`. Logs are ignored in `.gitignore`. --- .env | 1 + .gitignore | 3 + README.md | 63 +- .../bf2/ai/aibehaviours-fixlookatwrapper.ai | 822 ++++++++++++++++++ config/bf2/mods/bf2/ai/aidefault-custom.ai | 21 + .../bf2/ai/aidefaultstrategies-custom-esai.ai | 12 + .../ai/aidefaultstrategiesadd-custom-esai.ai | 2 + .../mods/bf2/settings/maplist-custom-coop.con | 24 + .../mods/bf2/settings/maplist-custom-cq.con | 82 ++ .../bf2/settings/serversettings-custom.con | 68 ++ .../python/bf2/BF2StatisticsConfig-custom.py | 109 +++ docker-compose.test.yml | 1 - docker-compose.yml | 90 +- 13 files changed, 1287 insertions(+), 11 deletions(-) create mode 100644 .env create mode 100644 config/bf2/mods/bf2/ai/aibehaviours-fixlookatwrapper.ai create mode 100644 config/bf2/mods/bf2/ai/aidefault-custom.ai create mode 100644 config/bf2/mods/bf2/ai/aidefaultstrategies-custom-esai.ai create mode 100644 config/bf2/mods/bf2/ai/aidefaultstrategiesadd-custom-esai.ai create mode 100644 config/bf2/mods/bf2/settings/maplist-custom-coop.con create mode 100644 config/bf2/mods/bf2/settings/maplist-custom-cq.con create mode 100644 config/bf2/mods/bf2/settings/serversettings-custom.con create mode 100644 config/bf2/python/bf2/BF2StatisticsConfig-custom.py diff --git a/.env b/.env new file mode 100644 index 00000000..9a2f2c31 --- /dev/null +++ b/.env @@ -0,0 +1 @@ +COMPOSE_PROJECT_NAME=bf2stats diff --git a/.gitignore b/.gitignore index 7bb73573..9174c38f 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,4 @@ /src/ASP/system/config/config.php.bak +/src/python/bf2/logs/*.log +/src/python/bf2/logs/snapshots/sent/*.txt +/src/python/bf2/logs/snapshots/unsent/*.txt diff --git a/README.md b/README.md index c070eb82..95ff0627 100644 --- a/README.md +++ b/README.md @@ -23,21 +23,67 @@ See [this](docs/bf2hub-bf2stats-example) example showing how to deploy [Battlefi ## Development -- Install `docker` and `docker-compose` -- Install `vscode` for development. Install `vscode` extensions [`PHP Intelephense`](https://marketplace.visualstudio.com/items?itemName=bmewburn.vscode-intelephense-client) for intellisense, and [xdebug](https://marketplace.visualstudio.com/items?itemName=xdebug.php-debug) and for `php` debugging. -- To start `php` debugging, press `F5` in `vscode`. Set breakpoints in code, and whenever a page is loaded, `vscode` shows hit breakpoints. To stop debugging, press `shift+F5`. - ```sh -# Start -docker-compose up --build -# ASP available at http://localhost:8081/ASP. Username: admin, password admin. See ./config/ASP/config.php config file +# 1. Start BF2 server, Gamespy server, and bf2stats +docker-compose up +# ASP available at http://localhost:8081/ASP. Username: admin, password admin. See ./config/ASP/config.php # bf2sclone available at http://localhost:8082. # phpmyadmin available at http://localhost:8083. Username: admin, password: admin. See ./config/ASP/config.php config file +# 2. To setup the DB the first time, use $db_host, $db_port, $db_name, $db_user, $db_pass in ./config/ASP/config.php. Then, restart the BF2 server for stats to be recorded +docker-compose restart bf2 + +# 3. Before launching the BF2 client, spoof gamespy DNS by adding these entries in C:\Windows\system32\drivers\etc\hosts +# Replace '192.168.1.100' with your development machine's IP address +192.168.1.100 battlefield2.available.gamespy.com +192.168.1.100 battlefield2.master.gamespy.com +192.168.1.100 battlefield2.ms14.gamespy.com +192.168.1.100 master.gamespy.com +192.168.1.100 motd.gamespy.com +192.168.1.100 gpsp.gamespy.com +192.168.1.100 gpcm.gamespy.com +192.168.1.100 gamespy.com +192.168.1.100 bf2web.gamespy.com +192.168.1.100 gamestats.gamespy.com +192.168.1.100 eapusher.dice.se + +# 4. Launch BF2 client and connect to the BF2 server +# - To use BF2Hub as the Gamespy server, launch BF2.exe, and login to your BF2Hub account, and connect to the BF2 server using MULTIPLAYER > CONNECT TO IP +# - To use PRMasterserver in docker-compose as the Gamespy server, if you have previously patched BF2.exe using the BF2Hub patcher, you must unpatch BF2.exe. Then launch BF2.exe (do not use BF2Hub), create a new Online account, login, and connect to the BF2 server using MULTIPLAYER > CONNECT TO IP. +# At the end of a round, the BF2 server will send a stats snapshot to the ASP. View stats in ASP and bf2sclone. + +# Development - Install vscode extensions +# Once installed, set breakpoints in code, and press F5 to start debugging. +code --install-extension bmewburn.vscode-intelephense-client # PHP intellisense +code --install-extension xdebug.php-debug # PHP remote debugging via xdebug +code --install-extension ms-python.python # Python intellisense # If xdebug is not working, iptables INPUT chain may be set to DROP on the docker bridge. # Execute this to allow php to reach the host machine via the docker0 bridge sudo iptables -A INPUT -i br+ -j ACCEPT +# BF2 server - Restart server +docker-compose restart bf2 +# BF2 server - Attach to the bf2 server console +docker attach $( docker-compose ps -q bf2 ) +# BF2 server - Exec into container +docker exec -it $( docker-compose ps -q bf2) bash +# BF2 server - Read python logs +docker exec -it $( docker-compose ps -q bf2 ) bash -c 'cat python/bf2/logs/bf2game_*' +# BF2 server - List snapshots +docker exec -it $( docker-compose ps -q bf2 ) bash -c 'ls -al python/bf2/logs/snapshots/sent' +docker exec -it $( docker-compose ps -q bf2 ) bash -c 'ls -al python/bf2/logs/snapshots/unsent' + +# asp-php - Exec into container +docker exec -it $( docker-compose ps -q asp-php ) sh +# asp-php - Read logs +docker exec -it $( docker-compose ps -q asp-php ) cat /src/ASP/system/logs/php_errors.log +docker exec -it $( docker-compose ps -q asp-php ) cat /src/ASP/system/logs/stats_debug.log +docker exec -it $( docker-compose ps -q asp-php ) cat /src/ASP/system/logs/validate_awards.log +docker exec -it $( docker-compose ps -q asp-php ) cat /src/ASP/system/logs/validate_ranks.log +# asp-php - List snapshots +docker exec -it $( docker-compose ps -q asp-php ) ls -al /src/ASP/system/snapshots/processed +docker exec -it $( docker-compose ps -q asp-php ) ls -al /src/ASP/system/snapshots/temp + # Test routes docker-compose -f docker-compose.test.yml up @@ -53,11 +99,12 @@ docker exec $( docker-compose ps | grep db | awk '{print $1}' ) mysqldump -uroot # Restore the DB zcat bf2stats.sql.gz | docker exec -i $( docker-compose ps | grep db | awk '{print $1}' ) mysql -uroot -padmin bf2stats -# Stop +# Stop BF2 server, gamespy server and bf2stats docker-compose down # Cleanup docker-compose down +docker volume rm bf2stats_prmasterserver-volume docker volume rm bf2stats_backups-volume docker volume rm bf2stats_logs-volume docker volume rm bf2stats_snapshots-volume diff --git a/config/bf2/mods/bf2/ai/aibehaviours-fixlookatwrapper.ai b/config/bf2/mods/bf2/ai/aibehaviours-fixlookatwrapper.ai new file mode 100644 index 00000000..61a95f02 --- /dev/null +++ b/config/bf2/mods/bf2/ai/aibehaviours-fixlookatwrapper.ai @@ -0,0 +1,822 @@ +rem *** Set number of behaviours and id/name mappings *** +aiSettings.setMaxNumberOfBehaviours 13 + +aiSettings.setBehaviour 0 Avoid +aiSettings.setBehaviour 1 MoveTo +aiSettings.setBehaviour 2 Idle +aiSettings.setBehaviour 3 Fire +aiSettings.setBehaviour 4 TakeCover +aiSettings.setBehaviour 5 Change +aiSettings.setBehaviour 6 Special +aiSettings.setBehaviour 7 Revive +aiSettings.setBehaviour 8 c4 +aiSettings.setBehaviour 9 Special2 +aiSettings.setBehaviour 10 Special3 +aiSettings.setBehaviour 11 Random +aiSettings.setBehaviour 12 Triggerable + + +rem *** Set number of vehicles and id/name mappings *** +aiSettings.setVehicle Tank +aiSettings.setVehicle Plane +aiSettings.setVehicle Boat +aiSettings.setVehicle Infantery +aiSettings.setVehicle Fixed +aiSettings.setVehicle Car +aiSettings.setVehicle LandingCraft +aiSettings.setVehicle Passenger +aiSettings.setVehicle LandingCraftPassenger +aiSettings.setVehicle LandingCraftFixed +aiSettings.setVehicle Helicopter +aiSettings.setVehicle TransportHelicopter +aiSettings.setVehicle ArmedCar +aiSettings.setVehicle ManDown +aiSettings.setVehicle ParatrooperFixed + +aiSettings.setVehicleClusterMapping Tank Tank +aiSettings.setVehicleClusterMapping Boat LandingCraft +aiSettings.setVehicleClusterMapping Infantery Infantery +aiSettings.setVehicleClusterMapping Car Tank +rem aiSettings.setVehicleClusterMapping LandingCraft LandingCraft +aiSettings.setVehicleClusterMapping LandingCraft ArmedCar +aiSettings.setVehicleClusterMapping ArmedCar ArmedCar + + +rem *** Set Sensing Agent Patterns id/name mappings *** +aiSettings.setSensingAgentPatternName Turret +aiSettings.setSensingAgentPatternName MouseFreeLook +aiSettings.setSensingAgentPatternName Soldier +aiSettings.setSensingAgentPatternName Null +rem the null pattern +aiSettings.setSensingAgentNullPattern Null + + +aiSettings.setManDownEquipment ManDown + +rem *** IMPORTANT !!! ************************** +rem * NEVER ALLOW IDLE's urgency to become 0. * +rem * The AI will CRASH in that case. * +rem *** REMINDER ******************************* + +rem *** Construct unit weights *** +aiSettings.createBehaviourModifiers UnitWeights +aiSettings.setBehaviourModifier Avoid 1.0 +aiSettings.setBehaviourModifier MoveTo 1.0 +aiSettings.setBehaviourModifier Idle 1.0 +aiSettings.setBehaviourModifier Fire 1.0 +aiSettings.setBehaviourModifier Special 1.0 +aiSettings.setBehaviourModifier TakeCover 1.0 +aiSettings.setBehaviourModifier Change 1.0 +aiSettings.setBehaviourModifier Revive 1.0 +aiSettings.setBehaviourModifier c4 1.0 +aiSettings.setBehaviourModifier Special2 1.0 +aiSettings.setBehaviourModifier Special3 1.0 +aiSettings.setBehaviourModifier Random 1.0 +aiSettings.setBehaviourModifier Triggerable 1.0 + +rem *** Construct HeliMove weights *** +aiSettings.createBehaviourModifiers HeliMoveWeights +aiSettings.setBehaviourModifier Avoid 1.0 +aiSettings.setBehaviourModifier MoveTo 1.0 +aiSettings.setBehaviourModifier Idle 0.01 +aiSettings.setBehaviourModifier Fire 1.0 +aiSettings.setBehaviourModifier Special 1.0 +aiSettings.setBehaviourModifier TakeCover 1.0 +aiSettings.setBehaviourModifier Change 1.0 +aiSettings.setBehaviourModifier c4 1.0 +aiSettings.setBehaviourModifier Special2 1.0 +aiSettings.setBehaviourModifier Special3 1.0 +aiSettings.setBehaviourModifier Random 1.0 +aiSettings.setBehaviourModifier Triggerable 1.0 + +rem *** Construct standard weights *** +aiSettings.createBehaviourModifiers StandardWeights +aiSettings.setBehaviourModifier Avoid 1.0 +aiSettings.setBehaviourModifier MoveTo 1.0 +aiSettings.setBehaviourModifier Idle 0.1 +aiSettings.setBehaviourModifier Fire 7.5 +aiSettings.setBehaviourModifier Special 3.0 +aiSettings.setBehaviourModifier TakeCover 2.0 +aiSettings.setBehaviourModifier Change 1.9 +aiSettings.setBehaviourModifier Revive 3.0 +aiSettings.setBehaviourModifier c4 1.0 +aiSettings.setBehaviourModifier Special2 1.0 +aiSettings.setBehaviourModifier Special3 1.0 +aiSettings.setBehaviourModifier Random 1.0 +aiSettings.setBehaviourModifier Triggerable 1.0 + +rem *** Construct plane weights *** +aiSettings.createBehaviourModifiers PlaneWeights +aiSettings.setBehaviourModifier Avoid 0.0 +aiSettings.setBehaviourModifier MoveTo 1.0 +aiSettings.setBehaviourModifier Idle 0.1 +aiSettings.setBehaviourModifier Fire 1.5 +aiSettings.setBehaviourModifier Special 1.0 +aiSettings.setBehaviourModifier TakeCover 0.0 +aiSettings.setBehaviourModifier Change 0.0 +aiSettings.setBehaviourModifier Revive 1.0 +aiSettings.setBehaviourModifier c4 1.0 +aiSettings.setBehaviourModifier Special2 1.0 +aiSettings.setBehaviourModifier Special3 1.0 +aiSettings.setBehaviourModifier Random 1.0 +aiSettings.setBehaviourModifier Triggerable 1.0 + +rem *** Construct Avoid inhibitors *** +aiSettings.createBehaviourModifiers AvoidInhibit +aiSettings.setBehaviourModifier Avoid 1.0 +aiSettings.setBehaviourModifier MoveTo 0.3 +aiSettings.setBehaviourModifier Idle 1.0 +aiSettings.setBehaviourModifier Fire 1.0 +aiSettings.setBehaviourModifier Special 0.5 +aiSettings.setBehaviourModifier TakeCover 1.0 +aiSettings.setBehaviourModifier Change 1.0 +aiSettings.setBehaviourModifier Revive 1.0 +aiSettings.setBehaviourModifier c4 1.0 +aiSettings.setBehaviourModifier Special2 1.0 +aiSettings.setBehaviourModifier Special3 1.0 +aiSettings.setBehaviourModifier Random 1.0 +aiSettings.setBehaviourModifier Triggerable 1.0 + +rem *** Construct Change Inhibit *** +aiSettings.createBehaviourModifiers ChangeInhibit +aiSettings.setBehaviourModifier Avoid 0.8 +aiSettings.setBehaviourModifier MoveTo 0.0 +aiSettings.setBehaviourModifier Idle 0.01 +aiSettings.setBehaviourModifier Fire 0.75 +aiSettings.setBehaviourModifier Special 0.0 +aiSettings.setBehaviourModifier TakeCover 1.0 +aiSettings.setBehaviourModifier Change 1.0 +aiSettings.setBehaviourModifier Revive 1.0 +aiSettings.setBehaviourModifier c4 1.0 +aiSettings.setBehaviourModifier Special2 1.0 +aiSettings.setBehaviourModifier Special3 1.0 +aiSettings.setBehaviourModifier Random 1.0 +aiSettings.setBehaviourModifier Triggerable 1.0 + +rem *** Set basic weights for bot behaviour *** +aiSettings.setBasicBotWeights UnitWeights +aiSettings.setStandardPersonality UnitWeights 1 +aiSettings.setStandardPersonality UnitWeights 2 + +rem ************************* Vehicle behaviour setup ****************************** + +aiSettings.createUCConstant UCUnion 1.0 +aiSettings.createUCLinear UCFire -0.22 1.3 +aiSettings.createUCLinear UCCallForMedic 0.1 1 +aiSettings.createUCXInverse UCScout 2.5 0.9 1.0 0.5 + +rem *** Tank Behaviour setup *** +aisettings.setVehicleMods Tank StandardWeights +aiSettings.setVehicleMaterialCost Tank Ground 1 +aiSettings.setVehicleMaterialCost Tank Road 1 +aiSettings.setVehicleMaterialCost Tank Shallows 1.5 +aiSettings.setVehicleMaterialCost Tank DeepWater -1 +aiSettings.setVehicleBehaviour Tank Avoid BBAvoid BBPAvoidCollision2d 1 UCUnion AvoidInhibit +aiSettings.setVehicleBehaviour Tank MoveTo BBMoveTo BBPGotoWaypoint2d 4 UCUnion UnitWeights +aiSettings.setVehicleBehaviour Tank Idle BBIdle BBPIdle2d 5 UCUnion UnitWeights +aiSettings.setVehicleBehaviour Tank Fire BBFireInfantery BBPFireInfantery 4 UCFire UnitWeights +aiSettings.setVehicleBehaviour Tank Special2 BBBridgeRepair BBPBridgeRepair 15 UCUnion UnitWeights +aiSettings.setVehicleBehaviour Tank Special3 BBDefuseMines BBPDefuseMines 13 UCUnion UnitWeights +aiSettings.setVehicleBehaviour Tank Change BBChange BBPChange 6 UCUnion ChangeInhibit +aiSettings.setVehicleDefaultBehaviour Tank Idle +aiSettings.addInterpreterEntry Tank MoveToMedium Medium +aiSettings.addInterpreterEntry Tank MoveToObjectMedium Medium +aiSettings.addInterpreterEntry Tank InfoWrapper +aiSettings.addInterpreterEntry Tank TankMoveTo +aiSettings.addInterpreterEntry Tank TankTurnTo +aiSettings.addInterpreterEntry Tank TankMoveToDirection +aiSettings.addInterpreterEntry Tank TankMoveToObject +aiSettings.addInterpreterEntry Tank Trigger +aiSettings.addInterpreterEntry Tank TriggerContinously +aiSettings.addInterpreterEntry Tank MouseTurretAimAt +aiSettings.addInterpreterEntry Tank TankResetControls +aiSettings.addInterpreterEntry Tank MouseTurretLookAt +aiSettings.addInterpreterEntry Tank Sense +aiSettings.activateDefaultInterpreter Tank BAPSTOverrideSensingAgent Full +aiSettings.activateDefaultInterpreter Tank BAPSTParallel Full +aiSettings.activateDefaultInterpreter Tank BAPSTSerial Full +aiSettings.activateDefaultInterpreter Tank BAPSTPlanEnd Full +aiSettings.activateDefaultInterpreter Tank BAPSTIf Full +aiSettings.activateDefaultInterpreter Tank BAPSTWait Full +aiSettings.activateDefaultInterpreter Tank BAPSTWhile Full +aiSettings.activateDefaultInterpreter Tank BAPSTWeaponWrapper Full +aiSettings.activateDefaultInterpreter Tank BAPSTAimingWrapper Full +aiSettings.activateDefaultInterpreter Tank BAPSTFinishedWrapper Full +aiSettings.activateDefaultInterpreter Tank BAPSTUpdateVehicle Full +aiSettings.activateDefaultInterpreter Tank BAPSTChangeWeapon Full +aiSettings.activateDefaultInterpreter Tank BAPSTICTurnLock Full +aiSettings.activateDefaultInterpreter Tank BAPSTICChangeVehicle Full +aiSettings.activateDefaultInterpreter Tank BAPSTEvaluate Full +aiSettings.activateDefaultInterpreter Tank BAPSTNotifyBot Full +aiSettings.activateDefaultInterpreter Tank BAPSTIdle Full +aiSettings.activateDefaultInterpreter Tank BAPSTSetSensingAgentFocus Full +aiSettings.activateDefaultInterpreter Tank BAPSTMergeSoldierInputs Full +aiSettings.activateDefaultInterpreter Tank BAPSTSendRadioMessage Full +aiSettings.activateDefaultInterpreter Tank BAPSTLookAtWrapper Full +aiSettings.activateDefaultInterpreter Tank BAPSTDebug Full +aiSettings.activateDefaultInterpreter Tank BAPSTForgetTarget Full +aiSettings.activateDefaultInterpreter Tank BAPSTUseFlareOnMissileLock Full +aiSettings.activateDefaultInterpreter Tank BAPSTEvaluateCondition Full +aiSettings.addSensingAgentPattern Tank Turret + +rem *** Plane Behaviour setup *** +aisettings.setVehicleMods Plane StandardWeights +aiSettings.setVehicleBehaviour Plane MoveTo BBMoveTo BBPGotoWaypoint3d 4 UCUnion UnitWeights +aiSettings.setVehicleBehaviour Plane Idle BBIdle BBPIdle3d 5 UCUnion UnitWeights +aiSettings.setVehicleBehaviour Plane Fire BBFire3d BBPFire3d 4 UCFire UnitWeights +aiSettings.setVehicleBehaviour Plane Change BBChange BBPChange 6 UCUnion ChangeInhibit +aiSettings.setVehicleDefaultBehaviour Plane Idle +aiSettings.addInterpreterEntry Plane InfoWrapper +aiSettings.addInterpreterEntry Plane PlaneMoveTo +aiSettings.addInterpreterEntry Plane PlaneMoveToDirection +aiSettings.addInterpreterEntry Plane PlaneMoveToObject +aiSettings.addInterpreterEntry Plane Trigger +aiSettings.addInterpreterEntry Plane TriggerContinously +aiSettings.addInterpreterEntry Plane PlaneAimAt +aiSettings.addInterpreterEntry Plane PlaneResetControls +aiSettings.addInterpreterEntry Plane Sense +aiSettings.activateDefaultInterpreter Plane BAPSTParallel Full +aiSettings.activateDefaultInterpreter Plane BAPSTSerial Full +aiSettings.activateDefaultInterpreter Plane BAPSTIf Full +aiSettings.activateDefaultInterpreter Plane BAPSTWait Full +aiSettings.activateDefaultInterpreter Plane BAPSTWhile Full +aiSettings.activateDefaultInterpreter Plane BAPSTWeaponWrapper Full +aiSettings.activateDefaultInterpreter Plane BAPSTFinishedWrapper Full +aiSettings.activateDefaultInterpreter Plane BAPSTUpdateVehicle Full +aiSettings.activateDefaultInterpreter Plane BAPSTChangeWeapon Full +aiSettings.activateDefaultInterpreter Plane BAPSTICTurnLock Full +aiSettings.activateDefaultInterpreter Plane BAPSTICChangeVehicle Full +aiSettings.activateDefaultInterpreter Plane BAPSTEvaluate Full +aiSettings.activateDefaultInterpreter Plane BAPSTNotifyBot Full +aiSettings.activateDefaultInterpreter Plane BAPSTIdle Full +aiSettings.activateDefaultInterpreter Plane BAPSTSetSensingAgentFocus Full +aiSettings.activateDefaultInterpreter Plane BAPSTSendRadioMessage Full +aiSettings.activateDefaultInterpreter Plane BAPSTDebug Full +aiSettings.activateDefaultInterpreter Plane BAPSTUseFlareOnMissileLock Full +aiSettings.activateDefaultInterpreter Plane BAPSTEvaluateCondition Full +rem http://www.bfeditor.org/forums/?showtopic=13499 +aiSettings.activateDefaultInterpreter Plane BAPSTLookAtWrapper Full + +rem *** Boat Behaviour setup *** +aisettings.setVehicleMods Boat StandardWeights +aiSettings.setVehicleMaterialCost Boat Ground -1 +aiSettings.setVehicleMaterialCost Boat Road -1 +aiSettings.setVehicleMaterialCost Boat Shallows -1 +aiSettings.setVehicleMaterialCost Boat DeepWater 1 +aiSettings.setVehicleBehaviour Boat Avoid BBAvoid BBPAvoidCollision2d 1 UCUnion AvoidInhibit +aiSettings.setVehicleBehaviour Boat MoveTo BBMoveTo BBPGotoWaypoint2d 4 UCUnion UnitWeights +aiSettings.setVehicleBehaviour Boat Idle BBIdle BBPIdle2d 5 UCUnion UnitWeights +aiSettings.setVehicleBehaviour Boat Fire BBFireLargeBore BBPFire2d 4 UCFire UnitWeights +aiSettings.setVehicleBehaviour Boat Change BBChangeTeleport BBPChangeTeleport 6 UCUnion ChangeInhibit +aiSettings.setVehicleDefaultBehaviour Boat Idle +aiSettings.addInterpreterEntry Boat InfoWrapper +aiSettings.addInterpreterEntry Boat BoatMoveTo +aiSettings.addInterpreterEntry Boat BoatMoveToDirection +aiSettings.addInterpreterEntry Boat BoatMoveToObject +aiSettings.addInterpreterEntry Boat Trigger +aiSettings.addInterpreterEntry Boat TriggerContinously +aiSettings.addInterpreterEntry Boat MouseTurretLookAt +aiSettings.addInterpreterEntry Boat MouseTurretAimAt +aiSettings.addInterpreterEntry Boat Sense +aiSettings.addInterpreterEntry Boat BoatResetControls +aiSettings.activateDefaultInterpreter Boat BAPSTParallel Full +aiSettings.activateDefaultInterpreter Boat BAPSTSerial Full +aiSettings.activateDefaultInterpreter Boat BAPSTIf Full +aiSettings.activateDefaultInterpreter Boat BAPSTPlanEnd Full +aiSettings.activateDefaultInterpreter Boat BAPSTWait Full +aiSettings.activateDefaultInterpreter Boat BAPSTWhile Full +aiSettings.activateDefaultInterpreter Boat BAPSTWeaponWrapper Full +aiSettings.activateDefaultInterpreter Boat BAPSTAimingWrapper Full +aiSettings.activateDefaultInterpreter Boat BAPSTFinishedWrapper Full +aiSettings.activateDefaultInterpreter Boat BAPSTUpdateVehicle Full +aiSettings.activateDefaultInterpreter Boat BAPSTChangeWeapon Full +aiSettings.activateDefaultInterpreter Boat BAPSTICTurnLock Full +aiSettings.activateDefaultInterpreter Boat BAPSTICChangeVehicle Full +aiSettings.activateDefaultInterpreter Boat BAPSTEvaluate Full +aiSettings.activateDefaultInterpreter Boat BAPSTNotifyBot Full +aiSettings.activateDefaultInterpreter Boat BAPSTIdle Full +aiSettings.activateDefaultInterpreter Boat BAPSTSetSensingAgentFocus Full +aiSettings.activateDefaultInterpreter Boat BAPSTSendRadioMessage Full +aiSettings.activateDefaultInterpreter Boat BAPSTLookAtWrapper Full +aiSettings.activateDefaultInterpreter Boat BAPSTForgetTarget Full +aiSettings.activateDefaultInterpreter Boat BAPSTDebug Full +aiSettings.activateDefaultInterpreter Boat BAPSTUseFlareOnMissileLock Full +aiSettings.activateDefaultInterpreter Boat BAPSTEvaluateCondition Full + +rem *** Infantery Behaviour setup *** +aisettings.setVehicleMods Infantery StandardWeights +aiSettings.setVehicleMaterialCost Infantery Ground 1 +aiSettings.setVehicleMaterialCost Infantery Road 1 +aiSettings.setVehicleMaterialCost Infantery Shallows 1.5 +aiSettings.setVehicleMaterialCost Infantery DeepWater 6 +aiSettings.setVehicleBehaviour Infantery Avoid BBAvoid BBPAvoidCollisionInfantery 1 UCUnion AvoidInhibit +aiSettings.setVehicleBehaviour Infantery MoveTo BBMoveTo BBPGotoWaypointInfantery 4 UCUnion UnitWeights +aiSettings.setVehicleBehaviour Infantery Idle BBIdle BBPIdleInfantery 5 UCUnion UnitWeights +aiSettings.setVehicleBehaviour Infantery Fire BBFireInfantery BBPFireInfantery 4 UCFire UnitWeights +aiSettings.setVehicleBehaviour Infantery Special BBMedicAssist BBPMedicAssist 12 UCUnion UnitWeights +aiSettings.setVehicleBehaviour Infantery Special2 BBBridgeRepair BBPBridgeRepair 15 UCUnion UnitWeights +aiSettings.setVehicleBehaviour Infantery c4 BBC4 BBPC4 12 UCUnion UnitWeights +aiSettings.setVehicleBehaviour Infantery Special3 BBDefuseMines BBPDefuseMines 13 UCUnion UnitWeights +aiSettings.setVehicleBehaviour Infantery Change BBChange BBPChange 6 UCUnion UnitWeights +aiSettings.setVehicleBehaviour Infantery Revive BBRevive BBPRevive 8 UCUnion UnitWeights +aiSettings.setVehicleBehaviour Infantery Random BBRandom BBPRandom 12 UCUnion UnitWeights +aiSettings.setVehicleBehaviour Infantery Triggerable BBTriggerable BBPTriggerable 12 UCUnion UnitWeights +aiSettings.setVehicleDefaultBehaviour Infantery Idle +aiSettings.addInterpreterEntry Infantery MoveToMediumSoldier Medium +aiSettings.addInterpreterEntry Infantery MoveToObjectMediumSoldier Medium +aiSettings.addInterpreterEntry Infantery InfoWrapper +aiSettings.addInterpreterEntry Infantery InfanteryMoveTo +aiSettings.addInterpreterEntry Infantery InfanteryMoveToDirection +aiSettings.addInterpreterEntry Infantery InfanteryMoveToObject +aiSettings.addInterpreterEntry Infantery Trigger +aiSettings.addInterpreterEntry Infantery TriggerContinously +aiSettings.addInterpreterEntry Infantery MouseTurretAimAt +aiSettings.addInterpreterEntry Infantery InfanteryResetControls +aiSettings.addInterpreterEntry Infantery MouseTurretLookAt +aiSettings.addInterpreterEntry Infantery Sense +aiSettings.addInterpreterEntry Infantery SoldierPose +aiSettings.activateDefaultInterpreter Infantery BAPSTOverrideSensingAgent Full +aiSettings.activateDefaultInterpreter Infantery BAPSTPlaceC4 Full +aiSettings.activateDefaultInterpreter Infantery BAPSTParallel Full +aiSettings.activateDefaultInterpreter Infantery BAPSTSerial Full +aiSettings.activateDefaultInterpreter Infantery BAPSTIf Full +aiSettings.activateDefaultInterpreter Infantery BAPSTPlanEnd Full +aiSettings.activateDefaultInterpreter Infantery BAPSTWait Full +aiSettings.activateDefaultInterpreter Infantery BAPSTWhile Full +aiSettings.activateDefaultInterpreter Infantery BAPSTWeaponWrapper Full +aiSettings.activateDefaultInterpreter Infantery BAPSTFinishedWrapper Full +aiSettings.activateDefaultInterpreter Infantery BAPSTAimingWrapper Full +aiSettings.activateDefaultInterpreter Infantery BAPSTUpdateVehicle Full +aiSettings.activateDefaultInterpreter Infantery BAPSTChangeWeapon Full +aiSettings.activateDefaultInterpreter Infantery BAPSTICTurnLock Full +aiSettings.activateDefaultInterpreter Infantery BAPSTICChangeVehicle Full +aiSettings.activateDefaultInterpreter Infantery BAPSTEvaluate Full +aiSettings.activateDefaultInterpreter Infantery BAPSTNotifyBot Full +aiSettings.activateDefaultInterpreter Infantery BAPSTIdle Full +aiSettings.activateDefaultInterpreter Infantery BAPSTSetSensingAgentFocus Full +aiSettings.activateDefaultInterpreter Infantery BAPSTMergeSoldierInputs Full +aiSettings.activateDefaultInterpreter Infantery BAPSTSendRadioMessage Full +aiSettings.activateDefaultInterpreter Infantery BAPSTLookAtWrapper Full +aiSettings.activateDefaultInterpreter Infantery BAPSTDebug Full +aiSettings.activateDefaultInterpreter Infantery BAPSTForgetTarget Full +aiSettings.activateDefaultInterpreter Infantery BAPSTUseFlareOnMissileLock Full +aiSettings.activateDefaultInterpreter Infantery BAPSTEvaluateCondition Full +aiSettings.activateDefaultInterpreter Infantery BAPSTRevive Full +aiSettings.addSensingAgentPattern Infantery Soldier + + + +rem *** Fixed Behaviour setup *** +aisettings.setVehicleMods Fixed StandardWeights +aiSettings.setVehicleBehaviour Fixed Idle BBIdle BBPIdle2d 5 UCUnion UnitWeights +aiSettings.setVehicleBehaviour Fixed Fire BBFireInfantery BBPFireInfantery 4 UCFire UnitWeights +aiSettings.setVehicleBehaviour Fixed MoveTo BBMoveToFixed UnRelated 8 UCUnion UnitWeights +aiSettings.setVehicleBehaviour Fixed Change BBChange BBPChange 6 UCUnion UnitWeights +aiSettings.setVehicleBehaviour Fixed Special2 BBBridgeRepair BBPBridgeRepair 15 UCUnion UnitWeights +aiSettings.setVehicleBehaviour Fixed Special3 BBDefuseMines BBPDefuseMines 13 UCUnion UnitWeights +aiSettings.setVehicleDefaultBehaviour Fixed Idle +aiSettings.addInterpreterEntry Fixed InfoWrapper +aiSettings.addInterpreterEntry Fixed Trigger +aiSettings.addInterpreterEntry Fixed TriggerContinously +aiSettings.addInterpreterEntry Fixed MouseTurretAimAt +aiSettings.addInterpreterEntry Fixed MouseTurretLookAt +aiSettings.addInterpreterEntry Fixed Sense +aiSettings.addInterpreterEntry Fixed InfanteryResetControls +aiSettings.activateDefaultInterpreter Fixed BAPSTOverrideSensingAgent Full +aiSettings.activateDefaultInterpreter Fixed BAPSTParallel Full +aiSettings.activateDefaultInterpreter Fixed BAPSTSerial Full +aiSettings.activateDefaultInterpreter Fixed BAPSTPlanEnd Full +aiSettings.activateDefaultInterpreter Fixed BAPSTIf Full +aiSettings.activateDefaultInterpreter Fixed BAPSTWait Full +aiSettings.activateDefaultInterpreter Fixed BAPSTWhile Full +aiSettings.activateDefaultInterpreter Fixed BAPSTAimingWrapper Full +aiSettings.activateDefaultInterpreter Fixed BAPSTWeaponWrapper Full +aiSettings.activateDefaultInterpreter Fixed BAPSTFinishedWrapper Full +aiSettings.activateDefaultInterpreter Fixed BAPSTUpdateVehicle Full +aiSettings.activateDefaultInterpreter Fixed BAPSTChangeWeapon Full +aiSettings.activateDefaultInterpreter Fixed BAPSTICTurnLock Full +aiSettings.activateDefaultInterpreter Fixed BAPSTICChangeVehicle Full +aiSettings.activateDefaultInterpreter Fixed BAPSTEvaluate Full +aiSettings.activateDefaultInterpreter Fixed BAPSTNotifyBot Full + +aiSettings.activateDefaultInterpreter Fixed BAPSTIdle Full +aiSettings.activateDefaultInterpreter Fixed BAPSTSetSensingAgentFocus Full +aiSettings.activateDefaultInterpreter Fixed BAPSTMergeSoldierInputs Full +aiSettings.activateDefaultInterpreter Fixed BAPSTSendRadioMessage Full +aiSettings.activateDefaultInterpreter Fixed BAPSTLookAtWrapper Full +aiSettings.activateDefaultInterpreter Fixed BAPSTDebug Full +aiSettings.activateDefaultInterpreter Fixed BAPSTUseFlareOnMissileLock Full +aiSettings.activateDefaultInterpreter Fixed BAPSTEvaluateCondition Full +aiSettings.addSensingAgentPattern Fixed Turret + +rem *** Car Behaviour setup *** +aiSettings.setVehicleMaterialCost Car Ground 1 +aiSettings.setVehicleMaterialCost Car Road 1 +aiSettings.setVehicleMaterialCost Car Shallows 1.8 +aiSettings.setVehicleMaterialCost Car DeepWater -1 + +aisettings.setVehicleMods Car StandardWeights +aiSettings.setVehicleBehaviour Car Avoid BBAvoid BBPAvoidCollision2d 1 UCUnion AvoidInhibit +aiSettings.setVehicleBehaviour Car MoveTo BBMoveTo BBPGotoWaypoint2d 4 UCUnion UnitWeights +aiSettings.setVehicleBehaviour Car Idle BBIdle BBPIdle2d 5 UCUnion UnitWeights +aiSettings.setVehicleBehaviour Car Change BBChange BBPChange 2 UCUnion UnitWeights +aiSettings.setVehicleBehaviour Car Fire BBFireUnarmed BBPFireDriveAttack 6 UCUnion UnitWeights +aiSettings.setVehicleBehaviour Car Special BBRunOverSoldier BBPRunOverSoldier 6 UCUnion UnitWeights + +aiSettings.setVehicleBehaviour Car Special2 BBBridgeRepair BBPBridgeRepair 15 UCUnion UnitWeights +aiSettings.setVehicleBehaviour Car Special3 BBDefuseMines BBPDefuseMines 13 UCUnion UnitWeights +aiSettings.setVehicleDefaultBehaviour Car Idle + +aiSettings.addInterpreterEntry Car CarResetControls +aiSettings.addInterpreterEntry Car MoveToMedium Medium +aiSettings.addInterpreterEntry Car MoveToObjectMedium Medium +aiSettings.addInterpreterEntry Car InfoWrapper +aiSettings.addInterpreterEntry Car CarMoveTo +aiSettings.addInterpreterEntry Car CarMoveToDirection +aiSettings.addInterpreterEntry Car CarMoveToObject +aiSettings.addInterpreterEntry Car Trigger +aiSettings.addInterpreterEntry Car TriggerContinously +aiSettings.addInterpreterEntry Car MouseTurretAimAt +aiSettings.addInterpreterEntry Car MouseTurretLookAt +aiSettings.addInterpreterEntry Car Sense +aiSettings.activateDefaultInterpreter Car BAPSTParallel Full +aiSettings.activateDefaultInterpreter Car BAPSTSerial Full +aiSettings.activateDefaultInterpreter Car BAPSTIf Full +aiSettings.activateDefaultInterpreter Car BAPSTPlanEnd Full +aiSettings.activateDefaultInterpreter Car BAPSTWait Full +aiSettings.activateDefaultInterpreter Car BAPSTWhile Full +aiSettings.activateDefaultInterpreter Car BAPSTAimingWrapper Full +aiSettings.activateDefaultInterpreter Car BAPSTFinishedWrapper Full +aiSettings.activateDefaultInterpreter Car BAPSTUpdateVehicle Full +aiSettings.activateDefaultInterpreter Car BAPSTChangeWeapon Full +aiSettings.activateDefaultInterpreter Car BAPSTICTurnLock Full +aiSettings.activateDefaultInterpreter Car BAPSTICChangeVehicle Full +aiSettings.activateDefaultInterpreter Car BAPSTEvaluate Full +aiSettings.activateDefaultInterpreter Car BAPSTNotifyBot Full +aiSettings.activateDefaultInterpreter Car BAPSTIdle Full +aiSettings.activateDefaultInterpreter Car BAPSTSetSensingAgentFocus Full +aiSettings.activateDefaultInterpreter Car BAPSTMergeSoldierInputs Full +aiSettings.activateDefaultInterpreter Car BAPSTSendRadioMessage Full +aiSettings.activateDefaultInterpreter Car BAPSTForgetTarget Full +aiSettings.activateDefaultInterpreter Car BAPSTDebug Full +aiSettings.activateDefaultInterpreter Car BAPSTUseFlareOnMissileLock Full +aiSettings.activateDefaultInterpreter Car BAPSTRunOverObject Full +aiSettings.activateDefaultInterpreter Car BAPSTHonkHorn Full +aiSettings.activateDefaultInterpreter Car BAPSTEvaluateCondition Full + +rem *** LandingCraft Behaviour setup *** +aisettings.setVehicleMods LandingCraft StandardWeights +aiSettings.setVehicleMaterialCost LandingCraft Ground 10 +aiSettings.setVehicleMaterialCost LandingCraft Road 10 +aiSettings.setVehicleMaterialCost LandingCraft Shallows 2 +aiSettings.setVehicleMaterialCost LandingCraft DeepWater 1 +aiSettings.setVehicleBehaviour LandingCraft Avoid BBAvoid BBPAvoidCollision2d 1 UCUnion AvoidInhibit +aiSettings.setVehicleBehaviour LandingCraft MoveTo BBMoveTo BBPGotoWaypointBoat 4 UCUnion UnitWeights +aiSettings.setVehicleBehaviour LandingCraft Idle BBIdle BBPIdle2d 5 UCUnion UnitWeights +aiSettings.setVehicleBehaviour LandingCraft Fire BBFireUnarmed UnRelated 6 UCUnion UnitWeights +aiSettings.setVehicleBehaviour LandingCraft Change BBChangeLandingCraft BBPChangeLandingCraft 6 UCUnion ChangeInhibit +aiSettings.setVehicleDefaultBehaviour LandingCraft Idle +aiSettings.addInterpreterEntry LandingCraft MoveToMediumBoat Medium +aiSettings.addInterpreterEntry LandingCraft MoveToObjectMediumBoat Medium +aiSettings.addInterpreterEntry LandingCraft CarMoveTo +aiSettings.addInterpreterEntry LandingCraft CarMoveToDirection +aiSettings.addInterpreterEntry LandingCraft CarMoveToObject +aiSettings.addInterpreterEntry LandingCraft Trigger +aiSettings.addInterpreterEntry LandingCraft TriggerContinously +aiSettings.addInterpreterEntry LandingCraft MouseTurretLookAt +aiSettings.addInterpreterEntry LandingCraft BoatResetControls +aiSettings.addInterpreterEntry LandingCraft Sense +aiSettings.activateDefaultInterpreter LandingCraft BAPSTParallel Full +aiSettings.activateDefaultInterpreter LandingCraft BAPSTSerial Full +aiSettings.activateDefaultInterpreter LandingCraft BAPSTIf Full +aiSettings.activateDefaultInterpreter LandingCraft BAPSTPlanEnd Full +aiSettings.activateDefaultInterpreter LandingCraft BAPSTWait Full +aiSettings.activateDefaultInterpreter LandingCraft BAPSTWhile Full +aiSettings.activateDefaultInterpreter LandingCraft BAPSTInfoWrapper Full +aiSettings.activateDefaultInterpreter LandingCraft BAPSTAimingWrapper Full +aiSettings.activateDefaultInterpreter LandingCraft BAPSTFinishedWrapper Full +aiSettings.activateDefaultInterpreter LandingCraft BAPSTUpdateVehicle Full +aiSettings.activateDefaultInterpreter LandingCraft BAPSTChangeWeapon Full +aiSettings.activateDefaultInterpreter LandingCraft BAPSTICTurnLock Full +aiSettings.activateDefaultInterpreter LandingCraft BAPSTICChangeVehicle Full +aiSettings.activateDefaultInterpreter LandingCraft BAPSTEvaluate Full +aiSettings.activateDefaultInterpreter LandingCraft BAPSTNotifyBot Full +aiSettings.activateDefaultInterpreter LandingCraft BAPSTIdle Full +aiSettings.activateDefaultInterpreter LandingCraft BAPSTPhysicsEnable Full +aiSettings.activateDefaultInterpreter LandingCraft BAPSTSendRadioMessage Full +aiSettings.activateDefaultInterpreter LandingCraft BAPSTForgetTarget Full +aiSettings.activateDefaultInterpreter LandingCraft BAPSTDebug Full +aiSettings.activateDefaultInterpreter LandingCraft BAPSTUseFlareOnMissileLock Full +rem http://www.bfeditor.org/forums/?showtopic=13499 +aiSettings.activateDefaultInterpreter LandingCraft BAPSTLookAtWrapper Full +aiSettings.addSensingAgentPattern LandingCraft Turret + + +rem *** Passenger Behaviour setup *** +aisettings.setVehicleMods Passenger StandardWeights +aiSettings.setVehicleBehaviour Passenger Idle BBIdle BBPIdle2d 5 UCUnion UnitWeights +aiSettings.setVehicleBehaviour Passenger Fire BBFireUnarmed UnRelated 6 UCUnion UnitWeights +aiSettings.setVehicleBehaviour Passenger Change BBChange BBPChange 6 UCUnion ChangeInhibit +aiSettings.setVehicleBehaviour Passenger MoveTo BBMoveToFixed UnRelated 8 UCUnion UnitWeights +aiSettings.setVehicleBehaviour Passenger Special2 BBBridgeRepair BBPBridgeRepair 15 UCUnion UnitWeights +aiSettings.setVehicleBehaviour Passenger Special3 BBDefuseMines BBPDefuseMines 13 UCUnion UnitWeights +aiSettings.setVehicleDefaultBehaviour Passenger Idle +aiSettings.addInterpreterEntry Passenger Trigger +aiSettings.addInterpreterEntry Passenger TriggerContinously +aiSettings.addInterpreterEntry Passenger MouseTurretLookAt +aiSettings.addInterpreterEntry Passenger InfanteryResetControls +aiSettings.addInterpreterEntry Passenger Sense +aiSettings.activateDefaultInterpreter Passenger BAPSTParallel Full +aiSettings.activateDefaultInterpreter Passenger BAPSTSerial Full +aiSettings.activateDefaultInterpreter Passenger BAPSTIf Full +aiSettings.activateDefaultInterpreter Passenger BAPSTPlanEnd Full +aiSettings.activateDefaultInterpreter Passenger BAPSTWait Full +aiSettings.activateDefaultInterpreter Passenger BAPSTWhile Full +aiSettings.activateDefaultInterpreter Passenger BAPSTInfoWrapper Full +aiSettings.activateDefaultInterpreter Passenger BAPSTFinishedWrapper Full +aiSettings.activateDefaultInterpreter Passenger BAPSTUpdateVehicle Full +aiSettings.activateDefaultInterpreter Passenger BAPSTChangeWeapon Full +aiSettings.activateDefaultInterpreter Passenger BAPSTICTurnLock Full +aiSettings.activateDefaultInterpreter Passenger BAPSTICChangeVehicle Full +aiSettings.activateDefaultInterpreter Passenger BAPSTEvaluate Full +aiSettings.activateDefaultInterpreter Passenger BAPSTNotifyBot Full +aiSettings.activateDefaultInterpreter Passenger BAPSTIdle Full +aiSettings.activateDefaultInterpreter Passenger BAPSTSetSensingAgentFocus Full +aiSettings.activateDefaultInterpreter Passenger BAPSTMergeSoldierInputs Full +aiSettings.activateDefaultInterpreter Passenger BAPSTSendRadioMessage Full +aiSettings.activateDefaultInterpreter Passenger BAPSTDebug Full +aiSettings.activateDefaultInterpreter Passenger BAPSTUseFlareOnMissileLock Full +aiSettings.activateDefaultInterpreter Passenger BAPSTEvaluateCondition Full +rem http://www.bfeditor.org/forums/?showtopic=13499 +aiSettings.activateDefaultInterpreter Passenger BAPSTLookAtWrapper Full +aiSettings.addSensingAgentPattern Passenger Turret + +rem *** Passenger Behaviour setup *** +aisettings.setVehicleMods LandingCraftPassenger StandardWeights +aiSettings.setVehicleBehaviour LandingCraftPassenger Idle BBIdle BBPIdle2d 5 UCUnion UnitWeights +aiSettings.setVehicleBehaviour LandingCraftPassenger Fire BBFireUnarmed UnRelated 6 UCScout UnitWeights +aiSettings.setVehicleBehaviour LandingCraftPassenger Change BBChangeLandingCraft BBPChangeLandingCraft 6 UCUnion ChangeInhibit +aiSettings.setVehicleBehaviour LandingCraftPassenger MoveTo BBMoveToFixed UnRelated 8 UCUnion UnitWeights +aiSettings.setVehicleDefaultBehaviour LandingCraftPassenger Idle +aiSettings.addInterpreterEntry LandingCraftPassenger Trigger +aiSettings.addInterpreterEntry LandingCraftPassenger TriggerContinously +aiSettings.addInterpreterEntry LandingCraftPassenger MouseTurretLookAt +aiSettings.addInterpreterEntry LandingCraftPassenger InfanteryResetControls +aiSettings.addInterpreterEntry LandingCraftPassenger Sense +aiSettings.activateDefaultInterpreter LandingCraftPassenger BAPSTParallel Full +aiSettings.activateDefaultInterpreter LandingCraftPassenger BAPSTSerial Full +aiSettings.activateDefaultInterpreter LandingCraftPassenger BAPSTIf Full +aiSettings.activateDefaultInterpreter LandingCraftPassenger BAPSTPlanEnd Full +aiSettings.activateDefaultInterpreter LandingCraftPassenger BAPSTWait Full +aiSettings.activateDefaultInterpreter LandingCraftPassenger BAPSTWhile Full +aiSettings.activateDefaultInterpreter LandingCraftPassenger BAPSTInfoWrapper Full +aiSettings.activateDefaultInterpreter LandingCraftPassenger BAPSTFinishedWrapper Full +aiSettings.activateDefaultInterpreter LandingCraftPassenger BAPSTUpdateVehicle Full +aiSettings.activateDefaultInterpreter LandingCraftPassenger BAPSTChangeWeapon Full +aiSettings.activateDefaultInterpreter LandingCraftPassenger BAPSTICTurnLock Full +aiSettings.activateDefaultInterpreter LandingCraftPassenger BAPSTICChangeVehicle Full +aiSettings.activateDefaultInterpreter LandingCraftPassenger BAPSTEvaluate Full +aiSettings.activateDefaultInterpreter LandingCraftPassenger BAPSTNotifyBot Full +aiSettings.activateDefaultInterpreter LandingCraftPassenger BAPSTIdle Full +aiSettings.activateDefaultInterpreter LandingCraftPassenger BAPSTSendRadioMessage Full +aiSettings.activateDefaultInterpreter LandingCraftPassenger BAPSTDebug Full +aiSettings.activateDefaultInterpreter LandingCraftPassenger BAPSTUseFlareOnMissileLock Full +aiSettings.activateDefaultInterpreter LandingCraftPassenger BAPSTEvaluateCondition Full +rem http://www.bfeditor.org/forums/?showtopic=13499 +aiSettings.activateDefaultInterpreter LandingCraftPassenger BAPSTLookAtWrapper Full + +rem *** LandingCraftFixed Behaviour setup *** +aisettings.setVehicleMods LandingCraftFixed StandardWeights +aiSettings.setVehicleBehaviour LandingCraftFixed Idle BBIdle BBPIdle2d 5 UCUnion UnitWeights +aiSettings.setVehicleBehaviour LandingCraftFixed Fire BBFireInfantery BBPFireInfantery 4 UCFire UnitWeights +aiSettings.setVehicleBehaviour LandingCraftFixed MoveTo BBMoveToFixed UnRelated 8 UCUnion UnitWeights +aiSettings.setVehicleBehaviour LandingCraftFixed Change BBChangeLandingCraft BBPChangeLandingCraft 6 UCUnion UnitWeights +aiSettings.setVehicleDefaultBehaviour LandingCraftFixed Idle +aiSettings.addInterpreterEntry LandingCraftFixed InfoWrapper +aiSettings.addInterpreterEntry LandingCraftFixed Trigger +aiSettings.addInterpreterEntry LandingCraftFixed TriggerContinously +aiSettings.addInterpreterEntry LandingCraftFixed MouseTurretAimAt +aiSettings.addInterpreterEntry LandingCraftFixed MouseTurretLookAt +aiSettings.addInterpreterEntry LandingCraftFixed Sense +aiSettings.addInterpreterEntry LandingCraftFixed InfanteryResetControls +aiSettings.activateDefaultInterpreter LandingCraftFixed BAPSTOverrideSensingAgent Full +aiSettings.activateDefaultInterpreter LandingCraftFixed BAPSTParallel Full +aiSettings.activateDefaultInterpreter LandingCraftFixed BAPSTSerial Full +aiSettings.activateDefaultInterpreter LandingCraftFixed BAPSTIf Full +aiSettings.activateDefaultInterpreter LandingCraftFixed BAPSTPlanEnd Full +aiSettings.activateDefaultInterpreter LandingCraftFixed BAPSTWait Full +aiSettings.activateDefaultInterpreter LandingCraftFixed BAPSTWhile Full +aiSettings.activateDefaultInterpreter LandingCraftFixed BAPSTWeaponWrapper Full +aiSettings.activateDefaultInterpreter LandingCraftFixed BAPSTAimingWrapper Full +aiSettings.activateDefaultInterpreter LandingCraftFixed BAPSTFinishedWrapper Full +aiSettings.activateDefaultInterpreter LandingCraftFixed BAPSTUpdateVehicle Full +aiSettings.activateDefaultInterpreter LandingCraftFixed BAPSTChangeWeapon Full +aiSettings.activateDefaultInterpreter LandingCraftFixed BAPSTICTurnLock Full +aiSettings.activateDefaultInterpreter LandingCraftFixed BAPSTICChangeVehicle Full +aiSettings.activateDefaultInterpreter LandingCraftFixed BAPSTEvaluate Full +aiSettings.activateDefaultInterpreter LandingCraftFixed BAPSTNotifyBot Full +aiSettings.activateDefaultInterpreter LandingCraftFixed BAPSTIdle Full +aiSettings.activateDefaultInterpreter LandingCraftFixed BAPSTSetSensingAgentFocus Full +aiSettings.activateDefaultInterpreter LandingCraftFixed BAPSTSendRadioMessage Full +aiSettings.activateDefaultInterpreter LandingCraftFixed BAPSTDebug Full +aiSettings.activateDefaultInterpreter LandingCraftFixed BAPSTUseFlareOnMissileLock Full +aiSettings.activateDefaultInterpreter LandingCraftFixed BAPSTEvaluateCondition Full +rem http://www.bfeditor.org/forums/?showtopic=13499 +aiSettings.activateDefaultInterpreter LandingCraftFixed BAPSTLookAtWrapper Full +aiSettings.addSensingAgentPattern LandingCraftFixed Turret + +rem ***** HeliBehaviour setup *** +aisettings.setVehicleMods Helicopter StandardWeights +aiSettings.setVehicleBehaviour Helicopter MoveTo BBMoveTo BBPGotoWaypoint3d 4 UCUnion HeliMoveWeights +aiSettings.setVehicleBehaviour Helicopter Idle BBIdle BBPIdle3d 5 UCUnion HeliMoveWeights +aiSettings.setVehicleBehaviour Helicopter Fire BBFire3d BBPHeliFire3d 4 UCFire HeliMoveWeights +aiSettings.setVehicleBehaviour Helicopter Change BBChange BBPChange 6 UCUnion ChangeInhibit +aiSettings.setVehicleDefaultBehaviour Helicopter Idle + +aiSettings.addInterpreterEntry Helicopter InfoWrapper +aiSettings.addInterpreterEntry Helicopter HeliMoveTo +aiSettings.addInterpreterEntry Helicopter HeliMoveToDirection +aiSettings.addInterpreterEntry Helicopter HeliMoveToObject +aiSettings.addInterpreterEntry Helicopter HeliMoveAwayFromObject +aiSettings.addInterpreterEntry Helicopter Trigger +aiSettings.addInterpreterEntry Helicopter TriggerContinously +aiSettings.addInterpreterEntry Helicopter HeliAimAt +aiSettings.addInterpreterEntry Helicopter HeliResetControls +aiSettings.addInterpreterEntry Helicopter Sense +aiSettings.activateDefaultInterpreter Helicopter BAPSTParallel Full +aiSettings.activateDefaultInterpreter Helicopter BAPSTSerial Full +aiSettings.activateDefaultInterpreter Helicopter BAPSTIf Full +aiSettings.activateDefaultInterpreter Helicopter BAPSTWait Full +aiSettings.activateDefaultInterpreter Helicopter BAPSTWhile Full +aiSettings.activateDefaultInterpreter Helicopter BAPSTWeaponWrapper Full +aiSettings.activateDefaultInterpreter Helicopter BAPSTFinishedWrapper Full +aiSettings.activateDefaultInterpreter Helicopter BAPSTUpdateVehicle Full +aiSettings.activateDefaultInterpreter Helicopter BAPSTChangeWeapon Full +aiSettings.activateDefaultInterpreter Helicopter BAPSTICTurnLock Full +aiSettings.activateDefaultInterpreter Helicopter BAPSTICChangeVehicle Full +aiSettings.activateDefaultInterpreter Helicopter BAPSTEvaluate Full +aiSettings.activateDefaultInterpreter Helicopter BAPSTNotifyBot Full +aiSettings.activateDefaultInterpreter Helicopter BAPSTIdle Full +aiSettings.activateDefaultInterpreter Helicopter BAPSTSetSensingAgentFocus Full +aiSettings.activateDefaultInterpreter Helicopter BAPSTSendRadioMessage Full +aiSettings.activateDefaultInterpreter Helicopter BAPSTDebug Full +aiSettings.activateDefaultInterpreter Helicopter BAPSTUseFlareOnMissileLock Full +aiSettings.activateDefaultInterpreter Helicopter BAPSTEvaluateCondition Full +rem http://www.bfeditor.org/forums/?showtopic=13499 +aiSettings.activateDefaultInterpreter Helicopter BAPSTLookAtWrapper Full + + +rem ***** TransportHelicopterBehaviour setup *** +aisettings.setVehicleMods TransportHelicopter StandardWeights +aiSettings.setVehicleBehaviour TransportHelicopter MoveTo BBMoveTo BBPGotoWaypoint3d 4 UCUnion HeliMoveWeights +aiSettings.setVehicleBehaviour TransportHelicopter Idle BBIdle BBPIdle3d 5 UCUnion HeliMoveWeights +aiSettings.setVehicleBehaviour TransportHelicopter Change BBChangeLandingCraft BBPChange 6 UCUnion ChangeInhibit +aiSettings.setVehicleDefaultBehaviour TransportHelicopter Idle + +aiSettings.addInterpreterEntry TransportHelicopter InfoWrapper +aiSettings.addInterpreterEntry TransportHelicopter HeliMoveTo +aiSettings.addInterpreterEntry TransportHelicopter HeliMoveToDirection +aiSettings.addInterpreterEntry TransportHelicopter HeliMoveToObject +aiSettings.addInterpreterEntry TransportHelicopter HeliMoveAwayFromObject +aiSettings.addInterpreterEntry TransportHelicopter Trigger +aiSettings.addInterpreterEntry TransportHelicopter TriggerContinously +aiSettings.addInterpreterEntry TransportHelicopter HeliAimAt +aiSettings.addInterpreterEntry TransportHelicopter HeliResetControls +aiSettings.addInterpreterEntry TransportHelicopter Sense +aiSettings.activateDefaultInterpreter TransportHelicopter BAPSTParallel Full +aiSettings.activateDefaultInterpreter TransportHelicopter BAPSTSerial Full +aiSettings.activateDefaultInterpreter TransportHelicopter BAPSTIf Full +aiSettings.activateDefaultInterpreter TransportHelicopter BAPSTWait Full +aiSettings.activateDefaultInterpreter TransportHelicopter BAPSTWhile Full +aiSettings.activateDefaultInterpreter TransportHelicopter BAPSTWeaponWrapper Full +aiSettings.activateDefaultInterpreter TransportHelicopter BAPSTFinishedWrapper Full +aiSettings.activateDefaultInterpreter TransportHelicopter BAPSTUpdateVehicle Full +aiSettings.activateDefaultInterpreter TransportHelicopter BAPSTChangeWeapon Full +aiSettings.activateDefaultInterpreter TransportHelicopter BAPSTICTurnLock Full +aiSettings.activateDefaultInterpreter TransportHelicopter BAPSTICChangeVehicle Full +aiSettings.activateDefaultInterpreter TransportHelicopter BAPSTEvaluate Full +aiSettings.activateDefaultInterpreter TransportHelicopter BAPSTNotifyBot Full +aiSettings.activateDefaultInterpreter TransportHelicopter BAPSTIdle Full +aiSettings.activateDefaultInterpreter TransportHelicopter BAPSTSetSensingAgentFocus Full +aiSettings.activateDefaultInterpreter TransportHelicopter BAPSTSendRadioMessage Full +aiSettings.activateDefaultInterpreter TransportHelicopter BAPSTDebug Full +aiSettings.activateDefaultInterpreter TransportHelicopter BAPSTUseFlareOnMissileLock Full +aiSettings.activateDefaultInterpreter TransportHelicopter BAPSTEvaluateCondition Full +rem http://www.bfeditor.org/forums/?showtopic=13499 +aiSettings.activateDefaultInterpreter TransportHelicopter BAPSTLookAtWrapper Full + +rem **-------- Armed Car ----------------------- + +aisettings.setVehicleMods ArmedCar StandardWeights +aiSettings.setVehicleMaterialCost ArmedCar Ground 1 +aiSettings.setVehicleMaterialCost ArmedCar Road 1 +aiSettings.setVehicleMaterialCost ArmedCar Shallows 1 +aiSettings.setVehicleMaterialCost ArmedCar DeepWater 2 +aiSettings.setVehicleBehaviour ArmedCar Avoid BBAvoid BBPAvoidCollision2d 1 UCUnion AvoidInhibit +aiSettings.setVehicleBehaviour ArmedCar MoveTo BBMoveTo BBPGotoWaypoint2d 4 UCUnion UnitWeights +aiSettings.setVehicleBehaviour ArmedCar Idle BBIdle BBPIdle2d 5 UCUnion UnitWeights +aiSettings.setVehicleBehaviour ArmedCar Change BBChange BBPChange 2 UCUnion UnitWeights +aiSettings.setVehicleBehaviour ArmedCar Fire BBFireInfantery BBPFireInfantery 4 UCFire UnitWeights +aiSettings.setVehicleBehaviour ArmedCar Special2 BBBridgeRepair BBPBridgeRepair 15 UCUnion UnitWeights +aiSettings.setVehicleBehaviour ArmedCar Special3 BBDefuseMines BBPDefuseMines 13 UCUnion UnitWeights +aiSettings.setVehicleDefaultBehaviour ArmedCar Idle +aiSettings.addInterpreterEntry ArmedCar CarResetControls +aiSettings.addInterpreterEntry ArmedCar MoveToMedium Medium +aiSettings.addInterpreterEntry ArmedCar MoveToObjectMedium Medium +aiSettings.addInterpreterEntry ArmedCar InfoWrapper +aiSettings.addInterpreterEntry ArmedCar CarMoveTo +aiSettings.addInterpreterEntry ArmedCar CarMoveToDirection +aiSettings.addInterpreterEntry ArmedCar CarMoveToObject +aiSettings.addInterpreterEntry ArmedCar Trigger +aiSettings.addInterpreterEntry ArmedCar TriggerContinously +aiSettings.addInterpreterEntry ArmedCar MouseTurretAimAt +aiSettings.addInterpreterEntry ArmedCar MouseTurretLookAt +aiSettings.addInterpreterEntry ArmedCar Sense +aiSettings.activateDefaultInterpreter ArmedCar BAPSTOverrideSensingAgent Full +aiSettings.activateDefaultInterpreter ArmedCar BAPSTParallel Full +aiSettings.activateDefaultInterpreter ArmedCar BAPSTSerial Full +aiSettings.activateDefaultInterpreter ArmedCar BAPSTIf Full +aiSettings.activateDefaultInterpreter ArmedCar BAPSTPlanEnd Full +aiSettings.activateDefaultInterpreter ArmedCar BAPSTWait Full +aiSettings.activateDefaultInterpreter ArmedCar BAPSTWhile Full +aiSettings.activateDefaultInterpreter ArmedCar BAPSTAimingWrapper Full +aiSettings.activateDefaultInterpreter ArmedCar BAPSTFinishedWrapper Full +aiSettings.activateDefaultInterpreter ArmedCar BAPSTUpdateVehicle Full +aiSettings.activateDefaultInterpreter ArmedCar BAPSTChangeWeapon Full +aiSettings.activateDefaultInterpreter ArmedCar BAPSTICTurnLock Full +aiSettings.activateDefaultInterpreter ArmedCar BAPSTICChangeVehicle Full +aiSettings.activateDefaultInterpreter ArmedCar BAPSTEvaluate Full +aiSettings.activateDefaultInterpreter ArmedCar BAPSTNotifyBot Full +aiSettings.activateDefaultInterpreter ArmedCar BAPSTIdle Full +aiSettings.activateDefaultInterpreter ArmedCar BAPSTSetSensingAgentFocus Full +aiSettings.activateDefaultInterpreter ArmedCar BAPSTMergeSoldierInputs Full +aiSettings.activateDefaultInterpreter ArmedCar BAPSTSendRadioMessage Full +aiSettings.activateDefaultInterpreter ArmedCar BAPSTDebug Full +aiSettings.activateDefaultInterpreter ArmedCar BAPSTLookAtWrapper Full +aiSettings.activateDefaultInterpreter ArmedCar BAPSTDebug Full +aiSettings.activateDefaultInterpreter ArmedCar BAPSTWeaponWrapper Full +aiSettings.activateDefaultInterpreter ArmedCar BAPSTForgetTarget Full +aiSettings.activateDefaultInterpreter ArmedCar BAPSTUseFlareOnMissileLock Full +aiSettings.activateDefaultInterpreter ArmedCar BAPSTEvaluateCondition Full +aiSettings.addSensingAgentPattern ArmedCar Turret + +rem ***-------------------- + +aisettings.setVehicleMods ManDown UnitWeights +aiSettings.setVehicleBehaviour ManDown Idle BBIdle BBPIdle2d 2 UCUnion UnitWeights +aiSettings.setVehicleDefaultBehaviour ManDown Idle +aiSettings.addInterpreterEntry ManDown Trigger +aiSettings.addInterpreterEntry ManDown InfanteryResetControls +aiSettings.activateDefaultInterpreter ManDown BAPSTWhile Full +aiSettings.activateDefaultInterpreter ManDown BAPSTParallel Full +aiSettings.activateDefaultInterpreter ManDown BAPSTSerial Full +aiSettings.activateDefaultInterpreter ManDown BAPSTSendRadioMessage Full +aiSettings.activateDefaultInterpreter ManDown BAPSTDebug Full +aiSettings.activateDefaultInterpreter ManDown BAPSTInfoWrapper Full +aiSettings.activateDefaultInterpreter ManDown BAPSTUseFlareOnMissileLock Full +aiSettings.activateDefaultInterpreter ManDown BAPSTSoldierPose Full +aiSettings.activateDefaultInterpreter ManDown BAPSTEvaluateCondition Full +rem http://www.bfeditor.org/forums/?showtopic=13499 +aiSettings.activateDefaultInterpreter ManDown BAPSTLookAtWrapper Full + +aiSettings.addSensingAgentPattern ManDown Null + +rem *** ParatrooperFixed Behaviour setup *** +aisettings.setVehicleMods ParatrooperFixed StandardWeights +aiSettings.setVehicleBehaviour ParatrooperFixed Idle BBIdle BBPIdle2d 5 UCUnion UnitWeights +aiSettings.setVehicleBehaviour ParatrooperFixed Fire BBFireInfantery BBPFireInfantery 4 UCFire UnitWeights +aiSettings.setVehicleBehaviour ParatrooperFixed MoveTo BBMoveToFixed UnRelated 8 UCUnion UnitWeights +aiSettings.setVehicleBehaviour ParatrooperFixed Change BBChangeLandingCraft BBPChange 6 UCUnion UnitWeights +aiSettings.setVehicleDefaultBehaviour ParatrooperFixed Idle +aiSettings.addInterpreterEntry ParatrooperFixed InfoWrapper +aiSettings.addInterpreterEntry ParatrooperFixed Trigger +aiSettings.addInterpreterEntry ParatrooperFixed TriggerContinously +aiSettings.addInterpreterEntry ParatrooperFixed MouseTurretAimAt +aiSettings.addInterpreterEntry ParatrooperFixed MouseTurretLookAt +aiSettings.addInterpreterEntry ParatrooperFixed Sense +aiSettings.addInterpreterEntry ParatrooperFixed InfanteryResetControls +aiSettings.activateDefaultInterpreter ParatrooperFixed BAPSTOverrideSensingAgent Full +aiSettings.activateDefaultInterpreter ParatrooperFixed BAPSTParallel Full +aiSettings.activateDefaultInterpreter ParatrooperFixed BAPSTSerial Full +aiSettings.activateDefaultInterpreter ParatrooperFixed BAPSTIf Full +aiSettings.activateDefaultInterpreter ParatrooperFixed BAPSTPlanEnd Full +aiSettings.activateDefaultInterpreter ParatrooperFixed BAPSTWait Full +aiSettings.activateDefaultInterpreter ParatrooperFixed BAPSTWhile Full +aiSettings.activateDefaultInterpreter ParatrooperFixed BAPSTWeaponWrapper Full +aiSettings.activateDefaultInterpreter ParatrooperFixed BAPSTAimingWrapper Full +aiSettings.activateDefaultInterpreter ParatrooperFixed BAPSTFinishedWrapper Full +aiSettings.activateDefaultInterpreter ParatrooperFixed BAPSTUpdateVehicle Full +aiSettings.activateDefaultInterpreter ParatrooperFixed BAPSTChangeWeapon Full +aiSettings.activateDefaultInterpreter ParatrooperFixed BAPSTICTurnLock Full +aiSettings.activateDefaultInterpreter ParatrooperFixed BAPSTICChangeVehicle Full +aiSettings.activateDefaultInterpreter ParatrooperFixed BAPSTEvaluate Full +aiSettings.activateDefaultInterpreter ParatrooperFixed BAPSTNotifyBot Full +aiSettings.activateDefaultInterpreter ParatrooperFixed BAPSTIdle Full +aiSettings.activateDefaultInterpreter ParatrooperFixed BAPSTSetSensingAgentFocus Full +aiSettings.activateDefaultInterpreter ParatrooperFixed BAPSTSendRadioMessage Full +aiSettings.activateDefaultInterpreter ParatrooperFixed BAPSTDebug Full +aiSettings.activateDefaultInterpreter ParatrooperFixed BAPSTUseFlareOnMissileLock Full +aiSettings.activateDefaultInterpreter ParatrooperFixed BAPSTEvaluateCondition Full +aiSettings.addSensingAgentPattern ParatrooperFixed Turret +rem http://www.bfeditor.org/forums/?showtopic=13499 +aiSettings.activateDefaultInterpreter ParatrooperFixed BAPSTLookAtWrapper Full \ No newline at end of file diff --git a/config/bf2/mods/bf2/ai/aidefault-custom.ai b/config/bf2/mods/bf2/ai/aidefault-custom.ai new file mode 100644 index 00000000..129043b9 --- /dev/null +++ b/config/bf2/mods/bf2/ai/aidefault-custom.ai @@ -0,0 +1,21 @@ +echo ***************************************************************************************** +echo AIDefault.ai **************************************************************************** +echo ***************************************************************************************** + +aiSettings.setNSides 2 +aiSettings.setAutoSpawnBots 1 + +rem Let's go with 63 bots! Hope your system holds up +aiSettings.overrideMenuSettings 1 +aiSettings.setMaxNBots 63 +aiSettings.maxBotsIncludeHumans 0 +aiSettings.setBotSkill 1.0 + +run BotNames.ai + +aiSettings.setInformationGridDimension 32 + + +run AIPathFinding.ai + +rem EOF diff --git a/config/bf2/mods/bf2/ai/aidefaultstrategies-custom-esai.ai b/config/bf2/mods/bf2/ai/aidefaultstrategies-custom-esai.ai new file mode 100644 index 00000000..220ecf6f --- /dev/null +++ b/config/bf2/mods/bf2/ai/aidefaultstrategies-custom-esai.ai @@ -0,0 +1,12 @@ +rem esai strategy : medium fca pf + +rem -= load enhanced sai core =- +run /mods/bf2/esai/core/esaicore.ai + +rem -= load enhanced sai default plugins =- +run /mods/bf2/esai/plugin/default/grabneutrals.ai +run /mods/bf2/esai/plugin/default/endgame.ai + +rem -= load user plugins =- +run /mods/bf2/esai/plugin/user/userconditions.ai +run /mods/bf2/esai/plugin/user/focusedcounterattack.ai diff --git a/config/bf2/mods/bf2/ai/aidefaultstrategiesadd-custom-esai.ai b/config/bf2/mods/bf2/ai/aidefaultstrategiesadd-custom-esai.ai new file mode 100644 index 00000000..fbc4f94d --- /dev/null +++ b/config/bf2/mods/bf2/ai/aidefaultstrategiesadd-custom-esai.ai @@ -0,0 +1,2 @@ +rem -= load strategy =- +run /mods/bf2/esai/strategy/user/mediumfcapf.ai diff --git a/config/bf2/mods/bf2/settings/maplist-custom-coop.con b/config/bf2/mods/bf2/settings/maplist-custom-coop.con new file mode 100644 index 00000000..bb49e48a --- /dev/null +++ b/config/bf2/mods/bf2/settings/maplist-custom-coop.con @@ -0,0 +1,24 @@ +; mods/bf2 coop +maplist.append dalian_plant gpm_coop 16 +maplist.append daqing_oilfields gpm_coop 16 +maplist.append dragon_valley gpm_coop 16 +maplist.append fushe_pass gpm_coop 16 +maplist.append greatwall gpm_coop 16 +maplist.append gulf_of_oman gpm_coop 16 +maplist.append midnight_sun gpm_coop 16 +maplist.append operation_clean_sweep gpm_coop 16 +maplist.append operationharvest gpm_coop 16 +maplist.append operationroadrage gpm_coop 16 +maplist.append operationsmokescreen gpm_coop 16 +maplist.append road_to_jalalabad gpm_coop 16 +maplist.append sharqi_peninsula gpm_coop 16 +maplist.append songhua_stalemate gpm_coop 16 +maplist.append taraba_quarry gpm_coop 16 +maplist.append zatar_wetlands gpm_coop 16 + +; mods/xpack coop +maplist.append ghost_town gpm_coop 16 +maplist.append mass_destruction gpm_coop 16 +maplist.append night_flight gpm_coop 16 +maplist.append surge gpm_coop 16 +maplist.append warlord gpm_coop 16 diff --git a/config/bf2/mods/bf2/settings/maplist-custom-cq.con b/config/bf2/mods/bf2/settings/maplist-custom-cq.con new file mode 100644 index 00000000..fc529e84 --- /dev/null +++ b/config/bf2/mods/bf2/settings/maplist-custom-cq.con @@ -0,0 +1,82 @@ +; mods/bf2 conquest +maplist.append dalian_plant gpm_cq 16 +maplist.append dalian_plant gpm_cq 32 +maplist.append dalian_plant gpm_cq 64 +maplist.append daqing_oilfields gpm_cq 16 +maplist.append daqing_oilfields gpm_cq 32 +maplist.append daqing_oilfields gpm_cq 64 +maplist.append dragon_valley gpm_cq 128 +maplist.append dragon_valley gpm_cq 16 +maplist.append dragon_valley gpm_cq 32 +maplist.append dragon_valley gpm_cq 64 +maplist.append fushe_pass gpm_cq 16 +maplist.append fushe_pass gpm_cq 32 +maplist.append fushe_pass gpm_cq 64 +maplist.append greatwall gpm_cq 16 +maplist.append greatwall gpm_cq 32 +maplist.append gulf_of_oman gpm_cq 16 +maplist.append gulf_of_oman gpm_cq 32 +maplist.append gulf_of_oman gpm_cq 64 +maplist.append highway_tampa gpm_cq 128 +maplist.append highway_tampa gpm_cq 16 +maplist.append highway_tampa gpm_cq 32 +maplist.append highway_tampa gpm_cq 64 +maplist.append highway_tampa gpm_cq 8 +maplist.append mashtuur_city gpm_cq 16 +maplist.append mashtuur_city gpm_cq 32 +maplist.append mashtuur_city gpm_cq 64 +maplist.append midnight_sun gpm_cq 16 +maplist.append midnight_sun gpm_cq 32 +maplist.append midnight_sun gpm_cq 64 +maplist.append operation_blue_pearl gpm_cq 16 +maplist.append operation_blue_pearl gpm_cq 32 +maplist.append operation_blue_pearl gpm_cq 64 +maplist.append operation_clean_sweep gpm_cq 16 +maplist.append operation_clean_sweep gpm_cq 32 +maplist.append operation_clean_sweep gpm_cq 64 +maplist.append operationharvest gpm_cq 16 +maplist.append operationharvest gpm_cq 32 +maplist.append operationharvest gpm_cq 64 +maplist.append operationroadrage gpm_cq 16 +maplist.append operationroadrage gpm_cq 32 +maplist.append operationroadrage gpm_cq 64 +maplist.append operationsmokescreen gpm_cq 16 +maplist.append operationsmokescreen gpm_cq 32 +maplist.append road_to_jalalabad gpm_cq 16 +maplist.append road_to_jalalabad gpm_cq 32 +maplist.append road_to_jalalabad gpm_cq 64 +maplist.append sharqi_peninsula gpm_cq 16 +maplist.append sharqi_peninsula gpm_cq 32 +maplist.append sharqi_peninsula gpm_cq 64 +maplist.append songhua_stalemate gpm_cq 16 +maplist.append songhua_stalemate gpm_cq 32 +maplist.append songhua_stalemate gpm_cq 64 +maplist.append taraba_quarry gpm_cq 16 +maplist.append taraba_quarry gpm_cq 32 +maplist.append wake_island_2007 gpm_cq 64 +maplist.append zatar_wetlands gpm_cq 16 +maplist.append zatar_wetlands gpm_cq 32 +maplist.append zatar_wetlands gpm_cq 64 + +; mods/xpack cq +maplist.append ghost_town gpm_cq 16 +maplist.append ghost_town gpm_cq 32 +maplist.append ghost_town gpm_cq 64 +maplist.append iron_gator gpm_cq 16 +maplist.append iron_gator gpm_cq 32 +maplist.append iron_gator gpm_cq 64 +maplist.append leviathan gpm_cq 16 +maplist.append leviathan gpm_cq 32 +maplist.append leviathan gpm_cq 64 +maplist.append mass_destruction gpm_cq 16 +maplist.append mass_destruction gpm_cq 32 +maplist.append mass_destruction gpm_cq 64 +maplist.append night_flight gpm_cq 16 +maplist.append night_flight gpm_cq 32 +maplist.append night_flight gpm_cq 64 +maplist.append surge gpm_cq 16 +maplist.append surge gpm_cq 32 +maplist.append surge gpm_cq 64 +maplist.append warlord gpm_cq 16 +maplist.append warlord gpm_cq 32 +maplist.append warlord gpm_cq 64 diff --git a/config/bf2/mods/bf2/settings/serversettings-custom.con b/config/bf2/mods/bf2/settings/serversettings-custom.con new file mode 100644 index 00000000..fc65057d --- /dev/null +++ b/config/bf2/mods/bf2/settings/serversettings-custom.con @@ -0,0 +1,68 @@ +sv.serverName "Default Server Name" +sv.password "" +sv.internet 1 +sv.serverIP "" +sv.serverPort 16567 +sv.welcomeMessage "" +sv.punkBuster 1 +sv.allowFreeCam 1 +sv.allowExternalViews 1 +sv.allowNoseCam 1 +sv.hitIndicator 1 +sv.maxPlayers 64 +sv.numPlayersNeededToStart 0 +sv.notEnoughPlayersRestartDelay 15 +sv.startDelay 15 +sv.endDelay 15 +sv.spawnTime 15 +sv.manDownTime 15 +sv.endOfRoundDelay 15 +sv.ticketRatio 100 +sv.roundsPerMap 3 +sv.timeLimit 0 +sv.scoreLimit 0 +sv.soldierFriendlyFire 100 +sv.vehicleFriendlyFire 100 +sv.soldierSplashFriendlyFire 100 +sv.vehicleSplashFriendlyFire 100 +sv.tkPunishEnabled 1 +sv.tkNumPunishToKick 3 +sv.tkPunishByDefault 0 +sv.votingEnabled 1 +sv.voteTime 15 +sv.minPlayersForVoting 1 +sv.teamVoteOnly 1 +sv.gameSpyPort 29900 +sv.allowNATNegotiation 0 +sv.interfaceIP "" +sv.autoRecord 0 +sv.demoIndexURL http:// +sv.demoDownloadURL http:// +sv.autoDemoHook "adminutils/demo/rotate_demo.py" +sv.demoQuality 1 +sv.adminScript "default" +sv.timeBeforeRestartMap 30 +sv.autoBalanceTeam 0 +sv.teamRatioPercent 100 +sv.coopBotRatio 100 +sv.coopBotCount 16 +sv.coopBotDifficulty 50 +sv.voipEnabled 1 +sv.voipQuality 3 +sv.voipServerRemote 0 +sv.voipServerRemoteIP "" +sv.voipServerPort 55125 +sv.voipBFClientPort 55123 +sv.voipBFServerPort 55124 +sv.voipSharedPassword "" +sv.useGlobalRank 1 +sv.useGlobalUnlocks 1 +sv.noVehicles 0 +sv.sponsorText "" +sv.sponsorLogoURL "https://example.com/bf2logo.png" +sv.communityLogoURL "https://example.com/bf2logo.png" +sv.radioSpamInterval 6 +sv.radioMaxSpamFlagCount 6 +sv.radioBlockedDurationTime 30 +sv.numReservedSlots 0 +sv.friendlyFireWithMines 1 diff --git a/config/bf2/python/bf2/BF2StatisticsConfig-custom.py b/config/bf2/python/bf2/BF2StatisticsConfig-custom.py new file mode 100644 index 00000000..aa3c461b --- /dev/null +++ b/config/bf2/python/bf2/BF2StatisticsConfig-custom.py @@ -0,0 +1,109 @@ +# ------------------------------------------------------------------------------ +# BF2Statistics 2.4.1 - Config File +# ------------------------------------------------------------------------------ +# Conventions: +# 0 -> Disable +# 1 -> Enable +# ------------------------------------------------------------------------------ + +# ------------------------------------------------------------------------------ +# Debug Logging +# ------------------------------------------------------------------------------ +debug_enable = 1 +debug_log_path = 'python/bf2/logs' # Relative from BF2 base folder +debug_fraglog_enable = 0 # Detailed 'Fragalyzer' Logs + +# ------------------------------------------------------------------------------ +# Backend Web Server +# ------------------------------------------------------------------------------ +http_backend_addr = 'asp-nginx' # Reach ASP over the `bf2-network` docker network. If your ASP is on another host, use its hostname or domain name here. +http_backend_port = 80 +http_backend_asp = '/ASP/bf2statistics.php' + +# ------------------------------------------------------------------------------ +# Backup Central Community Web Server (OPTIONAL) +# ------------------------------------------------------------------------------ +# Note: this cabalility is for linking stats data to a centrally maintained STATS # +# server. This could be useful for those who are running a LAN or Tournament # +# (with local STATS), but wish to have this data credited to their normal STATS # +# DB. There are three (3) options for the central DB update: # +# 0: Disabled - 'nuff said! # +# 1: Sync - This simply copies the SNAPSHOT as-is to the central DB # +# 2: Minimal - Record everything, except Rank & Award data (typically use # +# for LANs or Tournaments where local db starts blank) # +# ------------------------------------------------------------------------------ +http_central_enable = 0 # Use settings above (0, 1, 2) +http_central_addr = '192.168.1.102' # Address Central STATS Server +http_central_port = 80 +http_central_asp = '/ASP/bf2statistics.php' + +# ------------------------------------------------------------------------------ +# Snapshot Logging +# ------------------------------------------------------------------------------ +# Enables server to make snapshot backups. +# 0 = log only on error sending to backend +# 1 = all snapshots +# ------------------------------------------------------------------------------ +snapshot_logging = 0 +snapshot_log_path_sent = 'python/bf2/logs/snapshots/sent' # Relative from the BF2 base folder +snapshot_log_path_unsent = 'python/bf2/logs/snapshots/unsent' # Relative from the BF2 base folder + +# ------------------------------------------------------------------------------ +# Snapshot Prefix +# ------------------------------------------------------------------------------ +# Prefix Snapshots with this tag. This is also your Server's Prefix. Multiple +# servers on the same IP Must use different Prefix's to tell which is which. +# ------------------------------------------------------------------------------ +snapshot_prefix = '' + +# ------------------------------------------------------------------------------ +# Medals Processing +# ------------------------------------------------------------------------------ +# Suffix for your custom medals file(s). +# Example "custom" = medal_data_custom.py AND medal_data_xpack_custom.py (for SF). +medals_custom_data = '' + +# Removing medal requirements can mess up the keystring, Use this to force the correct string +# Recomended to enable if some medal requirements are removed from the medal_data.py +medals_force_keystring = 0 + +# ------------------------------------------------------------------------------ +# Player Manager +# ------------------------------------------------------------------------------ +# pm_backend_pid_manager: +# 1 = Load from ASP. +# 0 = Load from 'pm_local_pid_txt_file' +# ------------------------------------------------------------------------------ +pm_backend_pid_manager = 1 +pm_local_pid_txt_file = 'python/bf2/pid.txt' # Relative from BF2 base folder +pm_ai_player_addr = '127.0.0.1' # Not recommended to change + + +# ------------------------------------------------------------------------------ +# Clan Manager +# ------------------------------------------------------------------------------ +enableClanManager = 0 # Use the Clan Manager to control Access to your server! +serverMode = 0 + # Mode 1: Clan ONLY (Must be on Clan List to Join Server) + # Mode 2: Priority Proving Grounds (Clan Members AND those players that meet + # the minimum requirements.Clan Members get priority) + # Mode 3: Proving Grounds (Clan Members AND those players that meet the + # minimum requirements) + # Mode 4: Experts ONLY (Only players that meet the minimum requirements) + # Mode 0: Public (Free-for-All. No Restrictions!) + +# Clan Manager Criteria +criteria_data = ( + ('clantag', ''), # Clan Tag (Matches First Part of Player Name, used for Whitelist) + ('score', 0), # Minimum Global Score + ('rank', 0), # Minimum Global Rank + ('time', 0), # Minimum Global Time Played + ('kdratio', 0), # Minimum Global Kill/Death Ratio + ('country', ''), # Registered Country of Origin Code (Seperate multiple by comma ',') + ('banned', 0), # Maximum banned count! PermBan is ALWAY BlackListed + ) + +# ------------------------------------------------------------------------------ +# END CONFIGURATION +# ------------------------------------------------------------------------------ diff --git a/docker-compose.test.yml b/docker-compose.test.yml index 06284b4e..1193327c 100644 --- a/docker-compose.test.yml +++ b/docker-compose.test.yml @@ -76,4 +76,3 @@ services: networks: bf2-network: - name: bf2-network diff --git a/docker-compose.yml b/docker-compose.yml index 074387d5..c3590fab 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,5 +1,74 @@ version: '2.2' services: + # Battlefield 2 1.5 server with the bf2stats python scripts + bf2: + image: startersclan/docker-bf2:v1.5.3153.0 + volumes: + - ./config/bf2/mods/bf2/ai/aidefault-custom.ai:/server/bf2/mods/bf2/ai/aidefault.ai:ro # Customize bots + - ./config/bf2/mods/bf2/ai/aibehaviours-fixlookatwrapper.ai:/server/bf2/mods/bf2/ai/aibehaviours.ai:ro # LoopAtWrapper fix + - ./config/bf2/mods/bf2/settings/serversettings-custom.con:/server/bf2/mods/bf2/settings/serversettings.con:ro # Server config + - ./config/bf2/mods/bf2/settings/maplist-custom-coop.con:/server/bf2/mods/bf2/settings/maplist.con:ro # Maplist (coop) + # - ./config/bf2/mods/bf2/settings/maplist-custom-cq.con:/server/bf2/mods/bf2/settings/maplist.con:ro # Maplist (cq) + - ./src/python:/server/bf2/python + - ./config/bf2/python/bf2/BF2StatisticsConfig-custom.py:/server/bf2/python/bf2/BF2StatisticsConfig.py:ro # bf2stats python config + ports: + - 16567:16567/udp + - 29900:29900/udp + networks: + - bf2-network + - gamespy-network + depends_on: + - asp-nginx + - asp-php + tty: true + stdin_open: true + + # The gamespy server + prmasterserver: + image: startersclan/prmasterserver:v0.1.0 + volumes: + - prmasterserver-volume:/data + ports: + - 29900:29900/tcp # Login server + - 29901:29901/tcp # Login server + - 28910:28910/tcp # Master server + - 27900:27900/udp # Master server + - 29910:29910/udp # CD key server + networks: + # Spoof all gamespy DNS for the BF2 server connected to this network + gamespy-network: + aliases: + - battlefield2.available.gamespy.com + - battlefield2.master.gamespy.com + - battlefield2.ms14.gamespy.com + - gamestats.gamespy.com + - master.gamespy.com + - motd.gamespy.com + - gpsp.gamespy.com + - gpcm.gamespy.com + - gamespy.com + + # The reverse proxy for our web containers + # This is needed only for the BF2 client BFHQ to work properly (i.e. access the ASP via http://bf2web.gamespy.com) + traefik: + image: traefik:v2.7 + volumes: + # Allow traefik to listen to the Docker events + - /var/run/docker.sock:/var/run/docker.sock:ro + ports: + - 80:80 + networks: + - traefik-public-network + - traefik-network + restart: unless-stopped + command: + - --global.checknewversion=false + - --global.sendanonymoususage=false + # - --log.level=DEBUG + - --providers.docker=true + - --providers.docker.exposedbydefault=false + - --entrypoints.web.address=:80 + init-container: image: alpine:latest volumes: @@ -55,13 +124,26 @@ services: asp-nginx: image: nginx:1.21-alpine + labels: + - "traefik.enable=true" + - "traefik.docker.network=${COMPOSE_PROJECT_NAME?err}_traefik-network" + # traefik v2 + # http + - "traefik.http.routers.${COMPOSE_PROJECT_NAME?err}-asp-gamespy-http.entrypoints=web" + - "traefik.http.routers.${COMPOSE_PROJECT_NAME?err}-asp-gamespy-http.rule=Host(`bf2web.gamespy.com`)" # Note: `bf2web.gamespy.com` doesn't need https. The BF2 client BFHQ makes a HTTP requests to `bf2web.gamespy.com` with `Host: bf2web.gamespy.com`. volumes: - ./src/ASP:/src/ASP - ./config/ASP/nginx/nginx.conf:/etc/nginx/nginx.conf:ro ports: - 8081:80 networks: - - bf2-network + traefik-network: + # Spoof gamespy DNS for the BF2 server connected to this network + bf2-network: + aliases: + - bf2web.gamespy.com + - gamestats.gamespy.com # Unused + - eapusher.dice.se # Unused depends_on: - init-container - asp-php @@ -146,10 +228,14 @@ services: - bf2-network networks: + gamespy-network: bf2-network: - name: bf2-network + traefik-public-network: + traefik-network: + internal: true volumes: + prmasterserver-volume: backups-volume: logs-volume: snapshots-volume: