AGElint -- an AGE debugging toolkit

Post new mods and scenarios here.
User avatar
berto
Posts: 21461
Joined: Wed Mar 13, 2002 1:15 am
Location: metro Chicago, Illinois, USA
Contact:

more AGEWiki errors -- NOT!

Post by berto »


At the AGEOD AGEWiki

AGEWiki

there are at least sixteen different command reference pages where the indicated Syntax: specification (and example, if any) is in conflict with actual usage, as revealed by an inspection of the various AGEOD game data files.

...

Having been fed an important clue about the interchangeability of the | and ; as separator character, I retract my comments about alleged AGEWiki errors in that regard. (And: see my [oft-repeated] quote two posts following this one.)

Adapting the AGElint parser rules to this new info will be easy.

Still fewer, needless false positives. The truth wins out. Yay! [:)]
Campaign Series Legion https://cslegion.com/
Campaign Series Lead Coder https://www.matrixgames.com/forums/view ... hp?f=10167
Panzer Campaigns, Panzer Battles Lead Coder https://wargameds.com
User avatar
dunnsa
Posts: 75
Joined: Mon Jul 28, 2008 8:20 am

RE: more AGEWiki errors

Post by dunnsa »

AGEOD Volunteer
Visit the AGE Wiki at http://www.ageod.net/agewiki/Main_Page
User avatar
berto
Posts: 21461
Joined: Wed Mar 13, 2002 1:15 am
Location: metro Chicago, Illinois, USA
Contact:

RE: more AGEWiki errors

Post by berto »

Thanks for the tip. It was helpful. [;)]
ORIGINAL: berto

NOTE: I make no claim about the significance or insignificance of any discovered bug, problem, glitch, or anomaly. Whether or not it impacts game play, or goes entirely unnoticed. Whether in the larger scheme of things it's important, or unimportant. It's up for you to decide, and maybe for us as a community to determine. (If over time we agree that something is not worth reporting, or is not in fact any kind of problem, I will program it out of the toolkit.)

FURTHER NOTE: I offer no judgment about AGEOD, or its games. Nothing asserted, nothing implied. AGElint is a tool, not a weapon. We use it to build better games, not to tear down any company or anybody.

... This is the current state of AGElint, which reflects my imperfect and evolving understanding of the AGE system and its scripting. I make my share of mistakes, but except for honest differences of opinion, I correct my goofs!
[:)]
Campaign Series Legion https://cslegion.com/
Campaign Series Lead Coder https://www.matrixgames.com/forums/view ... hp?f=10167
Panzer Campaigns, Panzer Battles Lead Coder https://wargameds.com
User avatar
berto
Posts: 21461
Joined: Wed Mar 13, 2002 1:15 am
Location: metro Chicago, Illinois, USA
Contact:

AGElint -- v1.1.1 official release

Post by berto »


Here is the third "official" AGElint version, 1.1.1 (20120119): AGElint version 1.1.1 features some minor changes to the txt.y parser.

Here is a more detailed list of changes in AGElint 1.1.1:

Changes from AGElint_1.1.0 (20120117) to AGElint_1.1.1 (20120119):
The practical significance of these changes is very little. I ran chklint.pl against all five of the analyzed AGEOD games (ACW, NCP, ROP, RUS & WIA), and there were no differences in the error reports. Nonetheless, I thought it important to keep up with new info, and insights, hence this new release.

NOTE: There are still discrepancies, not relating to the ; vs. | field separator issue, between the AGEWiki docs and actual game data usage. The several cases of this are noted in the txt.y parser comments.

There Will Be Bugs. And they will be fixed!
Campaign Series Legion https://cslegion.com/
Campaign Series Lead Coder https://www.matrixgames.com/forums/view ... hp?f=10167
Panzer Campaigns, Panzer Battles Lead Coder https://wargameds.com
User avatar
berto
Posts: 21461
Joined: Wed Mar 13, 2002 1:15 am
Location: metro Chicago, Illinois, USA
Contact:

another game bug checking toolkit project

Post by berto »

ORIGINAL: berto

AGElint 1.1.[1] is the first release I am truly happy with. Some problems remain, but they are hidden, behind the scenes. You should get much useful results, with fewer distractions and aggravations, in this latest official AGElint version.

...

