more SRUNITS.csv woes

If you have the desire to modify SR2010 here is where you can discuss and share your designs and ideas. NOTE: Mods are a change to the original program and are not supported by BattleGoat Studios.

Moderators: Balthagor, Legend, Moderators

epicanthics
Corporal
Posts: 2
Joined: Jul 05 2006

more SRUNITS.csv woes

Post by epicanthics »

I've read all the threads and wiki entries I have found on the topic of importing custom equipment files, and I still have not had any results. Here are some details:

1. Using openoffice 2.0, I modified the SRUNIT_user.xls. The specific changes were minor; changed the name of the BMV-1 mech unit, and gave the other mech unit (the one with the id number but no stats) some stats based on the BMV-1. These changes were only meant to test whether the process worked.

2. When saving as CSV, I chose to save the file in US English Ascii format with field delimiter set to , and text delimiter set to ". The wiki stated that I may need to change the text delimiter to ' for it to work properly in openoffice. However, I have used both settings without seeing a result.

3. I have all the files in the custom folder as they are supposed to be, and close all documents before entering the map editor, whereupon I open the adriatics example scenario for testing. I then hit import cvars followed by the import equipment file picture button. I then go over to the units panel to see that there have been no changes made to the BMV-1 as is to be expected (the other mech unit does not show up at all).

4. Upon quitting the map editor, I examine the custom/default folder to see that default.uni has in fact been generated by the editor (the date modified is changed). However, I can't exactly look at the raw data to see if it was generated correctly.

At this point, I am stumped. All the suggestions made in previous threads have been followed and the result is the same. Here is a snippet of the SRUNITS.csv file. The formatting appears correct compared to the other untouched CSVs. I just don't see where the problem is here.

Code: Select all

"Supreme Ruler 2010 Master Equipment File",,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
"ID#","Model
Code","Equipment
Name","Class","Regions","U/G
to","refit","Year
Avail","Crew/
Squad","Num Squad in Batt","Cost
$M","Days to build 1 squad","Gun
mm","Max
Speed
km/h","Armr
mm","Engine
HP","Fuel
Type","move method","Max
Move
per Day
km","Spotting
Range
km","Unit / 
Squad
Weight
tonnes","Transp
Cap
tonnes","Target Type","Stealth
Str","Spotting
Strength","Initiative","Indirect ?","Ground
Attack
Range
km","Air
Attack
Range
km","Naval
Surface
Attack
km","Naval
Sub
Attack
km","Soft
Attack","Hard
Attack","Fort. Attack","Close
Air
Attack","Mid
Air
Attack","High
Air
Attack","Naval
Surface
Attack","Naval
Submar
Attack",,"Near
Orbit
Space
Attack","GeoSyn
Orbit
Space
Attack","Close
Range
Attack
(Urb/For)","Ground
defense","Tac Air
defense","Indirect
Fire
defense","Close Range
defense","Squad
Fuel
Use","Squad
Fuel
Cap","Supply 
Use per squad","Supply
Cap","Nuclear
Yield","NBC Prot","Strat Nuke","Tac. Nuke","Guided Mis.","Move&fire penalty","Limited firing arc","No land cap.","River Xing","Amphibious","Airdrop","Air Tanker","Ari refuel","ECM Equipped","Dock to unload","AirCarrier","Heli Carrier","Short Deck Take-off","Long Deck Take-off","Direct Def","Balistic Art.","Stand-off unit","Mine Layer","MineSweep","Bridge Build","U/G Demol","Engineering unit","UPGRADE Unit","No Research","No Build","Not Def Res","Out of Prod","Special
Tech #1","Special
Tech #2","Misisle pts value","Misisle pts capacity","Launch  type","Market  Availability","Uses larger Block Size","Gnd Move Cost","Naval Move Cost","Supply Level","Pollution","IG Cost","Agri","Ore","Petrol","Coal","Uranium","Timber","Water","Electricity","C. Good","I. Goods","M. Goods","Reserved","Prod # for Powergen","Base
Pic #","Turret
Pic #","Fire SND A","Fire SND B","Fire SND C","Death Sound","Move sound","Pic 1","Pic 2","Pic 3","Pic 4","Description","Weapons",,,,,,,,,,,,,,,,,,,,,,,,,
,,"Infantry Class",,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
1,,"Conscript","0 Infantry","*",,,"-",10,70,0.05,0.1,5.56,5,0,"-","-","0 Leg",25,20,2,"-","0 soft",60,150,1,"N",1,1,1,0,10,8,0,4,0,0,1,0,,0,0,12,12,9,9,11,0,0,0.02,0.5,,"N","N","N","N","N","N","N","N","N","N","N","N",,"N","N","N","N","N","N","N","N","N","N","N","N","N",,,"N",,0,"-","-",0,0,,,,,,,,,,,,,,,,,,,,,,22,,2,"X",14,1,16,1,2,3,4,,,,,,,,,,,,,,,,,,,,,,,,,,,
2,,"Foreign Legion","0 Infantry","EF",,,"-",10,70,0.1,0.15,5.56,5,0,"-","-","0 Leg",25,30,2,"-","0 soft",60,150,4,"N",1,1,1,0,14,11,0,10,0,0,1,0,,0,0,19,17,17,12,17,0,0,0.01,0.5,,"N","N","N","N","N","N","N","N","N","N","N","N",,"N","N","N","N","N","N","N","N","N","N","N","N","N",,,"N",,0,"-","-",0,0,,5,,,,,,,,,,,,,,,,,,,,22,,2,"X",14,1,16,1,2,3,4,,,,,,,,,,,,,,,,,,,,,,,,,,,
the excessive newlines in the code snippet are the result of pasting it from notepad. the actual document does not have them.

