ES_PRC8/_module/nss/takemarkfalse.nss
Jaysyn904 08e84b4e71 Initial upload
Initial upload.
2023-11-14 12:09:02 -05:00

79 lines
1.6 KiB
Plaintext

//::///////////////////////////////////////////////
//:: FileName takemarkfalse
//:://////////////////////////////////////////////
//:://////////////////////////////////////////////
//:: Created By: Script Wizard
//:: Created On: 9/30/2002 1:32:55 AM
//:://////////////////////////////////////////////
#include "nw_i0_tool"
void RemoveAllEffects( object oPlayer )
{
effect eEffect;
eEffect = GetFirstEffect(oPlayer);
while ( GetIsEffectValid(eEffect) == TRUE )
{
if ( GetEffectDurationType(eEffect) == DURATION_TYPE_TEMPORARY ||
GetEffectDurationType(eEffect) == DURATION_TYPE_PERMANENT )
{
RemoveEffect(oPlayer,eEffect);
}
eEffect = GetNextEffect(oPlayer);
}
}
void main()
{
object oTalkingPC = GetPCSpeaker();
object oInvItem;
int nTeam = GetLocalInt(oTalkingPC, "m_nTeam");
int nScore, nHasMark;
/* if(nTeam < 1) {
return;
}
if(nTeam == 1) {
nScore = GetLocalInt(OBJECT_SELF, "m_nGoodScore");
}
if(nTeam == 2) {
nScore = GetLocalInt(OBJECT_SELF, "m_nEvilScore");
}
*/
oInvItem = GetFirstItemInInventory(oTalkingPC);
// while (oInvItem != OBJECT_INVALID)
while (GetIsObjectValid(oInvItem) != 0)
{
if (GetTag(oInvItem) == "FalseMark") {
DestroyObject(oInvItem);
}
oInvItem = GetNextItemInInventory(oTalkingPC);
}
if(HasItem(oTalkingPC, "MarkofGamlee"))
nHasMark = 1;
if(HasItem(oTalkingPC, "MarkofOron"))
nHasMark = 1;
if(HasItem(oTalkingPC, "MarkofMaro"))
nHasMark = 1;
if(HasItem(oTalkingPC, "MarkofOron"))
nHasMark = 1;
if(nHasMark == 0) {
RemoveAllEffects(oTalkingPC);
}
}