The "hidden" problems? They include:
  • A loosely specified event syntax sequence. Due to some technical quirks with the bison (yacc) parser (the "lookahead" mechanism), I am yet unable to report erroneous action statements in Conditions, condition statements in Actions, and mistakenly omitted Conditions and Actions statements. This will be addressed in future versions.
  • In some situations, errors/warnings will mask subsequent errors/warnings. I need to improve parser 'error' recovery, for detecting *all* errors etc. in a given data file.
There are other things I still want to implement -- see the distribution TODO file -- but in general I am pleased with AGElint 1.1.[1]. I hope you will be, too.
Despite the "hidden" problems and the remaining TODOs, AGElint v1.1.1, the current "official" AGElint release, is more than "good enough" for now.

Over the near term, I am moving on to develop another *lint bug checking toolkit (sharing much of the same code and technologies in AGElint) for another non-AGEOD game system.
ORIGINAL: berto

How much further I take AGElint development depends on a lot of things, in particular
  • actual usage (not necessarily by me; I am finished running AGElint reports for others)
  • useful, constructive feedback (let us strive to keep negativity out of the discussion)
  • possibly other coders joining the effort (so AGElint is a community Open Source project)
  • user and player enthusiasm
I will return to developing, improving, and debugging AGElint as the need arises.

But for now, I've got that other game bug checking toolkit project to work on... [;)]
Campaign Series Legion https://cslegion.com/
Campaign Series Lead Coder https://www.matrixgames.com/forums/view ... hp?f=10167
Panzer Campaigns, Panzer Battles Lead Coder https://wargameds.com
User avatar
Chilperic
Posts: 964
Joined: Sun Mar 21, 2010 4:11 pm

RE: another game bug checking toolkit project

Post by Chilperic »

Installed and running on the last AACW beta patch. There are yet about 100 events bugged. [8|]
User avatar
berto
Posts: 21461
Joined: Wed Mar 13, 2002 1:15 am
Location: metro Chicago, Illinois, USA
Contact:

RE: another game bug checking toolkit project

Post by berto »


If you think it worthwhile, I can set aside temporarily my other *lint-like project and attempt to fix the unresolved AGElint issue of
  • A loosely specified event syntax sequence. Due to some technical quirks with the bison (yacc) parser (the "lookahead" mechanism), I am yet unable to report erroneous action statements in Conditions, condition statements in Actions, and mistakenly omitted Conditions and Actions statements. This will be addressed in future versions.
I don't think it should take me more than a day or two to fix this.
Campaign Series Legion https://cslegion.com/
Campaign Series Lead Coder https://www.matrixgames.com/forums/view ... hp?f=10167
Panzer Campaigns, Panzer Battles Lead Coder https://wargameds.com
User avatar
berto
Posts: 21461
Joined: Wed Mar 13, 2002 1:15 am
Location: metro Chicago, Illinois, USA
Contact:

recursive diffs of one AGEOD game install to another

Post by berto »


Here is a technique for determining all of the differences between two different AGEOD game installations, from one release to another.

For example, a recursive diff between the latest "official" RUS 1.04 and that version patched with RUS/Fatal Years 1.06RC:

Robert@roberto /cygdrive/c/Games/AGEOD
$ ls
Revolution under Siege Revolution under Siege FY

Robert@roberto /cygdrive/c/Games/AGEOD
$ diff -r "Revolution under Siege" "Revolution under Siege FY" 2>&1 | tee RUS.diff

The Cygwin (Unix/Linux) 'tee' command outputs to both screen and the specified file. If you prefer, you could instead avoid the screen output and just capture to the file with:

Robert@roberto /cygdrive/c/Games/AGEOD
$ diff -r "Revolution under Siege" "Revolution under Siege FY" 2>&1 > RUS.diff

You could then inspect the RUS.diff file, with either of:

Robert@roberto /cygdrive/c/Games/AGEOD
$ less RUS.diff

Robert@roberto /cygdrive/c/Games/AGEOD
$ view RUS.diff

or use NotePad (or your preferred Windows editor or file viewer) as you wish.

Here are some snippets from the RUS.diff file:

