Elemental Modding: Part 2 – New Factions

By on August 2, 2010 9:18:54 PM from JoeUser Forums JoeUser Forums

Frogboy

Join Date 03/2001
+1491

During the early betas of Elemental, we let users creation their own factions during the game setup. But over time, we kept getting more and more good ideas on how to make this more sophisticated that it became impractical to foist such a complex system onto the player (the UI would just get crazy).

Moreover, having to UI drive faction creation was resulting in factions that were more or less the same. So we moved this into the area of modding.

Let’s create a new faction. I’m going to create a new file called Froglers.xml and put it into my units directory in documents\my games\elemental

Inside I’m putting this file:

<RaceConfigs>

    <RaceConfig InternalName="Froglers">
        <DisplayName>Frog People</DisplayName>
        <Capital>Ribit</Capital>
        <ShortName>Froglers</ShortName>
        <LeaderName>Frogboy</LeaderName>
        <PopulaceName>Human</PopulaceName>
        <Description>This amphibious race hops on all fours.</Description>
        <Alignment>Good</Alignment>
        <FactionAllegiance>Kingdom</FactionAllegiance>
    <DefaultCityWallSet>CityWalls_Fence</DefaultCityWallSet>
    <NewCityHubType>Outpost</NewCityHubType>
    <CapitalHubType>Outpost</CapitalHubType>
    <!-- Race Stuff -->
    <RaceClassification>Frogs</RaceClassification>
    <RaceDisplayName>Frogs</RaceDisplayName>
    <RaceInternalName>Race_Type_Frogs</RaceInternalName>
    <MaleUnitType>Skath</MaleUnitType>
    <FemaleUnitType>Skath</FemaleUnitType>
    <GenericUnitType_Male>Skath</GenericUnitType_Male>
    <GenericUnitType_Female>Skath</GenericUnitType_Female>
    <TraderUnitType>Skath</TraderUnitType>
    <StartingUnitType>Kingdom_Soldier</StartingUnitType>
    <StartingUnitType>Kingdom_Pioneer</StartingUnitType>
    <ChooseFactionBack>Faction_Background_Altar.png</ChooseFactionBack>
    <UnitScale>1.0</UnitScale>
    <UnitSkinColor>32,255,32</UnitSkinColor>
    <UnitHairColor>155,255,75</UnitHairColor>
    <UnitClothing1Color>120,25,20,255</UnitClothing1Color>
    <UnitClothing2Color>78,60,55,255</UnitClothing2Color>
    <UnitMetalColor>145,145,145,255</UnitMetalColor>
    <BuildingPrimaryColor>165,255,130</BuildingPrimaryColor>
    <BuildingSecondaryColor>75,255,50</BuildingSecondaryColor>
    <BuildingRoofColor>90,255,10</BuildingRoofColor>
    <ZoneOfControlColor>165,255,30</ZoneOfControlColor>
    <TechTree>TechTree_Froglers</TechTree>
    <KnownStartingTech>Frogler_Starts</KnownStartingTech>
    <EnvironmentTerrainType>2</EnvironmentTerrainType>
    <PreferredLogoType>KingdomCrest2</PreferredLogoType>
    <SovereignUnitType>Lord_Relias</SovereignUnitType>
    <Spellbook>LifeSpellbook</Spellbook>
    <A_CoreManaRegeneration>50</A_CoreManaRegeneration>
  </RaceConfig>

</RaceConfigs>

 

Now, if you pop this in it’ll crash. That’s because we have to define some things first:

  1. RaceClassification
  2. RaceInternalName
  3. TechTree
  4. KnownStartingTech

Without those 4 things defined, the game won’t know what to do with this faction.  It is in these 4 things that we ultimately make what is special and unique.

I also cheated in terms of the 3D modeling. I used Skaths as my units. Skaths kind of look like frogs in the game so I figured…

We’ll need to define what Frogs are as a race. And we’ll need to come up with a technology tree for them.

Stay tuned.

