Gaming
 

Osrs os

From NWNWiki

osrs_os is a script used by OSRS when handling the OnSpawn event.

/////////////////////////////////////////////////////////////////////////////
//
// file:
//      osrs_os
//
// purpose:
//      OnSpawn event script.
//
/////////////////////////////////////////////////////////////////////////////

// the include file for Open Source Rule Set events
#include "osrs_inc"

/////////////////////////////////////////////////////////////////////////////
void main()
{
    // determine what type of object is calling this script
    int iCallingClass = osrs_GetCallerEventClass(OBJECT_SELF);
    switch(iCallingClass)
    {
        ////////////////////////////////////////      creature
        case I_OSRS_EVENT_CLASS_CREATURE:
            // Creature::OnSpawn Pre-event
            if (!osrs_c_os_pre())
            {
                return;
            }

            // Creature::OnSpawn event
            if (!osrs_c_os())
            {
                return;
            }

            // Creature::OnSpawn post-event
            osrs_c_os_post();

            break;

    }
}