markh
Conscript
Posts: 6
Joined: Sat Apr 04, 2009 4:17 pm

Dear Calvinus - question about files editable in excel

Sat Apr 04, 2009 4:50 pm

Dear Calvinus (or anyone else who has the answers!)

I have just acquired WW1 and I am still in the process of getting to grips with it. One of the game's features that got me interested in it was the statement on the Matrixgames website that files were editable in Excel - I very much enjoy creating and testing "what if" type scenarios. I feel that they add to the replayablity of games.

In that context, I looked at the modding folder\files. In

C:\World War One\Modding\Scenarios\GrandCampaignTwo\Nations

I noticed that the Nations CSV file contained data relating to the various Nations' - National Will, recruitment points, munitions, treasury, civil production etc ... I wanted to change and adjust some of these figures to see what a difference they made to the game - I was using some figures obtained from Patrick Kennedy's book "The Rise and Fall of Great Powers".

I adjusted the figures and saved the changes in the file. I then accessed the game and went to the appropriate scenario - Grand Campaign Two. When the scenario loaded I saw that there had been no change to the scenario's original data - i.e. national will, recruitment points, munitions or treasury, despite the numbers having been changed by me in the relevant file in the modding folder of the game.

What have I done wrong? In fact, can this basic data be edited to play "what if" type scenarios - I sincerely hope so. I am really looking forward to using this type of feature.

In addition, I was surprised to see what I think seems to be the relatively few British corps and armies represented in the game. Wikipedia indicates that while 8.41 million French and French colonials were mobilized in WW1, 8.95 million British Empire subjects were mobilized. The records seem to indicate that 7.6 million UK, Canadian and ANZAC military personnel served in France and Belgium - which is almost as many as French. So why does there seem to be such a large difference when you compare the English and French corps listed in the games CSV files - and can these be amended?

Regards, and thank you in advance.

Mark

User avatar
calvinus
Posts: 4681
Joined: Mon Dec 19, 2005 4:52 pm
Location: Italy
Contact: Website

Sat Apr 04, 2009 5:30 pm

Ok, quick answer:

When you have edited the XLS file, you have to save also the CSV file and copy it onto the proper directory, inside the Data folder...

Example:

Modding\Scenarios\GrandCampaignFour\Nations.xls

has its corresponding game DB in:

Data\DB\Scenarios\GrandCampaignFour\Nations.csv


Indeed the game (WW1.exe) loads and uses the CSV files, not the XLS files, that are for your editing job... ;)

For that concerns the UK units, this setup comes from the boardgame La Grande Guerre... so please refer to Philippe Thibaut.

Thanks,
Calvinus.

User avatar
calvinus
Posts: 4681
Joined: Mon Dec 19, 2005 4:52 pm
Location: Italy
Contact: Website

Sat Apr 04, 2009 5:31 pm

Moved here because it refers to Mondding.

markh
Conscript
Posts: 6
Joined: Sat Apr 04, 2009 4:17 pm

Sat Apr 04, 2009 7:32 pm

Hi Calvinus

Thanks for your prompt reply.

I tried editing the Nations.xls file in the moddding folder, then saving it as a Nations.CSV file. I then placed that file saved as a CSV into -

Data\DB\Scenarios\GrandCampaignFour folder (essentially replacing the existing Nations.csv file) as you suggested.

I am afraid that it did not work.

USING THE FILES CONVERTED FROM XLS TO CSV

The first hint of a problem occurred when the scenario was loading. In the page where there is a table with essentially three columns, with the scenarios listed on the left column, the major middle column has the words "World War One" on the top. The next row shows the words "Central Powers" and " Entente" and has each sides helmets- however, the flags of the various nations that are normally there were missing, and so were the flags of the neutral nations.

The scenario (with the modified Nations.CSV file) attempted to load - but it fails and a standard Microsoft box error box came up indicating that an error has occurred and asking if I wish to either try and "debug", send a crash report to Microsoft or " Do Not Send". In summary the changed data in the CSV file appears to have created some form of fundamental incompatibility resulting in a crash.

ATTEMPTING TO AMEND THE ACTUAL ORIGINAL GAME CSV FILES

Next, I went to the actual original Nations.CSV file in the Data\DB\Scenario folder and amend the CSV file directly (after saving and moving the original file). After amending the CSV file, I tried to load the game. I then got an error message that said

Microsoft VisualC++ Debug Library
Debug assertion failed
Program: C:\Program Files\World War One\WW1.exe

File e:\porgetti\games\WW1\sources\interface\mapwondow\guis\guimaptop.cpp line:69

Are these failures in my attempts to mod because there is an compatibility issues - i.e while it may be fine to amend a files such as Nations, there may be some other files to which the data must reconcile before it loads and this is the reason why the game is crashing when it tries to load a modified scenario.

I sincerely hope not! One of the real pluses for me from a game like "Hearts of Iron - DoomsDay" was that it had very simple files in Excel format that could be varied, edited and saved and which allowed for an endless varities of scenarios as to how the game could work. I could edit the key variables of any nation - such as treasury, munitions and arms etc ...