diff -r Revolution under Siege/!Profiler0.txt Revolution under Siege FY/!Profiler0.txt
1c1
< 12:19:48 AM (Reporting) TFileParser.MakeAliases 6803 Aliases loaded, out of 31 files
---
> 3:44:02 PM (Reporting) TFileParser.MakeAliases 7051 Aliases loaded, out of 31 files
Only in Revolution under Siege FY: FY.exe
Only in Revolution under Siege FY: Fatal Years 1.05.pdf
Only in Revolution under Siege FY: Fatal Years mod 1.06.zip
Only in Revolution under Siege FY: How to install the mod.txt
diff -r Revolution under Siege/RUS/Aliases/Areas_Aliases.ini Revolution under Siege FY/RUS/Aliases/Areas_Aliases.ini
1c1
< $Area_Kuban = 0
---
> $Area_Open_Seas = 0
56c56
< $Area_Open_Seas = 55
---
> $Area_Kuban = 55

[...]

diff -r Revolution under Siege/RUS/Aliases/MetaAreas_Aliases.ini Revolution under Siege FY/RUS/Aliases/MetaAreas_Aliases.ini
76,79c76,86
< $EventArea_WhiteAttackAnarchists = 154
< $EventArea_PolishIntervention = 155
<
<
---
> $Event_RepairRailroad = 154
> $Event_RepairRailroadWH3 = 155
> $Event_RepairRailroadWHI = 156
> $Industrial_Towns = 157
> $Odessa_French = 158
> $Kazan_check = 159
> $Arzamas_check = 160
> $Orel_check = 161
> $Tula_check = 162
> $Huliaipole_check = 163
> $Tzaritsyn_check = 164
diff -r Revolution under Siege/RUS/Aliases/TerrainsTypes.ini Revolution under Siege FY/RUS/Aliases/TerrainsTypes.ini
23a24,28
> $Beach = 19
> $Fort = 20
> $LandInterdictionLink = 21
> $TransitionLink = 22
> $City = 23
25,26c30,34
< $MajorFerry 25
< $Steppe = 29
---
> $MajorFerry = 25
> $NavalInterdictionLink = 26
> $LongTransitionLink = 27
> $VeryLongTransitionLink = 28
> $Steppes = 29

[...]

diff -r Revolution under Siege/RUS/Events/3-November1918.sct Revolution under Si
ege FY/RUS/Events/3-November1918.sct

[...]

433a434,435
> MaxDate = 1919/05/01
> Probability = 50
565c567
< FixType = 999
---
> FixType = 0
569a572
> FlavorName = A.V. Kolchak
576c579
< SelectRegion = $Odessa
---
> SelectRegion = $Gulf of Odessa
579,580c582,583
< SelectRegion = $Odessa
< StartEvent = evt_nam_Renforts_CMN_FrenchIntervention|1|2|evt_txt_Renforts_CMN_FrenchIntervention|Event-img_Renforts_CMN_FrenchIntervention|$Odessa|NULL
---
> SelectRegion = $Gulf of Odessa
> StartEvent = evt_nam_Renforts_CMN_FrenchIntervention|1|2|evt_txt_Renforts_CMN_FrenchIntervention|Event-img_Renforts_CMN_FrenchIntervention|$Gulf of Odessa|NULL
583c586
< MinDate = 1918/12/01
---
> MinDate = 1918/12/15
586c589
< Probability = 60
---
> Probability = 40
595,598d597
< SelectRegion = $Odessa
< SelectRegion = $Odessa
< BlockState = 0
<
600,601c599,601
< SelectRegion = $Odessa
< ChangeRgnOwner = UKR
---
> SelectRegion = $Gulf of Odessa
>
> SelectRegion = $Gulf of Odessa
604c604
< SelectRegion = $Odessa
---
> SelectRegion = $Gulf of Odessa
607c607
< SetKind = $Land
---
> SetKind = $Nav

[...]

diff -r Revolution under Siege/RUS/Events/CaucasusSetup.sct Revolution under Siege FY/RUS/Events/CaucasusSetup.sct
0a1,769
>
> NULL = NULL
>
>
> SelectFaction = $WHI
> StartEvent = evt_nam_WHI_CaucasusJoin_armydeploymentcondition1|1|0|NULL|NULL|NULL|NULL
>
> Conditions
> MinDate = 1918/12/01
>
> EvalEvent = evt_nam_RED_CaucasianDOW_Tracker;=;1
>
> Actions
>
>
> SetEvtOccurs = evt_nam_WHI_Caucasusarmydeploymentconditionfulfilled;CuOccurs;1
> SetEvtOccurs = evt_nam_WHI_Caucasusarmydeploymentconditionfulfilled;MaxOccurs;1
>
> EndEvent

