Hi team, something I think someone here helped me figure out but am not sure how to do anymore, it's a C++ language question :
How do you refer in a function to "the ID of yourself" ?
Here for example, I just want to pass in my logic the ID of the LeaderHeadInfo (I've put 12 as a placeholder but it's not good enough of course, I need to pass the real ID as first attribute)
This is from CvInfo.cpp :
How do you refer in a function to "the ID of yourself" ?
Here for example, I just want to pass in my logic the ID of the LeaderHeadInfo (I've put 12 as a placeholder but it's not good enough of course, I need to pass the real ID as first attribute)
This is from CvInfo.cpp :
Code:
void CvLeaderHeadInfo::setHasTrait(int i, bool bNewValue)
{
if (hasTrait(i) != bNewValue)
{
m_pbTraits = bNewValue;
}
//2.42n We need to store this, because some leaders will now have new traits and not be played
GC.getGameINLINE().storeLeaderTrait(12,i,bNewValue);
}