I was really hoping that reference to files editable in Excel meant that WW1 was also equally simply editable to allow for infinite different "what if" outcomes. in the same way HOI2 DD was.

Please let me know if you can think of how these Nations variables can be modded and edited and played.

Regards

Mark

tagwyn
AGEod Guard of Honor
Posts: 1220
Joined: Tue Apr 17, 2007 4:09 pm

Sat Apr 04, 2009 11:47 pm

How is the graphics mod coming? Anyone? t

User avatar
calvinus
Posts: 4681
Joined: Mon Dec 19, 2005 4:52 pm
Location: Italy
Contact: Website

Sun Apr 05, 2009 9:45 am

Ok Markh, so I suppose there is something in the .SCN file that is not "coherent" to what you modded in the Nations.CSV file. This could be an explanation. Post here your modded files and I will check them as soon I can.

Edit: the SCN files can be found in the Data\Scenario folder.

markh
Conscript
Posts: 6
Joined: Sat Apr 04, 2009 4:17 pm

Mon Apr 06, 2009 3:52 pm

Hi Calvinus

I am very grateful for your offer of assistance, however, your website will NOT allow me to attach the modded XLS file that I have saved in a CSV file format to this reply. When I try, the website states that there has been an "upload error" and says that CSV format is an "invalid file type".

I am therefore attaching the modded XLS file.

To save time and to enable you to identify my modded changes quickly - the changes are as follows:

I just wanted to try a very basic mod where I simply change the Recruit Point values and Munitions Values in the GrandCampaignTwo scenario.

The changes are as follows:

RECRUIT POINT values

England changed to 30;
France changed to 30;
Russia changed to 60.


MUNITIONS values

England changed to 25;
France changes to 20;
Russia changed to 20.

As you can see I just wanted to start with very basic changes. I am not looking to change scripting or complex calculations or relationships.

Thanks again for your help
Attachments

[The extension xls has been deactivated and can no longer be displayed.]


User avatar
calvinus
Posts: 4681
Joined: Mon Dec 19, 2005 4:52 pm
Location: Italy
Contact: Website

Mon Apr 06, 2009 3:59 pm

Hi Markh,

1) I took your excel file and exported to CSV format, using the ; as separator (indeed this could be the cause why the game crashed... you probably used a different separator... , or |)

2) So I zipped the CSV and posted it here (so next time zip the files... ;) )

I hope the CSV will now work...

BUT remember that every nation has a "maximum stock capacity" for RPs! :w00t:
Examine the RecruitPointsCapacity.xls DB... ;)
Attachments
Nations.zip
(2.87 KiB) Downloaded 256 times

User avatar
Gray_Lensman
Posts: 497
Joined: Mon Jun 18, 2007 4:04 am
Location: Who is John Galt?

Mon Apr 06, 2009 10:42 pm

deleted

markh
Conscript
Posts: 6
Joined: Sat Apr 04, 2009 4:17 pm

Wed Apr 08, 2009 2:42 pm

Hi Calvinus

I am not sure what you did but the zipped CSV file you sent back to me has worked PERFECTLY. THANK YOU very much.

I would like to ask you a further question so that I can learn and start doing this minor modding for myself.

Did you use any special program when you "exported" the XLS file to CSV format? I am sorry if the question sounds silly - but I just do not know how you did it. I have tried to further vary the old XLS mod file (keeping the file you sent me in a safe place), and then tried to save the newly varied XLS file in CSV format using Excel version 2003 (using the "save as" CSV function) - it did not work when I pasted that newly varied CSV file into the Data\DB\Scenario\GrandCampaignTwo folder - I got the same old problem.

I then tried to use a freeware XLS to CSV file conversion program produced by SoftInterface Inc. That did not work either.

As you previously suggested, I have Zipped the CSV file that I created by converting the XLS modding file and have ATTACHED it to this reply for you to look at when you have some time free. The most obvious problem with my newly created CSV file is that it does not even look like the CSV files in the Data\DB\Scenario\GrandCampaignTwo folder.

I would be interested if you could help me to be able to make these basic changes for myself.

I also looked at Gray_Lensmans post concerning OpenOffice. I downloaded a free version of that and tried to open the actual "Nations" CSV file in the Data\DB\Scenarios\GrandCampaignTwo folder using the CSV option. I then tried to vary that file in CSV. When I tried to start the game it crashed.

Any suggestion that you have would be greatly appreciated.

I read what you said about RecruitPointsCapacity.CSV. I hope to use the knowledge I gain from you to be able to vary those file details for myself.

Thanks in advance - and happy Easter to you and your family if I do not hear from you before the holidays.
Attachments
Nations.rar
(2.53 KiB) Downloaded 260 times

User avatar
calvinus
Posts: 4681
Joined: Mon Dec 19, 2005 4:52 pm
Location: Italy
Contact: Website

Wed Apr 08, 2009 2:48 pm

Hi Markh, I simply opened the Nations.xls file and saved it in CSV format... using the "Save as..." option (File menu). If you do not have the MS Excel installed on your PC, download and install the Open Office, as suggested by Gray. ;)