[...]

diff -r Revolution under Siege/RUS/Events/REDAI1918.sct Revolution under Siege FY/RUS/Events/REDAI1918.sct
52c52
< AI.SetLocalInterest = $Kungrad;5;$Chodzenli;5;$Khiva;5;$Ust-Urt Steppe;5;$Mirzachirla;5;$Sarakhs;5;$Yerbent;5;$Bakhardok;5;$Kara Koum;5;$Tashauz;5;$Tedzhen;5;$Il Yaly;5;$Krasnovodsk;5;$Koturdebe;5;$Okarem;5;$Nebit Dag;5;$Madav;5;$Sharlavuk;5;$Kum Dag;5;$Bajgiran;5;$Kara-Kala;5;$Kazandzhik;5;$Bakharden;5;$Achkhabad;5;$Karabogaz Coast;5;$Chagyl;5;$Sarykamysskoe;5;$Karakum Lake;5;$Urgench;5;$Sumanaj;5;$Kizyl-Bajdak;5;$Turkmenistan Desert;5;$Gorelde;5;$Repetek;5;$Merv;5;$Uch-Adzhi;5;$Kerki;5;$Novyy Uzen;5;$Aqtau;5;$Shebir;5;$Zharmysh;5;$Kabanbay;5;$Bejneu;5;$Akzigit;5;$Sam Pervij;5;$Saura;5;$Fetisovo;5;$Senek;5;$Moynoq;5;$Kaplankyr;5;$Darvaza;5;$Bugdayly;5;$Monzhukly;5;$Kerpichli;5;$Bikuri;5;$Bayramaly;5;$Kyzyl HodzhREDzar;5;
---
> AI.SetLocalInterest = $Kungrad;5;$Chodzenli;5;$Khiva;5;$Ust-Urt Steppe;5;$Mirzachirla;5;$Sarakhs;5;$Yerbent;5;$Bakhardok;5;$Kara Koum;5;$Tashauz;5;$Tedzhen;5;$Il Yaly;5;$Krasnovodsk;5;$Koturdebe;5;$Okarem;5;$Nebit Dag;5;$Madav;5;$Sharlavuk;5;$Kum Dag;5;$Bajgiran;5;$Kara-Kala;5;$Kazandzhik;5;$Bakharden;5;$Achkhabad;5;$Karabogaz Coast;5;$Chagyl;5;$Sarykamysskoe;5;$Karakum Lake;5;$Urgench;5;$Sumanaj;5;$Kizyl-Bajdak;5;$Turkmenistan Desert;5;$Gorelde;5;$Repetek;5;$Merv;5;$Uch-Adzhi;5;$Kerki;5;$Novyy Uzen;5;$Aqtau;5;$Shebir;5;$Zharmysh;5;$Kabanbay;5;$Bejneu;5;$Akzigit;5;$Sam Pervij;5;$Saura;5;$Fetisovo;5;$Senek;5;$Moynoq;5;$Kaplankyr;5;$Darvaza;5;$Bugdayly;5;$Monzhukly;5;$Kerpichli;5;$Bikuri;5;$Bayramaly;5;$Kyzyl Hodzhanazar;5;
146c146
< EvalSubUnitCount = >=;5
---
> EvalSubUnitCount = >=;30
198c198
< EvalSubUnitCount = >=;5
---
> EvalSubUnitCount = >=;30
406c406
< EvalSubUnitCount = >=;5
---
> EvalSubUnitCount = >=;25

[...]

diff -r Revolution under Siege/RUS/Events/REDAIICEMARCH.sct Revolution under Siege FY/RUS/Events/REDAIICEMARCH.sct
185c185
< AI.SetLocalInterest = $Tikhoretskaya;200;$Ekaterinodar;200;$Novorossiyk;200;
---
> AI.SetLocalInterest = $Tikhoretskaya;200;$Ekaterinodar;200;$Novorossiysk;200;

[...]

And on and on.

In the diff output, things like '185c185' refer to line #s in the diffed files; '<' denotes lines in the first listed file (in the diff command); '>' denotes the second listed file.

