.com.unity Forums
  The Official e-Store of Shrapnel Games

This Month's Specials

Raging Tiger- Save $9.00
winSPMBT: Main Battle Tank- Save $6.00

   







Go Back   .com.unity Forums > Illwinter Game Design > Dominions 3: The Awakening > Scenarios, Maps and Mods

Reply
 
Thread Tools Display Modes
  #1  
Old September 26th, 2008, 07:21 AM

llamabeast llamabeast is offline
National Security Advisor
 
Join Date: Nov 2006
Location: Oxford, UK
Posts: 5,921
Thanks: 194
Thanked 855 Times in 291 Posts
llamabeast will become famous soon enoughllamabeast will become famous soon enough
Default Script for combining multiple mods

I proudly present a perl script for combining multiple mods and eliminating any clashes. I expect it to be useful for games where you want to play with a number of mod nations which might otherwise clash. It's quite a big, lengthy script, and it has a lot of built-in knowledge of how mods work. So, barring any typos (always a possibility), I'm fairly sure it can handle anything that can be thrown at it without producing any bugs in the resulting megamod.

The usage is:

combineMods era mod1.dm mod2.dm ... modN.dm newModName

e.g. combineMods 2 TombKings.dm vaetti.dm MagicMod

This will produce a mod called MagicMod.dm which will include the Tomb Kings and the vaetti, both in the middle era.

The era has to be a number between 1 and 3 (1=early etc). All the mod nations included in the combined mod will be set to be in that era, so that they can play together.

You can combine any number of mods with this script, and it's also fine to include mods which modify vanilla nations, e.g. CBM.

For those who haven't used a perl script before: On Linux or, I think, Mac, you need to open a terminal and type "perl combineMods ..." where ... is all the parameters, as given above. On Windows I believe you need to download ActivePerl. I think it's free.

Here it is:
Attached Files
File Type: zip combineMods.zip (4.8 KB, 357 views)
__________________
www.llamaserver.net
LlamaServer FAQ
My mod nations: Tomb Kings and Vampire Counts
A compilation of high quality mod nations: Expanded Nations Packs

Last edited by llamabeast; May 19th, 2009 at 07:17 PM..
Reply With Quote
The Following 10 Users Say Thank You to llamabeast For This Useful Post:
  #2  
Old September 26th, 2008, 07:28 AM
Edratman's Avatar

Edratman Edratman is offline
First Lieutenant
 
Join Date: May 2007
Location: Reading, PA
Posts: 724
Thanks: 93
Thanked 37 Times in 27 Posts
Edratman is on a distinguished road
Default Re: Script for combining multiple mods

WOW.

As someone who usually plays 5 to 10 mod nations at a time, this is fantastic. I've had to manually change numbers throughout and I lost the takeout menu on which I had scribbled the new numbers.

Reply With Quote
  #3  
Old September 26th, 2008, 08:46 AM

Sombre Sombre is offline
BANNED USER
 
Join Date: Feb 2007
Posts: 5,463
Thanks: 165
Thanked 324 Times in 190 Posts
Sombre is on a distinguished road
Default Re: Script for combining multiple mods

Can it handle all the different shapes?

Firstshape, secondshape, tmpshape, forestshape, plainshape etc? Summon, call allies, domsummon?

What does it do with nametypes?
Reply With Quote
  #4  
Old September 26th, 2008, 09:03 AM

llamabeast llamabeast is offline
National Security Advisor
 
Join Date: Nov 2006
Location: Oxford, UK
Posts: 5,921
Thanks: 194
Thanked 855 Times in 291 Posts
llamabeast will become famous soon enoughllamabeast will become famous soon enough
Default Re: Script for combining multiple mods

Yep yep, it can handle all of them. It can handle all commands in Edi's unofficial modding manual (which I am assuming is complete).

With nametypes, it handles them sensibly, i.e. it keeps track of nametypes from different mods, renumbers them and makes sure each unit is pointing to the correct nametype. However, it obviously needs to choose which vanilla nametypes to overwrite. Near the top of the mod is an ordered list of which nametypes it should overwrite. I chose something like 127, 128, 150, 149, 148, 147 etc.. Obviously it's not ideal to overwrite any apart from 127 and 128, but generally I think that it's unlikely to be noticeable.
__________________
www.llamaserver.net
LlamaServer FAQ
My mod nations: Tomb Kings and Vampire Counts
A compilation of high quality mod nations: Expanded Nations Packs
Reply With Quote
  #5  
Old September 26th, 2008, 09:16 AM

llamabeast llamabeast is offline
National Security Advisor
 
