Imperator Development Diary - 15th of April

  • 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.
Ahhh hmmm I am not sure if that would be possible. I'd rather not go down the @THIS whatever route because its rather obtuse in what it actually is and working with in CK2 was not all that fun either lol, I'll look at trying a solution, I am sure there is some work around already with combining lists and variables and other magic but a cleaner one would be good.

Right, I think there may be workarounds. It was just an idea for the future. I doubt we'll need it anytime soon. We have a long way towards learning the game and mastering the new modding capabilities.

But thank you for all the new stuff :)
 
just wanted to ask about it:
are pie charts moddable (i.e. you can show values in them)?
asking about it because they are hardcoded in Hearts Of Iron IV and they have way more potential in modding in Imperator.
 
Saddly, I propably won't ever reach the enddate, cause, I never do, but would it be much work to add an option to keep playing? I can't speak for anyone else, but I like to keep playing after the game has oficially ended, even if it is just for the lulz.


You never play until the end date but you like to keep playing after the game jas officially ended? How does that work?
 
You never play until the end date but you like to keep playing after the game jas officially ended? How does that work?
Ok, let me rephrase that: I never reach the end date in Paradox games, because the endgame lag got too worse, or because I already conquered the world before that date, or what ever. In other sandbox games, Civilisation for example, I do reach the end date, and I do like to keep playing until I painted the map red, with the blood of my enemies... or with nuclear fallout, if Ghandi is still around (who doesn't like a little nuclear war now and then :D).
Besides, I can't imagine that I am the only one who would appreciate that option.
 
Ok, let me rephrase that: I never reach the end date in Paradox games, because the endgame lag got too worse, or because I already conquered the world before that date, or what ever. In other sandbox games, Civilisation for example, I do reach the end date, and I do like to keep playing until I painted the map red, with the blood of my enemies... or with nuclear fallout, if Ghandi is still around (who doesn't like a little nuclear war now and then :D).
Besides, I can't imagine that I am the only one who would appreciate that option.

Well, as said, since the end-date is moddable I would imagine that there would be one up on the workshop within hours or days of release
 
Let me know if you've got any questions about the script math system.

Feel free to poke me about anything as well! :D
Not sure who to ask about this, so my apologies if I should've tagged someone else. Anyway, my question is: Is it possible to use existing in-game proportions as triggers? Specifically, I'm considering making a mod that provides a benefit/incentive for not going full monoculture, and for that I need some way to "see" how multicultural a city, province, or country actually is. There's those really nice looking pie charts in game for that info, so I'm wondering if it is possible to pull the info that feeds into those charts, and if an area is multicultural enough (maybe requiring non-slave minority culture pops to make up a third of the total pops in the area?), give the citizen pops in that area a boost to their research rate output or something.
 
You got an example of targeted variables? In HoI a variable is a lot more limited in what it can contain, in Jomini a variable can be anything at all so not sure if that would cover your use case already.

The data system is the overarching grander system of everything in the gui and localization. The scripted gui is a specific subset of functions in the gui which link into the script system.
For modding needs the terms are relatively unimportant but for us there is a distinction.


Yep I've been talking a bit with him, the ability to do GetName etc is gonna be in but not for the first release, I had to work around some stuff to make it happen nicely same for displaying lists.
Arrays already exist in the script albeit called lists to keep them more in line with the script list terminology, I've got a prototype for them being shown in the gui which again will not be in for release but should be in "soon"

Is it possible to use GetName on saved scopes though? I think saved scopes are what used to be called event targets? Also are saved scopes local or global? If a character is saved as cool_person, is it saved within the scope of that country or is it global (as in there can be only one cool_person in the world or each country can have its own cool_person?)

Lastly, if someone wanted to mod the economy screen, would they use scripted GUIs or Data System?
 
Not sure who to ask about this, so my apologies if I should've tagged someone else. Anyway, my question is: Is it possible to use existing in-game proportions as triggers? Specifically, I'm considering making a mod that provides a benefit/incentive for not going full monoculture, and for that I need some way to "see" how multicultural a city, province, or country actually is. There's those really nice looking pie charts in game for that info, so I'm wondering if it is possible to pull the info that feeds into those charts, and if an area is multicultural enough (maybe requiring non-slave minority culture pops to make up a third of the total pops in the area?), give the citizen pops in that area a boost to their research rate output or something.
You can iterate over pops somewhere and count how many meet a set condition to count them.

Is it possible to use GetName on saved scopes though? I think saved scopes are what used to be called event targets? Also are saved scopes local or global? If a character is saved as cool_person, is it saved within the scope of that country or is it global (as in there can be only one cool_person in the world or each country can have its own cool_person?)

Lastly, if someone wanted to mod the economy screen, would they use scripted GUIs or Data System?
Yes you can, you would something like [SCOPE.sC( 'cool_person' ).GetName].

They are locally saved in the top scope and are removed once the top scope ends. If you want to save something on a country or globally use variables.

The scripted guis is just a subset of the data system, the data system is the overarching system for the gui and the localization. The scripted gui is just a specific subset that handles linking the gui to script effects and triggers.
 
You can iterate over pops somewhere and count how many meet a set condition to count them.


Yes you can, you would something like [SCOPE.sC( 'cool_person' ).GetName].

They are locally saved in the top scope and are removed once the top scope ends. If you want to save something on a country or globally use variables.

The scripted guis is just a subset of the data system, the data system is the overarching system for the gui and the localization. The scripted gui is just a specific subset that handles linking the gui to script effects and triggers.

Great!

I think I got it, if I understood correctly, as far as modding is concerned, the Data System that uses C++ stuff is used for modding only the look/design of the UI, whereas Scripted GUIs are used if new buttons need to be added with their own effects, correct?
 
Great!

I think I got it, if I understood correctly, as far as modding is concerned, the Data System that uses C++ stuff is used for modding only the look/design of the UI, whereas Scripted GUIs are used if new buttons need to be added with their own effects, correct?
Sort of, the data system has things that can run specific code effects or evaluate code conditions. The scripted gui is only if you want to run something via the script system.
 
You can iterate over pops somewhere and count how many meet a set condition to count them.
Is there a way to limit that check to an area when a pop is added or removed from that area, and at game start? I can't help but worry that if I let it try to check constantly, there would be really bad lag. (As an aside, how does culture converting pops work, exactly? Does the game remove the pop being converted then add a pop with the change made back to the location the original pop was, or does the game actually alter the pop?)

Anyway, I believe what I'll want to do is do two iterations, one to add up the number of non-slave pops in a city, and the other to add up the number of pops that are not slaves and are not the country's primary culture, assigning both of these values their own variables. Then I'll need to divide the latter variable by the former, check if that value is greater than or equal to 0.34, then apply the modifier if it is.

Does that sound about right? Or is there some easier way of doing this that I'm missing?
 
Code:
every_character = {
   limit = {
        has_variable = is_modder
    }
    add_excitement = 9001
}

Side question: how moddable are mapmodes? Is it possible to add new mapmodes or modify existing ones?
 
Side question: how moddable are mapmodes? Is it possible to add new mapmodes or modify existing ones?

The basic rules for coloring the map are in code due to performance reasons. But which colors are used in the different coloring modes can be set through defines, and new map modes can be created (or existing ones changed) with new combinations of coloring mode, map icons, names on map, and a bunch of zoom level and shading parameters.
 
Is there a way to limit that check to an area when a pop is added or removed from that area, and at game start? I can't help but worry that if I let it try to check constantly, there would be really bad lag. (As an aside, how does culture converting pops work, exactly? Does the game remove the pop being converted then add a pop with the change made back to the location the original pop was, or does the game actually alter the pop?)

Anyway, I believe what I'll want to do is do two iterations, one to add up the number of non-slave pops in a city, and the other to add up the number of pops that are not slaves and are not the country's primary culture, assigning both of these values their own variables. Then I'll need to divide the latter variable by the former, check if that value is greater than or equal to 0.34, then apply the modifier if it is.

Does that sound about right? Or is there some easier way of doing this that I'm missing?
No there is no hook in like an on action for when pops are removed, would be way too frequent. Checking pop percentages every day will give you bad performance yes.
Pretty sure it just changes the culture of the pop, does not make a new one and kill the old one.

That check would not need two iterations, you can just iterate over all pops once and do an if check inside, would likely be better performance as you are not building the list twice just once.
I am not sure if there is some smart game level trigger to check this stuff already, there might be.
 
Not sure if this has been asked elsewhere:

Since the game is now been opened up to the streamers I wonder if Paradox would consider letting some of the established modders who A) have established definite intentions to make mods for Imperator:Rome and B) have pre-purchased the game, get access to start working a little early? Thought I might as well ask as the worst case is you say no and I wait to start working until the 25th (which is what I'm doing now anyway).