Tons of interesting stuff there, including not a few bug fixes (changed parameters, fixed alias misspellings for example).

You can also use this 'diff -r' technique to track changes between AGEOD-released betas and "official" releases.

I am sure you will all find this recursive diff technique to be quite useful.
Campaign Series Legion https://cslegion.com/
Campaign Series Lead Coder https://www.matrixgames.com/forums/view ... hp?f=10167
Panzer Campaigns, Panzer Battles Lead Coder https://wargameds.com
User avatar
berto
Posts: 21461
Joined: Wed Mar 13, 2002 1:15 am
Location: metro Chicago, Illinois, USA
Contact:

RE: another game bug checking toolkit project

Post by berto »


At the public AGEOD Forum

http://www.ageod-forum.com/showthread.php?t=23891&page=3

this (freely available, for anybody to read) exchange:
[Nikel:] Those Python check scripts is a tool similar to Berto's to detect bugs?

Does it mean that AGE engine next title will have less bugs?

Is Lafrite the author of both the Piton checks and the next game?
[PhilThib:] Yes, similar but does not require Linux and faster to operate, directly onto excel files sources

This help solve a lot of pre-release "bugs" or errors, although it will require a little bit of extra time, this is a great improvement...
Also, earlier in that message thread Lodilefty's thanking Lafrite for "the Python© script checking tools."

You all have no idea how happy I am to learn this. Truly. [:)]

There is more than one way to skin a cat. [;)]

Clearly, AGEOD is forever wedded to its .XLS DB-centric approach. No doubt, they will find any tool "faster to operate" that works "directly onto excel files sources." More power to them!

Although some of us might disagree about the merits of the .XLS DB-centric approach in the first place, and find it more convenient and faster to work directly on the end-product text files, avoiding the whole .XLS DB -> saved .CSV file -> CSV splitter -> text file rigramole altogether.

One way or the other, whatever works.

The data files for the AGE games are massive, amounting to hundreds of megabytes in tens of thousands of files. (In PON's case, there is over 1 gigabyte of data in 60,000+ files!)

In game data sets of that size: There Will Be Bugs. Lots and lots of them, you can be sure. What's important: facing the issue squarely, and resolving to do something about it. Something meaningful. Something powerful.

It is truly great to learn that AGEOD is applying automated tools and techniques, in whatever form, to improve its QA. [8D]

"In whatever form." "Whatever works." I sincerely believe that.

A few years ago, while working with the Magna Mundi development team, I wrote:
At first glance, I am impressed with Jamie550's Validator

http://forum.paradoxplaza.com/forum/sho ... p?t=428317

The most impressive thing is that, by exposing the guts of the system, by laying out the parser to user modification, we can adapt it to MagnaMundi use. I will busy myself with learning this tool and proceeding with the adaptation.

I might still develop my mmdebug program, if after all I still see a need for it, but it will suffer from: it will probably remain a Linux and/or Cygwin tool, hence will likely not be used by other than myself. The fact that anybody--including the MM devs--can use and adapt Validator is a powerful argument in its favor.
So, despite having worked long and hard on mmdebug (and its earlier eu3debug forebear), I was willing to stifle disappointment and pride and instead endorse the tool (Validator) that people would actually use.

A debugging tool (or toolkit) is pointless if nobody uses it. (Although, for the record: By now, over a dozen persons have downloaded AGElint, if only to have a look-see.) If AGEOD actually uses Lafrite's tool, it's a win-win situation: Less work for AGEOD, fewer bugs for us gamers. What's not to like?

Which tool is more powerful? In the overall development sequence, which tool gives faster results?

Which tool kills the most bugs?

May the best tool win!

I'd be happy to "lose" this "competition". Lose the battle, win the war. [:D]

Then I could set aside this very hard and time-consuming QA work and get back to actually playing games again! [X(]
Campaign Series Legion https://cslegion.com/
Campaign Series Lead Coder https://www.matrixgames.com/forums/view ... hp?f=10167
Panzer Campaigns, Panzer Battles Lead Coder https://wargameds.com
User avatar
Chilperic
Posts: 964
Joined: Sun Mar 21, 2010 4:11 pm

RE: another game bug checking toolkit project

Post by Chilperic »

Too late.

Howewer, you were right.[:)]For my own use, agelint is unvaluable. And it may be used with windows 7. [;)]
User avatar
berto
Posts: 21461
Joined: Wed Mar 13, 2002 1:15 am
Location: metro Chicago, Illinois, USA
Contact:

