View Full Version : WBCleaner


AnitaGaribaldi
Apr 06, 2008, 03:30 AM
Hi!

I did this small utility program for me, I hope it will be useful for other. The GUI is very simple. I may add new features later on. The WorldBuilder adds some lines that make your new Scenarios created hardcoded. For example, if you want to change the start point from one civilization, it will always know some tiles from the beginning (even if it cannot see it from the new start). The WorldBuilder hardcode some civilizations characteristics like the Leader Name, if you are modding and decided to change the XML files, it will not change in the Scenario because of that.

Reading the threads:

http://forums.civfanatics.com/showthread.php?t=176397

and

http://forums.civfanatics.com/showthread.php?t=179437


I found out how to clean maps from WorldBuilder. If I missed something, just let me know it. I really think the utility should work with Scenarios from Vanilla and BTS.

You don't need to install the program, just open the Windows Explorer and click two times over WBCleaner.jar (requires JVM 1.4 or later - most computers have it - get a Java Run Time (JRE) (http://java.sun.com/javase/downloads/?intcmp=1281) if you don't have it). You will need the JDK only if you want to change the utility. The program should work with Macs too, but I don't have one to see how the GUI will look out. I haven't used the best practices to guarantee the tool will look nice in every OS. I have tested it only in Windows. If you use Mac and cannot read the GUI, send me a screen shoot, please.

You have to type the name of the file () or press "open" to choose the file from a dialog.

Options:
Allows All Speeds - In section BeginGame/EndGame changes (it DOES NOT ADD the options) Speed and GameTurn, to Speed=NONE and GameTurn=0

Clean up TeamReveal - Deletes all lines TeamReveal

Clean up Units - Deletes all units

Clean up Cities - Deletes all cities

Clean up civs - deletes the the data of LeaderName, CivDesc, CivShortDesc, CivAdjective, FlagDecal, WhiteFlag, Color, ArtStyle, StateReligion, StartingEra, CivicOption, Handicap
leaves the data of Team, LeaderType, CivType, PlayableCiv, MinorNationStatus, StartingGold, StartingX=, StartingY=

I have tested the program only with Warlords (I donīt have BTS) with the WB file I saved from WorldBuilder.

Have fun!

File Link: WBCleaner File (http://forums.civfanatics.com/downloads.php?do=file&id=9004&act=down)

r_rolo1
Apr 07, 2008, 10:00 AM
It is working with BtS WB files... :) ... Good job ;)

AnitaGaribaldi
Apr 15, 2008, 11:50 AM
Thanks for the feedback.

New version of the file uploaded. A small cut&paste mistake corrected. The only problem was that one button had the label in Portuguese.

Chiyochan
Aug 09, 2008, 05:15 PM
It would be cool if you could expand on this and make deleting resources possible as well.

Jabarto
Oct 20, 2008, 10:38 PM
Forgiv me for raising such an old thread, but I'm having a small problem with this utility. I've gotten much use out of it up to and including today, when it suddenly stopped working. When I try to clean a map, I get the message telling me that it succeeded, but when I check the cleaned WBS save, it's exactly the same as it was before. I've tried cleaning several different maps, updating Java, and restarting my computer, to no avail. I'm completely mystified as to what could have caused this. Anyone have any ideas?

derflensburger
Jan 07, 2010, 11:15 AM
Forgiv me for raising such an old thread, but I'm having a small problem with this utility. I've gotten much use out of it up to and including today, when it suddenly stopped working. When I try to clean a map, I get the message telling me that it succeeded, but when I check the cleaned WBS save, it's exactly the same as it was before. I've tried cleaning several different maps, updating Java, and restarting my computer, to no avail. I'm completely mystified as to what could have caused this. Anyone have any ideas?

Same for me:

1. Forgive me...

2. "cleaned!" but nothing has changed. Any ideas two years later?

dalamb
Jan 07, 2010, 12:06 PM
It creates a new file in the same directory; if you used it on file X, you get cleaned_X.

I had plans to start writing a replacement (http://forums.civfanatics.com/showthread.php?t=344446) over Christmas, but got sidetracked by pneumonia.

derflensburger
Jan 07, 2010, 12:23 PM
[QUOTE=dalamb;8789090]It creates a new file in the same directory; if you used it on file X, you get cleaned_X.
QUOTE]

Yeah, I noticed that but the "cleaned_" file doesn't seem to have any changes.

dalamb
Jan 07, 2010, 12:26 PM
Yeah, I noticed that but the "cleaned_" file doesn't seem to have any changes.Odd; it has always worked for me.

Xoatl_169
Jan 12, 2010, 10:52 PM
I cant seem to get it to work :( when i click it it makes the annoying error noise. Whatever i do (including the readme suggestion) I cant do it.

Tomberrysenior
Feb 03, 2010, 09:19 AM
Same for me, I clean the map, but all the civs remain the same, and I can't change them :/

dalamb
Feb 03, 2010, 02:20 PM
What, specifically, are you trying to change?

drunkinpenguin
Feb 15, 2010, 09:08 PM
If you are trying to change the starting civs from an official scenario, like Earth18Civs, then after using the WBCleaner program you must still open the "cleaned" worldbuildersave and edit the leader names and civ types. So, if let's say you want to change the English into the Vikings you would open the wbsave and delete "LEADER_ELIZABETH" And replace it with "LEADER_RAGNAR" you would also have to delete "CIVILIZATION_ENGLAND" and replace it with "CIVILIZATION_VIKINGS". These steps can be repeated as necessary, IF you want to remove a civ completely just delete the Leadername and leave it blank (should delete all the data under it too). This should solve your problems.

If your going to alter the map or change civs, I recommend starting the earth18civ scenario with Egypt since they move 1st. Then simply enter WB and edit anything you want, save it under a new name. Then complete the above steps. Reload your new altered scenario and place the starting units of your new civs wherever you please and viola! You've got a new map, with the civs of your choice.

PS, thanks for the utility, saves a lot of time deleting those data lines.