Bazaar developer reference

CvMinorCivAI::AddQuestNotification(CvString, CvString, PlayerTypes, int, int, bool)

Defined in
CvMinorCivAI.cpp, line 3181
Class
CvMinorCivAI
Hook name
CivHooks::CvMinorCivAI_AddQuestNotification

Hooks

static bool BeforeCvMinorCivAI_AddQuestNotification(CvMinorCivAI* self, CvString sString, CvString sSummaryString, PlayerTypes ePlayer, int iX, int iY, bool bNewQuest);static void AfterCvMinorCivAI_AddQuestNotification(CvMinorCivAI* self, CvString sString, CvString sSummaryString, PlayerTypes ePlayer, int iX, int iY, bool bNewQuest);static void ReplaceCvMinorCivAI_AddQuestNotification(void (*original)(CvMinorCivAI*, CvString, CvString, PlayerTypes, int, int, bool), CvMinorCivAI* self, CvString sString, CvString sSummaryString, PlayerTypes ePlayer, int iX, int iY, bool bNewQuest);CivRegisterBefore<CivHooks::CvMinorCivAI_AddQuestNotification>(host, &BeforeCvMinorCivAI_AddQuestNotification);CivRegisterAfter<CivHooks::CvMinorCivAI_AddQuestNotification>(host, &AfterCvMinorCivAI_AddQuestNotification);CivRegisterReplace<CivHooks::CvMinorCivAI_AddQuestNotification>(host, &ReplaceCvMinorCivAI_AddQuestNotification);

Code

3180/// Quest Notifications3181void CvMinorCivAI::AddQuestNotification(CvString sString, CvString sSummaryString, PlayerTypes ePlayer, int iX, int iY, bool bNewQuest)3182{3183	CvNotifications* pNotifications = GET_PLAYER(ePlayer).GetNotifications();3184	if(pNotifications)3185	{3186		sString += "[NEWLINE][NEWLINE]";3187		sString += Localization::Lookup("TXT_KEY_MINOR_QUEST_BLOCKING_TT").toUTF8();31883189		if (bNewQuest)3190			pNotifications->Add(NOTIFICATION_MINOR_QUEST, sString, sSummaryString, iX, iY, GetPlayer()->GetID(), 1);3191		else3192			pNotifications->Add(NOTIFICATION_MINOR_QUEST, sString, sSummaryString, iX, iY, GetPlayer()->GetID());3193	}3194}

Calls

Called by