chkweathers.pl -- another script forthcoming

Post by berto »


At the "RUS weather mod" thread

http://www.matrixgames.com/forums/tm.asp?m=2994074&mpage=1&key=&#3026049

post #5:
On a hunch, I did some data mining. And discovered still more default RUS weathers errors!

...

Recapping, we have at least the following errors in the default RUS weathers specification:
  • duplicate weather area region assignments: Alexandrovsk, Lake Ladoga, Pacific Ocean, Zalitch
  • weather area assignment in Areas.ini, not among Regions: Don River, Lappeenranta, Pieksamaki, Tuymazy
  • among Regions, no weather area assignment in Areas.ini: Aleksandrovsk, Don, Lappeenrenta, Pieksimaki, Wallachia, Zelenaya Roshcha (in effect, these regions have no assigned weathers!)
...

One more item to check with AGElint. [:)]

... In final AGElint form, these checks will take the form of a script, for example (something like): 'chkweathers.pl -g rus'.
Quoting myself again:
At present, AGElint is more than a beginning, but far from an ending. The dream is to code a set of utilities and capabilities to check all manner of AGEOD bugs/errors/glitches/anomalies... There's still much more untapped potential, much more to be done...
Indeed, indeed. [:)]
Campaign Series Legion https://cslegion.com/
Campaign Series Lead Coder https://www.matrixgames.com/forums/view ... hp?f=10167
Panzer Campaigns, Panzer Battles Lead Coder https://wargameds.com
User avatar
berto
Posts: 21461
Joined: Wed Mar 13, 2002 1:15 am
Location: metro Chicago, Illinois, USA
Contact:

a reminder, a clarification, and some general comment

Post by berto »


I feel I need to repeat:
I offer no judgment about AGEOD, or its games. Nothing asserted, nothing implied. AGElint is a tool, not a weapon. We use it to build better games, not to tear down any company or anybody.
And to clarify:

I do not find fault with AGEOD, or any dev, beta team member, or Coordinator, for not finding these mistakes.
In game data sets of [RUS' etc. massive] size: There Will Be Bugs.
How can there not be? There is simply too much detail for any human being, or any team of humans no matter how hard working and dedicated, to discover on their own. This is where

http://en.wikipedia.org/wiki/Static_code_analysis

http://en.wikipedia.org/wiki/Automated_code_review

come into play. We leverage the power of the computer, together with the appropriate software tools and techniques, to help us discover the bugs.

There is no shame in not knowing how to data mine, in not knowing Linux (Cygwin) command-line "sorcery", in not knowing how to program the appropriate and needed tools.

What I do find fault with, however, is: Knowing about the bugs, being provided with the tools (AGElint, or whatever), then: doing nothing about it. [;)]

I, too, am human, therefore fallible. I will reveal ignorance. I too will make mistakes. And I will do something about them!

But even if I don't, if AGEOD doesn't, the tools and techniques are there, for empowering the players (and modders).

Players of the world unite! You have nothing to lose but your bugs!
Campaign Series Legion https://cslegion.com/
Campaign Series Lead Coder https://www.matrixgames.com/forums/view ... hp?f=10167
Panzer Campaigns, Panzer Battles Lead Coder https://wargameds.com
User avatar
berto
Posts: 21461
Joined: Wed Mar 13, 2002 1:15 am
Location: metro Chicago, Illinois, USA
Contact:

thoughts for the day

Post by berto »


Ralph Nader, (in)famous American consumer protection advocate:
Power has to be insecure to be responsive.
Your best teacher is your last mistake.
Not that I'm a Green or anything. [8|]
Campaign Series Legion https://cslegion.com/
Campaign Series Lead Coder https://www.matrixgames.com/forums/view ... hp?f=10167
Panzer Campaigns, Panzer Battles Lead Coder https://wargameds.com
User avatar
Chilperic
Posts: 964
Joined: Sun Mar 21, 2010 4:11 pm

RE: thoughts for the day

Post by Chilperic »

I will not compare Lafrite 's tool and yours, even if I'm using both, when possible, as much of the xls data of the official versions are older than the current version (AACW database in xls is 2009 vintage....).
I will just say:

- using both tools is better, I don't understand why i should use only one, especially when both tools are running under windows 7)
- agelint is reporting bugs Lafrite 's one doesn't.

After all, there are 2 unofficial tools, done freely by people wanting to enhance QA. Like me. [:)]
User avatar
berto
Posts: 21461
Joined: Wed Mar 13, 2002 1:15 am
Location: metro Chicago, Illinois, USA
Contact:

RUS Areas.ini errors

Post by berto »


In the course of working on my RUS weather mod, in the RUS Areas.ini file, three interesting finds:

// Area #149
{Area}
UID = $EventArea_GermanOccupation2
Name = $EventArea_GermanOccupation2
Hierarchy = -1
ListParams = $Dymer|$Kiev|$Kaniv|$Nijyn|$Poltava|$Lubny|$Kremenchuk|$$Lebedyn|$Krasnokutsk|$Mahdalynivka|$Karlivka|$Novomoskovsk|$Brovary|$Boryspil|$Pryluky|$Lokhvitsa|$Pereiaslav|$Bakhmach|$Konotop|$Nossivka|$Borzna|$Shostka
{/Area}

The duplicate $ anomaly (in $$Lebedyn).

Then the misplaced $ bugs:

// Area #132
{Area}
UID = $EventArea_Epidemic_Swamp
Name = Event$Area_nam_Epidemic_Swamp

It should of course be: $EventArea_nam_Epidemic_Swamp

// Area #135
{Area}
UID = $EventArea_Close_to_Petrograd
Name = Event$Area_nam_Close_to_Petrograd

And this one should be: $EventArea_nam_Close_to_Petrograd

At this point, it is not clear what if any impact these anomalies might have on game play. Still, they are "interesting".

Please note: In AGElint, I have not yet incorporated Areas.ini checks. (Hint: there are more "interesting" finds, especially in the other games.) Maybe I should? (Of course!)
Campaign Series Legion https://cslegion.com/
Campaign Series Lead Coder https://www.matrixgames.com/forums/view ... hp?f=10167
Panzer Campaigns, Panzer Battles Lead Coder https://wargameds.com
User avatar
Chilperic
Posts: 964
Joined: Sun Mar 21, 2010 4:11 pm

RE: RUS Areas.ini errors

Post by Chilperic »

These 3 ones aren't used in FY. [:)]
User avatar
berto
Posts: 21461
Joined: Wed Mar 13, 2002 1:15 am
Location: metro Chicago, Illinois, USA
Contact:

RE: RUS Areas.ini errors

Post by berto »


Right. Although I sometimes try to clarify if a found bug is in this or that version, my comments can often be misconstrued.

When I post stuff in the AGElint or weathers mod threads, it is usually of generic nature.

When I post stuff in the RUS/FY thread, it is usually specific to that mod.

But there is ambiguity, sure.

Which is why, for the most part (except when explaining a new script, feature, or AGElint bug fix), the best policy is just to make tools, not to issue (widespread, specific) bug reports.

Let the modders/players make of AGElint (and any other mod) what they will. Empower them, then let them decide for themselves.
Campaign Series Legion https://cslegion.com/
Campaign Series Lead Coder https://www.matrixgames.com/forums/view ... hp?f=10167
Panzer Campaigns, Panzer Battles Lead Coder https://wargameds.com
User avatar
berto
Posts: 21461
Joined: Wed Mar 13, 2002 1:15 am
Location: metro Chicago, Illinois, USA
Contact:

another false positive: numbers vs. aliases

Post by berto »


Regarding a "false positive" about use of numbers in, for example, EvalRgnWeather.

No doubt numbers would work everywhere an alias is suggested. But it's probably not good practice.

Rather than signalling "syntax error", I think I will relax the grammar to permit numbers in place of aliases, but with a WARNING.

A nice and very worthwhile adjustment.

... On second thought, not!

It blows apart the parser (introduces potentially 1,000s of reduce/reduce ambiguities) and creates all manner of difficulty.

For example, consider the two (among very many) possibilities:

AI.SetLocalInterest = $Novocherkassk;5;$Rostov;5;$Taganrog;5;$Donetsk;5;$Makeievka;5

