NTai XE10.1b
Moderators: hoijui, Moderators
Issue 2:
I├óÔé¼Ôäóve hesitated to report this issue earlier
, because it used to have minor consequence, and I believed it had something to do with my own inabilities to make a correct config file.
This error occurs in all tested maps and all mods (AA,BA,OTA,CA)
Also this ├óÔé¼┼ôerror├óÔé¼┬Ø is strangely self correcting!
The problem exists with all 9.7 builds, however with the NTaiCaseTest build, it becomes a showstopper!
Showstopper = because it happens a lot more often, and the ├óÔé¼┼ôself correcting├óÔé¼┬Ø factor somehow occurs a lot less!
--------
Symptoms and consequence:
In the logs I see many entries with this text:
Let me show some examples:
Numbers in front are abstract frame/time steps, the problem is not restricted to corwin and corck, just an example
1 corck builds corwin. // everything is fine, corwin gets constructed, and starts spinning
2 corck builds cormex
3 corck tries to build corwin. -> logs: ├óÔé¼┼ôerror: a problem occurred load├óÔé¼┬ª corwin├óÔé¼┬Ø
4 corck skips building corwin, and goes to next item in queue
6-147 corck tries to build corwin with intervals according to queue, but continues to get error in log.
148 corck builds corwin // NO ERROR
- corwin gets constructed, and starts spinning
149-287 corck builds corwin with intervals according to queue, NO ERRORS!
288 corck tries to build corwin. -> logs: ├óÔé¼┼ôerror: a problem occurred load├óÔé¼┬ª corwin├óÔé¼┬Ø
As you can see from the example, the problem comes and goes!
Also when corck fails to build corwin due to error, ALL units (corcv etc) fails to build corwin.
For factories the problem becomes a bigger issue:
1 corck builds coralab
2 coralab tries to init, but log -> error: a problem occurred load├óÔé¼┬ª coralab
3 coralab doesn├óÔé¼Ôäót load queue, and do NOT build anything.
22 corck builds coralab
23 coralab tries to init, but log -> error: a problem occurred load├óÔé¼┬ª coralab
24 coralab doesn├óÔé¼Ôäót load queue, and do NOT build anything.
25-773 repeat above
773 ALL coralab├óÔé¼Ôäós suddenly inits correctly, loads buildqueue and ALL coralab├óÔé¼Ôäós starts building.
779-873 ALL coralabs tries to init, but log -> error: a problem occurred load├óÔé¼┬ª coralab
I have tried to do analysis of logs, to find a pattern in actions leading to the first occurrence (per game) of this error, but have failed
to find any pattern.
There is a small tendency to the above error first occurrence after this is recorded in the log:
Most of the time however the ├óÔé¼┼ôerror: a problem occurring loading├óÔé¼┬ª├óÔé¼┬Ø happens ├óÔé¼┼ôout of the blue!├óÔé¼┬Ø
I wish
I could do more to help nail this issue, but I only have my gut feeling to offer:
that this bug is loosely related to unitnames in uppercase.
I├óÔé¼Ôäóve hesitated to report this issue earlier

This error occurs in all tested maps and all mods (AA,BA,OTA,CA)
Also this ├óÔé¼┼ôerror├óÔé¼┬Ø is strangely self correcting!


The problem exists with all 9.7 builds, however with the NTaiCaseTest build, it becomes a showstopper!



Showstopper = because it happens a lot more often, and the ├óÔé¼┼ôself correcting├óÔé¼┬Ø factor somehow occurs a lot less!
--------
Symptoms and consequence:
In the logs I see many entries with this text:
This error is reported both for factories and constructers. The consequences are different.error: a problem occurred loading units unit definition corxxx
Let me show some examples:
Numbers in front are abstract frame/time steps, the problem is not restricted to corwin and corck, just an example
1 corck builds corwin. // everything is fine, corwin gets constructed, and starts spinning
2 corck builds cormex
3 corck tries to build corwin. -> logs: ├óÔé¼┼ôerror: a problem occurred load├óÔé¼┬ª corwin├óÔé¼┬Ø
4 corck skips building corwin, and goes to next item in queue
6-147 corck tries to build corwin with intervals according to queue, but continues to get error in log.
148 corck builds corwin // NO ERROR

149-287 corck builds corwin with intervals according to queue, NO ERRORS!
288 corck tries to build corwin. -> logs: ├óÔé¼┼ôerror: a problem occurred load├óÔé¼┬ª corwin├óÔé¼┬Ø
As you can see from the example, the problem comes and goes!

