Updated event system
Added caller scripts to the PC events. Full compile. Updated release.
This commit is contained in:
@@ -16,7 +16,7 @@
|
||||
#include "nw_i0_tool"
|
||||
void bleed(int iBleedAmt)
|
||||
{
|
||||
ExecuteScript("prc_ondying", OBJECT_SELF);
|
||||
|
||||
|
||||
object oPC = GetLastPlayerDying();
|
||||
if (!GetIsPC(oPC)){
|
||||
|
17
_module/nss/call_onacquired.nss
Normal file
17
_module/nss/call_onacquired.nss
Normal file
@@ -0,0 +1,17 @@
|
||||
//:://////////////////////////////////////////////
|
||||
/*
|
||||
* call_onacquired.nss
|
||||
*
|
||||
* OnAcquiredItem event caller
|
||||
*
|
||||
*
|
||||
*/
|
||||
//:://////////////////////////////////////////////
|
||||
|
||||
void main()
|
||||
{
|
||||
ExecuteScript("prc_onaquire", OBJECT_SELF);
|
||||
|
||||
ExecuteScript("onacquireditem", OBJECT_SELF);
|
||||
|
||||
}
|
17
_module/nss/call_onactivate.nss
Normal file
17
_module/nss/call_onactivate.nss
Normal file
@@ -0,0 +1,17 @@
|
||||
//:://////////////////////////////////////////////
|
||||
/*
|
||||
* call_onactivate.nss
|
||||
*
|
||||
* OnActivateItem event caller
|
||||
*
|
||||
*
|
||||
*/
|
||||
//:://////////////////////////////////////////////
|
||||
|
||||
void main()
|
||||
{
|
||||
ExecuteScript("prc_activate", OBJECT_SELF);
|
||||
|
||||
ExecuteScript("onactivateitem", OBJECT_SELF);
|
||||
|
||||
}
|
17
_module/nss/call_ondeath.nss
Normal file
17
_module/nss/call_ondeath.nss
Normal file
@@ -0,0 +1,17 @@
|
||||
//:://////////////////////////////////////////////
|
||||
/*
|
||||
* call_ondeath.nss
|
||||
*
|
||||
* OnPlayerDeath event caller
|
||||
*
|
||||
*
|
||||
*/
|
||||
//:://////////////////////////////////////////////
|
||||
|
||||
void main()
|
||||
{
|
||||
ExecuteScript("prc_ondeath", OBJECT_SELF);
|
||||
|
||||
ExecuteScript("onplayerdeath", OBJECT_SELF);
|
||||
|
||||
}
|
17
_module/nss/call_ondying.nss
Normal file
17
_module/nss/call_ondying.nss
Normal file
@@ -0,0 +1,17 @@
|
||||
//:://////////////////////////////////////////////
|
||||
/*
|
||||
* call_ondying.nss
|
||||
*
|
||||
* OnPlayerDying event caller
|
||||
*
|
||||
*
|
||||
*/
|
||||
//:://////////////////////////////////////////////
|
||||
|
||||
void main()
|
||||
{
|
||||
ExecuteScript("prc_ondying", OBJECT_SELF);
|
||||
|
||||
ExecuteScript("bleeding", OBJECT_SELF);
|
||||
|
||||
}
|
17
_module/nss/call_onenter.nss
Normal file
17
_module/nss/call_onenter.nss
Normal file
@@ -0,0 +1,17 @@
|
||||
//:://////////////////////////////////////////////
|
||||
/*
|
||||
* call_onenter.nss
|
||||
*
|
||||
* OnClientEnter event caller
|
||||
*
|
||||
*
|
||||
*/
|
||||
//:://////////////////////////////////////////////
|
||||
|
||||
void main()
|
||||
{
|
||||
ExecuteScript("prc_onenter", OBJECT_SELF);
|
||||
|
||||
ExecuteScript("oncliententer", OBJECT_SELF);
|
||||
|
||||
}
|
17
_module/nss/call_onexit.nss
Normal file
17
_module/nss/call_onexit.nss
Normal file
@@ -0,0 +1,17 @@
|
||||
//:://////////////////////////////////////////////
|
||||
/*
|
||||
* call_onexit.nss
|
||||
*
|
||||
* OnClientExit event caller
|
||||
*
|
||||
*
|
||||
*/
|
||||
//:://////////////////////////////////////////////
|
||||
|
||||
void main()
|
||||
{
|
||||
ExecuteScript("prc_leave", OBJECT_SELF);
|
||||
|
||||
ExecuteScript("onclientexit", OBJECT_SELF);
|
||||
|
||||
}
|
17
_module/nss/call_onheartbeat.nss
Normal file
17
_module/nss/call_onheartbeat.nss
Normal file
@@ -0,0 +1,17 @@
|
||||
//:://////////////////////////////////////////////
|
||||
/*
|
||||
* call_onheartbeat.nss
|
||||
*
|
||||
* OnHeartbeat event caller
|
||||
*
|
||||
*
|
||||
*/
|
||||
//:://////////////////////////////////////////////
|
||||
|
||||
void main()
|
||||
{
|
||||
ExecuteScript("prc_onheartbeat", OBJECT_SELF);
|
||||
|
||||
ExecuteScript("onheartbeat", OBJECT_SELF);
|
||||
|
||||
}
|
17
_module/nss/call_onlevelup.nss
Normal file
17
_module/nss/call_onlevelup.nss
Normal file
@@ -0,0 +1,17 @@
|
||||
//:://////////////////////////////////////////////
|
||||
/*
|
||||
* call_onlevelup.nss
|
||||
*
|
||||
* OnPlayerLevelUp event caller
|
||||
*
|
||||
*
|
||||
*/
|
||||
//:://////////////////////////////////////////////
|
||||
|
||||
void main()
|
||||
{
|
||||
ExecuteScript("prc_levelup", OBJECT_SELF);
|
||||
|
||||
ExecuteScript("onplayerlevelup", OBJECT_SELF);
|
||||
|
||||
}
|
17
_module/nss/call_onmodload.nss
Normal file
17
_module/nss/call_onmodload.nss
Normal file
@@ -0,0 +1,17 @@
|
||||
//:://////////////////////////////////////////////
|
||||
/*
|
||||
* call_onmodload.nss
|
||||
*
|
||||
* OnModuleLoad event caller
|
||||
*
|
||||
*
|
||||
*/
|
||||
//:://////////////////////////////////////////////
|
||||
|
||||
void main()
|
||||
{
|
||||
ExecuteScript("prc_onmodload", OBJECT_SELF);
|
||||
|
||||
ExecuteScript("onmoduleload", OBJECT_SELF);
|
||||
|
||||
}
|
17
_module/nss/call_onpcchat.nss
Normal file
17
_module/nss/call_onpcchat.nss
Normal file
@@ -0,0 +1,17 @@
|
||||
//:://////////////////////////////////////////////
|
||||
/*
|
||||
* call_onpcchat.nss
|
||||
*
|
||||
* OnPlayerChat event caller
|
||||
*
|
||||
*
|
||||
*/
|
||||
//:://////////////////////////////////////////////
|
||||
|
||||
void main()
|
||||
{
|
||||
ExecuteScript("prc_onplayerchat", OBJECT_SELF);
|
||||
|
||||
ExecuteScript("on_player_chat", OBJECT_SELF);
|
||||
|
||||
}
|
17
_module/nss/call_onpcequip.nss
Normal file
17
_module/nss/call_onpcequip.nss
Normal file
@@ -0,0 +1,17 @@
|
||||
//:://////////////////////////////////////////////
|
||||
/*
|
||||
* call_onpcequip.nss
|
||||
*
|
||||
* OnPlayerEquipItem event caller
|
||||
*
|
||||
*
|
||||
*/
|
||||
//:://////////////////////////////////////////////
|
||||
|
||||
void main()
|
||||
{
|
||||
ExecuteScript("prc_equip", OBJECT_SELF);
|
||||
|
||||
ExecuteScript("onplayerequipted", OBJECT_SELF);
|
||||
|
||||
}
|
17
_module/nss/call_onpcrest.nss
Normal file
17
_module/nss/call_onpcrest.nss
Normal file
@@ -0,0 +1,17 @@
|
||||
//:://////////////////////////////////////////////
|
||||
/*
|
||||
* call_onpcrest.nss
|
||||
*
|
||||
* OnPlayerRest event caller
|
||||
*
|
||||
*
|
||||
*/
|
||||
//:://////////////////////////////////////////////
|
||||
|
||||
void main()
|
||||
{
|
||||
ExecuteScript("prc_rest", OBJECT_SELF);
|
||||
|
||||
ExecuteScript("onplayerrest", OBJECT_SELF);
|
||||
|
||||
}
|
17
_module/nss/call_onrespawn.nss
Normal file
17
_module/nss/call_onrespawn.nss
Normal file
@@ -0,0 +1,17 @@
|
||||
//:://////////////////////////////////////////////
|
||||
/*
|
||||
* call_onrespawn.nss
|
||||
*
|
||||
* OnPlayerRespawn event caller
|
||||
*
|
||||
*
|
||||
*/
|
||||
//:://////////////////////////////////////////////
|
||||
|
||||
void main()
|
||||
{
|
||||
ExecuteScript("prc_onrespawn", OBJECT_SELF);
|
||||
|
||||
ExecuteScript("onplayerrespawn", OBJECT_SELF);
|
||||
|
||||
}
|
17
_module/nss/call_onunacquire.nss
Normal file
17
_module/nss/call_onunacquire.nss
Normal file
@@ -0,0 +1,17 @@
|
||||
//:://////////////////////////////////////////////
|
||||
/*
|
||||
* call_onunacquire.nss
|
||||
*
|
||||
* OnPlayerUnacquireItem event caller
|
||||
*
|
||||
*
|
||||
*/
|
||||
//:://////////////////////////////////////////////
|
||||
|
||||
void main()
|
||||
{
|
||||
ExecuteScript("prc_onunaquire", OBJECT_SELF);
|
||||
|
||||
ExecuteScript("onunacquireitem", OBJECT_SELF);
|
||||
|
||||
}
|
17
_module/nss/call_onunequip.nss
Normal file
17
_module/nss/call_onunequip.nss
Normal file
@@ -0,0 +1,17 @@
|
||||
//:://////////////////////////////////////////////
|
||||
/*
|
||||
* call_onunequip.nss
|
||||
*
|
||||
* OnPlayerUnequipItem event caller
|
||||
*
|
||||
*
|
||||
*/
|
||||
//:://////////////////////////////////////////////
|
||||
|
||||
void main()
|
||||
{
|
||||
ExecuteScript("prc_unequip", OBJECT_SELF);
|
||||
|
||||
ExecuteScript("onunequipitem", OBJECT_SELF);
|
||||
|
||||
}
|
@@ -16,8 +16,6 @@
|
||||
#include "x2_inc_switches"
|
||||
void main()
|
||||
{
|
||||
ExecuteScript("prc_onaquire", OBJECT_SELF);
|
||||
|
||||
//IMPORTANT THIS MUST BE IN YOUR OnAcquireItem Module Event Script
|
||||
//This is a fix for the Inventory Organizing System!
|
||||
object oPC = GetModuleItemAcquiredBy();
|
||||
|
@@ -37,7 +37,7 @@ void SendMessageToAllPC(string sMessage);
|
||||
//Main Script
|
||||
void main()
|
||||
{
|
||||
ExecuteScript("prc_onenter", OBJECT_SELF);
|
||||
|
||||
|
||||
//Declare Major Variables..
|
||||
object oPC;
|
||||
|
@@ -24,7 +24,6 @@ void SendMessageToAllPC(string sMessage);
|
||||
//Main Script
|
||||
void main()
|
||||
{
|
||||
ExecuteScript("prc_onleave", OBJECT_SELF);
|
||||
object oPC = GetExitingObject();
|
||||
|
||||
if(GetIsDM(oPC))
|
||||
|
@@ -19,7 +19,7 @@ Event of the Module Properties
|
||||
//Main Script
|
||||
void main()
|
||||
{
|
||||
ExecuteScript("prc_onheartbeat", OBJECT_SELF);
|
||||
|
||||
//IMPORTANT NOTE: If you are using nwnx2 to load your server you will
|
||||
//want to open up the OnModuleLoad script to activate the NWNX2 Reset
|
||||
//and below you will need to follow the directions to turn off normal reset.
|
||||
|
@@ -35,7 +35,6 @@ const string NWNX_DISCORD_URL = "/api/webhooks/713882600216723518/1EpwmMZ6F9VBjD
|
||||
//Main Script
|
||||
void main()
|
||||
{
|
||||
ExecuteScript("prc_onmodload", OBJECT_SELF);
|
||||
//Set whether we are using this module for multiplayer or single player..
|
||||
SetLocalInt(GetModule(), "MULTI", MULTI);
|
||||
|
||||
|
@@ -55,7 +55,7 @@ const int nReward2 = 800;
|
||||
// Raise OnDeath function (Standard Bioware Function)
|
||||
void Raise(object oPlayer)
|
||||
{
|
||||
ExecuteScript("prc_ondeath", OBJECT_SELF);
|
||||
|
||||
effect eVisual = EffectVisualEffect(VFX_IMP_RESTORATION);
|
||||
|
||||
effect eBad = GetFirstEffect(oPlayer);
|
||||
|
@@ -15,7 +15,7 @@ Likewise players cannot equipt items tagnamed "arena" outside of the arena.
|
||||
//Main Script
|
||||
void main()
|
||||
{
|
||||
ExecuteScript("prc_equip", OBJECT_SELF);
|
||||
|
||||
//Declare Major Variables
|
||||
object oItem = GetPCItemLastEquipped();
|
||||
object oPC = GetPCItemLastEquippedBy();
|
||||
|
@@ -89,7 +89,6 @@ else ApplyEffectAtLocation(DURATION_TYPE_INSTANT, EffectVisualEffect(VFX_IMP_KNO
|
||||
//a legal character or not, just delete the // below to use
|
||||
//DelayCommand(2.0, ExecuteScript("cheatercheck4", oPC));
|
||||
|
||||
ExecuteScript("prc_levelup", oPC);
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////
|
||||
//SimTools Languages
|
||||
|
@@ -36,8 +36,6 @@ void Raise(object oPlayer);
|
||||
//Main Script
|
||||
void main()
|
||||
{
|
||||
ExecuteScript("prc_onrespawn", OBJECT_SELF);
|
||||
|
||||
object oPC = GetLastRespawnButtonPresser();
|
||||
|
||||
if (!GetIsPC(oPC)) return;
|
||||
|
@@ -212,7 +212,7 @@ if(GetLocalInt(GetModule(), "MULTI")==TRUE)
|
||||
ExecuteScript("powerimmortal", oPC);
|
||||
}
|
||||
|
||||
ExecuteScript("prc_rest", oPC);
|
||||
//ExecuteScript("prc_rest", oPC);
|
||||
|
||||
//Your code goes here. (This happens when the PC is done resting..)
|
||||
|
||||
|
@@ -21,8 +21,6 @@ Scripting will still fire reguardless.
|
||||
#include "x2_inc_switches"
|
||||
void main()
|
||||
{
|
||||
ExecuteScript("prc_onunaquire", OBJECT_SELF);
|
||||
|
||||
//IMPORTANT THIS MUST BE IN YOUR OnUnAcquireItem Module Event Script
|
||||
//This is a fix for the Inventory Organizing System!
|
||||
object oPC = GetModuleItemLostBy();
|
||||
|
@@ -21,7 +21,6 @@
|
||||
//Main Script
|
||||
void main()
|
||||
{
|
||||
ExecuteScript("prc_unequip", OBJECT_SELF);
|
||||
|
||||
object oItem = GetPCItemLastUnequipped();
|
||||
object oPC = GetPCItemLastUnequippedBy();
|
||||
|
Reference in New Issue
Block a user