CvActionInfo::isConfirmCommand() const
- Defined in
- CvInfos.cpp, line 1147
- Class
- CvActionInfo
- Hook name
CivHooks::CvActionInfo_isConfirmCommand
Hooks
static bool BeforeCvActionInfo_isConfirmCommand(const CvActionInfo* self, bool& result);static void AfterCvActionInfo_isConfirmCommand(const CvActionInfo* self, bool& result);static bool ReplaceCvActionInfo_isConfirmCommand(bool (*original)(const CvActionInfo*), const CvActionInfo* self);CivRegisterBefore<CivHooks::CvActionInfo_isConfirmCommand>(host, &BeforeCvActionInfo_isConfirmCommand);CivRegisterAfter<CivHooks::CvActionInfo_isConfirmCommand>(host, &AfterCvActionInfo_isConfirmCommand);CivRegisterReplace<CivHooks::CvActionInfo_isConfirmCommand>(host, &ReplaceCvActionInfo_isConfirmCommand);
Code
1147bool CvActionInfo::isConfirmCommand() const1148{1149 if(ACTIONSUBTYPE_COMMAND == m_eSubType)1150 {1151 CvCommandInfo* pkCommandInfo = GC.getCommandInfo((CommandTypes)m_iOriginalIndex);1152 if(pkCommandInfo)1153 {1154 return pkCommandInfo->getConfirmCommand();1155 }1156 }1157 else if(ACTIONSUBTYPE_AUTOMATE == m_eSubType)1158 {1159 CvAutomateInfo* pkAutomateInfo = GC.getAutomateInfo(m_iOriginalIndex);1160 if(pkAutomateInfo)1161 {1162 return pkAutomateInfo->getConfirmCommand();1163 }1164 }11651166 return false;1167}