/*=========================================================================
* RND_Scpt.h : 
*     Script read
*
* (c) Ubi Studios 1997
*=======================================================================*/
 
#if !defined(__RND_SCPT_H__)
#define __RND_SCPT_H__
 
/******************************************/
#if _MSC_VER >= 1000
#pragma once
#endif /* _MSC_VER >= 1000 */
/******************************************/
 
/****************************************/
#if !defined(CPA_EXPORT)
#if defined(CPA_WANTS_IMPORT)
#define CPA_EXPORT __declspec(dllimport)
#elif defined(CPA_WANTS_EXPORT)
#define CPA_EXPORT __declspec(dllexport)
#else
#define CPA_EXPORT
#endif /*CPA_WANTS_IMPORT || CPA_WANTS_EXPORT*/
#endif /*CPA_EXPORT*/
/****************************************/
 
#undef EXTERN
#undef extern
#if !defined(D_RND_Input_VariableDefine)
#define EXTERN extern
#else
#define EXTERN
#endif /* D_RND_Input_VariableDefine*/
 
/**** Macros definitions ****/
#define C_GrandChildSection    ( 2)
#define C_ChildSection         ( 1)
#define C_ThisSection          ( 0)
#define C_ParentSection        (-1)
#define C_GrandParentSection   (-2)
 
#define C_GrandChildContext    ( 2)
#define C_ChildContext         ( 1)
#define C_ThisContext          ( 0)
#define C_ParentContext        (-1)
#define C_GrandParentContext   (-2)
 
#define M_IsTitle         (_eAction==SCR_EA_Anl_BeginSection)
#define M_IsEnd           (_eAction==SCR_EA_Anl_EndSection)
#define M_IsBegSubSection (_eAction==SCR_EA_Anl_BeginSubSection)
#define M_IsEndSubSection (_eAction==SCR_EA_Anl_EndSubSection)
#define M_IsEntry         (_eAction==SCR_EA_Anl_Entry)
 
#define M_ActionIs(szActionAsked) (!strcmpi(_p_szName,szActionAsked))
 
#define M_CheckScriptParamNumber(ulNumber) \
{ \
 if (SCR_fn_uc_RdL0_GetNumberOfParameters(_ap_szParams)!=ulNumber) \
  M_RNDFatalError(E_uwRNDScriptBadNumberOfArg); \
}
 
/**** Functions definitions ****/
#if !defined(U64)
SCR_tde_Anl_ReturnValue RND_fn_eRandomScriptCallBack(SCR_tdst_File_Description *_p_stFile,char *_p_szName,char *_ap_szParams[],SCR_tde_Anl_Action	_eAction);
#endif /* U64 */
 
#undef EXTERN
#undef extern
 
#endif /* __RND_SCPT_H__ */
