|
|
|
|
|
July 3rd, 2012, 04:18 PM
|
Second Lieutenant
|
|
Join Date: Aug 2010
Posts: 546
Thanks: 100
Thanked 10 Times in 8 Posts
|
|
Re: Single Player Improvement
Quote:
Originally Posted by Fantomen
Well, basically it would require a program that could decipher .trn files properly, and then output a correct 2h file. Or in other words, mimic the game client
|
I don't get this. I understand you're proposing an external program to read in the .trn files, then have a think like an external human player and produce its own move. That's just some AI, shouldn't be too difficult. What I don't get is: how are you going to get the external program to actually click the buttons and drag the units to do its move and so produce the 2h file? That seems much harder....
|
July 3rd, 2012, 04:32 PM
|
|
Shrapnel Fanatic
|
|
Join Date: Oct 2003
Location: Vacaville, CA, USA
Posts: 13,736
Thanks: 341
Thanked 479 Times in 326 Posts
|
|
Re: Single Player Improvement
Personally I think it would be easier with a macro program which is designed to do that very thing. They are usually used by advanced players in online games. Particularly online worlds to do the "grinding" (doing the same task repeatedly to gain levels). Macro recording software are designed so that you can write extensive files that will play the game for you. Then it runs on top of your game doing the mouse moves, the clicks, hitting the keys, etc. This way you could concentrate on the player part, and leave things like files and file transfer to host for the Dom3 game to do. No mucking around internally
My personal favorite is AutoHotKey which I use to give Dom3 capabilities that the devs havent put in. Most wouldnt call me a programmer but I have gotten it to do some fun things. I think a programmer could do quite abit with it.
http://www.autohotkey.com/docs/commands.htm
__________________
-- DISCLAIMER:
This game is NOT suitable for students, interns, apprentices, or anyone else who is expected to pass tests on a regular basis. Do not think about strategies while operating heavy machinery. Before beginning this game make arrangements for someone to check on you daily. If you find that your game has continued for more than 36 hours straight then you should consult a physician immediately (Do NOT show him the game!)
|
July 3rd, 2012, 05:25 PM
|
Corporal
|
|
Join Date: Aug 2011
Posts: 178
Thanks: 1
Thanked 47 Times in 8 Posts
|
|
Re: Single Player Improvement
Trouble is, autohotkey is not good at collecting information from the game. It would be a fraught task to program the collection of all the information needed by the AI to make decisions (reading the screen, counting troops, reading army reports). Probably easier to rebuild a picture of the gamestate from binary data in the save file (not thats its simple.. I've no experience of reverse engineering).
It might be realistic to use autohotkey or similar to give orders. With all the information down to commander numbers it should be relatively straight forward to predict the layout of the interface.
|
July 3rd, 2012, 05:53 PM
|
|
Shrapnel Fanatic
|
|
Join Date: Oct 2003
Location: Vacaville, CA, USA
Posts: 13,736
Thanks: 341
Thanked 479 Times in 326 Posts
|
|
Re: Single Player Improvement
Glean info from the debug log?
|
July 3rd, 2012, 06:21 PM
|
|
Colonel
|
|
Join Date: Nov 2008
Posts: 1,735
Thanks: 272
Thanked 120 Times in 93 Posts
|
|
Re: Single Player Improvement
Quote:
Originally Posted by JonBrave
Quote:
Originally Posted by Fantomen
Well, basically it would require a program that could decipher .trn files properly, and then output a correct 2h file. Or in other words, mimic the game client
|
I don't get this. I understand you're proposing an external program to read in the .trn files, then have a think like an external human player and produce its own move. That's just some AI, shouldn't be too difficult. What I don't get is: how are you going to get the external program to actually click the buttons and drag the units to do its move and so produce the 2h file? That seems much harder....
|
You are joking right? The external program just generates the .2h file.
|
July 3rd, 2012, 07:15 PM
|
|
Shrapnel Fanatic
|
|
Join Date: Oct 2003
Location: Vacaville, CA, USA
Posts: 13,736
Thanks: 341
Thanked 479 Times in 326 Posts
|
|
Re: Single Player Improvement
We really should split this conversation to its own thread, and return this thread to the OT about his excellent program.
|
The Following 2 Users Say Thank You to Gandalf Parker For This Useful Post:
|
|
July 3rd, 2012, 10:13 PM
|
First Lieutenant
|
|
Join Date: Jan 2011
Posts: 754
Thanks: 72
Thanked 12 Times in 11 Posts
|
|
Re: Single Player Improvement
First up, I've had a play with the program - it works very nicely, so thanks :-)
I'd really like to be able to easily include CBM in particular. The ability to include other mods would be a nice bonus, though. I will have a look and see if I can work out how to do this for myself in case you don't have time.
Quote:
Originally Posted by JonBrave
Quote:
Originally Posted by Fantomen
Well, basically it would require a program that could decipher .trn files properly, and then output a correct 2h file. Or in other words, mimic the game client
|
I don't get this. I understand you're proposing an external program to read in the .trn files, then have a think like an external human player and produce its own move. That's just some AI, shouldn't be too difficult. What I don't get is: how are you going to get the external program to actually click the buttons and drag the units to do its move and so produce the 2h file? That seems much harder....
|
Basically, they are "externalising" the AI logic. The flow goes something like this:
1) Dom3 server generates .trn file
2) "Robot Artifical Intelligence (AI)" reads .trn file to understand the current situation
3) "Robot AI" decides on moves based on step 2) - hopefully in a cleverer, or at least different, fashion to what the internal Dom3 AI does
4) "Robot AI" generates .2h file containing its moves
5) File is submitted to the Dom3 server
At the moment, you as a player do steps 2) through 4) using the Dom3 client. But in the proposed solution, the Dom3 client never comes into play - the external "Robot AI" does all of that, without ever opening Dom3 - thus no need to touch buttons, move things etc.
This is being proposed as a way of allowing the current AI in Dom3 (which some people have an issue with) to be replaced, without having to modify the actual Dom3 code base.
I personally think that this is an excellent idea. It does of course depend on having a good understanding of the formats for both .trn and .2h files, but since it doesn't remove the need for Dom3 licences from a player's perspective I am cautiously optimistic that it would be OK with the devs (never having dealt with them in person).
|
July 4th, 2012, 01:08 PM
|
|
Major
|
|
Join Date: Feb 2009
Location: Me a viking
Posts: 1,012
Thanks: 81
Thanked 122 Times in 73 Posts
|
|
Re: Single Player Improvement
I believe the one major benefit would be that you could integrate it into a server, like llamaserver, and have it take care of abandoned nations in mp games without actually turning them ai, so if you find a sub you just switch back to human control. It could work as easy as having a specific mail account for the robot, like domrobot@exampleserver.net, which you assign to abandoned nations rather than turning ai.
__________________
Voice of ***** and her spicy crew!
|
July 4th, 2012, 04:26 PM
|
Second Lieutenant
|
|
Join Date: Aug 2010
Posts: 546
Thanks: 100
Thanked 10 Times in 8 Posts
|
|
Re: Single Player Improvement
The external AI program will never get written. Without the actual codebase of the real Dom3, the amount of work you'd have to do just to generate consistently legal moves would be huge, before you even get to producing a sensible and better AI opponent. Or, Andy Murray could win Wimbledon this year.
|
July 5th, 2012, 04:51 AM
|
First Lieutenant
|
|
Join Date: Jan 2011
Posts: 754
Thanks: 72
Thanked 12 Times in 11 Posts
|
|
Re: Single Player Improvement
Quote:
Originally Posted by JonBrave
The external AI program will never get written. Without the actual codebase of the real Dom3, the amount of work you'd have to do just to generate consistently legal moves would be huge, before you even get to producing a sensible and better AI opponent. Or, Andy Murray could win Wimbledon this year.
|
Most likely correct. It is still a good idea, however.
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is On
|
|
|
|
|