Also when corck fails to build corwin due to error, ALL units (corcv etc) fails to build corwin.
For factories the problem becomes a bigger issue:

1 corck builds coralab
2 coralab tries to init, but log -> error: a problem occurred load├óÔé¼┬ª coralab
3 coralab doesn├óÔé¼Ôäót load queue, and do NOT build anything.
22 corck builds coralab
23 coralab tries to init, but log -> error: a problem occurred load├óÔé¼┬ª coralab
24 coralab doesn├óÔé¼Ôäót load queue, and do NOT build anything.
25-773 repeat above
773 ALL coralab├óÔé¼Ôäós suddenly inits correctly, loads buildqueue and ALL coralab├óÔé¼Ôäós starts building.
779-873 ALL coralabs tries to init, but log -> error: a problem occurred load├óÔé¼┬ª coralab
I have tried to do analysis of logs, to find a pattern in actions leading to the first occurrence (per game) of this error, but have failed

There is a small tendency to the above error first occurrence after this is recorded in the log:
There is a small tendency to the above error first occurrence, after the first level 2 factory is completed. But sometimes the error occurs already when the commander starts building.Factor::CBuild(2)unit finished does not exist?! Could it have been destroyed?
Most of the time however the ├óÔé¼┼ôerror: a problem occurring loading├óÔé¼┬ª├óÔé¼┬Ø happens ├óÔé¼┼ôout of the blue!├óÔé¼┬Ø

I wish


Code: Select all
Factor::CBuild(2)unit finished does not exist?! Could it have been destroyed?
Code: Select all
error: a problem occurred loading units unit definition corxxx
I've made that error message give more information just incase.
I also looked at exclusion zones and added checks just incase to make them lowercase though I dont think there was an issue anyway.
http://www.darkstars.co.uk/randomfiles/NTaiTest2.rar
on a side note, test test test!
http://www.darkstars.co.uk/randomfiles/MAPAI.rar
For a group of units to attack. u need 2 things
1) in config file, under [AI]: attackers=corxxx,armxxx; etc..
2) in config file, under [AI]: initial_threat_value=4; where 4 means build 4 units, then attack in group of 4. (use any number you like)
And finally. Using 9.7C build, NTAI should make a map mark: "attack pos". this happens after about 10 miniuts of game time (in my config).
Scouts are currently OFF, atleast thats my understanding

1) in config file, under [AI]: attackers=corxxx,armxxx; etc..
2) in config file, under [AI]: initial_threat_value=4; where 4 means build 4 units, then attack in group of 4. (use any number you like)
And finally. Using 9.7C build, NTAI should make a map mark: "attack pos". this happens after about 10 miniuts of game time (in my config).
Scouts are currently OFF, atleast thats my understanding

AF:
This is from new build test2:
[00:18] < Frame: 543 >next task?
[00:18] < Frame: 543 >CUnitConstructionTask::Init :: CORWIN
[00:18] < Frame: 543 >CUnitConstructionTask::Init error: a problem occurred loading unit definition: unitid=4998 building=CORWIN
[00:18] < Frame: 557 >next task?
EDIT, AF the new build crashs spring!
-after a few moves / minuts.
AF: what is MAPAI.dll for?
EDIT:
it exports map info. neat! but the export says 0 features found during export. with three tested maps....
Goidse:
hmm..
In the start, ntai often attacks a little cautious, leaving units to cover its rear.
But in my experience, it soon pick up speed, and attacks with all 5 units
What map are u using?
This is from new build test2:
[00:18] < Frame: 543 >next task?
[00:18] < Frame: 543 >CUnitConstructionTask::Init :: CORWIN
[00:18] < Frame: 543 >CUnitConstructionTask::Init error: a problem occurred loading unit definition: unitid=4998 building=CORWIN
[00:18] < Frame: 557 >next task?
EDIT, AF the new build crashs spring!
-after a few moves / minuts.
AF: what is MAPAI.dll for?
EDIT:

