Significant mistake in Tokugawa's ability

Turns out Nader Shah's ability has a mistake, too. The requirement "city is conquered" is not assigned to the requirement set "city is conquered", meaning the requirement always reports as true and domestic trade routes from ALL cities get the bonus.
I think there's been a missing requirement similar to this in Philip's "+5 CS vs civilizations following other religions" for a very long time now.

I could be remembering it incorrectly, but I think the bonus was applying even against Civs whose Holy Cities I converted and were following my religion.
 
The problem is that the writer, assuming the ability is behaving correctly, switches subjects midsentence. The first half has "cities within 6 tiles of Japan's capital" as the subject, but after the "and" they switch the subject to "all cities in Japan's empire" without telling the reader. The sentence does say that the effects are for those six cities. The only way it's not actually wrong is that the sentence doesn't make it an exclusive claim - technically, the six cities do get the tourism, and it never says no other cities do. Still, that's poor communication.

My proposed change:

Cities within 6 tiles of Japan's capital are 100% loyal. After researching Flight, all cities receive +1 Tourism for every District.
 
Tokugawa might be even stronger than what we all initially thought.



A logical read of this ability makes one think that the described bonuses (100% Loyalty and Tourism from districts) apply to the "Cities within 6 tiles of Japan's capital" mentioned in the subject of the sentence.

However, while modding, I discovered that the Tourism portion of this ability is actually coded to apply Tourism to all districts in all of Japan's cities. This is a massive buff compared to what I think everyone's initial interpretation was.

This seems like a mistake in execution rather than a mistake in wording. I wonder if they'll change it.
That's wrong as I have received confirmation that it works only within 6 tiles
 
Hi all, yes, it appears I made a mistake and overlooked the component that restricts the ability to 6 tiles. I apologize for the confusion, but I think this generated interesting discussion.

Also, thanks to @JNR13, we now know Nader Shah's ability is incorrectly set up. I took a look and saw exactly what JNR described.
 
awww dang i was really hoping it applied to all districts T^T
anyone happen to know if you could delete the "must be within 6 tiles" requirement for district tourism w/o deleting it for the loyalty bonus (or amenity bonus if youre playing w/ the basegame ability)
looking at the file GreatWarlords_Leaders.xml i think you could take this bit here:
<Row>
<RequirementSetId>PLAYER_HAS_FLIGHT_GREATWARLORDS</RequirementSetId>
<RequirementId>REQUIRES_PLAYER_HAS_FLIGHT</RequirementId>
</Row>
<Row>
<RequirementSetId>PLAYER_HAS_FLIGHT_GREATWARLORDS</RequirementSetId>
<RequirementId>BAKUHAN_REQUIREMENTS_MET_REQUIREMENT</RequirementId>
</Row>
and just delete the second bit and not the first and that'd work? my understanding is that "PLAYER_HAS_FLIGHT_GREATWARLORDS" is the requirement for districts to give tourism, so this bit is saying that "PLAYER_HAS_FLIGHT_GREATWARLORDS" requires 1) that the player have unlocked the flight tech, and 2) that the player has met the "bakuhan requirements", which from looking elsewhere in the code seems to be the "6 tiles from the capital" piece. so theoretically removing the second half should work??? i think?????
i dont have time to test rn so if anyone else wants to, fine by me. otherwise ill test later today and share what i find
 
awww dang i was really hoping it applied to all districts T^T
anyone happen to know if you could delete the "must be within 6 tiles" requirement for district tourism w/o deleting it for the loyalty bonus (or amenity bonus if youre playing w/ the basegame ability)
looking at the file GreatWarlords_Leaders.xml i think you could take this bit here:

and just delete the second bit and not the first and that'd work? my understanding is that "PLAYER_HAS_FLIGHT_GREATWARLORDS" is the requirement for districts to give tourism, so this bit is saying that "PLAYER_HAS_FLIGHT_GREATWARLORDS" requires 1) that the player have unlocked the flight tech, and 2) that the player has met the "bakuhan requirements", which from looking elsewhere in the code seems to be the "6 tiles from the capital" piece. so theoretically removing the second half should work??? i think?????
i dont have time to test rn so if anyone else wants to, fine by me. otherwise ill test later today and share what i find
quick update: i tested and this did in fact work, ill attach some screenshots showing it working in-game. deleting only the second half of what i quoted should make the +1 tourism apply to all districts w/o making the loyalty/amenity bonus apply to all cities. deleting both would make the tourism apply even before flight, in case anyone was curious :)
Spoiler :
Edo is the capital, and as can be seen, districts further than 6 tiles from Edo are still getting tourism, while only shizuoka (4 tiles from Edo) is getting amenities, and not yokohama (9 tiles from edo). amenities from being within 6 tiles of Edo show up under "amenities from civics". notably, city centers also count as districts and as such also get 1 tourism each
20221217144252_1.jpg
20221217144302_1.jpg
20221217144313_1.jpg
 
