46 lines
1.4 KiB
Plaintext
46 lines
1.4 KiB
Plaintext
|
int StartingConditional()
|
||
|
{
|
||
|
int iResult;
|
||
|
int iNPCQuests;
|
||
|
int iIndex;
|
||
|
string sName;
|
||
|
string sQuestNPC;
|
||
|
|
||
|
iResult = FALSE;
|
||
|
|
||
|
iNPCQuests = GetLocalInt(OBJECT_SELF,"QuestsCompleted");
|
||
|
iIndex = 1;
|
||
|
//SendMessageToPC(GetFirstPC(),"Quests Completed = " + IntToString(iNPCQuests));
|
||
|
|
||
|
while (iIndex <= iNPCQuests)
|
||
|
{
|
||
|
sName = GetLocalString(OBJECT_SELF,"QUEST_PC" + IntToString(iIndex));
|
||
|
//SendMessageToPC(GetFirstPC(),"QUEST_PC" + IntToString(iIndex) + " = " + sName);
|
||
|
if (sName == GetName(GetPCSpeaker()))
|
||
|
iResult = TRUE;
|
||
|
iIndex++;
|
||
|
}
|
||
|
|
||
|
if (iResult == FALSE)
|
||
|
{
|
||
|
SetCustomToken(101,GetLocalString(GetPCSpeaker(),"Token101"));
|
||
|
SetCustomToken(102,GetLocalString(GetPCSpeaker(),"Token102"));
|
||
|
SetCustomToken(103,GetLocalString(GetPCSpeaker(),"Token103"));
|
||
|
SetCustomToken(104,GetLocalString(GetPCSpeaker(),"Token104"));
|
||
|
SetCustomToken(105,GetLocalString(GetPCSpeaker(),"Token105"));
|
||
|
SetCustomToken(106,GetLocalString(GetPCSpeaker(),"Token106"));
|
||
|
SetCustomToken(107,GetLocalString(GetPCSpeaker(),"Token107"));
|
||
|
SetCustomToken(108,GetLocalString(GetPCSpeaker(),"Token108"));
|
||
|
SetCustomToken(110,GetLocalString(GetPCSpeaker(),"Token110"));
|
||
|
|
||
|
if (GetLocalString(GetPCSpeaker(),"Token120") == "")
|
||
|
SetCustomToken(120,"What do you need?");
|
||
|
else
|
||
|
SetCustomToken(120,GetLocalString(GetPCSpeaker(),"Token120"));
|
||
|
|
||
|
|
||
|
}
|
||
|
|
||
|
return iResult;
|
||
|
}
|