Nightinggale
Deity
- Joined
- Feb 2, 2009
- Messages
- 5,378
I just encountered an assert, investigated and fixed it. It turned out that the natives tried to sell -95 weapons for the price of 5. Sounds like a real bargain 
Either way it resulted in negative yields being stored in a city, hence the assert. I made the AI check for stored yields it's willing to sell. The problem was one check for stored yields without checking if the city wanted to sell it.

Either way it resulted in negative yields being stored in a city, hence the assert. I made the AI check for stored yields it's willing to sell. The problem was one check for stored yields without checking if the city wanted to sell it.
File: CvCity.cpp
Line: 4884
Expression: iValue >= 0 || eYield == YIELD_FOOD