Turns out Nader Shah's ability has a mistake, too. The requirement "city is conquered" is not assigned to the requirement set "city is conquered", meaning the requirement always reports as true and domestic trade routes from ALL cities get the bonus.
ok i checked the files on a whim and i think i found the issue youre talking about. it will take me a while before i can test it to make sure this actually works, but i THINK the bolded lines should be added into the GreatWarlords_Leaders.xml file (with the same amount of indents as everything else. not sure if thats important) for anyone who wants the more restrictive ability that better matches the description used in-game
<Row>
<RequirementSetId>OPPONENT_IS_FULL_HEALTH_REQUIREMENTS</RequirementSetId>
<RequirementId>PLAYER_IS_ATTACKER_REQUIREMENTS</RequirementId>
</Row>
<Row>
<RequirementSetId>CITY_WAS_NOT_FOUNDED_BY_THEM_REQUIREMENTS</RequirementSetId>
<RequirementId>REQUIRES_CITY_WAS_NOT_FOUNDED_WARLORDS</RequirementId>
</Row>

</RequirementSetRequirements>
if i understand correctly, the reason why these lines are needed is because otherwise the game has no way of connecting the trade route bonus to the requirement that it be from a city not founded by nader. this SHOULD fix that issue. i think. it looks like it would??? but also i dont really know for sure
Nader Shah's ability has another issue: it gives +3 Faith but the text says +2. No idea which one is the intentional one and which one is the error though.
that would be located at this location in the same file as before. ppl should be able to change the number here to match the description, if they want (or you could make it absurdly high :mischief:)
<Row>
<ModifierId>NADER_SHAH_TRADE_FAITH</ModifierId>
<Name>Amount</Name>
<Value>3</Value>
</Row>

personally, im keeping it as-is in the files since i prefer the less restrictive version of the ability and the additional 1 faith. but it'd be nice if we could rely on abilities actually working as described. thatd be nice, i think
 
if i understand correctly, the reason why these lines are needed is because otherwise the game has no way of connecting the trade route bonus to the requirement that it be from a city not founded by nader. this SHOULD fix that issue. i think. it looks like it would??? but also i dont really know for sure

I'm just a bit baffled this error exists in the first place. You're telling me there's no requirement whatsoever at the moment? I'd understand if they at least had attempted to use a requirement but it turned out it wasn't the correct one or something. But if that's not the case, how did they manage to confuse a simple "+X from trade routes" with "+X from trade routes not founded..." ??

If there's no requirement (even an incorrect one), then this isn't even just lack of attention to detail any longer. It's just lack of attention to fundamentals. Is the person writing the text not the same as the one writing the code?
 
I'm just a bit baffled this error exists in the first place. You're telling me there's no requirement whatsoever at the moment? I'd understand if they at least had attempted to use a requirement but it turned out it wasn't the correct one or something. But if that's not the case, how did they manage to confuse a simple "+X from trade routes" with "+X from trade routes not founded..." ??

If there's no requirement (even an incorrect one), then this isn't even just lack of attention to detail any longer. It's just lack of attention to fundamentals. Is the person writing the text not the same as the one writing the code?

I'll try to give an explanation without being too technical.

Most abilities in the game are granted by "Modifiers." Modifiers can have limitations imposed on them by "RequirementSets," which are simply collections of 1 or more individual "Requirements."

In this case, they made the appropriate Requirement to check for "city not founded by you"." They also made a RequirementSet to "hold" that Requirement, BUT they forgot to link the two together.

Nader Shah's Modifiers for the trade route yields have the intended RequirementSet assigned. However, because the RequirementSet is not linked with the Requirement, it's empty; thus, the trade route bonus applies to all of your cities instead of the intended "only cities not founded by you."

As for the +3 Faith instead of +2 Faith issue--that's a typo. I assume +2 Faith is what was intended, since presumably the description text itself was much more visible to everyone than the code itself.

Overall, these issues are in line with the general decline in polish that we've seen post-Gathering Storm. It's not entirely unexpected anymore, but it's disappointing nonetheless.
 
Last edited:
So, in other words, they bought the gift, they got the box to put it in, wrapped it all up and gave it to you, but they forgot to put the gift in the box, so now you just have an empty box.
 
In this case, they made the appropriate Requirement to check for "city not founded by you"." They also made a RequirementSet to "hold" that Requirement, BUT they forgot to link the two together.
Ok, so that's not so egregious as forgetting to set a Requirement entirely. Still, they clearly didn't test the ability because if they did it would be a "oh, right, forgot that" moment.
 
Top Bottom