Initial upload
Initial upload
This commit is contained in:
68
_module/nss/fky_chat_levelup.nss
Normal file
68
_module/nss/fky_chat_levelup.nss
Normal file
@@ -0,0 +1,68 @@
|
||||
//::////////////////////////////////////////////////////////////////////////:://
|
||||
//:: SIMTools V2.1 Speech Integration & Management Tools Version 2.1 :://
|
||||
//:: Created By: FunkySwerve :://
|
||||
//:: Created On: April 4 2006 :://
|
||||
//:: Last Updated: September 29 2006 :://
|
||||
//:: With Thanks To: :://
|
||||
//:: Dumbo - for his amazing plugin :://
|
||||
//:: Virusman - for Linux versions, and for the reset plugin :://
|
||||
//:: Dazzle - for his script samples :://
|
||||
//:: Butch - for the emote wand scripts :://
|
||||
//:: The DMFI project - for the languages conversions and many of the emotes:://
|
||||
//:: Lanessar and the players of the Myth Drannor PW - for the new languages:://
|
||||
//::////////////////////////////////////////////////////////////////////////:://
|
||||
#include "fky_chat_inc"
|
||||
void main()
|
||||
{
|
||||
if (ENABLE_LANGUAGES)//check to see if they gained a level in a language class, and if so, add that language
|
||||
{
|
||||
object oPC = GetPCLevellingUp();
|
||||
if (USING_NWNX_DB)
|
||||
{
|
||||
if ((GetLevelByClass(CLASS_TYPE_RANGER, oPC) || GetLevelByClass(CLASS_TYPE_DRUID, oPC)) && (!GetLocalInt(oPC, "FKY_CHAT_LANG37")))
|
||||
{
|
||||
SetLocalInt(oPC, "FKY_CHAT_LANG37", TRUE);
|
||||
SetPersistentInt(oPC, "FKY_CHAT_LANG37", TRUE);
|
||||
}
|
||||
if (GetLevelByClass(CLASS_TYPE_ROGUE, oPC) && (!GetLocalInt(oPC, "FKY_CHAT_LANG44")))
|
||||
{
|
||||
SetLocalInt(oPC, "FKY_CHAT_LANG44", TRUE);
|
||||
SetPersistentInt(oPC, "FKY_CHAT_LANG44", TRUE);
|
||||
}
|
||||
if (GetLevelByClass(CLASS_TYPE_ASSASSIN, oPC) && (!GetLocalInt(oPC, "FKY_CHAT_LANG5")))
|
||||
{
|
||||
SetLocalInt(oPC, "FKY_CHAT_LANG5", TRUE);
|
||||
SetPersistentInt(oPC, "FKY_CHAT_LANG5", TRUE);
|
||||
}
|
||||
if (GetLevelByClass(CLASS_TYPE_DRUID, oPC) && (!GetLocalInt(oPC, "FKY_CHAT_LANG14")))
|
||||
{
|
||||
SetLocalInt(oPC, "FKY_CHAT_LANG14", TRUE);
|
||||
SetPersistentInt(oPC, "FKY_CHAT_LANG14", TRUE);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
object oStorage = GetItemPossessedBy(oPC, TAG_OF_LANGUAGE_STORAGE_OBJECT);
|
||||
if ((GetLevelByClass(CLASS_TYPE_RANGER, oPC) || GetLevelByClass(CLASS_TYPE_DRUID, oPC)) && (!GetLocalInt(oPC, "FKY_CHAT_LANG37")))
|
||||
{
|
||||
SetLocalInt(oPC, "FKY_CHAT_LANG37", TRUE);
|
||||
SetLocalInt(oStorage, "FKY_CHAT_LANG37", TRUE);
|
||||
}
|
||||
if (GetLevelByClass(CLASS_TYPE_ROGUE, oPC) && (!GetLocalInt(oPC, "FKY_CHAT_LANG44")))
|
||||
{
|
||||
SetLocalInt(oPC, "FKY_CHAT_LANG44", TRUE);
|
||||
SetLocalInt(oStorage, "FKY_CHAT_LANG44", TRUE);
|
||||
}
|
||||
if (GetLevelByClass(CLASS_TYPE_ASSASSIN, oPC) && (!GetLocalInt(oPC, "FKY_CHAT_LANG5")))
|
||||
{
|
||||
SetLocalInt(oPC, "FKY_CHAT_LANG5", TRUE);
|
||||
SetLocalInt(oStorage, "FKY_CHAT_LANG5", TRUE);
|
||||
}
|
||||
if (GetLevelByClass(CLASS_TYPE_DRUID, oPC) && (!GetLocalInt(oPC, "FKY_CHAT_LANG14")))
|
||||
{
|
||||
SetLocalInt(oPC, "FKY_CHAT_LANG14", TRUE);
|
||||
SetLocalInt(oStorage, "FKY_CHAT_LANG14", TRUE);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user