versus (the region numbers have been made up):

AI.SetLocalInterest = 21;5;22;5;30;5;32;5;34;5

Allowing the second case introduces all sorts of mischief, including: How do we (easily, or at all) distinguish between a missing region alias vs. a missing interest coefficient?

Back to the drawing boards...
Campaign Series Legion https://cslegion.com/
Campaign Series Lead Coder https://www.matrixgames.com/forums/view ... hp?f=10167
Panzer Campaigns, Panzer Battles Lead Coder https://wargameds.com
User avatar
berto
Posts: 21461
Joined: Wed Mar 13, 2002 1:15 am
Location: metro Chicago, Illinois, USA
Contact:

no end to it ... or is there?

Post by berto »


I have programmed two more bug checking scripts, chkareas.pl & chkregions.pl, which between them have detected, across all five of the analyzed AGEOD games, more indisputable game data file errors.

[:(]

It all grows to be so tiresome, more trouble than it's worth...
Campaign Series Legion https://cslegion.com/
Campaign Series Lead Coder https://www.matrixgames.com/forums/view ... hp?f=10167
Panzer Campaigns, Panzer Battles Lead Coder https://wargameds.com
User avatar
berto
Posts: 21461
Joined: Wed Mar 13, 2002 1:15 am
Location: metro Chicago, Illinois, USA
Contact:

chkareas.pl & chkregions.pl

Post by berto »


[8|]

Getting back to work...

In developing chkareas.pl & chkregions.pl, I encounter a puzzle:

In ACW, there are two Regions files, both with the name "Susquehanna, PA":

[root@berto Regions]# pwd
/media/KINGSTON/Games/AGEOD/AGEod's American Civil War/ACW/GameData/Regions

[root@berto Regions]# ls -1 *Susquehanna*
46Susquehanna, PA.rgn
76Susquehanna, PA.rgn

The contents of those files:

[root@berto Regions]# egrep "^UID =|^Name =" 46Susquehanna,\ PA.rgn
UID = 46
Name = Susquehanna, PA
[...]

[root@berto Regions]# egrep "^UID =|^Name =" 76Susquehanna,\ PA.rgn
UID = 76
Name = Susquehanna, PA
[...]

In ACW/Aliases/Regions.ini, we have:

[root@berto Aliases]# pwd
/media/KINGSTON/Games/AGEOD/AGEod's American Civil War/ACW/Aliases

[root@berto Aliases]# egrep "= 46" Regions.ini | head -n 1
$Lackawanna, PA = 46

[root@berto Aliases]# egrep "= 76" Regions.ini | head -n 1
$Susquehanna, PA = 76

Note that Region 46 is "Susquehanna, PA", but for alias value 46, the corresponding alias is "Lackawanna, PA".

It gets curiouser. In LocalStrings_ACW.csv, we have:

[root@berto Settings]# pwd
/media/KINGSTON/Games/AGEOD/AGEod's American Civil War/ACW/Settings

[root@berto Settings]# egrep "Susquehanna|Lackawanna" LocalStrings_ACW.csv
RegionName46;Lackawanna, PA;Lackawanna, PA;Lackawanna, PA;Lackawanna, PA;NULL;Lackawanna, PA;
RegionName76;Susquehanna, MD;Susquehanna, MD;Susquehanna, MD;Susquehanna, MD;NULL;Susquehanna, MD;

Note that for alias RegionName76, the values are all "Susquehanna, MD". But as you can see above, region 76 is otherwise given as "Susquehanna, PA".

So what is it (for region 46): "Susquehanna, PA" or "Lackawanna, PA"?

And is it (for region 76): "Susquehanna, PA" or "Susquehanna, MD"?

Are you thoroughly confused yet? [&:]

There are more than a few discrepancies like that in the various AGEOD game data files.

Do these discrepancies matter? Are they cosmetic flavor only? Mere oversights? Are they clever kludges to solve obscure problems? Or are they bugs, that impact actual game play?

Whichever, I don't see what good can come from such (needless?) confusion.
Campaign Series Legion https://cslegion.com/
Campaign Series Lead Coder https://www.matrixgames.com/forums/view ... hp?f=10167
Panzer Campaigns, Panzer Battles Lead Coder https://wargameds.com
Post Reply

Return to “Mods and Scenarios”