Feedback and Suggestions

The problem is more fundamental than that. You are talking about redrawing while the problem appears to be that once each box is set, it's fixed and can't be removed. The method of removing it is to discard everything and build up a new screen, which likely isn't a good idea in CvMainInterface.py.

Moving all city related stuff into a function of it's own would most likely solve the problem. However how much work is that?

I think I will try to build the multiple tables. I'm actually fairly close considering how my current code is at the moment. Also the function to tell if a yield is inventable should also be fairly simple. Just add a bool to CvYieldInfo and set it to false by default. After XML is loaded, loop though all inventions and for every new yield gained by an invention, set the bool to true. Then make a python function to get that bool.
That function could also be used to improve the yield page on Colopedia.
 
I found something in CIV4YieldInfos.xml
Code:
<Type>YIELD_GRAIN</Type>
<Description>Luxury Food</Description>
Isn't that naming a bit inconsistent?

I checked CvEnums.h and got confused as I failed to find luxury food. Instead I found grain where I expected it to be. This made me wonder about another issue: why do we have an enum and an XML file telling the same thing? Changes will break the game unless they are done in sync.
I think yields should be handled like any other vector read from XML. Getting the index of a specific one in C++ would then be GC.getDefineINT("YIELD_EDUCATION"), which naturally should be cached. That way we can add more yields without modifying the DLL and we will no longer risk them going out of sync.

Just a little something I noticed while snooping around the code when I needed the right data to make a proof of concept code.
 
I found something in CIV4YieldInfos.xml
Code:
<Type>YIELD_GRAIN</Type>
<Description>Luxury Food</Description>
Isn't that naming a bit inconsistent?

I checked CvEnums.h and got confused as I failed to find luxury food. Instead I found grain where I expected it to be. This made me wonder about another issue: why do we have an enum and an XML file telling the same thing? Changes will break the game unless they are done in sync.
I think yields should be handled like any other vector read from XML. Getting the index of a specific one in C++ would then be GC.getDefineINT("YIELD_EDUCATION"), which naturally should be cached. That way we can add more yields without modifying the DLL and we will no longer risk them going out of sync.

Just a little something I noticed while snooping around the code when I needed the right data to make a proof of concept code.

Well, back when it took 15 mins or more to build my DLL I didn't bother to make changes like these. When I decided to add luxury food I just replaced grain, likewise with salt and silk, and maybe others. Also, like you pointed out to change or add a Yield you have to edit a slew of lines in C++ and all kinds of XML so it was easier to just rename it in the XML and add new art.
 
370 turns into a 2.0g game, it's telling me I have 2 turns to win. The Pope hasn't declared yet. [Later:] And indeed the Pope won 2 turns later, without ever showing up and firing a shot! A miracle! :)

I believe this is a vanilla bug or more like game design. It has been a while sense I played vanilla so correct me if I am wrong but once someone other than the player declares Independence the player must then Declare Independence as soon as possible and win Independence before the other player does, correct? As looking into the code as soon as someone declares their Independence the extended independence game time is added to max turns for all players. You then have that long to declare independence and win or you will lose. So, on default settings once someone declares independence the game will only last 100 more turns.

Question is do we want to keep it this way or change it? Having to compete against the AI is part of the game and being the first to start your conquest is also part of the challenge. The problem, you could say, in mastrude's saved game for example, Reccared I declared independence but lost to his Pope, but the game ended anyway. So, the player never even started his conquest. We could make it so that if the AI players fail the Other players still have a chance to win, but if we do this it will put less emphasis on actually starting your conquest before anyone else. That means the player can take the whole game before building up his Fealty, which is a strategy some players use, but using that strategy in the current game has the draw back of losing because someone else started conquest before you, thus "you are not prepared" (I say that in my best Illidan voice).

I feel like the Challenge to be the first to Declare Emperor should be part of the game. And who ever declares first get's to set the End game turn. The way the game is coded so far if no one declares by the Max Turn, the game will auto start your conquests.

Edit: In mastrude's saved game I swapped to Reccared I (Alt-Z) and in two turns was able to defeat the Pope and won the victory. I see I need to improve the AI's ability to make a last mad rush to save his arce :)
 
