Initial commit
Adding all of the current content for Anphillia Unlimited.
This commit is contained in:
52
_module/nss/cnr_at_j_sel_9.nss
Normal file
52
_module/nss/cnr_at_j_sel_9.nss
Normal file
@@ -0,0 +1,52 @@
|
||||
/////////////////////////////////////////////////////////
|
||||
//
|
||||
// Craftable Natural Resources (CNR) by Festyx
|
||||
//
|
||||
// Name: cnr_at_j_sel_9
|
||||
//
|
||||
// Desc: This script is run by the cnr_c_journal convo
|
||||
// when the player selects a trade.
|
||||
//
|
||||
// Author: David Bobeck 03May03
|
||||
//
|
||||
/////////////////////////////////////////////////////////
|
||||
#include "cnr_recipe_utils"
|
||||
|
||||
void main()
|
||||
{
|
||||
object oPC = GetPCSpeaker();
|
||||
object oTarget = GetLocalObject(oPC, "oCnrJournalTarget");
|
||||
|
||||
int bDMAdjustingXP = GetLocalInt(oPC, "bCnrDMAdjustingXP");
|
||||
if (bDMAdjustingXP == TRUE)
|
||||
{
|
||||
int nMenuPage = GetLocalInt(oPC, "nCnrXpMenuPage");
|
||||
int nTradeskillIndex = GetLocalInt(oPC, "nCnrAdjustingTradeIndex");
|
||||
int nXP;
|
||||
if (nMenuPage == 0)
|
||||
{
|
||||
// Level 9
|
||||
nXP = GetLocalInt(GetModule(), "CnrTradeXPLevel" + IntToString(9));
|
||||
}
|
||||
else if (nMenuPage == 1)
|
||||
{
|
||||
// Level 19
|
||||
nXP = GetLocalInt(GetModule(), "CnrTradeXPLevel" + IntToString(19));
|
||||
}
|
||||
else
|
||||
{
|
||||
// - 1000
|
||||
nXP = CnrGetTradeskillXPByIndex(oTarget, nTradeskillIndex);
|
||||
nXP -= 1000;
|
||||
}
|
||||
|
||||
CnrSetTradeskillXPByIndex(oTarget, nTradeskillIndex, nXP);
|
||||
return;
|
||||
}
|
||||
|
||||
int bTopTenVisible = GetLocalInt(oPC, "bCnrTopTenVisible");
|
||||
if (bTopTenVisible == FALSE)
|
||||
{
|
||||
SetLocalInt(oPC, "nCnrJournalSelIndex", 9);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user