KarlBar99

General Modding Questions Thread (All Welcome)

General Modding Questions Thread (All Welcome)

Whilst i'm creating this for my own little pet project to ask dumb basic questions in, anyone who has a question and wants it answered should feel free to drop by, the lack of anything like this that i've been able to find, (maybe i'm blind :p), is a bit sad for everyone else who has questions.

 

 

Ok my first really basic question. is there any way to modify an existing entry in an XML file without overwriting the entire file? The readme talks about adding new stuff and Total Conversions fine, but my modified tech tree is going to need to add tech option entries to some existing improvements. Having to completely overwrite the existing improvements file is not ideal, and their may be other examples i need to edit.

 

Does anyone know is ComponentClasDefs.xml is working as far as adding and using entries. I know occasionally some files won't be enabled in some games and this strikes me as the type of file that's most likely to have issues.

80,469 views 118 replies
Reply #51 Top

I wonder... has anyone looked into modding minor races? If so/how?

Reply #52 Top

The minor races have entries just like the majors but have a few key differences, shouldnt be difficuult to mod them, someone out there did a mod that made minor races lesser versions of majors, I think it was the Balance mod.

Reply #53 Top

Hola, i was wondering if anyone knows how to mod map sizes.

 

Ive been trying to alter insane map size settings makeing it way bigger, but so far i only either get no effect in the maps generated or the game crashes.

I started by altering      <HexSectorSize>380</HexSectorSize>      takeing the 380 and increasing it to 500, though the result was the game crashing.

My idea for altering it came from someones elses mod called Bigger Huge Map from sotof's mods. where he went from200 hexes to 356.

Also altering the    <Base>1200</Base>    dosent seem to have any real effect on maps generated, not sure what im missing.

Anyone got any ideas?


       

 

 

Reply #54 Top

First don't monkey with HexSectorSize.  To my knowledge even if you could make the map physically larger you'd hafta do alot of tinkering with the minimap setting to get it to work right, and I'm pretty sure you cant anyway.

However you can add more stars and planets and such.

Base>1200</Base> seems to increase the total number of objects the map allows to spawn.

<MaxHabitablePlanets>600</MaxHabitablePlanets> adjusts the total number of habitables that can spawn though to get much larger numbers you would need to edit StarSysteDefs.xml to get more to spawn per star.

<MapGenSectorSize>16</MapGenSectorSize> increase the total size/density of the clusters on the map, on a spiral for example it makes the arms much denser with many more stars, while on a tight cluster map it makes each cluster larger as well as denser.

Keep in mind even with a beefy machine its quite possible to create a map that is unfeasible for turn length mid/late game.

Reply #55 Top

Base>1200</Base> seems to increase the total number of objects the map allows to spawn.

It means that? That's good to know! I have been tinkering with map sizes, star frequencies, and resource availablilties to get very sparse maps to get a "space is big" feeling with many hexes between stars. And all I had to do was decrease that number? :)

I assume it can be decreased safely as there shouldn't be technical issues with having less stuff around? Have to try this. Thanks!

Reply #56 Top

couple that with lowering sector sizes and it should make a very large very sparse map.

Reply #57 Top

It works! Big thank you.

Did a few quick tests with the tiny and small maps and the parameter "Base" appears indeed to be the number of objects that the game tries to put on the map, and the "Stars" parameter in MapSetupDefs.xml is then simply the percentage of stars out of this total. Put Base=32 and Stars=0.5 ("Rare") and you get 16 stars. Base=16 + Stars=0.5 yields 8 stars etc. And I thought that Base parameter was some map size value thing that shouldn't be touched... SD needs to put comments in their XML files. :)

I'll try that sector size parameter, too. Thanks for the tip.

Reply #58 Top

Big Dumbass Question. Never paid attention to it before and it can be awkward getting the AI to do what you want so i thought i'd ask instead of trying to test. Do Area affects on a starbase, (i.e. stuff that affects it ZOC), affect the starbase as well in tactical combat. Or would a module need separate modifiers for that?

 

Also has anyone experimented with Strategic Repair penalties large enough to theoretically produce negative numbers. Does it actually deal damage or just stop all healing? I can test that fairly easily in practise but if someone allready knows i might as well ask.

Reply #59 Top

Quoting KarlBar99, reply 58

Big Dumbass Question. Never paid attention to it before and it can be awkward getting the AI to do what you want so i thought i'd ask instead of trying to test. Do Area affects on a starbase, (i.e. stuff that affects it ZOC), affect the starbase as well in tactical combat. Or would a module need separate modifiers for that?

 

Also has anyone experimented with Strategic Repair penalties large enough to theoretically produce negative numbers. Does it actually deal damage or just stop all healing? I can test that fairly easily in practise but if someone allready knows i might as well ask.

 

You need separate modifiers - the relevant effects have a <targettype> scope which is almost always set to Ship. This needs to be set to Starbase for the modifier to effect the SB.

 

As to Strategic repair, I've not tested it but I'd be willing to bet that turning it negative will cause damage over time.

Reply #60 Top

I want to create a few factions/races, but I am not sure if GC3 is supporting that right now. Maybe you can give me a quick overwiew.

 

Is it possible to create and upload a whole new faction with it's own ship/starbase style, custom research tree (with new techs), user interface (like in Birth of the Federation, not just a different color), structures and background music? Can we add videos with fitting ship styles for the first built frigate etc., or is that impossible because the game is using always the same video?

 

Oh, and is it possible to create new ship parts with for example Blender and add them to the game? I don't think there is a tutorial for stuff like that, right? :D

 

Can we really only load up some faction pictures and single ship designs to the workshop? Is there a workaround or is Stardock planning on improving the options?

Reply #61 Top

In reverse order.

That is really all you can upload to the Workshop right now, the dev's say mod support is coming but some of us have started just using the nexus for mods.

As far as I know you cannot create completely new ship parts.

Yes the game just always uses the same video it doesnt support changing vids.

As you asked in your final question the workshop doesnt support anything but ships and custom factions at this time.  Give the nexus a try its pretty easy to use.

Reply #62 Top

*facepalm* Should have thought to check that target thingy, put it down to late night stuff.

 

Also tested negative strategic repair modifiers. It does reduce a target's health to zero, (though the display suffers a rollover error), but they don't die at zero health till a battle starts.

Reply #63 Top

Discovered a new limitation. you can't have more than 8 stats attached to a ehch or you'll get a crash when clicking on the tech or on map build. Modules /Improvements attached as well may or may not count against this limit.

 

Also new version of my DreadLords Mod is up, any chance i can talk someone into at least loading it up and looking over the tech tree even if they don't play any turns please? :(

Reply #65 Top

Quoting KarlBar99, reply 63

Discovered a new limitation. you can't have more than 8 stats attached to a ehch or you'll get a crash when clicking on the tech or on map build. Modules /Improvements attached as well may or may not count against this limit.

 

Hmmm, this must only be on techs - I've got some 15 stats attached to military SB rings now and they cause no problems. I'd guess a UI issue, which probably means it will effect attached buildings.

Reply #66 Top

I just tried the game, and being an old GalCiv 2 player, I immediately start making my own faction, but I have two questions:

  1. How do I edit the .faction-files?

    I can't figure out how, and I'd like to take a look at what you can't and cannot do, as well as set up some bonuses or penalties that would be "illegal" by standard game rules/faction creation.

    I'm a bit shocked that they didn't keep the .xml formats used in GalCiv2, which made modding factions ridiculously easy. I'm also sad to see the flavourful ideological/party system go, but now I'm getting sidetracked...

  2. How do I create custom ship colours? I want to use the Terran colour scheme, but change the blue into red. I don't want Drengin colours, I want the standard Terran colours and standard Terran everything, just red instead of blue.

    I don't remember at all how GalCiv 2 handled it, but I don't remember this ever being an issue. But in GalCiv 3, I can't for the life of me figure out how to do it.
Reply #67 Top

Re: limitations in modifiers to techs

Good to know, planet traits have a similar limit of 4, probably set in the XSD's like it is for planet traits.

Luckmann

1. I don't believe you can edit the .faction files, generally if you want to create a faction with custom settings beyond what the ingame editor supports you need to create a completely new faction via making a mod using the FactionDefs.xml file and a number of other related edits depending on what it is you are trying to accomplish.

2. The color schemes also require modding if you want anything but the predefined color sets.  Though you can get alot of variety out of the combination of colors, surfaces and materials.  Editing colors is fairly straight forward but requires a bit of editing of several files in /Core you will find ColorDefes.xml ColorDefAlts.xml and GC3AppearanceDefs.xml while in /Game you will find color settings in FactionDefs.xml FactionMapColorDefs.xml and UIColorDefs.xml

Not too difficult but requires some work and I personally would love to see someone create a greatly expanded color palette mod, there is one but it requires replacing original game folder files and I just don't go there, here is the link if you are interested https://forums.galciv3.com/466774/page/1/#3561683

Reply #68 Top

Well that's a bummer.

Although finding and editing the files themselves is easy, knowing what does what appears to be a complete shot in the dark. I don't mind modding the base files - and don't see why that'd be a problem - but there seems to be no way to know just what to edit. I'm not even sure I found the appropriate file, let alone line, to edit.

I think it is "GC3_Terran_Appearance" in GC3ApperanceDefs, but the numbers (aside from EngineColor, yay) doesn't seem to correspond to something tangible, and there's not even any clue as to what should be changed. DiffuseGradientRow1? LightGradientRow3? Who knows? Nevermind creating a new colour set for a custom species.

I guess I'll just pass on the game for now and hope it gets fixed in the future. That's a pretty damn big oversight. Being able to set your own colours is elementary grade customization. I really wasn't expecting GalCiv3 to take a step backwards in terms of customization for factions, compared to it's predecessors.

Reply #69 Top

I do think that kinda of customization is something they will expand upon as the game goes forward.

Reply #70 Top

Question. if i wanted to create a custom "ship style" for a mod besides the ship style file and ship blueprints files are there any more i'd need to mod?

Reply #71 Top

Okay so i took a go at my last question by myself and have discovered something unfortunate.

 

You can't create new styles. Any new style added to FactionShipStyleSetDef, even if only the internal and display name are different will cause rampant unpredictable crashing when used. There's clearly some sort of hardcode at work there that's conflicting with extra factions. Which is pretty much 100% going to kill my dread lords project dead because without a custom style for them to use the AI can't use the faction to save it's life.

Reply #72 Top

Ok I havent done anything with actually producing custom ship style sets, but considering Gauntlet has done it and his mod works great I would suggest starting by looking at his mod for an idea of how to do it.  There is also a nice tutorial out there by Dumhed.

Reply #73 Top

Got links to those Deathwynd. Generally finding a specific thread around here can be a bit tough. Maybe i'm missing a file or something but despite re-building the file twice additional style groups in the noted file just randomly decide to crap out and crash. It's not even consistent. You can get it working. Make a change, it crashes, revert the change, and it still crashes, despite now being identical to a configuration that previously worked.

Reply #74 Top

Ok found the tutorial. And that is exactly, (well due to the escort fighter edit it's a complete replacement for the existing faction file but that's unavoidable and was causing no issues previously or currently) what i am doing. And it likes to crash as allready noted.

Reply #75 Top

Ok I assume you have added the ship styles you want into FactionShipStyleDefs.xml and then created NEW entries in ShipClassDefs.xml simply using the ship designs and thumbnails from your set but otherwise using standard blueprints.

Whatever you do keep to stock blueprints if you are having crashes.

Let me point out the entries to change using some entries from Gauntlets files. Green are items to change, red are items that must remain the same or strictly reference stock names such as blueprints

In FactionShipStyleDefs.xml

<ShipStyleSet>
<InternalName>FulgarTradeholdsShipStyleSet</InternalName> **Change this**
<DisplayName>FTH Ship Style</DisplayName> **Change this**
<Icon>GC3_S_Basic_Ship_Icon.png</Icon>
<DisplaySampleObjGfxConfig>0-FTH Medium Survey 01_with omestupidnumber.objgfxcfg</DisplaySampleObjGfxConfig> **Change this**
<ShipStyle>Krynn</ShipStyle>
<StartingShipyard>BasicShipyard</StartingShipyard>

Other than those entries only change the <ShipClass> tags you want to alter.

Then in the ShipClassDefs.xml

<ShipClass>
<InternalName>FulgarTradeholdsScout</InternalName> **Change this**
<DisplayName>Scout</DisplayName> **Change this**
<Description>Scout</Description> **Change this**
<ThumbnailOverride>0-FTH Tiny Scout_EC98DB4C08A84738BBE15A2EFF55AFAA.PNG</ThumbnailOverride> **Change this**
<ShipHullType>Tiny</ShipHullType>
<ShipRule>Scout</ShipRule>
<ShipDesign>0-FTH Tiny Scout_EC98DB4C08A84738BBE15A2EFF55AFAA</ShipDesign> **Change this**
<AIOnly>false</AIOnly>
<AIShipClass>Scout</AIShipClass>
<StrategicIcon>Scout</StrategicIcon>
<BlueprintDef>ScoutBlueprint</BlueprintDef>
</ShipClass>

If the only things you change are the items I've pointed out then there should be no crashing unless you have a space somewhere or a missing bracket, so if it still crashes then start looking for syntax errors.

The biggest thing I can think of that would cause an outright CTD is if the <ShipClass>Yournamehere</ShipClass> in the FactionShipStyleDefs.xml didn't match an entry in the ShipClassDefs.xml