• 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.

Sleight of Hand

retired modder
On Probation
14 Badges
Feb 14, 2012
12.114
5.868
  • Crusader Kings II
  • Darkest Hour
  • Europa Universalis IV: Call to arms event
  • For The Glory
  • Hearts of Iron III
  • March of the Eagles
  • Europa Universalis IV
  • Victoria 2
  • 500k Club
  • Crusader Kings II: Holy Knight (pre-order)
  • Europa Universalis IV: Pre-order
  • Hearts of Iron IV Sign-up
  • Stellaris Sign-up
  • Steel Division: Normand 44 Sign-up
Code:
		allow = {
				AND = {
					has_law = centralization_3
						NOT = {
							any_vassal = {
									OR = {
									primary_title = { tier = king }
									primary_title = { tier = duke }
									primary_title = { tier = count }
									primary_title = { tier = baron }
								}
							NOT = { opinion = { who = ROOT value = 25 }}
							prisoner = no
						}
					}
					holder_scope = {
						AND = {
							NOT = { trait = content }
							NOT = { trait = slothful }
							trait = ambitious
							prisoner = no
						}
					}
				}
			}

According to Notepad++ the brackets are okay but when I load up the William the Conqueror scenario it still says he can institute high crown authority even though many of his vassals hate him.

What I'm after with this trigger is all vassals (barons, counts, dukes and kings -- so it can apply to anyone) having a minimum of +25 opinion of you and not be in prison. As well as this you can't have the content or slothful traits but must have the ambitious trait and also not be a prisoner.

Thanks!
 

rafek

First Lieutenant
37 Badges
Oct 21, 2011
295
4
  • Stellaris: Nemesis
  • Stellaris: Distant Stars
  • A Game of Dwarves
  • Stellaris: Galaxy Edition
  • Stellaris: Digital Anniversary Edition
  • Stellaris: Leviathans Story Pack
  • Stellaris - Path to Destruction bundle
  • Stellaris: Synthetic Dawn
  • Stellaris: Humanoids Species Pack
  • Stellaris: Apocalypse
  • Stellaris: Galaxy Edition
  • Stellaris: Megacorp
  • Stellaris: Ancient Relics
  • Stellaris: Lithoids
  • Stellaris: Federations
  • Crusader Kings III
  • Crusader Kings III: Royal Edition
  • Stellaris: Necroids
  • Stellaris: Galaxy Edition
  • Europa Universalis IV
  • Heir to the Throne
  • Europa Universalis IV: Call to arms event
  • Divine Wind
  • Europa Universalis III: Chronicles
  • Europa Universalis III
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: The Old Gods
  • Warlock: Master of the Arcane
  • 500k Club
  • Crusader Kings II: Holy Knight (pre-order)
  • Europa Universalis IV: Pre-order
  • Stellaris
  • Age of Wonders III
  • Cities: Skylines - Parklife
  • Cities: Skylines
Hello,

If you would like the condition to require 25 and up, delete the NOT = { statement from the opinion = { who = ROOT value = 25 }. If you keep NOT there it will look for the 25 and below, which means that it will agree for negative one as well i.e. -15 etc.

Here is how it should look like:

Code:
	allow = {
				AND = {
					has_law = centralization_3
						NOT = {
							any_vassal = {
									OR = {
									primary_title = { tier = king }
									primary_title = { tier = duke }
									primary_title = { tier = count }
									primary_title = { tier = baron }
								}
							[COLOR="#FFFF00"]opinion = { who = ROOT value = 25 }[/COLOR]
							prisoner = no
						}
					}
					holder_scope = {
						AND = {
							NOT = { trait = content }
							NOT = { trait = slothful }
							trait = ambitious
							prisoner = no
						}
					}
				}
			}
 

Sleight of Hand

retired modder
On Probation
14 Badges
Feb 14, 2012
12.114
5.868
  • Crusader Kings II
  • Darkest Hour
  • Europa Universalis IV: Call to arms event
  • For The Glory
  • Hearts of Iron III
  • March of the Eagles
  • Europa Universalis IV
  • Victoria 2
  • 500k Club
  • Crusader Kings II: Holy Knight (pre-order)
  • Europa Universalis IV: Pre-order
  • Hearts of Iron IV Sign-up
  • Stellaris Sign-up
  • Steel Division: Normand 44 Sign-up
Thanks, I've tried editing my file accordingly but it still says William can implement high crown authority even though he has plenty of vassals with negative opinions of him.

Do you think you could take a look at my file and see what I've done wrong? I'd really appreciate that.

http://www.filefactory.com/file/nu48hiplq2h/n/crown_laws_txt
 

rafek

First Lieutenant
37 Badges
Oct 21, 2011
295
4
  • Stellaris: Nemesis
  • Stellaris: Distant Stars
  • A Game of Dwarves
  • Stellaris: Galaxy Edition
  • Stellaris: Digital Anniversary Edition
  • Stellaris: Leviathans Story Pack
  • Stellaris - Path to Destruction bundle
  • Stellaris: Synthetic Dawn
  • Stellaris: Humanoids Species Pack
  • Stellaris: Apocalypse
  • Stellaris: Galaxy Edition
  • Stellaris: Megacorp
  • Stellaris: Ancient Relics
  • Stellaris: Lithoids
  • Stellaris: Federations
  • Crusader Kings III
  • Crusader Kings III: Royal Edition
  • Stellaris: Necroids
  • Stellaris: Galaxy Edition
  • Europa Universalis IV
  • Heir to the Throne
  • Europa Universalis IV: Call to arms event
  • Divine Wind
  • Europa Universalis III: Chronicles
  • Europa Universalis III
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: The Old Gods
  • Warlock: Master of the Arcane
  • 500k Club
  • Crusader Kings II: Holy Knight (pre-order)
  • Europa Universalis IV: Pre-order
  • Stellaris
  • Age of Wonders III
  • Cities: Skylines - Parklife
  • Cities: Skylines
Hello again,

You had one too many NOT = {} added before any_vassal.

I checked with this code and it works as intended by you:

Code:
		potential = {
			NOT = { has_law = centralization_3 }
		}
		allow = {
				AND = {
					has_law = centralization_2
							any_vassal = {
									OR = {
									primary_title = { tier = king }
									primary_title = { tier = duke }
									primary_title = { tier = count }
									primary_title = { tier = baron }
								}
							opinion = { who = ROOT value = 10 }
						}
					
					holder_scope = {
						AND = {
							NOT = { trait = content }
							NOT = { trait = slothful }
							trait = ambitious
							prisoner = no
						}
					}
				}
			}

it will ensure here that ALL of the specified vassals have opinion of 10 or more, so NOT is not needed ;)

