• We have updated our Community Code of Conduct. Please read through the new rules for the forum that are an integral part of Paradox Interactive’s User Agreement.
Found a few false positives (on the newest version)

--- Error 1 of 1 ---
At <mod>\events\job_lord_spiritual.txt [character_event\mean_time_to_happen\modifier\location\OR\is_reformed_religion] (Line 432, column 6):
Invalid node "is_reformed_religion" in scope ProvTrigger (value is: yes)
Code:
		modifier = {
			factor = 3.0
			religion_group = pagan_group
			is_reformed_religion = no
			NOT = { religion = hellenic_pagan }
			location = {
				OR = {
					NOT = { religion_group = pagan_group }
					is_reformed_religion = yes
				}
			}
		}
An example of this can be found in the vanilla files in job_lord_spiritual in events

--- Error 1 of 1 ---
At <mod>\events\byzantine_events.txt [narrative_event\option\character_event\id] (Line 807, column 23):
"LoR.873" is not a valid CharEventId.
Code:
# The Letter (has daughter)
narrative_event = {
	id = LoR.869
	title = EVTNAMELoR.869
	desc =*EVTDESCLoR.869
	picture = GFX_evt_recieve_letter
	
	is_triggered_only = yes
	
	hide_from = yes
	
	option = {
		name = EVTOPTALoR.869
		character_event = { id = LoR.872 days = 7 tooltip = EVTTOOLTIPLoR.872 }
	}
	option = {
		name = EVTOPTBLoR.869
		character_event = { id = LoR.873 days = 7 tooltip = EVTTOOLTIPLoR.873 }
	}
}

I believe this one stems from event 869 pointing to a narrative_event via a character_event call, however this type of setup can be found like this in case (byzantine_events.txt for example)

--- Error 1 of 1 ---
At <mod>\events\00_ck2plus_events.txt [province_event\immediate\random_courtier] (Line 1694, column 3):
Invalid node "random_courtier" in scope ProvCommand (value is: <a complex type>)
Code:
province_event = {
	id = 1000182044
	desc = 1000182044.desc
	picture = "GFX_evt_garden"

	is_triggered_only = yes

	immediate = {
		random_vassal = {
			limit = { has_job_title = job_marshal }
			location = {
				set_province_flag = keep_it
				add_province_modifier = { name = "keep_it" duration = -1 }
			}
		}
		random_courtier  = {
			limit = { has_job_title = job_marshal }
			location = {
				set_province_flag = keep_it
				add_province_modifier = { name = "keep_it" duration = -1 }
			}
		}
	}

	option = {
		name = 1000182044.opta
		ai_chance = { factor = 0 }
	}
}
This event works just fine the way it is. Similarly random vassal throws a false positive in this exact same set.

Code:

EDIT: I am getting the following error:

--- Error 1 of 1 ---
At <mod>\events\adventures_the_old_gods.txt [character_event\only_ruler] (Line 22, column 2):
Invalid node "only_ruler" in scope CharEvent (value is: no)
Code:
character_event = {
	id = TOG.1200
	desc =*OK
	picture = GFX_evt_crusaders
	border = GFX_event_normal_frame_war

	hide_window = yes # Only fires for unplayable landless characters

	only_ruler = no
	only_men = yes
	
	min_age = 16
	max_age = 50
	capable_only = yes
	prisoner = no
	

	trigger = {
		has_dlc = "The Old Gods"

However according to http://forum.paradoxplaza.com/forum/showthread.php?611797-Event-coding-efficiency that is a valid place to put it. Is my source mistaken, am I mistaken, or is this a false positive?
 
Last edited:
Found a few false positives (on the newest version)

Code:
		modifier = {
			factor = 3.0
			religion_group = pagan_group
			is_reformed_religion = no
			NOT = { religion = hellenic_pagan }
			location = {
				OR = {
					NOT = { religion_group = pagan_group }
					is_reformed_religion = yes
				}
			}
		}
An example of this can be found in the vanilla files in job_lord_spiritual in events

Code:
# The Letter (has daughter)
narrative_event = {
	id = LoR.869
	title = EVTNAMELoR.869
	desc =*EVTDESCLoR.869
	picture = GFX_evt_recieve_letter
	
	is_triggered_only = yes
	
	hide_from = yes
	
	option = {
		name = EVTOPTALoR.869
		character_event = { id = LoR.872 days = 7 tooltip = EVTTOOLTIPLoR.872 }
	}
	option = {
		name = EVTOPTBLoR.869
		character_event = { id = LoR.873 days = 7 tooltip = EVTTOOLTIPLoR.873 }
	}
}

I believe this one stems from event 869 pointing to a narrative_event via a character_event call, however this type of setup can be found like this in case (byzantine_events.txt for example)

Code:
province_event = {
	id = 1000182044
	desc = 1000182044.desc
	picture = "GFX_evt_garden"

	is_triggered_only = yes

	immediate = {
		random_vassal = {
			limit = { has_job_title = job_marshal }
			location = {
				set_province_flag = keep_it
				add_province_modifier = { name = "keep_it" duration = -1 }
			}
		}
		random_courtier  = {
			limit = { has_job_title = job_marshal }
			location = {
				set_province_flag = keep_it
				add_province_modifier = { name = "keep_it" duration = -1 }
			}
		}
	}

	option = {
		name = 1000182044.opta
		ai_chance = { factor = 0 }
	}
}
This event works just fine the way it is. Similarly random vassal throws a false positive in this exact same set.

Code:

EDIT: I am getting the following error:

Code:
character_event = {
	id = TOG.1200
	desc =*OK
	picture = GFX_evt_crusaders
	border = GFX_event_normal_frame_war

	hide_window = yes # Only fires for unplayable landless characters

	only_ruler = no
	only_men = yes
	
	min_age = 16
	max_age = 50
	capable_only = yes
	prisoner = no
	

	trigger = {
		has_dlc = "The Old Gods"

However according to http://forum.paradoxplaza.com/forum/showthread.php?611797-Event-coding-efficiency that is a valid place to put it. Is my source mistaken, am I mistaken, or is this a false positive?

2nd issue: There is a validator setting to disable this warning
4th issue: As of some time ago, the correct term is "only_rulers". This may have changed at some point, can anyone confirm?

The rest should be fixed.
 
Is there a way to validate multiple mods at once?

Also, can anyone think of something that may allow a game to load and play fine, but for all the save games to crash, even on day one?

Not directly, most likely it will work to make a .mod file that lists the mods you want to validate as dependencies.
 
Version v1.5 RC7 has been released: https://www.dropbox.com/s/w9tdexicz0o7ls3/Audax.Validator v1.5 RC7.rar

If I did not reply to you, then you issue should be fixed, but of course report again if it doesn't seem to be.

Please keep reporting false positives with the Validator, I will try to update more often in the future (and it should be easier to do so as well).
 
In my mod I have a few files copied from vanilla in which I have only changed a few of the events/decisions.

If I added # Audax Validator "!" Ignore_ALL to the top of the file, is there any way I could "unignore" just the events/decisions I care about, or will I have to add # Audax Validator "." Ignore_ALL to every event/decision I don't?
 
In my mod I have a few files copied from vanilla in which I have only changed a few of the events/decisions.

If I added # Audax Validator "!" Ignore_ALL to the top of the file, is there any way I could "unignore" just the events/decisions I care about, or will I have to add # Audax Validator "." Ignore_ALL to every event/decision I don't?

Unfortunately, as of now there's no unignore feature, so you would need to add the ignore clause to each event you want to ignore.

If others have this sort of problem, please mention it and I can look into trying to make the system better.
 
4th issue: As of some time ago, the correct term is "only_rulers". This may have changed at some point, can anyone confirm?

It comes from an old thread that uses both only_ruler and only_rulers in different places.

character_event = {
only_ruler = yes
trigger = {
<other triggers>
}
}

Is Zarine's code example. But below that is a list of valid event potentials:

age = 16
is_prisoner = no
is_ruler = yes
max_age = 11
capable_only = yes
min_age = 16
only_capable = yes
only_men = yes
only_playable = yes
only_rulers = yes
only_women = yes
prisoner = no

-----

I'd like to make two feature requests for the Validator.

- A checkbox to disable "localisation" checks when doing a scan on the other categories. Depending on the state of the files in a specific category there can be hundreds of missing localisations and when I'm looking for a logic error it adds a lot of time sifting through to find the "real" problems.

- Is there any way to fix the PREVPREV issues? This:

--- Error 1 of 1 ---
At events\adventures_the_old_gods.txt [character_event\immediate\liege\capital_scope\random_independent_ruler\random_realm_province\ROOT\spawn_unit\match_character] (Line 971, column 9):
"PREVPREV" is not a valid ThisChar.
Additional information: There are more PREV clauses than parent scopes

Another Example:

--- Error 1 of 1 ---
At events\mongol_events.txt [narrative_event\immediate\901\kingdom\ROOT\war\target] (Line 1070, column 7):
"PREVPREV" is not a valid AnyTitle, ThisChar, or ThisTitle.
ThisChar: cannot be because PREVPREV points to ProvCommand.
However, a Char was expected.
ThisTitle: cannot be because PREVPREV points to ProvCommand.
However, a Title was expected.

It comes from vanilla and any time the event is a province type it spits out errors because the Validator isn't accounting for the scope changes the way the game does. I think. The PREVPREV / PREVPREVPREVPREV / THIS scopes in the vanilla events are working in game.
 
Some false positives I found in 1.5 RC7:
  1. "Invalid node "religion" in scope TitleCommand" when changing the religion of a title (eg mercenary band or holy order) in an event (such as vanilla event 670 in on_action_events.txt).
  2. "The event is set to be triggered only, but it is never called" for is_triggered_only events called from the gain_effect of a landed title (not used in vanilla, but I have verified it works in my mod).
  3. "Invalid node "pre_reformed" in scope ReligionDef" for pagan religions that are pre-reformed (such as vanilla hellenic_pagan)
Additionally the validator doesn't seem to merge multiple religion and landed title definitions and validate the result, but instead complains about finding a "Duplicate ID".
 
It comes from an old thread that uses both only_ruler and only_rulers in different places.

character_event = {
only_ruler = yes
trigger = {
<other triggers>
}
}

Is Zarine's code example. But below that is a list of valid event potentials:

age = 16
is_prisoner = no
is_ruler = yes
max_age = 11
capable_only = yes
min_age = 16
only_capable = yes
only_men = yes
only_playable = yes
only_rulers = yes
only_women = yes
prisoner = no

-----

I'd like to make two feature requests for the Validator.

- A checkbox to disable "localisation" checks when doing a scan on the other categories. Depending on the state of the files in a specific category there can be hundreds of missing localisations and when I'm looking for a logic error it adds a lot of time sifting through to find the "real" problems.

- Is there any way to fix the PREVPREV issues? This:

--- Error 1 of 1 ---
At events\adventures_the_old_gods.txt [character_event\immediate\liege\capital_scope\random_independent_ruler\random_realm_province\ROOT\spawn_unit\match_character] (Line 971, column 9):
"PREVPREV" is not a valid ThisChar.
Additional information: There are more PREV clauses than parent scopes

Another Example:

--- Error 1 of 1 ---
At events\mongol_events.txt [narrative_event\immediate\901\kingdom\ROOT\war\target] (Line 1070, column 7):
"PREVPREV" is not a valid AnyTitle, ThisChar, or ThisTitle.
ThisChar: cannot be because PREVPREV points to ProvCommand.
However, a Char was expected.
ThisTitle: cannot be because PREVPREV points to ProvCommand.
However, a Title was expected.

It comes from vanilla and any time the event is a province type it spits out errors because the Validator isn't accounting for the scope changes the way the game does. I think. The PREVPREV / PREVPREVPREVPREV / THIS scopes in the vanilla events are working in game.

1) This is actually possible, you just need to copy ValidatorSettings.txt and edit it to disable localization. Instructions are available in DidYouKnow.pdf.
2) Can you explain why the Validator is wrong and what the engine is actually doing? In that case these checks can be made to work correctly and everyone will be happy. Also if you happen to know if this stuff would work in Eu4 the same way.

I just tried out this useful tool. :)
A question: is it possible to ignore all the 'blahblah is not a valid LocalizationKey' messages? Unselection 'localization' under validation options doesn't do the trick.
Use ValidatorSettings.txt; this is described in DidYouKnow.pdf.

Could I get a copy of the source for this program? Specifically, the part that parses character files, so that I can adapt and use it for my Character Generator.
The Validator actually doesn't do anything fancy with parsing character files, so I don't think it'll be of much help for you. In any case the Validator is currently a mess of code that I'm abandoning for future games (to be replaced with something more sensible).
 
Last edited:
Version v1.5 RC10 has been released: https://www.dropbox.com/s/8wnn415ybt9fuhy/Audax.Validator v1.5 RC10.rar

If I did not reply to you, then you issue should be fixed, but of course report again if it doesn't seem to be.

Please keep reporting false positives with the Validator, and they will likely get fixed. If you are reporting a false positive, it is very useful to copy the error message into the post - you can just select the error message, then press Ctrl+C to copy it.
 
Using both versions you currently have up, getting nowhere. Not sure if a problem my end or the validators. All I'm getting is:

--- Error 1 of 1 ---
Parse Failure
Path: <mod>\common\landed_titles\landed_titles.txt
Error: Token "catholic" at line 4453, column 2 must be an equals sign.
Which looks like a false positive as the false parse in question is identical to all other occasions of the line in vanilla and the rest of the file, and:

Beginning validation...


ec) EXCEPTION CONTEXT






