#modding
1 messages · Page 80 of 1
Any mods simular to magna europa?
why doesnt my country have a flag and a leader? i have all of the files in the mod folder
did you add an interface file for the portrait?
and can you show the character file code?
and is the flag in a .tga format?
Autumn Begonnia and North America Divided are the closest for asia and north america
yea
did you save it in 32 bit?
how
how is that
the portrait is a .dds file
SpriteTypes = {
spriteType = {
name = "GFX_portrait_oun_andriy_melnyk"
texturefile = "gfx/leaders/OUN/portrait_oun_andriy_melnyk.dds"
}
}```
Needs to be put in a file in the interface folder
then you'd use that name as the picture
like, make an interface forlder in the mod file, and paste the code?
You'd be better off creating him as a character instead of using the create_country_leader effect, though
yes
in the interface folder
look at the vanilla code you can copy off that as well
is the interface folder supposed to go into gfx folder
no, just the interface folder in the root mod directory
like this?
does this need to have the name of the portrait or waht
Like i did it
it has to have GFX_ in front
i think?
ok, so i just added .dds at the end, and the portrait is in the game
but the flag isnt
yep that works too ig
did you save it as 32 bit?
@supple sable
what program are you using for flags
paint net
how
chill mate
@austere pivot
you good?
@oblique garnet
mods, i guess this guy is really asking for it now 💀
lmaoo
could you upload the flag file you used
do i have to compress it
No
?
No
Nice
thanks for help FBKong 👍
No worries
I would recommend using the character system in the future, but it's up to you
is there an easier way to make a focus tree
Do not use edge modding
what is that
Use notepad++, or visual studio code with the hoi4 plugin
but you'll still have to do most of it by hand
Like, the program is just for placing and naming the focus, then to edit it in notepad++
I would recommend just doing by hand since you can mostly just copy-paste a focus template
(which is at the start of most vanilla focus trees)
{
limit = { has_dlc = "Man the Guns" }
add_tech_bonus =
{
name = DDR_schon_heute
bonus = 1
uses = 3
category = ship_modules_tech
}
}
else =
{
add_tech_bonus =
{
name = DDR_schon_heute
bonus = 1
uses = 1
category = naval_equipment
}
}``` is this the correct syntax for an if/else statement or does the else go inside the if block
You can put it either way
splendid, thanks
While you're here, are there predefined "namelists" for the randomly generated advisors and division officers and if yes, can I assign a specific Tag a specific list
Names are defined in common/names/, i'm sure you can copy-paste a list and put your tag
I haven't done much modding in that aspect so i'm not too sure
yeah, seems simple enough
there are COUNTRY_TAG = {} blocks, so that should work
How do I swap country leaders? I am trying to replace one Country leader that I have for the communist Ideology with another, also communist.
just wondering on how to fix this, i have been trying with different ID's and none of them worked except infantry_equipment_0
Use infantry_equipment_0 for guns 1 and infantry_equipment_1 for guns 2 and so on
If you want higher teir guns for this day 1 production you need it to be researched in the countries history file
i tried but they didnt work for no reason
you need it researched
in the history file
ohh in the history file but where?
also it says that there is no variant for both support equipment and arty
weird i do have them
Find the country under history/countires then find "set_technology" and add infantry_weapons1
Ty
infantry_weapons1 = infantry_equiptment_1
along side that the divisions doesnt have equipment (arty and support)
dude why isnt it putting my portrait
can you show what you changed
so you want me to show the portrait i want to put?
It should have the exact same path as the base game one
the path
is there a guts and blackpowder mod
vanilla path
its the same path and both vanilla and my file are gimp dds
i might have found the solution
Ooh I see the issue
you dont need to do the DLC path
gfx/leaders/GRE suffices
oh ok ill give it a try
didnt work
i think paradox hates me
ok i think i made something wrong which ill fix now
anyone know what exactly this error entails?
i can't tell what is really missing and what to try fix
im also assuming that this casued a crash since the game crashes around that time
ok thats a start
so basically the top focus will be completed with an event
and the option you choose will complete one of these
uhhh has hoi4 changed the railway system?
uhhhh all the railways combined themselves into one
Is there a Attack on Titan mod
Does anybody have a template with the scripts that give you something upon completion of a focus, like giving 100 pp for example
are u greek?
i am
apo pou?
athina
aigaleo h akribos athina
rework gia ellada
kai ego ekana ena greece modern expansion pack alla to stamathsa gt eithele poli douleia kai to hoi 4 olo mou krasare
relatable
what other commands like these exist
if add_party_popularity exists, what to add next to add ideology
Thanks dude, now i can make any focus i want 👍
Nice
modifiers don't work in focuses as far as im aware though
How do I assign Airplane models to a country? I want to give a custom tag both the 3D models of Germany and the Icons
add them to an idea first, then add the idea as a focus reward
yes, that
(idk about models tho lol)
i cant find the file
or more likely, files
ok i think i found it
C:\Program Files (x86)\Steam\steamapps\common\Hearts of Iron IV\gfx\interface\equipmentdesigner\graphic_db
there are files in there that seem to regulate it, ill try it out
It did work!
the only thing it doesnt seem to change are the blueprints...
Paradox gonna make my mod obsolete 😭
Hey guys so I'm kinnda new to modding and I know like a fair bit of C++. Anyways so I have it hard to find the required folders all the time and I have to wonder if there is a simpler way.
I just spend 3 hours searching for 1 folder too (cause no one answers my questions here lol) what i figured out what helped is subscribing to mods that change the thing you want to change and look at their folder structure, thats how i found the one i was looking for
tldr, reverse engineer other mods
Interesting thanks!
sameeeee lmao
I made an Austrian focus tree with like 250 focuses that I basically abandoned after it was 90% done but oh well
I hope it's not going to take ages to update everything with all the new mechanics being added
Imagine having a german mod. That whould become obsolete in the next months
improvise adapt overcome
Yeah they will switch to Tanna Tuva
see what's lacking in the original and add that in
I hope they add ss mechanics, for historical accuracy
I think paradox is to strict with Japan and Germany in the no no zone department
they mentioned an inner circle mechanic in which advisers with high influence might challenge the rule of the führer so that might be a thing actually
Reichskommissariats Plus will be turned to Kazakhstan Plus and includes puppets for the entire world for Kazakhstan
real
i got auto-timeouted on this server for saying a word starting with r, they are too strict in general
racism
I belive that games should stop being such pussys with these topics. Its part of our history for bad and for good...
they got my arse for living in a period a while back but whatever I guess I don't talk here very often so that didn't really affect me 💀
Like i dont say it in a bad way dont get me wrong
the german version is still censored despite that no longer being a legal requirement in germany lol
except it's meant to be accessible for young teens and I don't think such topics are really appropriate for that demographic
especially with such an already "radical" sect in the fanbase
Yeah i think there should be an option that turns it off for streamers and for other people
I wanna watch an army of 14 year olds try anything in that direction
that would be hilarious
like in some of the mods that make use of the actual flag
Scraping the barrel models
Brother im like 15 and idc if it has a n@zi flag or not
Wait until you see human torpedoes
diarrhea driven
I watched a few documentaries about the human torpedoes and 1 they were scary for the pilot 2. They were like 80% one way trips
exactly my point
I hope we get flying dorito chip next update
i hope we get skibidi toilet next update
The ho-229, If we don't il just mod it in
If I'm 15 it doesn't mean i watch that shit
I want a mechanic where half the german military budget gets used by Görings Buffet
I could add that to my mod...

immersive germany
True, they just said nope to the Luftwaffe and they said yes to the waffles
What mod are you making?
Napoleon Victory in 1804
sick
Wait are you the cool dude who is making the Napoleonic war mod?
no
Not really
i started like a month ago, map almost done, 3 countries have content lol
Dis you uplöad it
no because i wanna wait till it's finished before uploading it
maybe a closed beta
but i dont wanna throw some half baked stuff out there
should be automatically applied once it's installed
depends on which one you installed
you can view the tree in game
Well, the updates are real time, so just have the game open while you work on a tree and use alt-tab to switch between windows, or get more monitors lol
I can't tell you what it does, the notes don't say what it does
You need hoi4 modding utilities
Hoi4 modding utilities lets you preview alot of things
Gfx and gui files, focus trees, event trees (see how events and their options interact with eachother)
@patent linden https://youtu.be/vfpjRVIo9X8?si=DqfLOqva_qurWkyk
Expansion pass available now to purchase: https://pdxint.at/EP1Store
This expansion pass for Hearts of Iron IV includes two expansion pass bonuses, one expansion pack, one country pack and one unit pack. Content in the pack invites you to write exciting new histories of Germany in a greatly reworked focus tree, survive as a minor Asian power u...
Man
No way
Yeah I saw that
Would be a shame if i were to use my vpn to go to piratebay instead of paying for it
You just open different files and youll see a hoi4 button in the top right you click and it opens a new window to display stuff
I use it a ton for scripted guis
me when im modding but I spilled on my computer frown ):
Hey I am brand new to modding and I have one quick question, when I add new ideologies, usually in the bar to display the amount of support an ideology has (the one near the pie graph) can only hold 5 ideologies. Is there a simple way I can make a scroll feature?
doesn't that appear automatically
Not for me at least
I have around 8 ideologies and only 5 are in visible range on that line
I’ll get a photo of what I’m talking about soon
I cant quite remember how to do it
But theres a way to change the base ideology frame into a scrolling one
I had to do it with my last mod bc we had something like 12 ideologies, but i could never make the first ideology be at the top of the scroll
Ah
Thank you so much for the advice still!!!
It’s much better than me trial and erroring it 😭
what is generally better? VSC or NTP++
Notepad
I generally use Notepad++
Is there a way to make it so a puppet of yours can have a puppet of their own?
Like they are your puppet, but they also have their own puppet
Hey there, can anyone suggest a place to hire someone to make a custom heart of iron 4 mod? with custom map and nations [dosent need custom focuses]
i think yes
puppets can have puppets, i think
why not make it yourself
modding for the new dlc will be talked about in a month or so! :D
Vsc has a plugin to see your focus
I usually use np++ but it's personal preference
only cause i had a bad experience with vsc where i accidentally deleted my whole mod
Fiverr, or depending on how much you're offering and what exactly you want the mod to contain, I can do it
Anyone able to help me out here?
did you modify the scripted triggers file for sweden
No I didnt
The weirdest part is that it's normal scopes like "FROM" and "Controller"
Does anyone know how I can assign specific Blueprint Images (see picture) to a specific tag?
Hope there could be a mod that plays an animation or short movie after the capitulation of a nation. Like playing the new DLC trailer after conquering SSR or USA
What are som good mods that doesn't change the gameplay but more like the UI, graphics or other nice to have mods etc.
Uhhhh im having troubles with this event
i want to make so russia becomes the controller of this state if they controll it
but it doesnt work
would anyone know how to do this?
i made so france can establish lithuania and courland even if they dont controll them
but if they create them and the states controlled by russia dont get returned to Russia that would break the focuses
nice mod, what is it about?
1789-1815 mod pretty much
Nice
what it should look like
why is this
randomly connected 2 focuses with lines when they have literally nothing together
ok so this code
is giving this output
why is it only doing australia
the code below it is running too
I think it only says that Australia becomes free, have you tested it in game?
wat
the bottom screenshot is from in game
i know what it says
i am asking why
i messed up the scope rip
what are some good smaller (in popularity, not necessarily size of mod) mods?
same
Do you guys have a good Poland mod?
2 Questions:
- How exactly do variables work in modding? I need an integer variable who's value is affected by both focuses and decisions, i remember someone mentioning that you can create global variables, but i don't know how
- How do i integrate said variable into localisation? I need it to show up in the description text of a decision category, how would I do that?
fair enough
im in the server imo
If I create the following variable in a focus set_variable = { var = veb_budget_counter value = 0 tooltip = DDR_create_veb_budget_tooltip } is the variable global/public by default, or is that what the temp_var thingy is for?
temp_var is erased from memory after the code block it is in is completed, if I understand correctly
a variable is by default the scope you are currently in, in a focus, thats the country
{
add_offsite_building = { type = dockyard level = 1 }
add_to_variable =
{
var = veb_budget_counter
value = -1
tooltip = DDR_reduce_to_veb_budget_tooltip
}
}``` so if I do this in my decision, it should work? I don't know if the seperate decision file for this tag counts as the same scope
on a side note, how can I display the value of a variable as seen in this image
I cant find anything in the HOL decision file about it
nevermind its in the decision category file
yup
ok, 2 things, DDR_veb_budget_counter_display:0 "The current VEB budget is: $H[DDR.veb_budget_counter]$!" this does not give me the correct text output
{
tag = DDR
value = DDR.veb_budget_counter
desc = DDR_veb_budget_counter_display
}```and this inside my decision category does not display the value in the UI, is this a scope issue? could this be caused by the value being non defined/null?
OK, i fixed the first thing, only the UI problem remains
How do I create a custom tooltip with the checkmark infront of it
i cant find it on the wiki
Nevermind i found it
Does anybody know the syntax for replace_unit_leader_trait? "replace_unit_leader_trait = { A B }" does not work.
I'm unsure, I'd guess you'd need a "remove_unit_leader_trait = " and a "add_unit_leader_trait = " similar to the "swap_ruler_trait" one
Nah mate i don't but should i get the seelow heights mod?
Say please who know, how to fix leader portrait?
what exactly is the problem
hello
how do I merge states?
when I add the provinces from one to another the old one is still there
say I wanted to merge Northern and Southern Silesia into just Silesia
Leader Portrait is not displayed and is replaced by another portrait
Show code
how do you add army_experience
thanks I see
Add all the provinces from northern silesia to southern silesia (or the other way around) and use that state number in a state somewhere else
or make the state with the highest number (currently 969) use that state's number instead
there can't be gaps in the states so that number needs to be replaced
does anyone know how to set a video or GIF as main menue background?
Instead of studying I've made this:
https://steamcommunity.com/sharedfiles/filedetails/?id=3343631478
can anyone help
tryixng to create a national spirit via focus
but still shows this only
he genuinely look so much better without hair dude ur already balding just let go PLEASE
thank you for blessing us with this mod he needed it BAD
you're welcome 🙏
just before the name you have a `
that may be causing it not to show the idea or even create it
i did
fixed
but it still doesnt work
Do you guys know if paradox changed the way army icons are used?
How do I get rid of mutually exclusives in MIOs?
How do I make it so that a nation starts with a national spirit?
you put in the history file of that country
Thats how I have it
if there is already an add_ideas for that country you can just slot your idea into it
There isnt
This is how I have it and it doesnt show up
Or is it possible to remove mutually exclusives in MIOs?
whats the idea in it?
yeah
Yes
you can
its in the '00_generic_organization' file in common/military_industrial_organization/organizations
you can find all the ones that are mutally exclusive and remove the line for making them as such
So is there no way to fix it
is it a base game idea or one you made?
One I made
are you able to add the idea via focus or decision?
it may be that idea isnt working right
Havent tried it
Tho I set up the idea exactly like the HoI4 tutorial said
Just with a couple alterations
try adding it to a focus reward and see if it pops up
if not take a screenshot of the idea and send it in
Thanks for the idea 👍
no problem and goodluck on getting it working
Thanks.
Sorry, i just dont notice and forgot
Anyone down for a game of hoi?
You can put all the sonya characters into the same scope since they are the same person
Are you also recruting them initially in the country's history file?
Anyone knows which define is responsible for base trade cost? I want to increase the base amount of resources per civ from 8 to a higher value
Hello. How do you change the leaders of other ideologies? (For example if my country turns communist that I have my custom leader)
trying to add units for crimea but i cant, does anyone know? (I created the CRI_1936.txt, file, it is set as units file for Crimea but they still dont appear)
which mods most help increase game speed and performance in vanilla?
Whot
recruit_character =
it says there are 30,000 errors and every country disappeared can anybody help 💀
Oh, thanks
send a screenshot
of the game?
yeah
For a nation, how would i make 1 focus tree for a player, and another for an AI
Did you loadt the OOB for Crimea in the History file?
maybe this?
You could check for the specific Tag on startup
ye, make like an event to check if it's a player, then assign focus tree
i will try that and report back
use an on_action
i do not know how to do that, could you elaborate
one sec
Theres a file called "00_on_actions.txt" in the Your_mod>common>on_actions folder
in there there is a block that starts with "on_startup"
you can try inserting something along the lines of TAG = { if = { limit = { is_ai = no } load_focus_tree = player_focustree } else = { load_focus_tree = ai_focus_tree} } }
i will do that
Why doesnt my 2nd focus appear
Probably because there's a problem with the code for either it or a for the code above it
a missing "=" is enough for it to break
The error thing says "near line 35"
could you send a screenshot?
send your code
could you also send your error log?
You have an extra bracket closing out the first focus
if you use notepad++ you can select a bracket to see if it's closing/opening where it's supposed to
i added this to on_actions, and when i select the nation, it spits out a generic focus tree. soviet_player.txt is in common/national_focus so i thought it should work....
you might just be better off putting the is_ai as a modifier inside the focus tree itself
While you're here, do you know where the "custom_icon" wiki entry is? it's part of the decision_category, but i can neither find it in the decisions wiki category, nor can I find a "decision_category" wiki category...
Thanks for the help 🙏
already tried that, didn't work
show the code
Remove the first modifier and just put the tag and is_ai together
it's just an interface/Gfx reference I don't think it has a wiki page
i know, but it has to be an entry in some other category
it would be an entry in an interface file
well it works but my gui is gone
what's your gui
is that in game?
yes
I've never seen that before
could you send the focus file? I can look at it when i get home
i think i can fix it by copying the other file and changing the id
yuh that might work
i fixed it thank you
what was the cause?
does anybody know why i cant get the goal_generic_support_democracy icon to show up on my focus?
it was because I forgot a " in the country_tags file lol
ahh yeah that happens
you'll have to find the interface name for it
this might help
ohhhh
i just had to get rid of the generic
thanks
all good
you have to add a localisation entry for it
okay i think my tutorial vid gets into that at the end so thank you
no worries
and this is my on_startup
what does the rest of it look like
it definitely loaded my player focus
like the default one
i just copied the base one and added my code into it
I'll check when I get home
Forgot what an OOB means, can you remind me rq
?
oh wait a second
its a comment
lol
set_building_level = {
type = infrastructure
level = 5
province = {
all_provinces = no
id = 25, 31, 19, 806
}
why doesnt this work?
yup i fixed it
nice
idk why the hoi4 devs left the OOB for crimea as an comment
Im unsure how hoi handles history files specifically, potentially because if they left it in, the OOB would load without Crimea existing as a country
yeah
hoi4 leaves an error message in logs if the oob is loaded but it doesnt exist
can anyone help me make this work?
it's weird, some of the focuses do have the arrows
did you have the make the lines automatically?
huh?
don't add the province block for infratsructure
did you put the focus requirements in the "available" block or in the "prerequisite" block
it's a copy-paste of the base soviet tree
just with some stuff modified
like removing the five year plan interruption thing
what do i put
it used to work when the focus tree just replaced the base one
but now that i am trying to make a player vs ai variant, it's breaking
it still says the same thing
completion_reward = {
add_political_power = 25
set_building_level = {
type = infrastructure
level = 5
id = 25, 31, 19, 806
}
}
oh wait
yeah when it's the ai focus tree, it looks and works fine
{
type = infrastructure
level = 5
instant_build = yes
}
i need the Ids
check the things you changed for typos
brackets that never close and such
there's no typos, because when i had my focus tree just replace the soviet tree, it worked
but the moment i changed the id from soviet_focus to soviet_player_focus to do the startup action, it broke
so i'm thinking there's a gfx interface thing that sets up how the soviet tree is setup, and i just have to copy it and change it for soviet_player_focus
but i don't know where that interface is
see what happens when you change that line back
i mean, it would just replace the base soviet focus again
changing it back is just where i started from, so i know it works
yes, but if it works you know for sure that it's that line that causes the error
ok lemme try it
well
i made a focus tree for the ai, and changed the id to "soviet_ai_focus" instead of "soviet_focus" and then did that on the on_startup block
and now the ai tree has the issue
it's almost definitely an interface thing
but idk where to look
If you remove the load_focus_tree from on startup, and load each of the files seperately, what happens?
you need to add an "mutually_exlusive" entry for both of the other 2 focuses in each of the 3 focuses
or foci?
i dont know the plural form of that
thanks
how do i check if a game rule is active?
if = { limit = {is_ai = yes} load_focus_tree = soviet_ai_focus } else = { load_focus_tree = soviet_focus }
imma just dump my code here
can someone explain to me why is the game pulling icons that are not specified in the pool? 🥲
both focus trees work, which is exactly where i started
i already know what is broken
the on_startup seems to break it, or rather loading the focus tree doesnt seem to work proerply
there exists a "mark_focus_tree_layout_dirty" which takes a boolean
it refresehes the focus tree, maybe adding that underneath the load_focus_tree helps fix it
hmmm
I'm unsure, probably because it wants to assign something to it, realizes that since its a different plane design it should automatically have a different icon and then chooses one at random
this is more of an educated guess than anything else really though
how do i make it so a focus can only be completed if they have a certain leader
You could try setting a limit = { country_leader = your_country_leader_id }
in the "available" block
don't know if that works
Thank you for the suggestion! So far my only conclusion was that the ingame 1936 pre-templated aircrafts could be coded somewhere else and that's what is forcing those icons to override the ones in the pool..
i dont think that worked
If my assumption is correct, a very stupid solution would be to create copies of the icon you want to reuse, create extra definition entries for them and then adding those to the pool
You can see if it worked in the focus
if there is an X or a ✔️ with a "has country leader your_country_leader" then it worked
it broke the game
how do i know the id because its a custom leader
did you create him in the history file or in the character file for your tag
history
i dont know if there is an "id =" option for the create_country_leader
also im trying to change his name and its just going blank
yeah im not sure
set_country_leader_name = King Anthony I
this is making his name go blank
yes, because you need to put "." around it if you use spaces
right now the game is looking for a variable named "King" and then gets confused by the rest of the statement
still didnt work
anyway, ABK_kirilli_bechvaya = { name = "Kirill Bechvaya" portraits = { civilian = { large = GFX_portrait_Kirill_Bechvaya } } country_leader = { ideology = stalinism expire = "1950.1.1.1" id = -1 } } i dont know if "Id" is the correct name for it, but the "id" here is "ABK_kirilli_bechvaya"
then put a King_Anthony_I there and add an entry for that in the localisation file
didn't work sadly
yeah i think thats what i have to do
https://www.reddit.com/r/hoi4modding/comments/mpeo8h/lines_between_focus_tree_not_appearing/ but this dude on reddit has a similar problem
it's token, not id
reddit is a terrible source to ask questions from my experience
half of the answers are "stupid question/I don't know" and the other half is completely made up bullshit that has nothing to do with your question
perhaps
bruh 200 errors
maybe this has something to do with it
@patent linden what do i put in localization
if you do the whole load on startup thing but you delete the original file and only leave the ai_focus_tree file in your mod, what happens?
l_english:
King_Anthony_I:0 "King Anthony I"
as in delete the file from the game files?
yes, delete one of them, load the remaining one
ok
dang it thats what i did and it gives 200 errors idk why
send your create character code and the localisation code
create_country_leader = {
name = "Anthony Bongiovanni"
desc = ""
picture = portrait_ant_anthony.dds
ideology = conservatism
traits = {
#
}
}
l_english:
ANT_establish_anthonys_constitution:0 "Establish Anthony's Consitution"
ANT_establish_anthonys_constitution_desc:0 "The long awaited consitution formulated by our leader Anthony now must be voted on to be enacted! Glory to the Republic of Ant!"
ANT_reform_the_economy:0 "Reform the Economy"
ANT_reform_the_economy_desc:0 "Our ecnomy is in shambles and needs to be reformed. We need better buildings and infastructure to promote more business in our country."
ANT_gather_the_nationalists:0 "Gather the Nationalists"
ANT_gather_the_nationalists_desc:0 "Our country has been destroyed by the democratic swines. We must unite the true patriots of our country and overthrow their evil reign!"
ANT_encourage_the_unions:0 "Encourage the Unions"
ANT_encourage_the_unions_desc:0 "The working man earns nothing in our society. We must allow unions to maintain the economic prosperity and health of our workers!"
ANT_crown_anthony:0 "Crown Anthony"
ANT_crown_anthony_desc:0 "It is time that we crown our great leader Anthony Bongiovanni, so he can become king of our glorious country."
King_Anthony_I:0 "King Anthony I"
do "name = ANT_anthony_bongiovanni" and in the localisation file do "ANT_anthony_bongiovanni:0 "Anthony Bongiovanni"
the token you do after the "name =" and the token you use in the localisation file need to be the same
If I tell you to go grab a box labeled "Screws" then you will try to grab a box labeled "Screws" and nothing else
same goes for the computer
206 errors
it looks for the box labeled "ANT_anthony_bongiovanni"
it did not solve the issue
are all of them caused by your mod
i think
then something seems to be borked with the whole load_focus_tree thing
try your event solution from before, if its still borked, the "load_focus_tree" should be the problem, if not, the on_action might be to blame
aight
[13:07:25][1936.01.01.12][effect.cpp:422]: Invalid scope type for effect set_building_level in common/national_focus/ant_country.txt line : 72
[13:07:25][1936.01.01.12][effect.cpp:344]: Error: "Unexpected token: id, near line: 76
Unexpected token: id, near line: 77
Unexpected token: id, near line: 78
Unexpected token: id, near line: 79" in file: "common/national_focus/ant_country.txt" near line: 80
[13:07:25][1936.01.01.12][nationalfocus.cpp:165]: Duplicate focus name will cause database problems: ANT_gather_the_nationalists
lines 72-80 seem to be causing problems in your code
type = infrastructure
level = 5
instant_build = yes
id = 25
id = 31
id = 19
id = 806
}
}
focus = {
id = ANT_reform_the_economy
icon = GFX_goal_generic_construct_infrastructure
x = 0
y = 1
relative_position_id = ANT_establish_anthonys_constitution
available = {
}
bypass = {
}
cost = 5
prerequisite = { focus = ANT_establish_anthonys_constitution }
cancel_if_invalid = yes
continue_if_invalid = no
available_if_capitulated = no
completion_reward = {
add_political_power = 25
set_building_level = {
type = infrastructure
level = 5
instant_build = yes
id = 25
id = 31
id = 19
id = 806
}
}
ai_will_do = {
}
}
remove the id entries and see if the error remains
in the set_building_level that is
don't remove id = ANT_reform_the_economy
[13:14:15][1936.01.01.12][effect.cpp:422]: Invalid scope type for effect set_building_level in common/national_focus/ant_country.txt line : 72
[13:14:15][1936.01.01.12][effect.cpp:344]: Error: "Unexpected token: id, near line: 76" in file: "common/national_focus/ant_country.txt" near line: 80
[13:14:15][1936.01.01.12][nationalfocus.cpp:165]: Duplicate focus name will cause database problems: ANT_gather_the_nationalists
do add_building_construction = { type = infrastructure level = 5 instant_build = yes }
[13:17:52][no_game_date][effect.cpp:422]: Invalid scope type for effect set_building_level in common/national_focus/ant_country.txt line : 72
[13:17:52][no_game_date][nationalfocus.cpp:165]: Duplicate focus name will cause database problems: ANT_gather_the_nationalists
[13:17:52][no_game_date][effect.cpp:344]: Error: "Non assign effect is not enclosed in {}: set_country_leader_name, near line: 232" in file: "common/national_focus/ant_country.txt" near line: 233
replace the set_building_level with what i send you
and add {} to the thing in line 232
@patent linden it's the focus tree somehow
i did the event, and it fired and did change the focus tree
the new focus tree just has messed up lines
did you restart the game at least once
yes
hmm
[13:26:48][1936.01.01.12][nationalfocus.cpp:165]: Duplicate focus name will cause database problems: ANT_gather_the_nationalists
and i dont know why its saying this either
can you be more specific
ok so
this is my focus
Fifth Focus
focus = {
id = SOU_seeking_recognition
icon = GFX_goal_the_confederate_states
x = 7
y = 4
prerequisite = { focus = SOU_international_relations }
available = {
NOT = { is_in_faction_with = USA }
}
bypass = {}
cost = 5
cancel_if_invalid = yes
continue_if_invalid = no
available_if_capitulated = no
completion_reward = {
create_trade_agreement = {
target = ENG
}
add_opinion_modifier = {
target = ENG
modifier = SOU_ENG_opinion
}
add_stability = 0.05 # 5% stability increase
}
ai_will_do = {
factor = 1
modifier = {
JAP = { has_government = communism }
factor = 0
}
}
}
}
and this is the modifier
in modifiers txt
trade_opinion_modifier = {
id = SOU_ENG_opinion
trade = 200
}
but it just says this
is trade the right one
yeah
i want to get trade opinion plus 100 between tag SOU and tag ENG
and you don't need decay right
OH
i know why
trade is a boolean
trade = yes value = 200
try this
like this example
fixed this but still the name issue
weird
is it test_trade_modifier or trade opinion modifier
it's trade
yeah
where
in the trade tab
hmmm
` SOU_ENG_opinion = {
wait no
SOU_ENG_opinion = { trade = yes value = 200 }
try this
@crisp condor
wat
yes
okay
the 3 letters infront of them are abbreviations for the names of the DLCs
use the 00_opinion_modifiers.txt
those are the base game modifiers
look for one which has the value you want, or create a new one
ok
oh
okay
thanks
@sand locust
still the same...
Is the focus right?
I think you are missing a closing bracket
should, yeah
does the modifier "SOU_ENG_opinion" exist
in opinion modifiers yeah
maybe this
what does this mean
I cant figure out what the problem is, restast the game and see what happens
i don't see any prerequisite scopes in your tree
wait im blind
but you should still remove the other modifier
it seems to be conflicting and loading both trees at the same time
so remove the on_action as well
that's probably what the localisation file says
is there any localisation
for anything
change the name and see if it stays the same
okay
changed it to lat_zamas on both
did nothing, it still says ziegfrid
could you send your ideas file?
That's fine
i've never seen that before, that's so strange
it's picked a random name from the names list
the error
but it still shows theres no modification?
[14:57:54][no_game_date][triggerimplementation.cpp:9350]: common/scripted_effects/BLT_scripted_effects.txt:83: has_game_rule: game rule LIT_ai_behavior does not exist
does this mean anything?
Could you try create a new ideas file and put that inside it, then delete the existing one?
it shouldn't affect it
ill try it rn
this is all thats in the ideas
is this correct?
Looks good
That might be too many zeroes for stability_weekly which is why the modifier doesn't show up
hmm mabye
ill try it again
stability_weekly = 0.025
put this
no change
ill force reload focus but idk if it will do anything
THERE WE GO
focuses change but the ideas dont?
on debug base mode
nvm
yep
i had this issue the other day too
i was having to manually reset focuses
with reload focus
i have another question but i think it goes to localisation
if i kill the fascist and communist leaders with a purge and force them to die in the focus, would a randomly generated leader back them up or could i change the party and leaders to make it say banned
If you have debug mode enabled you shouldn't have to manually reset it
you can't make it say banned, they would just be replaced with generic leaders
but you can create a leader named banned
i had it on the other day, everything was showing up as debug, all the province id's, focus id's etc
since they wouldn't actually become leader the portrait wouldn't matter
how are you enabling it?
this is what i was thinking
hmm thats strange
thanks for the help
no worries
so how do i address it
like if i want it to have one focus tree for ai and one for another
might be a bit of a stupid question but how do i put a national spirit that is there from the start
add the idea in the country's history file
no question is a stupid question!
have a modifier for is_AI = no in that focus tree
and is_ai = yes in the other
just throw it into history ?
yep exactly
oh wow
so i make it in ideas and then one in history or jst in history?
bc i looked at france's victors of ww1 idea and it is in ideas
and its from the start too
keep the idea in ideas, and just add add_ideas in the history file
thank you
wait
i changed the lat_independenceS to just lat_independence and it didnt do anything either
tried to edit the provinces.bmp and resulted a pixel map lol
yo guys, how do i set a countries flag with tlike the gfx n stuff,
its for a new country with a new tag so im not replacing an existing countries flag
This lesson will explain how to create a new country in Hearts of Iron 4.
If you found this video helpful and want to help the channel grow you can use the super thanks button above, any amount helps the Iron Workshop improve and continue to make more videos like this one.
Timestamps for this tutorial/lesson:
00:00 - Lesson beginning
02:00 - ...
did that tons of times, gonna try again just to see if it works
anywho now the game refuses to start
i have tried that, and it doesn't work
well i haven't done the ai_yes one
i'll try it
it does not work
it defaults to whichever file is called soviet.txt
@timber zenith is it possible that i put it in wrong
like it should be under 1 modifier instead of 2 or
mmmm
it's reverting to the default treee
aaaaaaa
it's this thing all over again
it won't even let me take the focus
yes
the ai is still getting it because the first modifier lets it
the second modifier is just saying "because i'm not ai i'll get it, with a higher priority"
it doesn't prevent ai from getting it
put it inside the other add_ideas scope
yeah it still caused the other pic
of no lines and not being able to take the focus
what's the modifier for the other focus tree?
it's just the base tree
change the modifier in that one to require the person to be ai
did you put it as two modifiers, or just one?
i tried it both ways
let me try something rq
ok
i figured it out thanks
i need help with one more tjing though
sure
ok so
this is my completion reward
completion_reward = {
# Add bunkers to the specified provinces
add_building_construction = {
type = bunker
level = 3
province_id = 873
instant_build = yes
}
add_building_construction = {
type = bunker
level = 3
province_id = 951
instant_build = yes
}
add_building_construction = {
type = bunker
level = 3
province_id = 11888
instant_build = yes
}
add_building_construction = {
type = bunker
level = 3
province_id = 6958
instant_build = yes
}
}
}
}
and this is how it looks ingame
but it doesnt add any fort to the province id when i completed it
Put the forts inside a state scope
as in like 111 = { }
oops wrong reply
but @sand locust i got no idea man
it's so weird right
the focus tree appears correctly after reloading the game but it has these broken lines
which indicates a stacked focus or broken prerequisites
weird
how is this relevant to my problem
it's not?
put the buildings inside that scope
111 means the state that you're putting them in
as in the state id
it might have something to do with all the focuses still having the same IDs as the regular soviet focus tree
are there any changes other than the cost?
ty
im really starting to get a hold of this now
i'm glad to hear it 🙂
it removes the majors disrupting third 5 year plan, makes the purge focuses have less of a forced time gap, and then makes lessons of war not wait a full year
i was pretty careful to not add anything new that would cause an error
@timber zenith completion_reward = {
# Add bunkers to the specified provinces
111 ={}
add_building_construction = {
type = bunker
level = 3
province_id = 873
instant_build = yes
}
111 ={}
add_building_construction = {
type = bunker
level = 3
province_id = 951
instant_build = yes
}
111 ={}
add_building_construction = {
type = bunker
level = 3
province_id = 11888
instant_build = yes
}
111 ={}
add_building_construction = {
type = bunker
level = 3
province_id = 6958
instant_build = yes
}
}
}
}
like this
and it worked fine for a while until a friend suggested i make it fire only for the player while letting the ai keep the old focus
?
your brackets aren't correct
mine?
oh
111 = { stuff }
yes ik
all of them are in 1 state
tho
virginia
362
no worries
you might be able to put those individual changes into an is_ai if scope
you might need to unpause for a sec
i did
could you show the code you used again?
completion_reward = {
362 ={
add_building_construction = {
type = bunker
level = 3
province_id = 873
instant_build = yes
}
add_building_construction = {
type = bunker
level = 3
province_id = 951
instant_build = yes
}
add_building_construction = {
type = bunker
level = 3
province_id = 11888
instant_build = yes
}
add_building_construction = {
type = bunker
level = 3
province_id = 6958
instant_build = yes
}
}
}
ohh i see
it's just province instead of province_id
no worries mate
Hello, I have a question that maybe only a dev could answer because its about the upcoming dlc. How much will Gotterdammerung effect the tech tree code? I'm doing a changed date mod and want to change the tech tree's dates and other things
i'd imagine it just changes germany and the other nations
im mostly concerned about the special secret projects. if those are seperate from the current tech code, then ill be happy
i think that would just be adding something new, not changing existing
how do i change the leader of a party?
Can somebody show me how to make a custom general
for a custom nation
please?
tried this but it doesnt show up for tag SOU
can anybody help please
@timber zenith
did you recruit them in the country's history file?
recruit_character = SOU_robert_e_lee