Spawner switchover.
Spawner switch over. PnP Umberhulks & Stone Golems. A real search check in Level 10a - Small Cave. Respawning placeables in 10a - Umber Hulk Cave & 10a - Small Cave
This commit is contained in:
27
_module/nss/ra_disarmtrap01.nss
Normal file
27
_module/nss/ra_disarmtrap01.nss
Normal file
@@ -0,0 +1,27 @@
|
||||
//Disarm Trap XP award for Thieves
|
||||
//Operates on this math: (TrapDC * XPMultiplier) - (ThiefLevel x Skill) = XP Award
|
||||
// Created by Todmaerin 6/22/02
|
||||
// Modified 6/30/02
|
||||
|
||||
object oThief = GetLastDisarmed();
|
||||
void main()
|
||||
{
|
||||
string sThiefLevel;
|
||||
int nPosition;
|
||||
int nRogueTrue;
|
||||
for (nPosition= 1; nPosition <= 3; nPosition ++)
|
||||
{
|
||||
nRogueTrue = GetLocalInt(oThief, IntToString(GetClassByPosition (nPosition, oThief) ));
|
||||
};
|
||||
if (nRogueTrue = CLASS_TYPE_ROGUE)
|
||||
{
|
||||
sThiefLevel = IntToString(GetLevelByClass (CLASS_TYPE_ROGUE, oThief));
|
||||
int nDisarmSkill = GetSkillRank(SKILL_DISABLE_TRAP, oThief);
|
||||
int nTrapDC = GetTrapDisarmDC(OBJECT_SELF);
|
||||
float fXPMod = 1.2;
|
||||
//the math
|
||||
int nXPAward = FloatToInt((nTrapDC * fXPMod) - (StringToInt(sThiefLevel) * nDisarmSkill));
|
||||
GiveXPToCreature (oThief, nXPAward);
|
||||
}
|
||||
|
||||
}
|
Reference in New Issue
Block a user