markh
Conscript
Posts: 6
Joined: Sat Apr 04, 2009 4:17 pm

Wed Apr 08, 2009 3:26 pm

Hi Calvinus

I do have Excel on my machine. I did use the "save as" option in the Excel file menu. However, the file I ended up with saved in CSV looks very different to the zipped file that you were able to provide me with earlier, and also very different from the way the CSV files in Data\DB\Scenario\GrandCampaignTwo look.

Did you get a chance to look at the zipped CSV file I sent you in my last posting?

I think that these differences may be significant in relation to the problems.

I was also interested in your comments about the difference in "separators" that you saw in the XLS file that I first sent you in my very early post.

As you can see from the subsequent zipped CSV file that I sent you, when I convert my XLS files to CSV files using the Excel option (file menu) my data in the CVS file appears in different columns, whereas your saved CSV file appears in ONE colum separated by ";". I do not know how we are both saving the same XLS file as a CSV and we appear to get this very different format. What are your thoughts?

User avatar
calvinus
Posts: 4681
Joined: Mon Dec 19, 2005 4:52 pm
Location: Italy
Contact: Website

Wed Apr 08, 2009 3:41 pm

I did nothing particular... :bonk: My Excel saves directly using the semicolon ';' :blink:
I examined all toolbars and options, but I'm not able to find a solution... Maybe Gray can help us. :wacko:

User avatar
Generalisimo
Posts: 4176
Joined: Wed Jun 07, 2006 10:03 pm
Location: Buenos Aires, Argentina
Contact: ICQ WLM

Wed Apr 08, 2009 4:03 pm

markh wrote:Hi Calvinus

I do have Excel on my machine. I did use the "save as" option in the Excel file menu. However, the file I ended up with saved in CSV looks very different to the zipped file that you were able to provide me with earlier, and also very different from the way the CSV files in Data\DB\Scenario\GrandCampaignTwo look.

Did you get a chance to look at the zipped CSV file I sent you in my last posting?

I think that these differences may be significant in relation to the problems.

I was also interested in your comments about the difference in "separators" that you saw in the XLS file that I first sent you in my very early post.

As you can see from the subsequent zipped CSV file that I sent you, when I convert my XLS files to CSV files using the Excel option (file menu) my data in the CVS file appears in different columns, whereas your saved CSV file appears in ONE colum separated by ";". I do not know how we are both saving the same XLS file as a CSV and we appear to get this very different format. What are your thoughts?

Open your file with Notepad and you will notice that your file has "," as a separator instead of ";".
The problem is generated by your OS, that has defined "," as a separator instead of ";".
If I am not mistaken, you can change that from your Control Panel, in Regional Configuration and change your list separator from "," to ";" (I cannot remember if there is a simpler way to do it :w00t: )
"History is the version of past events that people have decided to agree upon."
Napoleon Bonaparte


BOA-AAR: ¡Abajo el imperialismo Británico! (en español)

AGEOD Facebook Fanpage - news & screenshots about the upcoming games!

User avatar
calvinus
Posts: 4681
Joined: Mon Dec 19, 2005 4:52 pm
Location: Italy
Contact: Website

Wed Apr 08, 2009 4:15 pm

Mmh... maybe this can corrupt the file!
Maybe not all ',' are to be converted into ';'... :bonk:

User avatar
Generalisimo
Posts: 4176
Joined: Wed Jun 07, 2006 10:03 pm
Location: Buenos Aires, Argentina
Contact: ICQ WLM

Wed Apr 08, 2009 4:20 pm

calvinus wrote:Mmh... maybe this can corrupt the file!
Maybe not all ',' are to be converted into ';'... :bonk:

Not all "," will be converted to ";"... ;)
The list separator will be changed on the entire system from "," to ";"... just that ;)
"History is the version of past events that people have decided to agree upon."
Napoleon Bonaparte




BOA-AAR: ¡Abajo el imperialismo Británico! (en español)



AGEOD Facebook Fanpage - news & screenshots about the upcoming games!

markh
Conscript
Posts: 6
Joined: Sat Apr 04, 2009 4:17 pm

Thu Apr 09, 2009 2:45 pm

Dear Calvinus and Generalisimo

SUCCESS!! Thanks very much to BOTH of you for all your assistance. Generalisimo's suggestion worked. I changed my "list separator" in the Regional configuration section of Control Panel and the file I converted from XLS to CSV became compatable with the program. This is fantastic! The timing is brilliant - just in time for me to get emersed in WW1 during the Easter break.

Calvinus - for the record, I understand that you may be putting together a modders guide. People with the same regional settings as me English (Australian) may have the same problems with their Excel file conversions to CSV.

Anyway, thanks again guys, and happy Easter.

Mark

User avatar
calvinus
Posts: 4681
Joined: Mon Dec 19, 2005 4:52 pm
Location: Italy
Contact: Website

Thu Apr 09, 2009 2:50 pm

Well, good news. Enjoy your vacations! And play the new version 1.06D... ;)

Return to “WW1 mods and modding”

Who is online

Users browsing this forum: No registered users and 12 guests