AI changes on Windows
Moderator: Forum Moderators
AI changes on Windows
Have anyone worked with Wesnorth on Windows?
I am having problems to try AI modifications.
First: I am using this example of how to execute the game from the terminal:
http://forums.wesnoth.org/viewtopic.php?f=10&t=38344
I am trying to execute the following line on terminal:
If I remove the "--nogui" it seems to work allright, but with the "--nogui" it is not showing on terminal who have winned the game.
I know that on Windows the data is writed on the file "stdout.txt" and not on terminal. But, it just write on the file if I run the terminal as administrator.
Second: Another problem is that I have changed the AI for my custom AI: "jieverson.cfg", but it is not working.
My custom file is at "C:\Users\Jiéverson\Documents\My Games\Wesnoth1.11\data\add-ons\AI-demos\ais\jieverson.cfg"
The file is current just a copy and paste of the "ai_grunt-rush-Freelands-S1", but it don't seems to work.
The result is always "winner: 1 (using ai_default_rca)" or "winner: 2 (using ai_default_rca)".
I tried using the Fred ai:
But, the result still say that the winner have used the "ai_default_rca".
I am having problems to try AI modifications.
First: I am using this example of how to execute the game from the terminal:
http://forums.wesnoth.org/viewtopic.php?f=10&t=38344
I am trying to execute the following line on terminal:
Code: Select all
wesnoth -m --controller 1:ai --controller 2:ai --parm 1:fog:no --parm 2:fog:no --parm 1:gold:100 --parm 2:gold:100 --parm 1:village_gold:2 --parm 2:village_gold:2 --ai-config 1:jieverson.cfg --ai-config 2:jieverson.cfg --side 1:Northerners --side 2:Rebels --nogui
I know that on Windows the data is writed on the file "stdout.txt" and not on terminal. But, it just write on the file if I run the terminal as administrator.
Second: Another problem is that I have changed the AI for my custom AI: "jieverson.cfg", but it is not working.
My custom file is at "C:\Users\Jiéverson\Documents\My Games\Wesnoth1.11\data\add-ons\AI-demos\ais\jieverson.cfg"
The file is current just a copy and paste of the "ai_grunt-rush-Freelands-S1", but it don't seems to work.
The result is always "winner: 1 (using ai_default_rca)" or "winner: 2 (using ai_default_rca)".
I tried using the Fred ai:
Code: Select all
wesnoth -m --controller 1:ai --controller 2:ai --parm 1:fog:no --parm 2:fog:no --parm 1:gold:100 --parm 2:gold:150 --parm 1:village_gold:2 --parm 2:village_gold:2 --ai-config 1:~add-ons/AI-demos/ais/ai_grunt-rush-Freelands-S1.cfg --side 1:Northerners --side 2:Rebels --nogui
Re: AI changes on Windows
There is a whole topic dedicated to this particular point in Technical Support.jieverson wrote:I know that on Windows the data is writed on the file "stdout.txt" and not on terminal. But, it just write on the file if I run the terminal as administrator.
Author of the unofficial UtBS sequels Invasion from the Unknown and After the Storm.
-
- Inactive Developer
- Posts: 2461
- Joined: August 15th, 2008, 8:46 pm
- Location: Germany
Re: AI changes on Windows
Basically: no. Almost all development takes place on *nix machines, which generally means that the whole project doesn't work too well on other systems, including, but not limited to, the main executable, wesnothd, python tools, perl tools etc.jieverson wrote:Have anyone worked with Wesnorth on Windows?
I also never used wesnoth from command line (not on windows or at all), so I would expect bugs. Best you can do is copy the exact command from mattsc (who worked most with it lately and reported a number of bugs, but all on MacOS, most of them system independent however) and hope that it works.
Needing to be administrator is an acceptable restriction however.
projects (BfW 1.12):
A Simple Campaign: campaign draft for wml starters • Plan Your Advancements: mp mod
The Earth's Gut: sp campaign • Settlers of Wesnoth: mp scenario • Wesnoth Lua Pack: lua tags and utils
updated to 1.8 and handed over: A Gryphon's Tale: sp campaign
A Simple Campaign: campaign draft for wml starters • Plan Your Advancements: mp mod
The Earth's Gut: sp campaign • Settlers of Wesnoth: mp scenario • Wesnoth Lua Pack: lua tags and utils
updated to 1.8 and handed over: A Gryphon's Tale: sp campaign
Re: AI changes on Windows
I hope you meant ‘unacceptable’.Anonymissimus wrote:Needing to be administrator is an acceptable restriction however.
Author of the unofficial UtBS sequels Invasion from the Unknown and After the Storm.
Re: AI changes on Windows
Yes! It's unacceptable. I am a windows user (I am a .NET developer and a hardcore gamer when I am not working, so windows is the only option).shadowmaster wrote:I hope you meant ‘unacceptable’.Anonymissimus wrote:Needing to be administrator is an acceptable restriction however.
But thanks to you guys, I have solved the problem.
I just found "stderr.txt" on my Virtual Store (C:\Users\<My User>\AppData\Local\VirtualStore\Program Files (x86)\Battle of Wesnoth), and then have deleted it.
After deleting the file, the original (on c:\Program Files (x86)\Battle of Wesnoth) start to be updated.
Another detail was that, to execute a custon AI (like mine, Ron or Fred) I had to copy the folder "AI-demos" from "My Documents\My Games\Wesnoth\data\add-ons" to "C:\Users\<My User>\AppData\Local\VirtualStore\Program Files (x86)\Battle of Wesnoth\userdata\data\add-ons".
I realized the Fred Rush is biiiiiig slow. So, I will do my experiments based on Ron Rush.
Thanks to all.... if I have more problems or do another discovery, I will contact u all
Re: AI changes on Windows
Yes, Fred is not in a good shape at the moment. If you look at my recent commits, they are all geared toward speeding things up. Of course, one of the reasons why I want to speed things up is so that I can add more evaluations, meaning Fred will always be slower than Ron - but hopefully not this much slower.jieverson wrote:I realized the Fred Rush is biiiiiig slow. So, I will do my experiments based on Ron Rush.
I'm glad to hear that you got your problems solved.
SP campaigns: Galuldur's First Journey (1.12 & 1.14) & Grnk the Mighty (1.10 & 1.12)
AI experiments: Micro AIs (wiki, forum thread, known/fixed bugs), Fred, AI-demos add-on
AI experiments: Micro AIs (wiki, forum thread, known/fixed bugs), Fred, AI-demos add-on
Re: AI changes on Windows
Maybe should pin my solution to this topic:
http://forums.wesnoth.org/viewtopic.php?f=4&t=23894
http://forums.wesnoth.org/viewtopic.php?f=4&t=23894
Re: AI changes on Windows
I don’t use Windows, but if my memory serves the problem you are encountering here is that you are not passing a few additional command line parameters to make sure Wesnoth usesjieverson wrote:Another detail was that, to execute a custon AI (like mine, Ron or Fred) I had to copy the folder "AI-demos" from "My Documents\My Games\Wesnoth\data\add-ons" to "C:\Users\<My User>\AppData\Local\VirtualStore\Program Files (x86)\Battle of Wesnoth\userdata\data\add-ons".
...\My Documents\My Games\Wesnoth
as the user preferences/data directory instead of the built-in fallback of <wherever Wesnoth.exe is located>\userdata
. You may be able to determine what those parameters are by looking at the properties of the Start Menu or desktop shortcut originally created by the Wesnoth installer — then you could create a .cmd
/.bat
file for easier command line invocation in the future.Author of the unofficial UtBS sequels Invasion from the Unknown and After the Storm.
Re: AI changes on Windows
Nice, I will try it at night!
Re: AI changes on Windows
Ty shadowmaster! It have worked nice =]shadowmaster wrote:I don’t use Windows, but if my memory serves the problem you are encountering here is that you are not passing a few additional command line parameters to make sure Wesnoth usesjieverson wrote:Another detail was that, to execute a custon AI (like mine, Ron or Fred) I had to copy the folder "AI-demos" from "My Documents\My Games\Wesnoth\data\add-ons" to "C:\Users\<My User>\AppData\Local\VirtualStore\Program Files (x86)\Battle of Wesnoth\userdata\data\add-ons"....\My Documents\My Games\Wesnoth
as the user preferences/data directory instead of the built-in fallback of<wherever Wesnoth.exe is located>\userdata
. You may be able to determine what those parameters are by looking at the properties of the Start Menu or desktop shortcut originally created by the Wesnoth installer — then you could create a.cmd
/.bat
file for easier command line invocation in the future.
The param is "--config-dir Wesnoth1.11"
Are there a way to execute the game 500 times to compare the different AIs?
- Alarantalara
- Art Contributor
- Posts: 786
- Joined: April 23rd, 2010, 8:17 pm
- Location: Canada
Re: AI changes on Windows
Check out the files in utils/ai_test (included in source distribution but not in all (any?) binary packages).
Alternatively, SeattleDad created a modification of the above to deal with the commandline bugs in 1.10. You can find it in the AI-demos add-on under ml_utils.
Alternatively, SeattleDad created a modification of the above to deal with the commandline bugs in 1.10. You can find it in the AI-demos add-on under ml_utils.