Complete.Org:
Mailing Lists:
Archives:
freeciv-ai:
June 2003: [freeciv-ai] (PR#2755) AI hangs at modified rulesets (fix) |
![]() |
[freeciv-ai] (PR#2755) AI hangs at modified rulesets (fix)[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
Following code causes this hang: while (distance >= move_rate) { Because I have a unit with a movement-rate of 0, this loop will never finish. Tested with succes using freeciv 1.14: at line 254 of CVS, add if (move_rate != 0) { and add an indent to each following line, until line 276, where this if is ended with an extra '}'. Bart Coppens (bart@xxxxxxxxxxxxxx) [coppensbart@xxxxx - Tue Jan 7 20:40:25 2003]: > (CVS of 03/01/2003; no additional patches applied) > While trying to edit some values of my rulesets and playtesting > certain > positions of units, I came across this. I have A 3-player savegame. > All three > are set to human. For testing, I tried to play as Aragorn against > Sauron. So > I set Sauron to AI. When I started the game; civserver didn't respond > anymore. Backtrace of the killed (Ctrl+C) civserver: > > start > Starting game. > > > Player 'Sauron' now has AI skill level 'easy'. > > Program received signal SIGINT, Interrupt. > dangerfunct (danger=2809, move_rate=0, distance=11) at > advmilitary.c:257 > 257 danger /= 2; > (gdb) backtrace > #0 dangerfunct (danger=2809, move_rate=0, distance=11) at > advmilitary.c:257 > #1 0x080b336e in assess_danger (pcity=0x82fcb60) at advmilitary.c:581 > #2 0x080b2b27 in assess_danger_player (pplayer=0x812b614) at > advmilitary.c:352 > #3 0x08050198 in srv_loop () at srv_main.c:2107 > #4 0x0804fc95 in srv_main () at srv_main.c:1920 > #5 0x0804a26a in main (argc=3, argv=0xbffffa34) at civserver.c:154 > > Reproducable: always. Just load the savegame below with the rulesets, > set > Sauron (Aragorn has the same result) to AI and start. > Complete rulesets & tilesets: http://www.bartcoppens.be/modpack/for- > pille.bz2 > Scenario testsavegame: > http://www.bartcoppens.be/modpack/middle-earth-bart-alpha1.sav.gz > > Bart Coppens
|