Join Date: Nov 2006
Location: Oxford, UK
Posts: 5,921
Thanks: 194
Thanked 855 Times in 291 Posts
llamabeast will become famous soon enoughllamabeast will become famous soon enough
Default Re: Script for combining multiple mods

Oh, hang on. firstshape etc all currently assume that you've already defined the monster you want to change to. But of course that won't always be true.

Hmm. I will have a think about that, and try to fix it this afternoon.
__________________
www.llamaserver.net
LlamaServer FAQ
My mod nations: Tomb Kings and Vampire Counts
A compilation of high quality mod nations: Expanded Nations Packs
Reply With Quote
The Following User Says Thank You to llamabeast For This Useful Post:
  #6  
Old September 26th, 2008, 09:48 AM

Xietor Xietor is offline
Lieutenant General
 
Join Date: Feb 2007
Location: New Orleans
Posts: 2,741
Thanks: 21
Thanked 28 Times in 17 Posts
Xietor is on a distinguished road
Default Re: Script for combining multiple mods

Thanks Llamabeast!
__________________
"War is an art and as such is not susceptible of explanation by fixed formula."
- General George Patton Jr.
Reply With Quote
  #7  
Old September 26th, 2008, 12:27 PM

llamabeast llamabeast is offline
National Security Advisor
 
Join Date: Nov 2006
Location: Oxford, UK
Posts: 5,921
Thanks: 194
Thanked 855 Times in 291 Posts
llamabeast will become famous soon enoughllamabeast will become famous soon enough
Default Re: Script for combining multiple mods

Okay, I have it very nearly fixed, but have run out of time before some friends who are staying for the weekend turn up. I'll re-upload it on Sunday or Monday.
__________________
www.llamaserver.net
LlamaServer FAQ
My mod nations: Tomb Kings and Vampire Counts
A compilation of high quality mod nations: Expanded Nations Packs
Reply With Quote
  #8  
Old September 26th, 2008, 12:45 PM
Edratman's Avatar

Edratman Edratman is offline
First Lieutenant
 
Join Date: May 2007
Location: Reading, PA
Posts: 724
Thanks: 93
Thanked 37 Times in 27 Posts
Edratman is on a distinguished road
Default Re: Script for combining multiple mods

I'm very interested in seeing how you handle firstshape. It seems to be quite a formidible task, at least to my limited knowledge about the subject.
Reply With Quote
  #9  
Old October 4th, 2008, 05:03 AM

llamabeast llamabeast is offline
National Security Advisor
 
Join Date: Nov 2006
Location: Oxford, UK
Posts: 5,921
Thanks: 194
Thanked 855 Times in 291 Posts
llamabeast will become famous soon enoughllamabeast will become famous soon enough
Default Re: Script for combining multiple mods

Okay! Reuploaded at last! See the first post.

The new version is significantly more cunning, and once more I don't _know_ of anything it can't handle. Summons, sites, nametypes, it's all in. The script is now a beast at about 900 lines (many of which are repetitious to be fair).

Also, the resultant mod is somewhat self-documenting. If you right-click on it from the Dom3 "Mod preferences" screen it will list which mods it includes, along with the version number of each. If you look at the mod file you'll find it lists near the top the ID number ranges that it uses.
__________________
www.llamaserver.net
LlamaServer FAQ
My mod nations: Tomb Kings and Vampire Counts
A compilation of high quality mod nations: Expanded Nations Packs
Reply With Quote
The Following 3 Users Say Thank You to llamabeast For This Useful Post:
  #10  
Old October 4th, 2008, 06:05 AM
Edratman's Avatar

Edratman Edratman is offline
First Lieutenant
 
Join Date: May 2007
Location: Reading, PA
Posts: 724
Thanks: 93
Thanked 37 Times in 27 Posts
Edratman is on a distinguished road
Default Re: Script for combining multiple mods

Thank you very much. I plan on giving it a test spin tonight when I have more time.

Today is one of my "Give-in-to-the-old-ball-and-chain" days. All of us married chaps must concede a couple of them a year. It is a day dedicated to doing things where she offers up the idea (sic), and the only thing I have to do is add the time, labor and money.

Not much different than all the threads where someone reads a book and then suggests that someone can feel free to make a mod nation based on his brillant thoughts.

Well, actually there is a difference; I can ignore those threads forever without enduring relentless, painful nagging.
Reply With Quote
Reply

Bookmarks


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On

Forum Jump


All times are GMT -4. The time now is 06:19 AM.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©1999 - 2024, Shrapnel Games, Inc. - All Rights Reserved.