Sins of a Solar Empire : Real-Time Strategy. Unrivalled Scale.
© 2003-2013 Ironclad Games Corporation Vancouver, BC. All rights reserved.
© 2006-2013 Stardock Entertainment

A few questions for experienced modders.

By on June 20, 2012 2:09:54 PM from Sins of a Solar Empire Forums Sins of a Solar Empire Forums

ultima9

Join Date 06/2008
0

Hello all.  I'm sure a lot of people are playing rebellion now... but i'm still having fun in classic sins...  (yeah, i'll buy rebellion at some point, hehe)

 

Creating a mod, and i've got a few questions for those who have more xp than i do.  I've managed to create a fairly large map with a fun theme.  Most of it is working just fine at this point, but i'm running into a couple issues i either just can't figure out or haven't messed with because i don't want to "break" the setup i have now. 

 

First, i've set up militia on pretty much every planet.  In one system (the only one that doesn't have a starting player) all the militia spawn just as i wish them to.  However, on all the systems that have starting players, the militia DO spawn, but the correct militia does not always work - they appear randomly.  In other words, although the templates load correctly, the name of the militia seems to be random.  This isn't a HUGE deal, because as i said, the templates load right, but since it is a themed map it doesn't fit the story well w/ random militia names on all the planets.  I assigned them all the correct militia (militia0, militia1, etc) in galaxy forge, and double checked them in notepad.  I can't find any difference between the entries that do always work and those that don't.  The only difference i can see is that the central system has no starting players, and one of the planets is a "home" planet.  The randomly spawning militias don't have a "home" planet, and are located on systems that have starting players.  I can't see why this would make a difference, but it's the only variable i can find. 

 

Second, in fitting the theme of the map, i was wondering if it would be possible to remove galaxy travel and wormhole travel research abilities, and force players to find the respective Ancient Artifacts that unlock these abilities.  By placing one of each in each player's home system, i thought it would be an interesting way to allow the players to open up the galaxy by discovering the remnants of the "decaying empire" located in the middle of the galaxy.  Is this feasible?  If so, will it cripple the AI players to the point that they'll never leave the home system?  It is a large map, so i am expecting it to take quite a while to actually clear it.  If the AI players will EVENTUALLY discover the artifacts, then it should be ok because the militia are quite entrenched and it will take a while to colonize new worlds.  Has anyone tried something like this before?  I've created a good number of maps, but have yet to touch the tech trees. 

 

Third, if i was to change the militia setting "isNormalPlayer" to TRUE, would it allow you to select them as a playable character?  I was hoping it wouldn't, and instead allow that militia to actually counter-attack you as you move through their territory rather than being stuck inside each GW.  If i removed the tech to galaxy travel and wormhole travel from everyone's tech trees, and didn't place an Ancient Artifact unlocking it in their star system, i was hoping it would basically confine them to one star system that they would actively defend and control.  Does the militia AI actually upgrade planets and actively build new structures and ships?  It seems that they do at least build new ships if you give them a shipyard, but i haven't taken the time to actually run a map long enough to see major differences.  Plus, i have yet to upgrade their starting planet pop levels, so even though they start with a lot of credits, it would erode VERY fast due to all the maintenance fees.  Not sure if they DO build but are just broke, or if they just don't build much and sit there waiting for real players to show up.

 

Those are the major questions i have right now.  Thanks for taking the time to read through all that, and for replying. 

7 Replies
Search this post
Subscription Options


Reason for Karma (Optional)
Successfully updated karma reason!
June 20, 2012 2:58:34 PM from Sins of a Solar Empire Forums Sins of a Solar Empire Forums

However, on all the systems that have starting players, the militia DO spawn, but the correct militia does not always work - they appear randomly. In other words, although the templates load correctly, the name of the militia seems to be random.

Did you disable the default template? Keep in mind by default the game spawns random militia at every neutral planet.

Second, in fitting the theme of the map, i was wondering if it would be possible to remove galaxy travel and wormhole travel research abilities, and force players to find the respective Ancient Artifacts that unlock these abilities.

Not unless you want to make a mod just for the map.

Third, if i was to change the militia setting "isNormalPlayer" to TRUE, would it allow you to select them as a playable character? I was hoping it wouldn't, and instead allow that militia to actually counter-attack you as you move through their territory rather than being stuck inside each GW.

No, it wouldn't. I'm not sure what effect setting that to true would have exactly but normal players would not be able to play as them.

Reason for Karma (Optional)
Successfully updated karma reason!
June 20, 2012 3:32:21 PM from Sins of a Solar Empire Forums Sins of a Solar Empire Forums

Did you disable the default template? Keep in mind by default the game spawns random militia at every neutral planet.

Yes i did.  Double checked it again to be sure, and yeah, all the default boxes are unchecked in galaxy forge.  Any other ideas? 

Not unless you want to make a mod just for the map.

I do have a mod for the map.  Already had to change the galaxydef file to tweak a few things and i also made a few modifications to starbases just for fun.  So it is possible to edit the research trees then? 

No, it wouldn't. I'm not sure what effect setting that to true would have exactly but normal players would not be able to play as them.

Cool.  I'll have to fiddle w/ that setting when i get home from work then, see if i can figure out what exactly it does.

Thanks for the quick response!

Reason for Karma (Optional)
Successfully updated karma reason!
June 20, 2012 3:48:25 PM from Sins of a Solar Empire Forums Sins of a Solar Empire Forums

Quoting Throndor,
Yes i did. Double checked it again to be sure, and yeah, all the default boxes are unchecked in galaxy forge. Any other ideas?

Hmm, well I know with Rebellion the game no longer loads all 20 some militia into the game. Rather it picks 5 or 6 at random each time and just uses those when you put "RandomMilitia" as the owner. What might be happening is those that aren't working were of a militia name that didn't get picked and thus defaulted to a different militia.

Quoting Throndor,
I do have a mod for the map. Already had to change the galaxydef file to tweak a few things and i also made a few modifications to starbases just for fun. So it is possible to edit the research trees then?

Then all you have to do is open the player[Race].entity files and remove the wormhole and long range jump tech entity references. Remember to update the Research count at the top of that section.

Quoting Throndor,
Cool. I'll have to fiddle w/ that setting when i get home from work then, see if i can figure out what exactly it does.

I will be curious to know what you discover.

Reason for Karma (Optional)
Successfully updated karma reason!
June 21, 2012 7:01:27 PM from Sins of a Solar Empire Forums Sins of a Solar Empire Forums

Alright, i figured out why my militia forces were not always working right.  The templates i was using were set to be owned by "randommilitia" - as soon as i removed the templates for all the neutral planets they all showed up correctly.  Going to try to see if "planetowner" works, since all the planets are already owned by each militia i'm hoping that will keep me from having to create a bunch of templates for each individual militia. I'm not really sure why the planet ownership was changed depending on what militia forces were assigned to the planet, but it is working now so i'm moving on.

 

Editing the research trees worked like a charm - thanks GoaFan77.

 

The "isNormalPlayer" flag seems to just let the engine know whether or not it should spawn the player if they are not played by a real player (or real AI player).  If you set it to true on a militia, the militia just don't spawn.  My guess is that the engine identifies a "militia" player by having "isNormalPlayer, isRaidingPlayer, and isInsurgentPlayer" all flagged as false.  I've got a few other ideas i'm going to try, if any of them lead anywhere interesting i'll post them.

Reason for Karma (Optional)
Successfully updated karma reason!
June 21, 2012 9:13:20 PM from Sins of a Solar Empire Forums Sins of a Solar Empire Forums

Some combinations of those booleans I do believe can result in militia being offensive and attacking you in small amounts...

Reason for Karma (Optional)
Successfully updated karma reason!
June 22, 2012 12:32:25 PM from Sins of a Solar Empire Forums Sins of a Solar Empire Forums

Quick update for any following this thread...

Setting the militia planet templates to "PlanetOwner" works.  If you set a planet's owner to a specific militia, then set a template to spawn for "PlanetOwner" then they will spawn and spawn for that specific militia. 

That's 2 done...  Doing some playtesting, will get back to the "make the militia fight back" thing after i check to see how the ai handles the fact that they can't research galaxy/wormhole travel.

Reason for Karma (Optional)
Successfully updated karma reason!
June 22, 2012 12:42:52 PM from Sins of a Solar Empire Forums Sins of a Solar Empire Forums

Aplos implemented it in his Stars mod....he probably isn't the only person who knows how to do it but it's a specific person...

Reason for Karma (Optional)
Successfully updated karma reason!
Stardock Forums v1.0.0.0    #108434  walnut1   Server Load Time: 00:00:00.0000125   Page Render Time: