31 lines
713 B
Plaintext
Raw Permalink Normal View History

void SetPLocalInt(object oPC,string sLocalName, int nValue)
{
object oMember;
oMember = GetFirstFactionMember(oPC);
while (GetIsObjectValid(oMember))
{
SetLocalInt(oMember,sLocalName,nValue);
oMember = GetNextFactionMember(oPC);
}
return;
}
void main()
{
object oPC = GetLastUsedBy();
if(GetIsSkillSuccessful(oPC,SKILL_DISABLE_TRAP,20) && GetLocalInt(oPC,"DeTrapped") == 0)
{
PlayAnimation(ANIMATION_PLACEABLE_ACTIVATE);
SetPLocalInt(oPC,"DeTrapped",1);
FloatingTextStringOnCreature("You hear a loud creaking from the corridor much like metal sliding over stone...",oPC);
GiveXPToCreature(oPC,100);
}
else
{
FloatingTextStringOnCreature("Nothing happens...",oPC);
}
}