Here is the screenie, showing now HIGH as greyed out:
urINU.jpg
 
Last edited:

Sleight of Hand

retired modder
On Probation
14 Badges
Feb 14, 2012
12.114
5.868
  • Crusader Kings II
  • Darkest Hour
  • Europa Universalis IV: Call to arms event
  • For The Glory
  • Hearts of Iron III
  • March of the Eagles
  • Europa Universalis IV
  • Victoria 2
  • 500k Club
  • Crusader Kings II: Holy Knight (pre-order)
  • Europa Universalis IV: Pre-order
  • Hearts of Iron IV Sign-up
  • Stellaris Sign-up
  • Steel Division: Normand 44 Sign-up
Hey thanks! Did you check the other sections too? I mean for low, medium, high and absolute? I had them slightly different because the first two are NOT being minus relations (>-25 and >-10) and the second two ARE being positive relations (>+10 and +25).
 

rafek

First Lieutenant
37 Badges
Oct 21, 2011
295
4
  • Stellaris: Nemesis
  • Stellaris: Distant Stars
  • A Game of Dwarves
  • Stellaris: Galaxy Edition
  • Stellaris: Digital Anniversary Edition
  • Stellaris: Leviathans Story Pack
  • Stellaris - Path to Destruction bundle
  • Stellaris: Synthetic Dawn
  • Stellaris: Humanoids Species Pack
  • Stellaris: Apocalypse
  • Stellaris: Galaxy Edition
  • Stellaris: Megacorp
  • Stellaris: Ancient Relics
  • Stellaris: Lithoids
  • Stellaris: Federations
  • Crusader Kings III
  • Crusader Kings III: Royal Edition
  • Stellaris: Necroids
  • Stellaris: Galaxy Edition
  • Europa Universalis IV
  • Heir to the Throne
  • Europa Universalis IV: Call to arms event
  • Divine Wind
  • Europa Universalis III: Chronicles
  • Europa Universalis III
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: The Old Gods
  • Warlock: Master of the Arcane
  • 500k Club
  • Crusader Kings II: Holy Knight (pre-order)
  • Europa Universalis IV: Pre-order
  • Stellaris
  • Age of Wonders III
  • Cities: Skylines - Parklife
  • Cities: Skylines
Hey,

Nope, I haven't only checked the one you were referring to.

With all the cases of opinion, just follow the rule: number and below, use NOT = { opinion = { who = ROOT value = 10 } will ensure that the opinion is 10 or below, while deleting the NOT = {} will ensure that opinion is 10 or above.

If you have any problems just let me know.
 

Sleight of Hand

retired modder
On Probation
14 Badges
Feb 14, 2012
12.114
5.868
  • Crusader Kings II
  • Darkest Hour
  • Europa Universalis IV: Call to arms event
  • For The Glory
  • Hearts of Iron III
  • March of the Eagles
  • Europa Universalis IV
  • Victoria 2
  • 500k Club
  • Crusader Kings II: Holy Knight (pre-order)
  • Europa Universalis IV: Pre-order
  • Hearts of Iron IV Sign-up
  • Stellaris Sign-up
  • Steel Division: Normand 44 Sign-up
I appreciate your help but I simply can't get it to do what I want it to. I tested it by changing the required relations to +25 and loaded up in 1066 as Harold Godwinesson -- I then typed 'cash' and threw gold, titles and guardianships around to get all my direct vassals up to +25 or more and it still has a red cross by it.

I really don't have the patience for this sort of thing so I'm just going to give up. It's very frustrating because it's far too easy to raise crown authority in vanilla but I can't seem to find a working alternative. I suppose at the very least I could just add the 'ambitious' trait as a requirement.

Thanks again.
 

rafek

First Lieutenant
37 Badges
Oct 21, 2011
295
4
  • Stellaris: Nemesis
  • Stellaris: Distant Stars
  • A Game of Dwarves
  • Stellaris: Galaxy Edition
  • Stellaris: Digital Anniversary Edition
  • Stellaris: Leviathans Story Pack
  • Stellaris - Path to Destruction bundle
  • Stellaris: Synthetic Dawn
  • Stellaris: Humanoids Species Pack
  • Stellaris: Apocalypse
  • Stellaris: Galaxy Edition
  • Stellaris: Megacorp
  • Stellaris: Ancient Relics
  • Stellaris: Lithoids
  • Stellaris: Federations
  • Crusader Kings III
  • Crusader Kings III: Royal Edition
  • Stellaris: Necroids
  • Stellaris: Galaxy Edition
  • Europa Universalis IV
  • Heir to the Throne
  • Europa Universalis IV: Call to arms event
  • Divine Wind
  • Europa Universalis III: Chronicles
  • Europa Universalis III
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: The Old Gods
  • Warlock: Master of the Arcane
  • 500k Club
  • Crusader Kings II: Holy Knight (pre-order)
  • Europa Universalis IV: Pre-order
  • Stellaris
  • Age of Wonders III
  • Cities: Skylines - Parklife
  • Cities: Skylines
Hello again,

I have went through the file and you had NOT = {} statement one too much before any_vassal again, making effecting prisoner = no as prisoner = yes. I have edited and tested it and now it works as the reputation/opinion conditions are met.

Attaching the file below.

Just be aware that now, your conditions will actually accept even one vassal who has opinion of at least X and is not a prisoner.

If you would like to make the conditions stricter and force all to meet the opinion requirement, let me know and I will add it to your file. The in-game tooltip shows it in a weird way but it works, as I used it for my mod.
 

Attachments

  • crown_laws.txt
    9,4 KB · Views: 4
Last edited:

Sleight of Hand

retired modder
On Probation
14 Badges
Feb 14, 2012
12.114
5.868
  • Crusader Kings II
  • Darkest Hour
  • Europa Universalis IV: Call to arms event
  • For The Glory
  • Hearts of Iron III
  • March of the Eagles
  • Europa Universalis IV
  • Victoria 2
  • 500k Club
  • Crusader Kings II: Holy Knight (pre-order)
  • Europa Universalis IV: Pre-order
  • Hearts of Iron IV Sign-up
  • Stellaris Sign-up
  • Steel Division: Normand 44 Sign-up
I do want all vassals to meet the requirement (a certain relations level) but I didn't know you could. I looked thru the vanilla files and I only saw any_vassal.

If you could fix it up for all your direct vassals (barons, counts, dukes and/or kings) then that would be really amazing. :)

No rush -- whenever you have time. It is much appreciated.
 

rafek

First Lieutenant
37 Badges
Oct 21, 2011
295
4
  • Stellaris: Nemesis
  • Stellaris: Distant Stars
  • A Game of Dwarves
  • Stellaris: Galaxy Edition
  • Stellaris: Digital Anniversary Edition
  • Stellaris: Leviathans Story Pack
  • Stellaris - Path to Destruction bundle
  • Stellaris: Synthetic Dawn
  • Stellaris: Humanoids Species Pack
  • Stellaris: Apocalypse
  • Stellaris: Galaxy Edition
  • Stellaris: Megacorp
  • Stellaris: Ancient Relics
  • Stellaris: Lithoids
  • Stellaris: Federations
  • Crusader Kings III
  • Crusader Kings III: Royal Edition
  • Stellaris: Necroids
  • Stellaris: Galaxy Edition
  • Europa Universalis IV
  • Heir to the Throne
  • Europa Universalis IV: Call to arms event
  • Divine Wind
  • Europa Universalis III: Chronicles
  • Europa Universalis III
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: The Old Gods
  • Warlock: Master of the Arcane
  • 500k Club
  • Crusader Kings II: Holy Knight (pre-order)
  • Europa Universalis IV: Pre-order
  • Stellaris
  • Age of Wonders III
  • Cities: Skylines - Parklife
  • Cities: Skylines
No problem I will do it now. They way you achieve it, is simply by adding the condition, stating: there is no vassal that has opinion lower than X. The game shows it in a weird way in tooltip so do not suggest yourself with that and just test it in practice. Will attach you the file later on or post to your mailbox.
 
Last edited: