• 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.
Showing developer posts only. Show all posts in this thread.
Thanks, though somehow I ended up at 367 errors now when I had 360 in the last version.

Edit: One false positive:
At <mod>\common\cb_types\Vanilla CBs.txt [claim\can_use\ROOT\OR\dynasty] (Line 66, Column 5):
"25061" is not a valid ThisChar or OpinionClauseDefinedTypes.
1.10 allowed checking for a dynasty ID directly.

At <mod>\common\landed_titles\landed_titles.txt [k_shiite] (Line 352, Column 1):
Invalid node "caliphate" in scope KingTitleDef (value is: yes)
I'm pretty sure you can have any title be a caliphate; or at least any title above county level.
 
Last edited:
Do you know if "yes" works for birth and death? They started showing up in the latest patch, I think, so it might work now, but I haven't tested.
They put in the changelog that the innermost date is now ignored, so I have to assume that "yes" is now entirely valid.
 
I am currently working on a new version of the Validator. It will not initially support either Ck2 or Eu4, but eventually it may do so. (Is Eu4 out yet? Do I need to make a validator for that?)

The current Validator will continue to be developed with bug fixes and stuff as necessary, and will probably be used for Eu4 since the new one won't be ready for a bit.

Why? Basically, in the current Validator, I often want to do something, but the architecture makes it really difficult to do. Changing it is immensely difficult and leads to misery. So it's easier to start over with a clean slate.

The new Validator will have a CLI that supports popular OSes, and likely a GUI that won't work on all popular OSes.

So, what are your top features of the Validator that you use, or that you'd want. I need to know what is most important to people and get those set up first. Examples include: a GUI, non-Windows support, Windows support, comment metadata, helpful error correction + suggestion, errors that go to the file directly, and whatever you want.
I think it is important to note that CKII is by far the most popular CKII game out (the CKII Wiki gets more traffic than my other 4 wikis combined), so it would be wise to ensure it works with it.

As to features:
A basic GUI is important (though I can personally handle a command line just fine, I'd prefer a GUI)
Windows support. The other OSes is not a priority to me, though I imagine people who use them would rather like that ;)
If most/all errors can go to the appropriate line in the for the relevant mod file that'd be great, yeah

Beyond that the most important thing to me is really just clear, understandable error messages. If I can't figure out what the Validator is actually reacting to it isn't particularly helpful. The current version handles this nicely though.
The automatic correction feature is not something I've ever used. I prefer fixing errors manually in nearly all cases.

Can't think of anything important beyond that.
 
I do not think PREVPREV = {...} is valid.

I'm pretty certain that FROM = {...} cannot reference the calling scope, because the event has to be called within a scope referencing the character who will receive it. Calling FROM seems to only scope to the character who received the calling event.
PREVPREV is a valid scope, as is PREVPREVPREV, and in some files even PREVPREVPREVPREV.
I have no idea if PREV = { PREV = { } } actually works.
 
You don't understand—I don't mean xxxx = PREVPREV (where I'd call PREVPREV a reference, but not a scope, since you're not executing commands within it but instead using it as a variable) but PREVPREV = {...} which as far as I can tell is not valid. It's certainly not used by Paradox in the current version of the vanilla game. If you've been able to use it successfully, I will take note of it....

As to PREV = { PREV = {...}} it definitely works (and in the somewhat convoluted way described above).
Seems you're right; did a quick test and PREVPREV = { } did not in fact work. Strange; I could've sworn I've used it in the past without any issues, but a quick search through my mod folder confirms that's not actually the case.
 
The Validator can't seem to handle a symbolic link going from the mod folder in My Documents to the mod folder in the game folder; it makes it think there's two copies of the dependency, and it therefore refuses to do anything beyond spitting out the error message:
--- Error 1 of 1 ---
Parse Failure
Path: <appdir>\C:\Crusader Kings II\mod\ProjectBalance.mod
Error: There were 2 instances of the mod with name "-ARKOpack Armoiries-". It was required as a dependency of "Project Balance". These include the following: "C:\Crusader Kings II\mod\ARKOpack_Armoiries.mod", "E:\Meneth\Documents\Paradox Interactive\Crusader Kings II\mod\ARKOpack_Armoiries.mod",

A bit problematic, as I use a symbolic link to actually have the mod folder where I want it without CKII throwing a fuss about it.
 
