Big changes over the weekend. I added in many of the promotions from the design contest thread. (Note they might need to be balance tweaked, most of them pump recon and require a travelling zoo to be overpowered so I feel it balances out the metal weapon promotions). And most of them have good pics (pulled from the unit icons that provide them)
Also a major lightbulb went off I pulled all the variables into the class and set them as global variables to do all the gc.getInfoTypeForString() commands only once. This let me dramatically speed up the code so that on a large map it played much faster than a standard map before. This let me pull out most of the for i in (0, len(x)): code and replace it with if y in x: doubling the speed gains. This did cause me to pull all three major functions into one class so that all the variable would be set in one place.
I am still having trouble with the field commander creating an outpost. Everything seems to work, but I am having difficulty selecting a city for the commander unit to init in. I have left the code in, but commented it all out in case anyone has suggestions.
Still looking for good suggestions for promotions, but that is in the other thread. Cheers
PS, the files contain the code that should be inserted into the original files of the same name, and the pointers for where to insert it. The XML files can just be added below all the current unit/promotions.
Also a major lightbulb went off I pulled all the variables into the class and set them as global variables to do all the gc.getInfoTypeForString() commands only once. This let me dramatically speed up the code so that on a large map it played much faster than a standard map before. This let me pull out most of the for i in (0, len(x)): code and replace it with if y in x: doubling the speed gains. This did cause me to pull all three major functions into one class so that all the variable would be set in one place.
I am still having trouble with the field commander creating an outpost. Everything seems to work, but I am having difficulty selecting a city for the commander unit to init in. I have left the code in, but commented it all out in case anyone has suggestions.
Still looking for good suggestions for promotions, but that is in the other thread. Cheers
PS, the files contain the code that should be inserted into the original files of the same name, and the pointers for where to insert it. The XML files can just be added below all the current unit/promotions.