Files
Anphillia_PRC8/_module/nss/chd_on_conver.nss
Jaysyn904 28cdb617b3 Initial commit
Adding all of the current content for Anphillia Unlimited.
2024-01-04 07:49:38 -05:00

34 lines
800 B
Plaintext

/*
** CHD 0.0.1
** Author: Krisztian PIFKO <monsta@monsta.hu>
** License: GPL
** Last modified: 2004-12-04
**
** chd_on_conver.nss: look for spoken pattern of a PC and change it's deity
**
** use it in an NPC's on conversation event
*/
void main()
{
object oPC=GetLastSpeaker();
int nConversation = GetListenPatternNumber();
if (GetIsPC(oPC)){
if (nConversation == -1 && GetCommandable(OBJECT_SELF))
{
ClearAllActions();
BeginConversation();
}
if (nConversation==50){
string sNewDeity=GetMatchedSubstring(0);
if (sNewDeity!=""){
SetDeity(oPC,sNewDeity);
FloatingTextStringOnCreature("Your new deity is now "+sNewDeity+".",oPC,FALSE);
}
}
}
}