Yeah I do, I believe you are ready to handle it, good luck. ^^Toffer do you still have that post you once made that presented a way to solve the bark (bonus) -> bark (promotion) issues in the Civopedia?
Link
Yeah I do, I believe you are ready to handle it, good luck. ^^Toffer do you still have that post you once made that presented a way to solve the bark (bonus) -> bark (promotion) issues in the Civopedia?
Traceback (most recent call last):
File "CvScreensInterface", line 251, in linkToPedia
File "Pedia", line 1275, in link
UnicodeEncodeError: 'ascii' codec can't encode characters in position 0-4: ordinal not in range(128)
ERR: Python function linkToPedia failed, module CvScreensInterface
Hmm, looks like a text formatting issue.The thing is that supposedly .getType should get what's defined in <Type> (e.g. BONUS_BARK), but it doesn't do this as it only outputs a single letter. The game then tries to link it to said letter and it can't find anything with that, of course.
View attachment 513383
Great.@Toffer90 that worked.![]()
That's the idea. ^^EDIT: By the way, do I do the same (replace LINK=literal) for every tag in game?
I think that's some code stuff that isn't related to the PPIO. It's very tricky to make it behave properly and still get a decent AI out of it because the whole thing tries too hard to be predictive for the sake of the same functions tying into the way the AI makes its selections. This would be very difficult to repair and it freaks me out to be honest because there's so much capacity here for introducing really bad bugs. I might try again to resolve this and improve the functioning at some point - isolating this out for when human players are making selections to entirely different functions would probably be a good place to start.I found a somewhat annoying issue that could have to do with PPIO or not.
When you want to change specialists inside the city view you first click on the arrow down of e.g. Engineer, that reduces the Engineers by one and creates one Citizen. If you now click the arrow up of e.g. Priest then the one Citizen remains, instead one worker from the map is taken away. When you now click on the map where the worker has been taken away he returns and the Citizen's numbers are back to zero - this is what I wanted from the start but why is this extra step needed? This only happens with smaller cities where not every tile on the fat cross is worked on.
My wish is that if I want to add to specialists and if there are "Citizen" specialists available then those should be reduced and not the workers from the map (btw, this works alright with any numbers of Citizens of 2 and higher but not with the last one).
Idle is only removed when other processes are available.I tried your modmod and i#m still pleased.
One thing i want to ask: you removed idle from the building queue.
Is it possible to reinstall it?
Is there any reason to do idle instead of the other processes?
You cant save hammersYou can also idle by not selecting anything and leaving the city screen, either by clicking on the map or pressing ESC.
Saving hammers for wonders, perhaps.
I use building queues and or add multiple buildings to the buildlist.Idle is only removed when other processes are available.
Is there any reason to do idle instead of the other processes?
int CvPlayer::calculateScore(bool bFinal, bool bVictory) const
{
PROFILE_FUNC();
if (!isAlive())
{
return 0;
}
if (GET_TEAM(getTeam()).getNumMembers() == 0)
{
return 0;
}
/************************************************************************************************/
/* Afforess Start 06/25/10 */
/* */
/* Calculating the Score from python is time consuming */
/************************************************************************************************/
/*
long lScore = 0;
CyArgsList argsList;
argsList.add((int) getID());
argsList.add(bFinal);
argsList.add(bVictory);
PYTHON_CALL_FUNCTION(__FUNCTION__, PYGameModule, "calculateScore", argsList.makeFunctionArgs(), &lScore);
return ((int)lScore);
*/
int iPopulationScore = getScoreComponent(getPopScore(), GC.getGameINLINE().getInitPopulation(), GC.getGameINLINE().getMaxPopulation(), GC.getSCORE_POPULATION_FACTOR(), true, bFinal, bVictory);
int iLandScore = getScoreComponent(getLandScore(), GC.getGameINLINE().getInitLand(), GC.getGameINLINE().getMaxLand(), GC.getSCORE_LAND_FACTOR(), true, bFinal, bVictory);
int iTechScore = getScoreComponent(getTechScore(), GC.getGameINLINE().getInitTech(), GC.getGameINLINE().getMaxTech(), GC.getSCORE_TECH_FACTOR(), true, bFinal, bVictory);
int iWondersScore = getScoreComponent(getWondersScore(), GC.getGameINLINE().getInitWonders(), GC.getGameINLINE().getMaxWonders(), GC.getSCORE_WONDER_FACTOR(), false, bFinal, bVictory);
return iPopulationScore + iLandScore + iTechScore + iWondersScore;
Start timer // I wouldn't know how a timer may look like in c++ code, that's why I need you.
long lScore = 0;
CyArgsList argsList;
argsList.add((int) getID());
argsList.add(bFinal);
argsList.add(bVictory);
PYTHON_CALL_FUNCTION(__FUNCTION__, PYGameModule, "calculateScore", argsList.makeFunctionArgs(), &lScore);
End Timer and log result.
Start new timer
int iPopulationScore = getScoreComponent(getPopScore(), GC.getGameINLINE().getInitPopulation(), GC.getGameINLINE().getMaxPopulation(), GC.getSCORE_POPULATION_FACTOR(), true, bFinal, bVictory);
int iLandScore = getScoreComponent(getLandScore(), GC.getGameINLINE().getInitLand(), GC.getGameINLINE().getMaxLand(), GC.getSCORE_LAND_FACTOR(), true, bFinal, bVictory);
int iTechScore = getScoreComponent(getTechScore(), GC.getGameINLINE().getInitTech(), GC.getGameINLINE().getMaxTech(), GC.getSCORE_TECH_FACTOR(), true, bFinal, bVictory);
int iWondersScore = getScoreComponent(getWondersScore(), GC.getGameINLINE().getInitWonders(), GC.getGameINLINE().getMaxWonders(), GC.getSCORE_WONDER_FACTOR(), false, bFinal, bVictory);
iPopulationScore + iLandScore + iTechScore + iWondersScore; // return this to void to include the return statement in the timer even though it wouldn't take any time at all really.
End Timer and log result.
return iPopulationScore + iLandScore + iTechScore + iWondersScore;
One could also use the CPU clock at the start and at the end to see the time difference, I think...I think it's possible to use the IDE to measure that directly. I'll take a look at it.