.com.unity Forums

.com.unity Forums (http://forum.shrapnelgames.com/index.php)
-   Scenarios, Maps and Mods (http://forum.shrapnelgames.com/forumdisplay.php?f=146)
-   -   Utility: Dom3xTest (http://forum.shrapnelgames.com/showthread.php?t=45908)

Dimaz July 8th, 2010 03:16 PM

1 Attachment(s)
Sometimes it’s necessary to test some battle “offline” before it actually takes place in MP game. How many soldiers you need to capture that tough indy province? How to better position your troops and mages in upcoming big battle with enemy’s army? Will your Tart Cyclop be able to defeat 50 Green Lions and what items he needs to do it?
You can test all this by manually creating .map file putting both side’s armies there, then creating a game, setting the orders and changing the placement, then moving the armies to one province and watching the battle. However, manually adding all the commanders, equipment and units to the map file can take a long time, and you’ll need to move the files here and there after that if you want to test some battle several times. So I was always wondering why there’s no simple tool to automate parts of process and make it faster.
After some particularly long testing session I decided to make it myself. So, the aim of the project:
Create GUI for making small test .map file with 2 armies ready to engage each other. Automate the process of creating the test game and running the test.
Here is version 0.2 of the utility that I called Dominions 3 Extended Tester (dom3xTester). Currently it’s possible to select commanders and give them equipment, units and extra magic, and create a working .map file with nation vs nation or nation vs indies setup.
How to do it:

1) Select commander by unit ID or unit type (possible variants will be listed when you start typing commander’s unit type).
2) Give him items and magic (hope no explanation needed here).
3) Double-click on the tree area to add commander to list.
4) Add more commanders and/or units.
5) Choose nations for both sides or for one if you want to test fight with indies.
6) Select “Make .map file” from File menu.
7) During the process, if you feel your commander “build” can be useful later, you can save it by pressing “Save” button. The commander will appear in small list area and you’ll be able to load him by double-clicking at any time.

After that you can copy the map file (with the name xtestX_vs_Y.map) to dominions map folder and create a game (automation part is not done yet). Select the same nations you did in the dom3xtester (important!) and set both nations to human. Do the usual stuff and start the battle by moving both armies to province 1. Repeat if necessary.

I have to warn that it's really 0.2 version, so many buttons do nothing, probably there are some horrible bugs and so on. If you have good advice or can help with the project somehow, please comment here!
BTW, the program is written in QT/C++, so it should compile without problems on Linux and Macs, too.
Here's the link to get 0.2 version
http://rapidshare.com/files/40576197...st0.2.rar.html

UPDATE 16.12.10
https://rapidshare.com/files/3891512788/0.5.rar - link to latest version (0.5)
Attached dumpItems.rar that should be extracted to data folder for compatibility with CBM 1.71.

Gandalf Parker July 8th, 2010 03:33 PM

Re: Dom3xTest
 
There were a few versions to do this already. But not nearly as complete.
Thank you.

WraithLord July 12th, 2010 11:08 AM

Re: Dom3xTest
 
Dimaz, I really appreciate your dedication for completing this and sharing with the community.

I fear however that this tool may have a significant impact on the MP experience: basically a player with enough time on his hands to do however simulations that he needs would not need much of anything else in order to excel. The only way to counter such advantage is to resort to the same practice.
It's similar in a way to gem gens impact.

I think this is why IW shut down their built in sim in the first place.

Gandalf Parker July 12th, 2010 12:02 PM

Re: Dom3xTest
 
Short Comment:
There is also something to be said for the "social psych". The "social player" tends to have a preference for providing information. Which can help build a community exactly along the line of one that social players love, and their presence should be encouraged. But when those same social players stretch out to further aid the community by automating information (help files, guides, walk-thrus, sims) then it detracts from the socializing community that they desire.

Longer comment:
Business has had many decades of access to psychology papers on demographic types and how to increase or decrease their number. It might not be on purpose that online worlds have shifted to minimal help files with glaring errors causing players to socialize more in the game and to frequent the forums where ads are displayed. It might not be on purpose that fan-created help sites are not prominently stickied on official sites. But it also might not be entirely the mindless stupidity that players often chalk it up to. Everything has its Pros and Cons. (by the way, Experts and Gurus who give answers are another category, and also has pros/cons)

Dimaz July 12th, 2010 03:47 PM

Re: Dom3xTest
 