so, what am I doing wrong here?
User avatar
Balthagor
Supreme Ruler
Posts: 22083
Joined: Jun 04 2002
Human: Yes
Location: BattleGoat Studios

Post by Balthagor »

my apologies, this thread seems to have slipped past me.

Some questions;

- Are you adding a new unit? Does it have an entirely unique ID number (value in the first column)

- When you select import, does the system "freeze" for a few seconds? (would be a sign it is reading the file) FYI, you do not need to import the Cvars file to import the equipment file. You don't even need to have a scenario loaded.

- When you try and find the "in game" changes, are you looking at custom scenarios in the scenario list? There are three buttons along the left side of the scenario selection list for scenario/custom/savegame.

If you'd like, send me the .csv file you've created and I'll try it out. If I can get it working I can send it back to you so you can try and see what format works.
Chris Latour
BattleGoat Studios
chris@battlegoat.com
Draken
General
Posts: 1168
Joined: Jul 14 2004
Human: Yes
Location: Space Coast, FL

Post by Draken »

Bump!

I'm having the exact same problem as epicanthics (using Open Office 2.0.3).

I'm not adding new units, just deleting existing ones a modifiying some of them.

The editor does not "freeze" and it generates the default unit file every time.

My source unit file is named SRUNITS.csv and located in the custom folder.

Ideas?

(Edit)

More info:
I downloaded the unit file from the site, opened it with OpenOffice, change the name of the Conscript unit to ConscriptIO, save it as a .csv ... And it doesnt imports...
User avatar
George Geczy
General
Posts: 2688
Joined: Jun 04 2002
Location: BattleGoat Studios
Contact:

Post by George Geczy »

Remember that once the file is imported, it is still in the 'Custom' section, which means it gets used only for Custom Scenarios (not the main scenarios included with the game). If you're already accounting for that, then I'm not sure what's up, but like Chris suggested send us a copy of the edited CSV file and we'll give it a try (you can send to support@bgforums.com )

-- George.
Draken
General
Posts: 1168
Joined: Jul 14 2004
Human: Yes
Location: Space Coast, FL

Post by Draken »

File sent!

I even tried creating the csv using excel instead of Open Office....