Goidse:
hmm..
In the start, ntai often attacks a little cautious, leaving units to cover its rear.
But in my experience, it soon pick up speed, and attacks with all 5 units
What map are u using?
Last edited by lale on 11 May 2007, 18:42, edited 1 time in total.
No, you assign a group of tasklists and it randomly picks one. Theres no ordering to which tasklist it picks at the moment.
NTai doesnt need scouts, and scouting is broken and was disabled as such.
And NTai leaves untis behidn ebcause those untis belong to the next group in line.
if your initial attack group is 5 untis and 4 units have been built and suddenly 2 units are finished then 1 will join the group and go attack and 1 will stay behind and wait for the next group to finish, which will have a size of 6 units.
Also lale, It looks like your editing the configs using a text editor but keep in mind most people edit configs using Toolkit (albeit there are a few features not integrated into toolkit such as metatags and targetting priorities).
Also keep in mind that toolkit writes out a new config it doesnt edit it, so saving in toolkit erases any unsupported tags or comments or formatting you've applied in a text editor, such as // /**/ metatags, or targetting priorities. For examples of metatags and targetting priorities look at old XTA configs from lindir and Arghs old nanoblobz config.
lale could you email me the config you were testing and details of the game you get the crash most often on? It'd help if reproducing the issue was as easy as possible. I'll try and run it through a debugger on my old computer.
NTai doesnt need scouts, and scouting is broken and was disabled as such.
And NTai leaves untis behidn ebcause those untis belong to the next group in line.
if your initial attack group is 5 untis and 4 units have been built and suddenly 2 units are finished then 1 will join the group and go attack and 1 will stay behind and wait for the next group to finish, which will have a size of 6 units.
Also lale, It looks like your editing the configs using a text editor but keep in mind most people edit configs using Toolkit (albeit there are a few features not integrated into toolkit such as metatags and targetting priorities).
Also keep in mind that toolkit writes out a new config it doesnt edit it, so saving in toolkit erases any unsupported tags or comments or formatting you've applied in a text editor, such as // /**/ metatags, or targetting priorities. For examples of metatags and targetting priorities look at old XTA configs from lindir and Arghs old nanoblobz config.
lale could you email me the config you were testing and details of the game you get the crash most often on? It'd help if reproducing the issue was as easy as possible. I'll try and run it through a debugger on my old computer.
- 1v0ry_k1ng
- Posts: 4656
- Joined: 10 Mar 2006, 10:24
- hughperkins
- AI Developer
- Posts: 836
- Joined: 17 Oct 2006, 04:14
Hi AF, had a go at running NTai, but the commander just sits there not moving.
Steps taken:
- installed Spring 0.74b3
- downloaded NTai_XE9.7C.zip
- unzipped NTai_XE9.7C.zip
- copied NTai.dll into $taspring\AI\bot-libs
- downloaded NTaiToolkit0.26a.zip
- unzipped and copied contents into $taspring\ai (so the NTai directory in the zip ends up at $taspring\ai\ntai)
- ran spring with XTA 8.1 and ntai bot
- shutdown spring
- ran NTaitoolkit
- opened config $taspring\ai\ntai\XTA_BT2.tdf
- saved the config
- reran spring with XTA 8.1 and ntai bot
- nothing happened?
Steps taken:
- installed Spring 0.74b3
- downloaded NTai_XE9.7C.zip
- unzipped NTai_XE9.7C.zip
- copied NTai.dll into $taspring\AI\bot-libs
- downloaded NTaiToolkit0.26a.zip
- unzipped and copied contents into $taspring\ai (so the NTai directory in the zip ends up at $taspring\ai\ntai)
- ran spring with XTA 8.1 and ntai bot
- shutdown spring
- ran NTaitoolkit
- opened config $taspring\ai\ntai\XTA_BT2.tdf
- saved the config
- reran spring with XTA 8.1 and ntai bot
- nothing happened?
I dont remember adding a fulyl functional XTA config to the toolkit download. The onyl config that could possibly considered functional for XTA is Ivory Kings, and IK is not giving me the config for some reasond espite the tremendous probability of it never seeing the light of day that results from "wait till I'm finished syndrome".
Your gonna have to build the config yourself.
In the mean time logs wouldnt go amiss. error reports in this thread 90% of the time are utterly useless because they make no mention of logs. Its like 'I couldnt find the needle' the long needle? short? shiny? dull? in a haystack? where? etc, no context.
Goidse, it sounds like youve not assigned the attacker tag to every single attacker. If you tell it to build a peewee and you dont tell it that a peewees an attacker, itll just sit by the factory forever attacking things which come up close. Dont rely on automatic detection of attackers either, its notoriously unreliable(hence why it can be turned on and off).
Your gonna have to build the config yourself.
In the mean time logs wouldnt go amiss. error reports in this thread 90% of the time are utterly useless because they make no mention of logs. Its like 'I couldnt find the needle' the long needle? short? shiny? dull? in a haystack? where? etc, no context.
Goidse, it sounds like youve not assigned the attacker tag to every single attacker. If you tell it to build a peewee and you dont tell it that a peewees an attacker, itll just sit by the factory forever attacking things which come up close. Dont rely on automatic detection of attackers either, its notoriously unreliable(hence why it can be turned on and off).
First: The crash only happens with the dll in NTaiTest2.rar. All previous versions including NTaiCaseTest.rar do not crash.
Second: As you suspect, I do not use the toolkit now,
but have used it until I discovered the problem with solobuild and upper case unit names. (This bug is fixed in NTaiCaseTest). So my current config is based on lots of work in the toolkit, but the section for solobuild and maxenergy are made with a text editor.
Since I wanted to be sure, the crash wasn├óÔé¼Ôäót related to misspelling, I started a new configfile with the toolkit.
Crashreport:
NTaiTest2 crashes if a unitname (eg corwin) instead of a metatag (eg b_power) is entered in build list for a constructor. (at least for corcom)
Step to reproduce: (at least on my machine)
1) erase aa.tdf from learn and config folder
2) start spring, selecting AA v2.23 and map SmallDivide (most maps will do)
3) exit spring (now; new config file is made.)
4) start toolkit, open aa.tdf,
5) make list ├óÔé¼┼ôcom1├óÔé¼┬Ø insert 1 unit ├óÔé¼┼ôcorwin├óÔé¼┬Ø into list
6) assign list ├óÔé¼┼ôcom1├óÔé¼┬Ø to unit corcom
7) save file
8 ) start spring, set bot ntai for core, start game (same map and mod)
9) wait for game to start
10) spring crashes within the first few seconds. when corcom tries to construct corwin.
log file ends with:
, but as you can see from above you should easy be able to reproduce the problem without.
A few more facts:
Second: As you suspect, I do not use the toolkit now,

