Battledale_PRC8/_module/nss/fr_iwd_testogre1.nss
Jaysyn904 7b9e44ebbb Initial upload
Initial upload.  PRC8 has been added.  Module compiles, PRC's default AI & treasure scripts have been integrated.  Started work on top hak for SLA / Ability / Scripting modifications.
2024-03-11 23:44:08 -04:00

33 lines
933 B
Plaintext

void main()
{
object oPC = GetLastUsedBy();
object oS = GetWaypointByTag("fr_iwd_ogre_jump1");
object oF = GetWaypointByTag("fr_iwd_ogre_pit1");
if (GetIsPC(oPC)== TRUE)
{
int nDex = GetAbilityScore(oPC, ABILITY_DEXTERITY);
int nStr = GetAbilityScore(oPC, ABILITY_STRENGTH);
int nDice = d20(1);
int nScore = nDex + nStr + nDice;
string sDex = IntToString(nDex);
string sStr = IntToString(nStr);
string sDice = IntToString(nDice);
string sScore = IntToString(nScore);
string sBigScore = "Test: "+sDex+"(dex) + "+sStr+"(str) + "+sDice+"(d20) = "+sScore;
if(nDex + nStr + nDice >= 33)
{
AssignCommand (oPC,JumpToObject(oS));
PlaySound("fs_hoof_large2");
SendMessageToPC(oPC, sBigScore);
}
else
{
AssignCommand (oPC,JumpToObject(oF));
PlaySound("fs_hoof_large2");
SendMessageToPC(oPC, sBigScore);
}
}
}