:-(
User avatar
George Geczy
General
Posts: 2688
Joined: Jun 04 2002
Location: BattleGoat Studios
Contact:

Post by George Geczy »

Well, thanks for the file, but for some reason it worked here...

Some thoughts:

1) Make sure the file is named correctly (srunits.csv) and placed in the Custom folder.

2) Make sure the app you have editing the file (Excel or Openoffice) has the file CLOSED after you export - If the file is still open in the spreadsheet or word processor, then the Mapeditor import will not work because the file is 'in use'. You will not get an error, it will simply not work.

3) After import, it will apply to all scenarios in the Custom section; to apply to existing (in-game) scenarios, you would need to copy the .UNI file to the Maps\Data directory.

A quick way to test the import:
- Change the name of CONSCRIPT as mentioned earlier, such as CONSCRIPTIO;
- save the .csv file;
- in the Mapeditor Import the Unit file and right away go to the units tab and see if the change is there (you may have to turn off the 'Filter to Region' checkbox). The name in the list should be changed.

Give it another try and see what happens.

-- George.
Draken
General
Posts: 1168
Joined: Jul 14 2004
Human: Yes
Location: Space Coast, FL

Post by Draken »

Works well in my laptop, but not in my game PC...

If I find out what's wrong with my game PC I'll post it here...

Thanks again George!
Iluwen
Sergeant
Posts: 13
Joined: Sep 15 2006

Post by Iluwen »

I am having a similar problem. I can't get the map editor to import the SRUNITS file. When I click Import, nothing happens.
User avatar
Balthagor
Supreme Ruler
Posts: 22083
Joined: Jun 04 2002
Human: Yes
Location: BattleGoat Studios

Post by Balthagor »

did you try George's suggestions? What happened when you tested the import?
Chris Latour
BattleGoat Studios
chris@battlegoat.com
Iluwen
Sergeant
Posts: 13
Joined: Sep 15 2006

Post by Iluwen »

Yes, I checked the file name, and closed the folder before launching the editor.

When I import, nothing happens. The editor does not pause, as if loading something. It doesn't seem to recognize anything to load.
User avatar
Balthagor
Supreme Ruler
Posts: 22083
Joined: Jun 04 2002
Human: Yes
Location: BattleGoat Studios

Post by Balthagor »

send me your file and I will try it out

Chris@battlegoat.com
Chris Latour
BattleGoat Studios
chris@battlegoat.com
User avatar
Balthagor
Supreme Ruler
Posts: 22083
Joined: Jun 04 2002
Human: Yes
Location: BattleGoat Studios

Post by Balthagor »

Further suggestion if George's test does not work;

check your .CSV file by opening it with Notepad or some other basic text editor. The lines should look like this;

1,,ConscriptIO,0 Infantry,*,,,-,10,70,0.05,0.10

if your data is in quotation marks or separated by semicolons it will not import correctly.
Chris Latour
BattleGoat Studios
chris@battlegoat.com
Draken
General
Posts: 1168
Joined: Jul 14 2004
Human: Yes
Location: Space Coast, FL

Post by Draken »

HA!

Fixed my problem.... 8)

For some reason, Open Office was saving the .csv using double qoutes as text delimiters on my game PC, but without delimiters on mty laptop...

I knew it was something I was overlooking, but Chris gave me a clue!

Thanks Chris!!!

:D
Iluwen
Sergeant
Posts: 13
Joined: Sep 15 2006

Post by Iluwen »

Working now. Putting a space instead of quotation marks in the text delimiter box when Open Office opens the file fixs the quotatiom mark problem.

Thanks.
User avatar
Balthagor
Supreme Ruler
Posts: 22083
Joined: Jun 04 2002
Human: Yes
Location: BattleGoat Studios

Post by Balthagor »

For anyone else who may have questions about modding the equipment file, the information on the Wiki for modding has been updated;

http://www.supremewiki.com/index.php/Modding
Chris Latour
BattleGoat Studios
chris@battlegoat.com
Post Reply

Return to “Mods”