Now it gives an error message if a dependency isn't found.
A dependency doesn't actually mean the mod depends on the other mod. It simply means in the case of any conflicts, all conflicts will be resolved in the favor of the mod claiming the other as a dependency.

Edit: After I removed the dependency it simply crashed:
Code:
StatusLog > ERROR
StatusLog > System.Diagnostics.Contracts.__ContractsRuntime+ContractException: Precondition failed: text != null
StatusLog >    at System.Diagnostics.Contracts.__ContractsRuntime.TriggerFailure(ContractFailureKind kind, String msg, String userMessage, String conditionTxt, Exception inner)
StatusLog >    at System.Diagnostics.Contracts.__ContractsRuntime.ReportFailure(ContractFailureKind kind, String msg, String conditionTxt, Exception inner)
StatusLog >    at System.Diagnostics.Contracts.__ContractsRuntime.Requires(Boolean condition, String msg, String conditionTxt)
StatusLog >    at Audax.Validator.Log.InternalWrite(String text)
StatusLog >    at Audax.Validator.Log.LogLine(LogLevel level, String tag, String line)
StatusLog >    at Audax.Validator.Log.E(String tag, String line)
StatusLog >    at Audax.Validator.ValidationManager.Run(Dispatcher dispatcher)
ValidationManager: StatusLog > There were 2 instances of the mod with name "-ARKOpack Armoiries-". It was required as a dependency of "Project Balance". These include the following: "C:\Crusader Kings II\mod\ARKOpack_Armoiries.mod", "E:\[user_name <******>]\Documents\Paradox Interactive\Crusader Kings II\mod\ARKOpack_Armoiries.mod", 
StatusLog > The Validator will arbitrarily choose one of them, but you should really look into this, unless you are doing something funny like using symbolic links.
ValidationManager: There were 2 instances of the mod with name "-ARKOpack Armoiries-". It was required as a dependency of "Project Balance". These include the following: "C:\Crusader Kings II\mod\ARKOpack_Armoiries.mod", "E:\[user_name <******>]\Documents\Paradox Interactive\Crusader Kings II\mod\ARKOpack_Armoiries.mod", 
The Validator will arbitrarily choose one of them, but you should really look into this, unless you are doing something funny like using symbolic links.
ValidationManager: 
App: A FATAL ERROR HAS OCCURRED
Time: 10.01.2014 12:10:12
Validator Version: 1.5 RC20 [1.5.19.0]
System.Diagnostics.Contracts.__ContractsRuntime+ContractException: Precondition failed: text != null
   at System.Diagnostics.Contracts.__ContractsRuntime.TriggerFailure(ContractFailureKind kind, String msg, String userMessage, String conditionTxt, Exception inner)
   at System.Diagnostics.Contracts.__ContractsRuntime.ReportFailure(ContractFailureKind kind, String msg, String conditionTxt, Exception inner)
   at System.Diagnostics.Contracts.__ContractsRuntime.Requires(Boolean condition, String msg, String conditionTxt)
   at Audax.Validator.Log.InternalWrite(String text)
   at Audax.Validator.Log.LogLine(LogLevel level, String tag, String line)
   at Audax.Validator.Log.E(String tag, String line)
   at Audax.Validator.ValidationManager.Run(Dispatcher dispatcher)
   at Audax.Validator.MainWindow.ValidateClick(Object sender, RoutedEventArgs e)
   at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
   at System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args)
   at System.Windows.Controls.Button.OnClick()
   at System.Windows.Controls.Primitives.ButtonBase.OnMouseLeftButtonUp(MouseButtonEventArgs e)
   at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
   at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
   at System.Windows.UIElement.ReRaiseEventAs(DependencyObject sender, RoutedEventArgs args, RoutedEvent newEvent)
   at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
   at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
   at System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args)
   at System.Windows.UIElement.RaiseTrustedEvent(RoutedEventArgs args)
   at System.Windows.Input.InputManager.ProcessStagingArea()
   at System.Windows.Input.InputProviderSite.ReportInput(InputReport inputReport)
   at System.Windows.Interop.HwndMouseInputProvider.ReportInput(IntPtr hwnd, InputMode mode, Int32 timestamp, RawMouseActions actions, Int32 x, Int32 y, Int32 wheel)
   at System.Windows.Interop.HwndMouseInputProvider.FilterMessage(IntPtr hwnd, WindowMessage msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
   at System.Windows.Interop.HwndSource.InputFilterMessage(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
   at MS.Win32.HwndWrapper.WndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
   at MS.Win32.HwndSubclass.DispatcherCallbackOperation(Object o)
   at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
   at MS.Internal.Threading.ExceptionFilterHelper.TryCatchWhen(Object source, Delegate method, Object args, Int32 numArgs, Delegate catchHandler)
 
I believe that in cases where empty files are skipped, it should already be that when the only contents of the file are comments, the file will be skipped. Tell me if that doesn't seem to work.
It does not seem to work no, as it is giving me errors for those files with just "#override" in them.
 
Can you give an example of such a file? I assume it has to do with province history but am not sure. And being empty does work fine?
Sure.
PB changes the map a bit, and after that happened, vanilla added more provinces.
As such, PB has to override to those province history files, as they're tied to a province number rather than a title ID.
As an example, PB overrides province #911 - Timbuktu. All that's in that file is "#Override".
This makes sure that the title ID in there does not get tied to the province ID.

That gives errors like this in the Validator:
--- Error 1 of 5 ---
Duplicate IDs in file names: <mod>\history\provinces\911 - Namur.txt and <mod>\history\provinces\911 - Timbuktu.txt
--- Error 2 of 5 ---
At <mod>\history\provinces\911 - Timbuktu.txt [] (Line 0, column 0):
The required "title" entry was not found.
--- Error 3 of 5 ---
At <mod>\history\provinces\911 - Timbuktu.txt [] (Line 0, column 0):
The required "culture" entry was not found.
--- Error 4 of 5 ---
At <mod>\history\provinces\911 - Timbuktu.txt [] (Line 0, column 0):
The required "religion" entry was not found.
--- Error 5 of 5 ---
At <mod>\history\provinces\911 - Timbuktu.txt [] (Line 0, column 0):
The required "max_settlements" entry was not found.
 
Okay, in ValidatorSettings.txt did you turn on AddFlag = ProvinceHistory.NoWarnOnEmptyFile?
Working now.
That file must've been deleted when I switched from the GamersGate version to Steam version of CKII.
 
Code:
character_event = {
	id = TOG.1061
	desc =*EVTDESC_TOG_1061
	picture = GFX_evt_heretic
	border = GFX_event_normal_frame_war
	
	is_triggered_only = yes
	
	option = {
		name = EVTOPTA_TOG_1060
		trigger = {
			owner = { religion_group = FROM }
		}
	}
	option = {
		name = EVTOPTB_TOG_1060
		trigger = {
			owner = { NOT = { religion_group = FROM	} }
		}
	}
}

This is from Vanilla - i know it does look totally odd but it DOES work (just tested) - i dont know why it does work but it does. (owner in character scope trigger)

It's incorrect, but yes it does work (it shouldn't if coded properly...). So no, ignore that it does work and have the Validator report this as an error.
 
This will sound like a big ask but one thing I would love to see is a validator option of checking that every title in landed_titles folder that is count and above has an entry in gfx/flags, this would make it easier to find out which flags is missing as one missing screws up the rest.
 
Last time I checked it already did that.
Really? It wouldn't do it when I did my little mod and I had like 100 extra titular titles with some flags etc. and like 3 were missing and it buggered up all of them and I didn't know which one it was :(
 
They said earlier that NOT would still work as it did previously -- but if you're using the new debug mode, it's going to throw up errors when used with multiple operands.

Personally, if the validator could provide the option of showing an error when NOT is used instead of NOR with multiple operands, it'd be appreciated. I'd like to weed those out, as I intend to use the debug mode quite a bit.
How do you enable debug mode?
 
Anyone else find this useful? I'm inclined to leave it out but if enough people want it I can add it.
I would like it as well, I have had numerous border bugs before like that simply because I say copy and pasted the wrong border name and had no idea what was going on, especially when making some province and character events etc where I only change the event type and not the content I always forget the border
 
GetSonDaughter
--- Error 1 of 1 ---
At <mod>\localisation\mymod_v1.csv [Entry\1] (Line 3, column 22):
Localization error: Invalid bracket command: "GetSonDaughterCap" in "GetSonDaughterCap" in "[GetSonDaughterCap] of [From.GetFirstName]"

False positive with v1.11.19. GetSonDaughterCap is working fine and was added to CK2 in v2.4.
You need to use a scope in your localisation entry, just [GetSonDaughterCap] doesn't work it needs to be [From.GetSonDaughterCap] or another scope I am pretty sure
 
  • 1
Reactions: