Remade Dungeon Level One: Central
Remade Dungeon Level One: Central. Added Didiamus' creature overrides. Full compile.
This commit is contained in:
110
_module/nss/sc_spot_dc10.nss
Normal file
110
_module/nss/sc_spot_dc10.nss
Normal file
@@ -0,0 +1,110 @@
|
||||
//:: Returns true if the PC passes a DC 10 spot check.
|
||||
//:: Only allows one chance to search
|
||||
|
||||
int StartingConditional()
|
||||
{
|
||||
object oPC = GetPCSpeaker();
|
||||
string sPlacableTag = GetTag(OBJECT_SELF);
|
||||
int nPlayerSpotted = GetLocalInt(oPC, "PlayerSpotted_" + sPlacableTag); // Unique flag for each player
|
||||
|
||||
// Check if the player has already attempted spotting at this placable
|
||||
if (nPlayerSpotted == 1)
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
// Check if the player's search skill check is successful against DC 10
|
||||
if (GetIsSkillSuccessful(oPC, SKILL_SPOT, 10))
|
||||
{
|
||||
// Set the flag on the player to ensure it's only run once per player
|
||||
SetLocalInt(oPC, "PlayerSpotted_" + sPlacableTag, 1);
|
||||
|
||||
return TRUE; // Condition met, continue with the conversation
|
||||
}
|
||||
else
|
||||
{
|
||||
// Set the flag on the player to ensure it's only run once per player
|
||||
SetLocalInt(oPC, "PlayerSpotted_" + sPlacableTag, 1);
|
||||
return FALSE;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
//:: Returns true if PC passes a DC 10 search check
|
||||
|
||||
/*int StartingConditional()
|
||||
{
|
||||
//:: Declare major variables
|
||||
object oPC = GetPCSpeaker();
|
||||
|
||||
// Check if the player's search skill check is successful against DC 10
|
||||
if (GetIsSkillSuccessful(oPC, SKILL_SEARCH, 10))
|
||||
{
|
||||
//:: Player passed the search check
|
||||
return TRUE;
|
||||
}
|
||||
else
|
||||
{
|
||||
//:: Player failed the search check
|
||||
return FALSE;
|
||||
}
|
||||
} */
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
//:: Returns true if PC passes a DC 10 search check
|
||||
|
||||
/*int StartingConditional()
|
||||
{
|
||||
//:: Declare major variables
|
||||
object oPC = GetPCSpeaker();
|
||||
|
||||
// Check if the player's search skill check is successful against DC 10
|
||||
if (GetIsSkillSuccessful(oPC, SKILL_SEARCH, 10))
|
||||
{
|
||||
//:: Player passed the search check
|
||||
return TRUE;
|
||||
}
|
||||
else
|
||||
{
|
||||
//:: Player failed the search check
|
||||
return FALSE;
|
||||
}
|
||||
} */
|
Reference in New Issue
Block a user