Locked Post 98 Replies
Search this post
Subscription Options


Reason for Karma (Optional)
Successfully updated karma reason!
August 2, 2010 9:26:20 PM from Elemental Forums Elemental Forums

OOOOH!

Reason for Karma (Optional)
Successfully updated karma reason!
August 2, 2010 9:27:04 PM from Elemental Forums Elemental Forums

Judging from this I can make hobbits/halflings and reduce their size with a simple <UnitScale>.3</UnitScale> mod. That will save me so much time. Giants = <UnitScale>3.0</UnitScale>? and how do I make them take up more space on the tacmap?

Reason for Karma (Optional)
Successfully updated karma reason!
August 2, 2010 9:49:54 PM from Elemental Forums Elemental Forums

When the modding becomes more fleshed out, are we going to have a list of all built-in parameters and what they signify? 

And will it be possible to define additional parameters?  For example, would it be possible to decree that each faction should have a hat style and add in <FactionHats></FactionHats> to everything?

Reason for Karma (Optional)
Successfully updated karma reason!
August 2, 2010 10:24:20 PM from Elemental Forums Elemental Forums

I'm finding this to be the good stuff. It goes very well with my ideas I've been thinking ... for factions and minor races, and making them special and unique.

Reason for Karma (Optional)
Successfully updated karma reason!
August 2, 2010 11:02:30 PM from Elemental Forums Elemental Forums

Will we be able to do any of this in an editor? In other words, when we created new factions earlier in the beta, we had buttons to click and fields to type in names, graphics, UI, etc.

Will this be incorporated into the toolkit of modding utilities, or do we have to make new races in XML?

Reason for Karma (Optional)
Successfully updated karma reason!
August 3, 2010 12:26:20 AM from Elemental Forums Elemental Forums

Yes. In an XML editor.

Reason for Karma (Optional)
Successfully updated karma reason!
August 3, 2010 12:55:08 AM from Elemental Forums Elemental Forums

I'm disappointed that you decided to remove the ingame editor because that would have been more accessible to a lot more people.

Reason for Karma (Optional)
Successfully updated karma reason!
August 3, 2010 12:57:13 AM from Elemental Forums Elemental Forums

I'm sure some one else will create a robust, practical, and quick faction editor in less than a month. Gotta love guys like 

Reason for Karma (Optional)
Successfully updated karma reason!
August 3, 2010 1:20:45 AM from Elemental Forums Elemental Forums

Quoting Zawath,
I'm disappointed that you decided to remove the ingame editor because that would have been more accessible to a lot more people.


I have to agree here.. it was fun to create a quick and dirty race and get in and play it..

Reason for Karma (Optional)
Successfully updated karma reason!
August 3, 2010 1:27:33 AM from Elemental Forums Elemental Forums

The following would be interesting to have a bit more background-info:

Code: xml
  1. <SovereignUnitType>Lord_Relias</SovereignUnitType>
  2.     <Spellbook>LifeSpellbook</Spellbook>
  3.     <A_CoreManaRegeneration>50</A_CoreManaRegeneration>

 

The SovereinUnitType: Is this the Sov the faction is using if they are a played by the AI? What happens if the player choose Relias and another faction and as an enemy faction this one is choosen? Do we have two Relias in the game?

Spellbook: What is the idea behind? The spellbooks are defined by the sov not be the faction or?

A_CoreManaRegeneration: ? What does this value mean and how is this used ingame?

Reason for Karma (Optional)
Successfully updated karma reason!
August 3, 2010 3:27:54 AM from Elemental Forums Elemental Forums

This is looking VERY powerful. I'm excited!

One question, can a faction house multiple units from different races. Eg skeletons and vampires where the basic units for swordsmen and archers use a skeleton model but the higher level uses humanoid/vampire models. Or goblins, orcs and trolls for a single faction where each step up uses different models and has different stats, costs etc?

Reason for Karma (Optional)
Successfully updated karma reason!
August 3, 2010 5:03:00 AM from Elemental Forums Elemental Forums

