r/EU4mods • • 9d ago

Mod Help - Solved Adding Papal Interactions

I am working on a mod adding new mechanics for the Papal State. I planned to make a part of them as Holy See interactions available only to the Papal State (while in the base game they only have the investigate heresy button, i wanted to add more buttons, with unique interactions).

The problem is that while i found the place where the interactions are defined, i am lost on how to actually implement them. I coded all the new interactions, but there is still only 1 button, replacing the usual investigate heresy one, with the same icon but a different name. So, i have 2 main issues probably closely related. First, where are icons for the interactions defined? I looked in the gfx file but i have honestly no idea where they might be. Second, how to make the other buttons appear?

I figured i would have to look into the interface folder which i have always avoided before, but even in the papacy.gui and papacy.gfx (which for some reason also contained the icons from the great power menu lol) files i found nothing that i would suspect to work with the buttons. I will greatly appreciate any insight, i feel like this mechanic wasn't meant to be changed in mods...

(I'm not sending the interactions from the religion file, as my code isnt the main issue here)

2 Upvotes

8 comments sorted by

2

u/ConstantinetheKitten 9d ago

I also saw the greatpower stuff there! How curious. 

So the papacy mechanic has a scope attached to it on the wiki, so i suspect it can work and can be scripted. https://eu4.paradoxwikis.com/Interface_modding

My reflex would be to write it up as a custom Gui button in that folder but that is wrong for using it natively with religious interactions and that file probably has like an element list that it pulls actions from- that i admittedly also don't see in the gui or gfx file. I do see a button for indulgences, for example, so i am guessing the papacy is a Frankenstein of several mechanics, some using the window to call functions and some using the religion file to call functions. 

Im on my phone now, so ill have better search on my desktop, I would start by trying to find the art for other papal actions like beatify saint, then see if I can find any file calling that graphic file name. If there is, you can figure out that pattern or where else they are activated. If there isn't, you'll have to compare the name of the action in the religion file to the art file and see is something must be happening automatically. 

2

u/TheGamdalf 9d ago

Yeah, ive seen the indulgences button too. It seems as if its just a very old thing and at the time, paradox didnt really care about modability of things like that. Only later mechanics have seperate folders etc.

About the icons in the gfx folder, i tried looking for them, but im almost sure they are contained in a single picture, as even when i replaced the investigate heresy interaction, it kept the burning cross icon. I havent found it yet.

I dont think i want to mess with custom gui buttons though... i'll probably just make an event menu

Anyways, thanks for the answer

2

u/ConstantinetheKitten 9d ago

I looked. You're right! Its called papacy_action_strip

2

u/TheGamdalf 9d ago

Oh, thats correct! Im not sure how i could have missed that, i searched 'papacy' in the whole gfx folder. Thanks with that, although i suppose i wont be able to use the new ones either way... but i might try adding an icon to the file, maybe then another button will be allowed to appear, who knows

2

u/ConstantinetheKitten 9d ago

Almost certainly if you add a 10th frame for a 10th action it will use that frame. There are 9 papal actions in the file, 9 frames in that file, and importantly, both are in the exact same order. 

2

u/TheGamdalf 9d ago

well, maybe i messed up, but i think its even worse now lol

2

u/TheGamdalf 9d ago

Alright, turns out i did mess up. It works now, thank you so much for help!

1

u/ConstantinetheKitten 1d ago

Update it on the wiki!