ERROR
System.NullReferenceException: Object reference not set to an instance of an object.
at Audax.Validator.Clausewitz.Ck2.TitleParserFactory.LoadDefaultConstraints(Context c)
at Audax.Validator.TypeCore.ConstraintPrevalidation.<>c__DisplayClass8.<OnPrevalidation>b__2(KeyValuePair`2 fac)
at System.Linq.Enumerable.<SelectManyIterator>d__31`3.MoveNext()
at Audax.Validator.TypeCore.ConstraintPrevalidation.OnPrevalidation(Context c, Scope scope)
at Audax.Validator.GameValidator.Validate(Action onEachValidatorCompleteAction)


Every single time, no matter what settings I pick. I had a quick look through the thread and found nothing recent that was identical. Most of my files were generated with the help of Jon Strykers map filler, if that helps. Thanks for reading.
 
Using both versions you currently have up, getting nowhere. Not sure if a problem my end or the validators. All I'm getting is:


Which looks like a false positive as the false parse in question is identical to all other occasions of the line in vanilla and the rest of the file, and:




Every single time, no matter what settings I pick. I had a quick look through the thread and found nothing recent that was identical. Most of my files were generated with the help of Jon Strykers map filler, if that helps. Thanks for reading.

I am fairly sure that you do have a problem in the landed_titles.txt file. There may be some issue near what is pointed out, and you can post the file so we can look at it. However the Validator shouldn't crash on it, so that part will be fixed.
 
Version v1.5 RC13 has been released: https://www.dropbox.com/s/lnijs5lqfnwscwu/Audax.Validator v1.5 RC13.rar

If I did not reply to you, then you issue should be fixed, but of course report again if it doesn't seem to be.

Please keep reporting false positives with the Validator, and they will likely get fixed. If you are reporting a false positive, it is very useful to copy the error message into the post - you can just select the error message, then press Ctrl+C to copy it.
 
Thank you for replying and helping. I ran the RC13 version of the validator and it is not crashing for me, now reading through the other errors.

https://www.dropbox.com/s/b07v0flxx0lk2lr/landed_titles.txt

T
his is my landed.txt file as you offered to look at it. The exact entry that it has a problem with is k_kal_sharok. My confusion is that a) as I said before, this is all autogenerated and identical to all other entries on the file, and b) from it's error message, it's trying to tell me to insert an = sign either before the entire line, which wouldn't link to anything at all, or b it's telling me to insert an = sign in a column that notepad++ doesn't use at all (since it uses 1, then 5).

So what it currently looks like is this:

catholic = 100 # Crusade target weight

and what it's telling me to do is this:

= catholic = 100 # Crusade target weight
 
Thank you for replying and helping. I ran the RC13 version of the validator and it is not crashing for me, now reading through the other errors.

https://www.dropbox.com/s/b07v0flxx0lk2lr/landed_titles.txt

T
his is my landed.txt file as you offered to look at it. The exact entry that it has a problem with is k_kal_sharok. My confusion is that a) as I said before, this is all autogenerated and identical to all other entries on the file, and b) from it's error message, it's trying to tell me to insert an = sign either before the entire line, which wouldn't link to anything at all, or b it's telling me to insert an = sign in a column that notepad++ doesn't use at all (since it uses 1, then 5).

So what it currently looks like is this:



and what it's telling me to do is this:

The line before it says " culture = kal sharok"; notice there is a space between kal and sharok. So the Validator thinks you're saying
culture = kal
sharok [=] catholic
hence the error message