Quoting seanw3,
Judging from this I can make hobbits/halflings and reduce their size with a simple <UnitScale>.3</UnitScale> mod. That will save me so much time. Giants = <UnitScale>3.0</UnitScale>? and how do I make them take up more space on the tacmap?

Excellent questions. As soon as I saw the scale modification listed I wondered the same thing.

Reason for Karma (Optional)
Successfully updated karma reason!
August 3, 2010 5:06:01 AM from Elemental Forums Elemental Forums

Guys, Frogboy isn't saying there Won't Be a Visual Editor. He's saying it will be a XML Editor AS WELL. Meaning there Will Be a Visual Editor AND it will allow us to edit XML variables as well. This means that for those people who don't like messing with XML you will have an easier way to do it!!! Be thankful, Not disappointed

Reason for Karma (Optional)
Successfully updated karma reason!
August 3, 2010 6:44:24 AM from Elemental Forums Elemental Forums

Quoting Raven X,
Guys, Frogboy isn't saying there Won't Be a Visual Editor. He's saying it will be a XML Editor AS WELL. Meaning there Will Be a Visual Editor AND it will allow us to edit XML variables as well. This means that for those people who don't like messing with XML you will have an easier way to do it!!! Be thankful, Not disappointed

 

Sure he doesn't mean a 'standard' XML editor? Eclipse for example .

Reason for Karma (Optional)
Successfully updated karma reason!
August 3, 2010 6:56:09 AM from Elemental Forums Elemental Forums

I understood it as well, that you can use a XML editor. I didn't saw any commitment that they will make an own editor for the fractions (especially an own XML editor would not be worth the work).

Reason for Karma (Optional)
Successfully updated karma reason!
August 3, 2010 7:05:27 AM from Elemental Forums Elemental Forums

Quoting Raven X,
Guys, Frogboy isn't saying there Won't Be a Visual Editor. He's saying it will be a XML Editor AS WELL. Meaning there Will Be a Visual Editor AND it will allow us to edit XML variables as well. This means that for those people who don't like messing with XML you will have an easier way to do it!!! Be thankful, Not disappointed

Quoting Frogboy,
Yes. In an XML editor.

He is only saying XML editor and not "also in XML editor". And I haven't read anywhere else "We have moved the faction creation screen to the Workshop".

Reason for Karma (Optional)
Successfully updated karma reason!
August 3, 2010 7:47:21 AM from Elemental Forums Elemental Forums

I'm sure the existing editor will still remain but just won't be 'pushed' as the best option. It is an XML editor but it has limitations.

I interpret the statement as they were going to make it part of the game start options but when they found that building factions didn't differentiate enough they decided to move this out in the Workshop mod area. After all, the tool just generates XML anyway - but it is limited. By encouraging us to mod to the full extent and going beyond the tool the full freedom of the engine can be utilised.

Reason for Karma (Optional)
Successfully updated karma reason!
August 3, 2010 9:03:48 AM from Elemental Forums Elemental Forums

Quoting Frogboy,
Yes. In an XML editor.

 

A lot of people have interpreted this differently.

 

Are you saying that the only "Editor" we'll be using to make new races is NotePad, DreamWeaver, etc.?

 

I'll rephrase my first question. The screen we had in game before it was removed to create new races, will we ever see that come back, so we can choose their colors, appearance, ability and so forth WITHOUT modifying the XML files? It is an accessibility question. While anybody with two days of scripting or coding experience can modify XML, people who don't will avoid the XML and essentially lose the option for a custom race without a visual editor to do so in (not a text editor).

So is the "Editor" a text editor, or is it something like the Tile Editor?

Reason for Karma (Optional)
Successfully updated karma reason!
August 3, 2010 9:13:49 AM from Elemental Forums Elemental Forums

Quoting ,

During the early betas of Elemental, we let users creation their own factions during the game setup. But over time, we kept getting more and more good ideas on how to make this more sophisticated that it became impractical to foist such a complex system onto the player (the UI would just get crazy).

Pretty sure that the above statement tells you everything you need to know, i.e. that faction creation will be done via xml with your choice of text editors, i.e. eclipse, etc.

Somebody in the comunity will probably create a a java app that generates the xml for you, as mentioned by a previous poster.

Reason for Karma (Optional)
Successfully updated karma reason!
August 3, 2010 10:08:38 AM from Elemental Forums Elemental Forums

I'm asking because what I really want to know is if there will be any limitations. When we created a race in the earlier Betas, we had X amount of points to spend on attributes for that race. Then, we had visual appearance things to customize.

With xml, it becomes load -> quit -> change number -> load -> quit -> change number until your race looks right.

Than, the attribute points. If we're doing it in XML, we can just give our race endless amounts of abilities and make a race of demigods. Before, creating a race was like creating a sovereign - it was pretty similar to the classics like MoO, and it was similar to Gal Civ 2 in a way. Creating a race is one of the most fun aspects of those games. Now, we can't just create our own race -  we have to mod the game. We have no way of knowing if our race is anywhere close to balanced in comparison to the other races, because we have no point system to guide us.

That's the biggest issue here, I believe. If you're going to keep it this way (I imagine you will, at least until after the release) then you need to add a much wider variety of races to choose from. Isn't it possible to have the old race creation screen without the hundred options provided by the XML files? Then modders can do what they want and people who want to play the game can just do so, with their custom race.

I remember reading that the race creation would end up outside of the main game and I was excited to open up the race creation screen without launching the game and take my time designing my new race. Now, the plan is to have people use Notepad. While I'm capable and experienced with XML, I don't want to "work" to create a race I was able to create in the earlier beta. I just want to make it following the games starting race guidelines.

Just some feedback and suggestions; either add more varied races to choose from at start, or come up with a more user friendly race creation method.

Reason for Karma (Optional)
Successfully updated karma reason!
August 3, 2010 10:18:19 AM from Elemental Forums Elemental Forums

You make some good points.

Best regards,
Steven. 

Reason for Karma (Optional)
Successfully updated karma reason!
August 3, 2010 10:22:48 AM from Elemental Forums Elemental Forums

While I don't really have much of a problem editing .xml-files, not having a proper in-game/workshop faction builder would suck ass. Poking at the .xml's is something I do to tune or edit my factions beyond the basics, I'd truly hate to create factions from scratch.

There's a reason I'm not a programmer or part of mod teams. It's not because I can't learn to muck about in various codes, but because I'm consistently bored out of my skull doing so.

Edit:

Quoting MadMagnus,
I'm asking because what I really want to know is if there will be any limitations. When we created a race in the earlier Betas, we had X amount of points to spend on attributes for that race. Then, we had visual appearance things to customize.

With xml, it becomes load -> quit -> change number -> load -> quit -> change number until your race looks right.

Then, the attribute points. If we're doing it in XML, we can just give our race endless amounts of abilities and make a race of demigods. Before, creating a race was like creating a sovereign - it was pretty similar to the classics like MoO, and it was similar to Gal Civ 2 in a way. Creating a race is one of the most fun aspects of those games. Now, we can't just create our own race -  we have to mod the game. We have no way of knowing if our race is anywhere close to balanced in comparison to the other races, because we have no point system to guide us.

That's the biggest issue here, I believe. If you're going to keep it this way (I imagine you will, at least until after the release) then you need to add a much wider variety of races to choose from. Isn't it possible to have the old race creation screen without the hundred options provided by the XML files? Then modders can do what they want and people who want to play the game can just do so, with their custom race.

I remember reading that the race creation would end up outside of the main game and I was excited to open up the race creation screen without launching the game and take my time designing my new race. Now, the plan is to have people use Notepad. While I'm capable and experienced with XML, I don't want to "work" to create a race I was able to create in the earlier beta. I just want to make it following the games starting race guidelines.

