[154] Spoils of War SP still active after switching to freedom

Taroshin

Chieftain
Joined
May 12, 2012
Messages
7
I just played a game where I'd unlocked Nationalism and taken Spoils of War. I then changed plans and switched to Freedom policy but noticed I was still getting the cultural plunder when capturing cities.
I was playing as India so it wasn't a Denmark/Jelling Stone issue. After the first time it happened I checked before/after capturing the next town to make sure it wasn't just the message, I was definitely getting the culture added to my pool.
 
I don't think I can fix this. The bug appears to be in the inaccessible vanilla player:HasPolicy function:
PHP:
for policyInfo in GameInfo.Policies("CityCaptureCulture != 0") do
  if player:HasPolicy(policyInfo.ID) then
    CityCaptureYield(capturedCity,
      YieldTypes.YIELD_CULTURE,
      policyInfo.CityCaptureCulture,
      policyInfo.CityCaptureCulturePerPop,
      policyInfo.CityCaptureCulturePerEra,
      policyInfo.CityCaptureCulturePerEraExponent
      )
  end
end
 
No worries Thal, thanks for the reply. It seemed a rare enough situation (switching policies like I did) that I figured I'd mention it in case it was unknown.

p.s. Love your work and the efforts of all modders involved. :)
 
Top Bottom