Since I wanted to be sure, the crash wasn├óÔé¼Ôäót related to misspelling, I started a new configfile with the toolkit.
Crashreport:
NTaiTest2 crashes if a unitname (eg corwin) instead of a metatag (eg b_power) is entered in build list for a constructor. (at least for corcom)
Step to reproduce: (at least on my machine)
1) erase aa.tdf from learn and config folder
2) start spring, selecting AA v2.23 and map SmallDivide (most maps will do)
3) exit spring (now; new config file is made.)
4) start toolkit, open aa.tdf,
5) make list ├óÔé¼┼ôcom1├óÔé¼┬Ø insert 1 unit ├óÔé¼┼ôcorwin├óÔé¼┬Ø into list
6) assign list ├óÔé¼┼ôcom1├óÔé¼┬Ø to unit corcom
7) save file
8 ) start spring, set bot ntai for core, start game (same map and mod)
9) wait for game to start
10) spring crashes within the first few seconds. when corcom tries to construct corwin.
log file ends with:
I do not mind sending you my old config file[-] < FRAME: 0 >loading contents of tasklist :: com1 :: filling tasklist with #1 items
[-] < FRAME: 0 >CunitConstructionTask::CunitConstructionTask building :: CORWIN (btw upper case??)
[-] < FRAME: 0 >loaded contents of tasklist :: com1 :: loaded tasklist at 1 items
[-] < FRAME: 0 >CunitConstructionsTask::Init :: CORWIN
(no more entries ├óÔé¼ÔÇ£ spring has crashed at this point)

A few more facts:
- Crash happens with both BA 4.7 and AA 2.23.
Crash seams to be independent of map. (tested 5 different)
Tried to play with previous dll from NTaiCaseTest.rar using above simple config -> no crash.
Crash happens if unitname in list is: corwin, cortide, corsolar, corllt. But probably for all units corcom can construct
Crash might be confined to corcom, untested at this time.
I├óÔé¼Ôäóve done a little more testing with NTaiCaseTest.
Since I've started to rebuild using the toolkit, I was curios if "cleaning" to the config file would do anything to reduce the error:
I have, however, observed that the above error is highly depended on units under construction getting destroyed├óÔé¼┬ª
Since I've started to rebuild using the toolkit, I was curios if "cleaning" to the config file would do anything to reduce the error:
But so far no luckCUnitConstructionTask::Init error: a problem occurred loading unit definition: unitid=4998 building=CORWIN
(not confined to corwin, only an example)