WL, I remember your opinion as you said it earlier and I had thought about it. However, I cannot agree with you. First, my utility adds nothing that cannot be achieved by other methods, it's just to simplify things a bit. Second, the testing alone definitely cannot win the game for you or even win a war. You still have to plan carefully, talk to people if diplo is allowed, know some tricks and so on. What testing can do, is reduce your losses or in some cases change the outcome of battle or two. You know that I prefer to test many situations, and still I have only one win in HoF. Ano tests almost all battles with indies before attacking, and he plays better than me, and he has 1 win I think, too. So, I'm 99% sure that this tool won't change the general balance between players, as winning one or two extra battles with the help of it doesn't change that much.
In other news, I'm hoping to make 0.3 somewhere this week. I noticed that I forgot to include unit saving to the .map, also, I'm planning to add scenario S/L (full information on both sides) and .map army import if I have time (for maps with already preset armies, it'll be possible to select any province that has an army and it'll be imported).

zzcat July 13th, 2010 12:24 AM

Re: Dom3xTest
 
I'm with Dimaz. Peoples can run simulation through mapediting and debug mod so the tool just allows the people who don't have mapediting knowledge to test their tactics before using them in MP. IMHO it can't affect MP balance in any respect. If you plan less than your opponents, you deserve to lose.

"Victorious warriors win first and then go to war, while defeated warriors go to war first and then seek to win." -Sun-Tzu.

WraithLord July 13th, 2010 04:21 AM

Re: Dom3xTest
 
Dimaz, you have a good point there :)
Very well, I still have some reservations but nonetheless I give my (oh how important ;) ) blessing to your project.

I've even started fiddling with it a bit. If you like I can give you feedback and send files for things that don't work (via email medium I suggest).

Last comment, the tool is impressive, taking into account that it's a one man project. Kudos :)
What IDE did you use to create it?- Visual C++?

Dimaz July 13th, 2010 06:11 AM

Re: Dom3xTest
 
WL, thanks for your blessing :) I hope it includes W9 part so I'll be able to work on the project 1.5 times as fast at least :)
Yes, I want to hear the feedback from you, and anybody else in fact, too. I use Visual Studio for development, but as I said the project is fully portable to other platforms and environments as it's pure QT and doesn't include anything system-specific (yet). If anyone is interested, I can send the complete source (I have to warn, though, that it's even worse than the interface). I already mentioned the general ideas of future development: 1) all .map work 2) automation 3) mod support (currently only units from vanilla can be used, and with the popularity of stuff-adding mods like llama's it's becoming a problem). If somebody wants to help with those things or maybe make better interface or whatever, you're welcome. :)

ano July 13th, 2010 04:25 PM

Re: Dom3xTest
 
I believe it will work just well with the mods wile you know unit id. Let Ember Lord be just an anonymous unit with id XXX. The most commonly used mods may be added just plainly, as an option, while for the rarer ones you may just use an id.

Dimaz July 13th, 2010 05:10 PM

Re: Dom3xTest
 
No, it uses the Edi's db to know the slot and naming information, so currently you cannot use mod units (you can add some other unit with similar slots and then change the id inside map file, obviously).

Dimaz July 15th, 2010 01:58 PM

Re: Dom3xTest
 
Version 0.3 is ready.
CHANGES:
Units are correctly added to .map file.
Units/commanders can be removed from the tree.
Units/commanders in the tree can be unselected by clicking on them second time, so the right panel can be changed without influencing the tree.
Some minor changes.
NEW STUFF
Full setup for both sides can be saved and loaded with Save/Load Scenario commands in File menu.
The side can be imported from existing .map file: after selecting map, you choose side and the province number (only provinces containing preset armies can be selected). Currently only #commander, #units and #additem map tags are taken into account.
Link
http://rapidshare.com/files/40713623...st0.3.rar.html

Gandalf Parker July 15th, 2010 03:04 PM

Re: Dom3xTest
 
If you chat with LLamaBeast he might be able to help you out with the game automation. The PbEM start-and-quit routine might work for you also.

Dimaz July 29th, 2010 02:56 PM

Re: Dom3xTest
 
Well, I've finished 0.5 version of the dom3tester. I worked pretty hard and added some nice features:
1) Quick test option. Now, after armies setup, you can choose Quick test from file menu instead of Create .map file. Then if you have predesigned pretenders for choosen nations, you will be able to choose the one you need (useful for testing sacreds where bless is important), otherwise it will use supplied random pretender. After pretender selection the game will be created (it requires some 43xxx tcp port to be free cause the game is created in tcp server mode), and after that dominions are launched in your game so you'll get Select nation screen a few seconds after you started - no manual file moving is needed anymore.
2) Now, you can ask, what to do if I want to test with CBM switched on or I want to include EDM creatures in my test. Well, I worked even harder and added mod support to the utility. In Options/Mods you can select the mods you need for particular test (currently the choice is not saved after program restart) and you'll be able to select mod creatures and items immediately, and the game will be created with your choosen mods. I tested it with CBM, EDM and debug mods and it works fine; if you have problems with some particular mod just let me know and I'll look into it. Mod nations are not currently supported, unfortunately, but the units from them still can be used I think. However, please don't disable previously enabled mods after you used some of the stuff from them - most probably the program will crash, I hadn't time to add all the necessary checks in it.
Download here:
http://rapidshare.com/files/409844950/0.5.rar.html

