Updated for NWNEE 37-13
Updated for NWNEE 37-13. Updated NWNxEE. Full compile. Updated release archive.
This commit is contained in:
@@ -2,7 +2,6 @@
|
||||
/// @brief Replacement for ValidateCharacter: ELC & ILR
|
||||
/// @{
|
||||
/// @file nwnx_elc.nss
|
||||
#include "nwnx"
|
||||
|
||||
const string NWNX_ELC = "NWNX_ELC"; ///< @private
|
||||
|
||||
@@ -21,11 +20,8 @@ const int NWNX_ELC_VALIDATION_FAILURE_TYPE_CUSTOM = 6;
|
||||
|
||||
/// @anchor elc_fail_subtype
|
||||
/// @name ELC Failure Subtypes
|
||||
/// @note By default these constants are commented out to avoid a
|
||||
/// limitation on constants. Uncomment them as needed.
|
||||
/// @{
|
||||
const int NWNX_ELC_SUBTYPE_NONE = 0;
|
||||
/*
|
||||
const int NWNX_ELC_SUBTYPE_SERVER_LEVEL_RESTRICTION = 1;
|
||||
const int NWNX_ELC_SUBTYPE_LEVEL_HACK = 2;
|
||||
const int NWNX_ELC_SUBTYPE_COLORED_NAME = 3;
|
||||
@@ -75,7 +71,7 @@ const int NWNX_ELC_SUBTYPE_SKILL_LIST_COMPARISON = 48;
|
||||
const int NWNX_ELC_SUBTYPE_FEAT_LIST_COMPARISON = 49;
|
||||
const int NWNX_ELC_SUBTYPE_MISC_SAVING_THROW = 50;
|
||||
const int NWNX_ELC_SUBTYPE_NUM_FEAT_COMPARISON = 51;
|
||||
*/
|
||||
const int NWNX_ELC_SUBTYPE_NUM_MULTICLASS = 52;
|
||||
/// @}
|
||||
|
||||
/// @brief Sets the script that runs whenever an ELC validation failure happens
|
||||
@@ -150,95 +146,71 @@ int NWNX_ELC_GetValidationFailureSpellID();
|
||||
|
||||
void NWNX_ELC_SetELCScript(string sScript)
|
||||
{
|
||||
string sFunc = "SetELCScript";
|
||||
|
||||
NWNX_PushArgumentString(NWNX_ELC, sFunc, sScript);
|
||||
NWNX_CallFunction(NWNX_ELC, sFunc);
|
||||
NWNXPushString(sScript);
|
||||
NWNXCall(NWNX_ELC, "SetELCScript");
|
||||
}
|
||||
|
||||
void NWNX_ELC_EnableCustomELCCheck(int bEnabled)
|
||||
{
|
||||
string sFunc = "EnableCustomELCCheck";
|
||||
|
||||
NWNX_PushArgumentInt(NWNX_ELC, sFunc, bEnabled);
|
||||
NWNX_CallFunction(NWNX_ELC, sFunc);
|
||||
NWNXPushInt(bEnabled);
|
||||
NWNXCall(NWNX_ELC, "EnableCustomELCCheck");
|
||||
}
|
||||
|
||||
void NWNX_ELC_SkipValidationFailure()
|
||||
{
|
||||
string sFunc = "SkipValidationFailure";
|
||||
|
||||
NWNX_CallFunction(NWNX_ELC, sFunc);
|
||||
NWNXCall(NWNX_ELC, "SkipValidationFailure");
|
||||
}
|
||||
|
||||
int NWNX_ELC_GetValidationFailureType()
|
||||
{
|
||||
string sFunc = "GetValidationFailureType";
|
||||
|
||||
NWNX_CallFunction(NWNX_ELC, sFunc);
|
||||
return NWNX_GetReturnValueInt(NWNX_ELC, sFunc);
|
||||
NWNXCall(NWNX_ELC, "GetValidationFailureType");
|
||||
return NWNXPopInt();
|
||||
}
|
||||
|
||||
int NWNX_ELC_GetValidationFailureSubType()
|
||||
{
|
||||
string sFunc = "GetValidationFailureSubType";
|
||||
|
||||
NWNX_CallFunction(NWNX_ELC, sFunc);
|
||||
return NWNX_GetReturnValueInt(NWNX_ELC, sFunc);
|
||||
NWNXCall(NWNX_ELC, "GetValidationFailureSubType");
|
||||
return NWNXPopInt();
|
||||
}
|
||||
|
||||
int NWNX_ELC_GetValidationFailureMessageStrRef()
|
||||
{
|
||||
string sFunc = "GetValidationFailureMessageStrRef";
|
||||
|
||||
NWNX_CallFunction(NWNX_ELC, sFunc);
|
||||
return NWNX_GetReturnValueInt(NWNX_ELC, sFunc);
|
||||
NWNXCall(NWNX_ELC, "GetValidationFailureMessageStrRef");
|
||||
return NWNXPopInt();
|
||||
}
|
||||
|
||||
void NWNX_ELC_SetValidationFailureMessageStrRef(int nStrRef)
|
||||
{
|
||||
string sFunc = "SetValidationFailureMessageStrRef";
|
||||
|
||||
NWNX_PushArgumentInt(NWNX_ELC, sFunc, nStrRef);
|
||||
NWNX_CallFunction(NWNX_ELC, sFunc);
|
||||
NWNXPushInt(nStrRef);
|
||||
NWNXCall(NWNX_ELC, "SetValidationFailureMessageStrRef");
|
||||
}
|
||||
|
||||
object NWNX_ELC_GetValidationFailureItem()
|
||||
{
|
||||
string sFunc = "GetValidationFailureItem";
|
||||
|
||||
NWNX_CallFunction(NWNX_ELC, sFunc);
|
||||
return NWNX_GetReturnValueObject(NWNX_ELC, sFunc);
|
||||
NWNXCall(NWNX_ELC, "GetValidationFailureItem");
|
||||
return NWNXPopObject();
|
||||
}
|
||||
|
||||
int NWNX_ELC_GetValidationFailureLevel()
|
||||
{
|
||||
string sFunc = "GetValidationFailureLevel";
|
||||
|
||||
NWNX_CallFunction(NWNX_ELC, sFunc);
|
||||
return NWNX_GetReturnValueInt(NWNX_ELC, sFunc);
|
||||
NWNXCall(NWNX_ELC, "GetValidationFailureLevel");
|
||||
return NWNXPopInt();
|
||||
}
|
||||
|
||||
int NWNX_ELC_GetValidationFailureSkillID()
|
||||
{
|
||||
string sFunc = "GetValidationFailureSkillID";
|
||||
|
||||
NWNX_CallFunction(NWNX_ELC, sFunc);
|
||||
return NWNX_GetReturnValueInt(NWNX_ELC, sFunc);
|
||||
NWNXCall(NWNX_ELC, "GetValidationFailureSkillID");
|
||||
return NWNXPopInt();
|
||||
}
|
||||
|
||||
int NWNX_ELC_GetValidationFailureFeatID()
|
||||
{
|
||||
string sFunc = "GetValidationFailureFeatID";
|
||||
|
||||
NWNX_CallFunction(NWNX_ELC, sFunc);
|
||||
return NWNX_GetReturnValueInt(NWNX_ELC, sFunc);
|
||||
NWNXCall(NWNX_ELC, "GetValidationFailureFeatID");
|
||||
return NWNXPopInt();
|
||||
}
|
||||
|
||||
int NWNX_ELC_GetValidationFailureSpellID()
|
||||
{
|
||||
string sFunc = "GetValidationFailureSpellID";
|
||||
|
||||
NWNX_CallFunction(NWNX_ELC, sFunc);
|
||||
return NWNX_GetReturnValueInt(NWNX_ELC, sFunc);
|
||||
NWNXCall(NWNX_ELC, "GetValidationFailureSpellID");
|
||||
return NWNXPopInt();
|
||||
}
|
||||
|
Reference in New Issue
Block a user