Just some feedback and suggestions; either add more varied races to choose from at start, or come up with a more user friendly race creation method.
This, this, a thousand times this.

It's one thing having a firm framework to work from, allotted points, etc, and *then* start smacking the .xml to do exactly what you want; maybe you want to break the attribute allottment, maybe you want to remove some restriction or stack faction characteristics "illegally". I regularly do in GalCiv2.

It's another thing entirely to build something completely free-form from scratch. I suck at sandcastles.

Reason for Karma (Optional)
Successfully updated karma reason!
August 3, 2010 10:35:53 AM from Elemental Forums Elemental Forums

so if i wanted this to be arctic i would do what?  <EnvironmentTerrainType>2</EnvironmentTerrainType>

Reason for Karma (Optional)
Successfully updated karma reason!
August 3, 2010 10:59:13 AM from Elemental Forums Elemental Forums

Quoting Luckmann,
While I don't really have much of a problem editing .xml-files, not having a proper in-game/workshop faction builder would suck ass. Poking at the .xml's is something I do to tune or edit my factions beyond the basics, I'd truly hate to create factions from scratch.

There's a reason I'm not a programmer or part of mod teams. It's not because I can't learn to muck about in various codes, but because I'm consistently bored out of my skull doing so.

Edit:



Quoting MadMagnus,
reply 20
I'm asking because what I really want to know is if there will be any limitations. When we created a race in the earlier Betas, we had X amount of points to spend on attributes for that race. Then, we had visual appearance things to customize.

With xml, it becomes load -> quit -> change number -> load -> quit -> change number until your race looks right.

Then, the attribute points. If we're doing it in XML, we can just give our race endless amounts of abilities and make a race of demigods. Before, creating a race was like creating a sovereign - it was pretty similar to the classics like MoO, and it was similar to Gal Civ 2 in a way. Creating a race is one of the most fun aspects of those games. Now, we can't just create our own race -  we have to mod the game. We have no way of knowing if our race is anywhere close to balanced in comparison to the other races, because we have no point system to guide us.

That's the biggest issue here, I believe. If you're going to keep it this way (I imagine you will, at least until after the release) then you need to add a much wider variety of races to choose from. Isn't it possible to have the old race creation screen without the hundred options provided by the XML files? Then modders can do what they want and people who want to play the game can just do so, with their custom race.

I remember reading that the race creation would end up outside of the main game and I was excited to open up the race creation screen without launching the game and take my time designing my new race. Now, the plan is to have people use Notepad. While I'm capable and experienced with XML, I don't want to "work" to create a race I was able to create in the earlier beta. I just want to make it following the games starting race guidelines.

Just some feedback and suggestions; either add more varied races to choose from at start, or come up with a more user friendly race creation method.This, this, a thousand times this.


It's one thing having a firm framework to work from, allotted points, etc, and *then* start smacking the .xml to do exactly what you want; maybe you want to break the attribute allottment, maybe you want to remove some restriction or stack faction characteristics "illegally". I regularly do in GalCiv2.

It's another thing entirely to build something completely free-form from scratch. I suck at sandcastles.

I totally agree with this.  Not having an in game race editor is not going to be fun for 90% of the people that play the game.  I'm not a modder, but I want to be able to customize my races using a balanced set of 'points', like in the earlier betas.  Right now, I can't even figure out what the +/-'s of the standard races are. 

Reason for Karma (Optional)
Successfully updated karma reason!
August 3, 2010 11:15:09 AM from Elemental Forums Elemental Forums

I too am worried about not having any limitations when creating a new race/faction with XML. It feels like cheating when you don't have any points restrictions and can do whatever you want.

If that is the only way to create a new faction, I will probably have to skip custom faction creation myself (which sucks) and wait for the modding community to post a package of balanced new factions. Meanwhile I'll just have to play with the predesigned ones. This is something I NEVER do in 4x games, I always create my own race in GalCiv etc.

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