Changing Victory Locations

Post new mods and scenarios here.

Moderator: MOD_WestCiv

Post Reply
Rosseau
Posts: 2931
Joined: Sun Sep 13, 2009 2:20 am

Changing Victory Locations

Post by Rosseau »

You can't simply change them in the Scenario text file, so I assume they are tied to the map, and/or are more complicated to alter. Thanks!
User avatar
Gil R.
Posts: 10820
Joined: Fri Apr 01, 2005 4:22 am

RE: Changing Victory Locations

Post by Gil R. »

It so happens that before seeing your thread I was working on the relevant part of the modder's guide. I'll post more later, but here is what I say about how Victory Hexes are assigned in each scenario's scenario.txt file:

"9. The list of Victory Hexes, for which each line must provide X-coordinate + <space> Y-coordinate + <space> + Side. For the latter, one uses 0 if a V.H. is USA-only (blue hex), 1 for CSA-only (red hex), and 2 for one that can benefit either side (white hex). It is essential to end this list with ‘0 0 0’ so that the code knows it has reached the end."

Very easy to change, once you know how.
Michael Jordan plays ball. Charles Manson kills people. I torment eager potential customers by not sharing screenshots of "Brother Against Brother." Everyone has a talent.
Rosseau
Posts: 2931
Joined: Sun Sep 13, 2009 2:20 am

RE: Changing Victory Locations

Post by Rosseau »

If I make a change, I get an "assertion failed" box when starting the scenario. For example,

106 95 2
to
107 96 2
User avatar
Gil R.
Posts: 10820
Joined: Fri Apr 01, 2005 4:22 am

RE: Changing Victory Locations

Post by Gil R. »

That's strange. Can you tell me which scenario it is? And did you make any other changes? Accidentally replacing an <underscore> character with a <space> character will cause trouble.

Also, what program are you using? The very basic (often TOO basic) Notepad program that ships with most PC's is perfect. If you are using something more advanced it may have inserted some character(s) in there.
Michael Jordan plays ball. Charles Manson kills people. I torment eager potential customers by not sharing screenshots of "Brother Against Brother." Everyone has a talent.
Rosseau
Posts: 2931
Joined: Sun Sep 13, 2009 2:20 am

RE: Changing Victory Locations

Post by Rosseau »

No, I was really careful, Gil. I usually use Notepad++ but found that MS spreadsheet is easier. Anyway, I successfully modded the starter scenario, adding a bunch of new units no problem.

Give it a try yourself and let me know if it's me. I just opened the file in the Williamsburg_(Hancock_vs_Early_(small_scenario))_S just to test and make that small change and got the error, as I did in the starter scenario, too.

Otherwise, seems pretty hard to break [:)]

User avatar
Gil R.
Posts: 10820
Joined: Fri Apr 01, 2005 4:22 am

RE: Changing Victory Locations

Post by Gil R. »

This is getting beyond my area of expertise, but it seems to me that Notepad++ might have messed up the format. If you want to post the file here in a zip file I can take a look. (I would rather do that than try to mod the file on my computer, simply because I've spent countless hours doing that sort of thing on my laptop with Notepad and nothing like this has happened.) I can guarantee you, though, that if you use regular Notepad and make no changes other than to the three relevant numbers for that or any other Victory Hex nothing will go wrong.

Michael Jordan plays ball. Charles Manson kills people. I torment eager potential customers by not sharing screenshots of "Brother Against Brother." Everyone has a talent.
rickier65
Posts: 14241
Joined: Thu Apr 20, 2000 8:00 am

RE: Changing Victory Locations

Post by rickier65 »

ORIGINAL: rosseau

No, I was really careful, Gil. I usually use Notepad++ but found that MS spreadsheet is easier. Anyway, I successfully modded the starter scenario, adding a bunch of new units no problem.

Give it a try yourself and let me know if it's me. I just opened the file in the Williamsburg_(Hancock_vs_Early_(small_scenario))_S just to test and make that small change and got the error, as I did in the starter scenario, too.

Otherwise, seems pretty hard to break [:)]



I just made the change you outlined using notepad and it went through fine on my system. I haven't tried notepad++ yet. I'll try that now.

Thanks
Rick
Rosseau
Posts: 2931
Joined: Sun Sep 13, 2009 2:20 am

RE: Changing Victory Locations

Post by Rosseau »

Yep, regular notepad worked. I might have saved it wrong in ++. Anyway, this opens up huge possibilities.

The only thing that's a bit tough is to add (paste in) Union troops, as it forces you to renumber the rebs down the list, which can be tricky (to me at least). Also, MS spreadsheet is a must with the OB's, but it can be done. There's just so much you can change, it will keep us busy for quite a while.

Thanks for the support - quite kind of you to help with such a minor issue as mine.
rickier65
Posts: 14241
Joined: Thu Apr 20, 2000 8:00 am

RE: Changing Victory Locations

Post by rickier65 »

ORIGINAL: rosseau

Yep, regular notepad worked. I might have saved it wrong in ++. Anyway, this opens up huge possibilities.

The only thing that's a bit tough is to add (paste in) Union troops, as it forces you to renumber the rebs down the list, which can be tricky (to me at least). Also, MS spreadsheet is a must with the OB's, but it can be done. There's just so much you can change, it will keep us busy for quite a while.

Thanks for the support - quite kind of you to help with such a minor issue as mine.

I just rechecked using notepad++ to change it back and that worked for me as well.

You might double check the settings and the file type notepad++ set for when it's editing that file.

Thanks!
Rick
User avatar
Gil R.
Posts: 10820
Joined: Fri Apr 01, 2005 4:22 am

RE: Changing Victory Locations

Post by Gil R. »

ORIGINAL: rosseau

Yep, regular notepad worked. I might have saved it wrong in ++. Anyway, this opens up huge possibilities.

The only thing that's a bit tough is to add (paste in) Union troops, as it forces you to renumber the rebs down the list, which can be tricky (to me at least). Also, MS spreadsheet is a must with the OB's, but it can be done. There's just so much you can change, it will keep us busy for quite a while.

Thanks for the support - quite kind of you to help with such a minor issue as mine.

Your life will become easier once I post the modder's guide AND you are able to use the scenario editor to reposition units. Stay tuned...
Michael Jordan plays ball. Charles Manson kills people. I torment eager potential customers by not sharing screenshots of "Brother Against Brother." Everyone has a talent.
Post Reply

Return to “Mods and Scenarios”