I have, however, observed that the above error is highly depended on units under construction getting destroyed├óÔé¼┬ª
- If a game is run, without opposition (so no destruction of ntai├óÔé¼Ôäós units), the above error will not happen.
If NTAI is attacked early in the game, the error will happen early, and influence the whole game forward.
So basically unitname construction si borked.
Also metatags != universal build keywords. metatags are defined by the config builder so:
say I define m_factory as corlab corvp and corsy, and give a commander a tasklist with an m_factory keyword, it will randomly pick either a corlab, corvp or corsy to build, filtering out anything that the commander cant build. This way you can define your own keywords such as artillery, raiders , flamers etc.
Also metatags != universal build keywords. metatags are defined by the config builder so:
say I define m_factory as corlab corvp and corsy, and give a commander a tasklist with an m_factory keyword, it will randomly pick either a corlab, corvp or corsy to build, filtering out anything that the commander cant build. This way you can define your own keywords such as artillery, raiders , flamers etc.
Report from NTaiCaseTest3:
Crash has been Fixed!
------
Bug inside my head has been fixed!
OK: factories do NOT shutdown due to error about loading unit (se below)
Problem was in my head and in the config file.
Basically I was having problem with enemy scouts destroying units exiting factories, and came up with this ingenious solution:
>> Put ├óÔé¼┼ôb_reclaim├óÔé¼┬Ø inside build queues for factories <<
BIG MISTAKE!
Factories do NOT reclaim! (forgot that)
When a factory encounters a b_reclaim, it writes a Timeout:
Actually I think all factories should auto-reclaim per default in (or TA mods) spring , if a unit is destroyed in its creation/exit port. Especially if this is implemented:
http://spring.clan-sy.com/phpbb/viewtopic.php?t=10135
-----------------
Errors skipping of building units in list remain.
(But this is a small
error, as it is self correcting, only affects neat build order)
The error starts with the same unitID: eg.
First I see:
The metatags sounds interesting, so now I can make my own m_builder?
Are units in metatags chosen according to learn efficiency, or at random?
(I think I will wait a while before experimenting with metatags, considering the above mentioned failure with the bug in my head)
Crash has been Fixed!
------
Bug inside my head has been fixed!

OK: factories do NOT shutdown due to error about loading unit (se below)
Problem was in my head and in the config file.







Basically I was having problem with enemy scouts destroying units exiting factories, and came up with this ingenious solution:

>> Put ├óÔé¼┼ôb_reclaim├óÔé¼┬Ø inside build queues for factories <<
BIG MISTAKE!



Factories do NOT reclaim! (forgot that)



When a factory encounters a b_reclaim, it writes a Timeout:
After which the factory shutdowns / goes passiveID: 90 Timeout: 2147483647 parms: 75, source of command: cmd_recl Cactions::Reclaim
Actually I think all factories should auto-reclaim per default in (or TA mods) spring , if a unit is destroyed in its creation/exit port. Especially if this is implemented:
http://spring.clan-sy.com/phpbb/viewtopic.php?t=10135
-----------------
Errors skipping of building units in list remain.
(But this is a small

The error starts with the same unitID: eg.
First I see:
Again after several similar errors: (with different unit names, but same unitID)[-] < FRAME: 18031 >CKeywordConstructionTask::Init b_defense
[-] < FRAME: 18036 >next task?
[-] < FRAME: 18036 >CunitConstructionTask::Init :: CORWIN
[-] < FRAME: 18036 >CUnitConstructionTask::Init error: a problem occurred loading unit definition: unitid=4916 building=CORWIN
[-] < FRAME: 18039 >next task?
Now a new corck has been built and the unitID changes:[-] < FRAME: 26369 >CunitConstructionTask::Init :: CORALAB
[-] < FRAME: 26369 >CUnitConstructionTask::Init error: a problem occurred loading unit definition: unitid=4916 building=CORALAB
- And until the error ├óÔé¼┼ôself corrects├óÔé¼┬Ø ALL constructors skips building of unit.[-] < FRAME: 26513 >CunitConstructionTask::Init :: CORWIN
[-] < FRAME: 26513 >CUnitConstructionTask::Init error: a problem occurred loading unit definition: unitid=4947 building=CORWIN
The metatags sounds interesting, so now I can make my own m_builder?
Are units in metatags chosen according to learn efficiency, or at random?
(I think I will wait a while before experimenting with metatags, considering the above mentioned failure with the bug in my head)