I quit trying to hide uninvented yields. Adding another table makes the city screen weird, even though I only use one. Also non-related code is affected, like the turn in the top of the main screen is blinking. In fact a whole lot of stuff appears to be screwed now and I have no idea why.

Making a city only python file could work though as it would init the table every time the colony is opened. However I'm not going to code that.

Now that I looked closely at the code and figured out how it works I'm going to merge in the two row table (hopefully).

EDIT: RaR contains around 130 extra lines in the table generation code due to DynamicYieldsIcon. It seems rather complicated :(

EDIT: google found ray working on it on civforum.de where he talks about continuing the work of NeseryozniyVET. While the text didn't contain the info I was actually looking for, it did tell me what I needed to know (I think) meaning it might be less complex than I first thought.
 
I merged in the two row code. It conflicted a bit with M:C code, but it looks like I managed to solve all issues. Also I changed the hidden yield icon code to cover all yields, including the the far left and right ones (which were left out for some reason).

The problem now appears to be that the low number of yields makes it look a bit stretched on widescreen. I'm not sure we can do anything about that except add more yields :)

Also I should play with it for a while to see if it actually works all the time. Right now I spent 30 seconds dragging and inventing a yield.

I'm not sure when I should commit this. Something inside me is against committing something which makes widescreen looks like that. On the other hand waiting for more yields mean the file could be outdated when they finally arrives.

Either way next up for coding is removing hardcoded yield order in DLL. It should follow XML just like it does with the other XML files. That will make it way easier when we reorder yields to place barley on top of ale etc. Moving yields around will break savegames though, which mean we should likely wait with the moves until we break them anyway by say adding more yields. I hate losing my savegame(s) as I tend to load the same over and over to test new features in a consistent setup.
 

Attachments

  • 2row.jpg
    2row.jpg
    170.9 KB · Views: 53
  • 2rows-wide.jpg
    2rows-wide.jpg
    192.2 KB · Views: 72
As I've told you, I'm not a very good Civ player, though I do better with Colonization. I've been working up the difficulty levels till I'm now playing at normal. What I've noticed as the level rises is that terrain is less and less hospitable. For example, there's a lot less silver at normal level.

So, do I have that right? Is that the main effect of greater difficulty? What else changes, roughly?
 
I merged in the two row code. It conflicted a bit with M:C code, but it looks like I managed to solve all issues. Also I changed the hidden yield icon code to cover all yields, including the the far left and right ones (which were left out for some reason).

The problem now appears to be that the low number of yields makes it look a bit stretched on widescreen. I'm not sure we can do anything about that except add more yields :)
Hm I kinda like the more "spacious" look. :king: It might even leave room to have more information - would it be possible to show the buy/sell price to the left of the yield picture, and have the current stockpile + production appear to the right?

there's a lot less silver at normal level.

So, do I have that right? Is that the main effect of greater difficulty? What else changes, roughly?
I don't think the map is actually affected. You can check xml/gameinfo/handicapinfo for the settings (here's civ4 modiki but it's different from col).

It's remarkable how hugely the AI had to cheat even in Civ4BtS just to keep up; I don't think most players were aware of it. Its problems in Civ4Col must be even worse; I can't imagine how it could truly plan multiple turns ahead across numerous settlements for things like building/unit construction requirements and profession yield requirements, or actually plan and set up appropriate multicity trade routes for production chains. It's probably not solveable without handicaps which is fine, the vanilla AI is just bad bad bad :crazyeye:
 
Hm I kinda like the more "spacious" look. :king: It might even leave room to have more information - would it be possible to show the buy/sell price to the left of the yield picture, and have the current stockpile + production appear to the right?

The only thing that appears "scretched" is the Discover Icons and we can edit those to be at a "normal size" or resize them by resolution. But, I'll have to check it out in game to see how it "feels" so you can commit it if you want, we can always revert back right :)

It's remarkable how hugely the AI had to cheat even in Civ4BtS just to keep up; I don't think most players were aware of it. Its problems in Civ4Col must be even worse; I can't imagine how it could truly plan multiple turns ahead across numerous settlements for things like building/unit construction requirements and profession yield requirements, or actually plan and set up appropriate multicity trade routes for production chains. It's probably not solveable without handicaps which is fine, the vanilla AI is just bad bad bad :crazyeye:

I have started working on this starting with the AI's ability to accumulate Luxury Food. The AI has rules it follows when setting up it's import and exports and you can toy with this as much as you want. Sense the AI had no idea what Luxury Food was and why it was so important I finally got around to explaining it all to it and it is slowly figuring it all out (that's a lot of its).

Edit: The AI may be too good at the moment, they just won a Conquest Victory by turn 240, yikes!
 
You know those slits atop castle walls? The ones everybody thinks are for shooting arrows? They are for peeing through. :)
 
I pushed the two row change.

Also I investigated removing the ordered enum for YieldTypes from DLL, making XML control it. That's not possible. It turns out that the code to handle python code like YieldTypes.YIELD_HAMMERS is set at compile time in C++ meaning there is no way to make it depend on XML. I'm now investigating a plan B where the game asserts if XML and enum have a mismatch. That way at least we will not have undetected bugs due to this issue.
 
You know those slits atop castle walls? The ones everybody thinks are for shooting arrows? They are for peeing through. :)