Action August 1st, 2010 12:47 AM

Re: Dom3xTest
 
This is extremely useful, and very well done.

Excellent work.

One question: when I go to do a Quick Test, it allows me to select my pretenders, but after that nothing happens, the program doesn't crash, but it doesn't go any further either.

Does that indicate a problem with ports not being open?

The normal create map functionality works fine.

Dimaz August 1st, 2010 04:27 PM

Re: Dom3xTest
 
Thanks! I'm glad it's useful for others too, and it's certainly useful for me :) About your question:
1) Check that you have Mini.tga, I forgot to include it in the release.
2) Check if "Quick test" creates game called "xtest". First pretender files are copied to this folder and then the dom3 server is launched; if everything is OK it should create fatherland and .trn and .2h files. If the files are not created, you either miss the map or the port is not free. Also, check that the path to dom3 is correct (it's in .ini file in the tester folder), it should point to the dom3 folder.
I hope to create some error feedback when I have time; currently it's still 0.5 and I was mainly interested in functionality and not usability.
Also, the dom3 executable shouldn't be renamed.

Numahr August 10th, 2010 05:07 AM

Thanks for this very useful tool.
One question: is it possible to give magic research to any side? For example to give conjuration 4, so that we can script the spell we want to try? I see some buttons on top but they do not seem active.

Dimaz August 14th, 2010 01:48 AM

Re: Dom3xTest
 
I planned this feature (research levels) from the beginning but hadn't time to implement it yet. So the controls are disabled currently. I'll try to add it when I have time.

pyg August 14th, 2010 11:47 PM

Re: Dom3xTest
 
Quote:

Originally Posted by Dimaz (Post 751325)
BTW, the program is written in QT/C++, so it should compile without problems on Linux and Macs, too.
Here's the link to get 0.2 version
http://rapidshare.com/files/40576197...st0.2.rar.html

Couple of hints: 1) Include source so people using Linux and Macs can check it out (also build scripts). 2) Keep the latest version linked in the OP. Also shrapnel can host attachments such as this quite nicely.

Dimaz December 16th, 2010 07:33 AM

Re: Dom3xTest
 
Added attachment to first post with the dumpItems.txt file that should be placed to data folder to work with CBM 1.71.
Also I'll try to work a bit on this project after New Year, if you have ideas what should be improved, please tell me.

Numahr December 17th, 2010 03:14 AM

Re: Dom3xTest
 
I am aware that this may be complicated to implement; but I still suggest for inclusion of level researched. There is no significan battle without magic; but impact of magic is totally different depending on whether one casts mind burn or master enslave.

Dimaz December 17th, 2010 03:19 AM

Re: Dom3xTest
 
It is planned, that's why the levels are present in the interface.

Lihaässä January 9th, 2011 07:38 AM

Re: Dom3xTest
 
Thanks for a good tool! Could it be possible to allow armies use all research possible until you'll find a way how to determine specific levels of research in each path?

Also it would be really useful to give gems to execute the spells.

Dimaz January 9th, 2011 11:36 AM

Re: Dom3xTest
 
Thanks :)
I use debug mod for both this situations. First it sets all the spells at research level 0, and second it adds the 1-pearl version of wish that allows to get all the gems you want.

John Agartha May 10th, 2011 04:55 PM

Re: Dom3xTest
 
Great utility! Thanks for posting it.

Have you made any further progress on adding magic/research to the program?

Gandalf Parker May 10th, 2011 05:51 PM

Re: Dom3xTest
 
now THAT is the way to ask for things.
Where were you when the Devs were still around?

Dimaz May 11th, 2011 02:00 AM

Re: Dom3xTest
 
I haven't worked on it much after 0.5 release and adapting it to CBM 1.7. I still hope to finish what I had planned originally as I use it too and want some more functions (I think I'm more interested in running the same battle several times automatically than in research limits).

Dimaz September 30th, 2012 02:13 AM

Re: Dom3xTest
 
Someone informed me that the download link is dead, here's the new one.
https://rapidshare.com/files/3891512788/0.5.rar


All times are GMT -4. The time now is 09:40 PM.

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