#6771 closed defect (fixed)

Unable to start AI sandbox difficulty from the command line

Reported by: Langbart Owned by: Freagarach
Priority: Should Have Milestone: Alpha 27
Component: UI – Game setup Keywords:
Cc: Patch: Phab:D4975

Description

to reproduce

Line 
12-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)
14-autostart-aiseed=AISEED sets the seed used for the AI random generator (default 0, use -1 for random)
pyrogenesis -autostart="random/mainland" -autostart-ai=1:petra -autostart-aidiff=1:0 -autostart-player=-1

errrors

0 A.D. (0.0.27) Main log (warnings and errors only)
ERROR: JavaScript error: gamesettings/attributes/PlayerAI.js line 51 Engine.ConfigDB_GetValue is not a function fromInitAttributes@gamesettings/attributes/PlayerAI.js:51:46 fromInitAttributes@gamesettings/GameSettings.js:90:17 AutoStart@autostart/autostart.js:6:17 autostartHost@autostart/entrypoint.js:49:23

Engine exited successfully on 2023-04-01 at 14:38:55 with 423 message(s), 1 error(s) and 0 warning(s).

reproducible

bisect (not tested, just a guess based on previous tickets)

related tickets

Change History (2)

comment:1 by Freagarach, 13 months ago

Component: Core engineUI – Game setup
Owner: set to Freagarach
Patch: Phab:D4975

comment:2 by Stan, 12 months ago

Resolution: fixed
Status: newclosed

In 27637:

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

Note: See TracTickets for help on using tickets.