mirror of
https://foundry.openuru.org/gitblit/r/CWE-ou-minkata.git
synced 2025-07-17 10:52:46 +00:00
Fix compile for ancient max versions
This commit is contained in:
@ -51,43 +51,46 @@ You can contact Cyan Worlds, Inc. by email legal@cyan.com
|
||||
#include <maxversion.h>
|
||||
|
||||
#if MAX_VERSION_MAJOR <= 9
|
||||
#define BMMCOLOR(x, y, z, w) \
|
||||
{x, y, x, w};
|
||||
# define BMMCOLOR(x, y, z, w) \
|
||||
{x, y, x, w};
|
||||
|
||||
#define DEFAULTREMAP NoRemap()
|
||||
# define DEFAULTREMAP NoRemap()
|
||||
|
||||
#define ENUMDEPENDENTS(maxObject, proc) \
|
||||
maxObject->EnumDependents(proc);
|
||||
# define ENUMDEPENDENTS(maxObject, proc) \
|
||||
maxObject->EnumDependents(proc);
|
||||
|
||||
typedef TCHAR MCHAR;
|
||||
typedef TCHAR MCHAR;
|
||||
#else
|
||||
#define BMMCOLOR(x, y, z, w) \
|
||||
BMM_Color_64(x, y, z, w);
|
||||
# define BMMCOLOR(x, y, z, w) \
|
||||
BMM_Color_64(x, y, z, w);
|
||||
|
||||
#define DEFAULTREMAP DefaultRemapDir()
|
||||
# define DEFAULTREMAP DefaultRemapDir()
|
||||
|
||||
#define ENUMDEPENDENTS(maxObject, proc) \
|
||||
maxObject->DoEnumDependents(proc);
|
||||
# define ENUMDEPENDENTS(maxObject, proc) \
|
||||
maxObject->DoEnumDependents(proc);
|
||||
#endif //MAX_VERSION_MAJOR
|
||||
|
||||
#if MAX_VERSION_MAJOR <= 13
|
||||
#define GetParamBlock2Controller(pb, id) pb->GetController(id)
|
||||
#define SetParamBlock2Controller(pb, id, tab, ctl) pb->SetController(id, tab, ctl)
|
||||
# define GetParamBlock2Controller(pb, id) pb->GetController(id)
|
||||
# define SetParamBlock2Controller(pb, id, tab, ctl) pb->SetController(id, tab, ctl)
|
||||
#else
|
||||
#define GetParamBlock2Controller(pb, id) pb->GetControllerByID(id)
|
||||
#define SetParamBlock2Controller(pb, id, tab, ctl) pb->SetControllerByID(id, tab, ctl)
|
||||
# define GetParamBlock2Controller(pb, id) pb->GetControllerByID(id)
|
||||
# define SetParamBlock2Controller(pb, id, tab, ctl) pb->SetControllerByID(id, tab, ctl)
|
||||
#endif // MAX_VERSION_MAJOR
|
||||
|
||||
#if MAX_VERSION_MAJOR <= 11 // max 2009. Just a guess, really. 2010 doesn't need this function.
|
||||
#define INIT_CUSTOM_CONTROLS(instance) InitCustomControls(instance)
|
||||
# define INIT_CUSTOM_CONTROLS(instance) InitCustomControls(instance)
|
||||
#else
|
||||
#define INIT_CUSTOM_CONTROLS(instance)
|
||||
# define INIT_CUSTOM_CONTROLS(instance)
|
||||
#endif
|
||||
|
||||
#if MAX_VERSION_MAJOR <= 10 // Max 2008
|
||||
#define GETNAME_RETURN_TYPE TCHAR*
|
||||
# define GETNAME_RETURN_TYPE TCHAR*
|
||||
#else
|
||||
#define GETNAME_RETURN_TYPE const TCHAR*
|
||||
# define GETNAME_RETURN_TYPE const TCHAR*
|
||||
#endif
|
||||
|
||||
// Old versions of Max define this as an integer, not a Class_ID
|
||||
#define XREFOBJ_COMPAT_CLASS_ID Class_ID(0x92aab38c, 0)
|
||||
|
||||
#endif // _PLASMA_MAXCOMPAT_H
|
@ -78,14 +78,8 @@ You can contact Cyan Worlds, Inc. by email legal@cyan.com
|
||||
#include <comutil.h>
|
||||
#include <direct.h>
|
||||
|
||||
// PlasmaMax Stuff included everywhere
|
||||
// Some of these files may pull in Max SDK headers, so put this below hsWindows.h!
|
||||
#include "plMaxNode.h"
|
||||
#include "plMaxNodeData.h"
|
||||
#include "MaxComponent/plComponent.h"
|
||||
#include "MaxComponent/plComponentReg.h"
|
||||
|
||||
// Misc Max SDK
|
||||
#include <max.h>
|
||||
#include <bmmlib.h>
|
||||
#include <CustAttrib.h>
|
||||
#include <ICustAttribContainer.h>
|
||||
@ -93,7 +87,8 @@ You can contact Cyan Worlds, Inc. by email legal@cyan.com
|
||||
#include <guplib.h>
|
||||
#include <iMenuMan.h>
|
||||
#include <IMtlEdit.h>
|
||||
#include <iskin.h>
|
||||
#include <iparamb2.h> // above ISkin.h for Max 7
|
||||
#include <ISkin.h>
|
||||
#include <istdplug.h>
|
||||
#include <maxversion.h>
|
||||
#include <mnmath.h>
|
||||
@ -101,6 +96,13 @@ You can contact Cyan Worlds, Inc. by email legal@cyan.com
|
||||
#include <notify.h>
|
||||
#include <pbbitmap.h>
|
||||
|
||||
// PlasmaMax Stuff included everywhere
|
||||
// Some of these files may pull in Max SDK headers, so put this below hsWindows.h!
|
||||
#include "plMaxNode.h"
|
||||
#include "plMaxNodeData.h"
|
||||
#include "MaxComponent/plComponent.h"
|
||||
#include "MaxComponent/plComponentReg.h"
|
||||
|
||||
// Utility
|
||||
#include "MaxCompat.h"
|
||||
#include "resource.h"
|
||||
|
@ -43,7 +43,14 @@ You can contact Cyan Worlds, Inc. by email legal@cyan.com
|
||||
class Class_ID;
|
||||
class Interface;
|
||||
class plMaxNode;
|
||||
struct NotifyInfo;
|
||||
|
||||
#include <maxversion.h>
|
||||
#if MAX_VERSION_MAJOR >= 9
|
||||
struct NotifyInfo;
|
||||
#else
|
||||
// Max headers are more minimalistic in pre-9 maxes
|
||||
# include <notify.h>
|
||||
#endif
|
||||
|
||||
class plComponentDlg
|
||||
{
|
||||
|
@ -48,6 +48,7 @@ You can contact Cyan Worlds, Inc. by email legal@cyan.com
|
||||
#include "plMaxNodeBase.h"
|
||||
#include "plMaxNodeData.h"
|
||||
#include "MaxComponent/plComponentBase.h"
|
||||
#include "MaxCompat.h"
|
||||
|
||||
#include <guplib.h>
|
||||
#include <iparamm2.h>
|
||||
@ -483,7 +484,7 @@ bool plMaxNodeBase::IsXRef()
|
||||
{
|
||||
// Is this an XRef'd object?
|
||||
Object *obj = GetObjectRef();
|
||||
if (obj->SuperClassID() == SYSTEM_CLASS_ID && obj->ClassID() == XREFOBJ_CLASS_ID)
|
||||
if (obj->SuperClassID() == SYSTEM_CLASS_ID && obj->ClassID() == XREFOBJ_COMPAT_CLASS_ID)
|
||||
return true;
|
||||
|
||||
//
|
||||
|
Reference in New Issue
Block a user