Changeset 27637

Timestamp:
May 10, 2023, 5:34:38 PM (15 months ago)
Author:
Stan
Message:

Allow starting by command with sandbox AI.

takes 0 as false; ?? doesn't.

Patch by: @Freagarach
Accepted by: @sera, @Langbart

Fixes: #6771

Differential Revision: https://code.wildfiregames.com/D4975

Location:
ps/trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • ps/trunk/binaries/data/mods/public/gamesettings/attributes/PlayerAI.js

    r26583 r27637  
    4949            this.set(+i, {
    5050                "bot": pData[i].AI,
    51                 "difficulty": pData[i].AIDiff || +Engine.ConfigDB_GetValue("user", "gui.gamesetup.aidifficulty"),
     51                "difficulty": pData[i].AIDiff +Engine.ConfigDB_GetValue("user", "gui.gamesetup.aidifficulty"),
    5252                "behavior": pData[i].AIBehavior || Engine.ConfigDB_GetValue("user", "gui.gamesetup.aibehavior"),
    5353            });
  • ps/trunk/binaries/system/readme.txt

    r26584 r27637  
    1111-autostart-seed=SEED            sets randomization seed value (default 0, use -1 for random)
    1212-autostart-ai=PLAYER:AI         sets the AI for PLAYER (e.g. 2:petra)
    13 -autostart-aidiff=PLAYER:DIFF   sets the DIFFiculty of PLAYER's AI (0: sandbox, 5: very hard)
     13-autostart-aidiff=PLAYER:DIFF   sets the DIFFiculty of PLAYER's AI (0: sandbox, 5: very hard)
    1414-autostart-aiseed=AISEED        sets the seed used for the AI random generator (default 0, use -1 for random)
    1515-autostart-player=NUMBER        sets the playerID in non-networked games (default 1, use -1 for observer)
  • ps/trunk/source/ps/GameSetup/GameSetup.cpp

    r27470 r27637  
    804804 * -autostart-ai=PLAYER:AI         sets the AI for PLAYER (e.g. 2:petra)
    805805 * -autostart-aidiff=PLAYER:DIFF   sets the DIFFiculty of PLAYER's AI
    806  *                                 (0: sandbox, 5: very hard)
     806 *                                 (0: sandbox, 5: very hard)
    807807 * -autostart-aiseed=AISEED        sets the seed used for the AI random
    808808 *                                 generator (default 0, use -1 for random)
     
    844844 * -autostart-client=127.0.0.1 -autostart-playername="Alice"
    845845 * The players use the developer overlay to control players.
    846  *
    847846 * 2) Load Alpine Lakes random map with random seed, 2 players (Athens and Britons), and player 2 is PetraBot:
    848847 * -autostart="random/alpine_lakes" -autostart-seed=-1 -autostart-players=2 -autostart-civ=1:athen -autostart-civ=2:brit -autostart-ai=2:petra
    849  *
    850  * 3) Observe the PetraBot on a triggerscript map:
    851  * -autostart="random/jebel_barkal" -autostart-seed=-1 -autostart-players=2 -autostart-civ=1:athen -autostart-civ=2:brit -autostart-ai=1:petra -autostart-ai=2:petra -autostart-player=-1
    852848 */
    853849bool Autostart(const CmdLineArgs& args)
Note: See TracChangeset for help on using the changeset viewer.