That reminds me of King Louis IX of France's misfortune of having the contents of a chamber pot emptied on to his royal cloak as he traveled through his cities early one morning. He dismounted and quickly ran to the culprits lair and found him to be a student who had risen early to study. The saintly king gave the student a scholarship.

By the way, I updated the bug report thread with all the reported failed asserts.
 
Recently it seems that more than half of my huntsman's attacks on animals result in success, but no food gained. Would you please look into this?
 
I'm not 100% on this, but it seems to me that the game announces that you have the ability to find the Silk Road long before you actually can.
 
Recently it seems that more than half of my huntsman's attacks on animals result in success, but no food gained. Would you please look into this?
Now that you mention it. I noticed the hunter didn't have any luxury food and was like "didn't I kill a buck last turn?" and then I killed another animal and gained some. I wanted to take a closer look, but then I got an assert and forgot all about luxury food. I did go hunting though :lol:

This really is something which belongs in the bugs thread though.
 
Now that you mention it. I noticed the hunter didn't have any luxury food and was like "didn't I kill a buck last turn?" and then I killed another animal and gained some. I wanted to take a closer look, but then I got an assert and forgot all about luxury food. I did go hunting though :lol:

This really is something which belongs in the bugs thread though.

This should be fixed in the Git version. mastrude, what DLL version are you using? I uploaded one with a fixed saved game you posted other day. Try using that DLL.

The link is here http://forums.civfanatics.com/attachment.php?attachmentid=359129&d=1377213458

Edit: Then again it may only be in my version I haven't posted to Git yet.
 
In the current game, we're into the time of conquest but the civic choice screen hasn't appeared. It seems that no one else is fighting their pope either. So what's the deal?
 

Attachments

  • Current Solo MT 2.0g game.ColonizationSave
    261.8 KB · Views: 126
In the current game, we're into the time of conquest but the civic choice screen hasn't appeared. It seems that no one else is fighting their pope either. So what's the deal?

Well, three turns later or so Clovis defeats his Pope and wins by Conquest Victory. If you look back in your event log you will see Clovis declared war on Pope Leo III in 1441. And considering he currently out numbers the Pope 110+ to 12 I'd say he was destine to win:king:

Once another Civ starts their Conquest there is no auto Conquest for the player. Your only hope is that that player is defeated or you can start your conquest soon and defeat the Pope before they do. You may have to declare war on that Civ and try to prevent them from winning as well. This is basically the same as in Vanilla.
 
Once another Civ starts their Conquest there is no auto Conquest for the player. Your only hope is that that player is defeated or you can start your conquest soon and defeat the Pope before they do. You may have to declare war on that Civ and try to prevent them from winning as well. This is basically the same as in Vanilla.

OK, I guess that seems reasonable. What threw me off was that I looked at the diplomatic screen and Clovis' pope didn't appear on it at all. I expected a sign there that Clovis was at war.
 
Top Bottom