mirror of
https://foundry.openuru.org/gitblit/r/CWE-ou-minkata.git
synced 2025-07-14 10:37:41 -04:00
Fix some stupid stuff that would have crashed the plugin...
This commit is contained in:
@ -1015,15 +1015,15 @@ protected:
|
||||
|
||||
void IGetNewLocalFileName( plBaseSoundEmitterComponent *soundComponent, plBaseSoundEmitterComponent::WhichSound which )
|
||||
{
|
||||
char* fileName[ MAX_PATH ], dirName[ MAX_PATH ];
|
||||
char fileName[ MAX_PATH ], dirName[ MAX_PATH ];
|
||||
const char* name = soundComponent->GetSoundFileName( which );
|
||||
|
||||
if( name != nil )
|
||||
strcpy( (char*)fileName, name );
|
||||
strcpy( fileName, name );
|
||||
else
|
||||
strcpy( (char*)fileName, _T( "" ) );
|
||||
strcpy( fileName, _T( "" ) );
|
||||
|
||||
strcpy( dirName, (const char*)fileName );
|
||||
strcpy( dirName, fileName );
|
||||
::PathRemoveFileSpec( dirName );
|
||||
|
||||
OPENFILENAME ofn = {0};
|
||||
|
@ -304,12 +304,8 @@ plMaxNodeBase *plComponentBase::GetINode()
|
||||
ReferenceMaker* rm = di.Next();
|
||||
while (rm != nil)
|
||||
{
|
||||
for (int i = 0; i < rm->NumRefs(); i++)
|
||||
{
|
||||
RefTargetHandle h = rm->GetReference(i);
|
||||
if (h->SuperClassID() == BASENODE_CLASS_ID)
|
||||
return (plMaxNodeBase*)h;
|
||||
}
|
||||
if (rm->SuperClassID() == BASENODE_CLASS_ID)
|
||||
return (plMaxNodeBase*)rm;
|
||||
|
||||
rm = di.Next();
|
||||
}
|
||||
|
@ -4470,19 +4470,15 @@ static void GetMtlNodes(Mtl *mtl, INodeTab& nodes)
|
||||
ReferenceMaker *rm = di.Next();
|
||||
while (rm != nil)
|
||||
{
|
||||
for (int i = 0; i < rm->NumRefs(); i++)
|
||||
if (rm->SuperClassID() == BASENODE_CLASS_ID)
|
||||
{
|
||||
RefTargetHandle item = rm->GetReference(i);
|
||||
if (item->SuperClassID() == BASENODE_CLASS_ID)
|
||||
{
|
||||
INode *node = (INode*)item;
|
||||
if (node->GetMtl() == mtl)
|
||||
nodes.Append(1, &node);
|
||||
}
|
||||
INode *node = (INode*)rm;
|
||||
if (node->GetMtl() == mtl)
|
||||
nodes.Append(1, &node);
|
||||
}
|
||||
|
||||
rm = di.Next();
|
||||
}
|
||||
|
||||
rm = di.Next();
|
||||
}
|
||||
|
||||
int hsMaterialConverter::GetMaterialArray(Mtl *mtl, hsTArray<hsGMaterial*>& out, UInt32 multiIndex /* = 0 */)
|
||||
|
@ -25,7 +25,7 @@ You can contact Cyan Worlds, Inc. by email legal@cyan.com
|
||||
*==LICENSE==*/
|
||||
#include "plBumpMtl.h"
|
||||
#include "plBumpMtlBasicPB.h"
|
||||
#include "resource.h"
|
||||
#include "../resource.h"
|
||||
#include "iparamm2.h"
|
||||
|
||||
class BumpBasicDlgProc;
|
||||
|
@ -27,7 +27,7 @@ You can contact Cyan Worlds, Inc. by email legal@cyan.com
|
||||
#include "max.h"
|
||||
#include "MaxIcon.h"
|
||||
|
||||
#include "resource.h"
|
||||
#include "../resource.h"
|
||||
#include "plCompositeMtl.h"
|
||||
//#include "plCompositeMtlPB.h"
|
||||
//#include "plMaxLayer.h"
|
||||
|
@ -27,7 +27,7 @@ You can contact Cyan Worlds, Inc. by email legal@cyan.com
|
||||
#include "plDecalMtl.h"
|
||||
#include "../resource.h"
|
||||
//extern ClassDesc2* GetMaxLayerDesc();
|
||||
#include "Shaders.h"
|
||||
#include "../Shaders.h"
|
||||
#include "MaxComponent/plMaxAnimUtils.h"
|
||||
|
||||
#include "plPassBaseParamIDs.h"
|
||||
|
@ -25,7 +25,7 @@ You can contact Cyan Worlds, Inc. by email legal@cyan.com
|
||||
*==LICENSE==*/
|
||||
#include "plDecalMtl.h"
|
||||
#include "plDecalMtlBasicPB.h"
|
||||
#include "resource.h"
|
||||
#include "../resource.h"
|
||||
#include "iparamm2.h"
|
||||
|
||||
class DecalBasicPBAccessor;
|
||||
|
@ -48,7 +48,7 @@ You can contact Cyan Worlds, Inc. by email legal@cyan.com
|
||||
plNoteTrackWatcher::plNoteTrackWatcher( plPassMtlBase *parentMtl ) : fParentMtl(nil)
|
||||
{
|
||||
fNoteTrackCount = parentMtl->NumNoteTracks();
|
||||
MakeRefByID( FOREVER, kRefParentMtl, parentMtl );
|
||||
ReplaceReference(kRefParentMtl, parentMtl);
|
||||
}
|
||||
|
||||
plNoteTrackWatcher::~plNoteTrackWatcher()
|
||||
|
@ -27,7 +27,7 @@ You can contact Cyan Worlds, Inc. by email legal@cyan.com
|
||||
#include "plParticleMtl.h"
|
||||
#include "../resource.h"
|
||||
//extern ClassDesc2* GetMaxLayerDesc();
|
||||
#include "Shaders.h"
|
||||
#include "../Shaders.h"
|
||||
|
||||
#include "iparamm2.h"
|
||||
|
||||
|
@ -333,7 +333,7 @@ void plPassMtlBase::NoteTrackAdded( void )
|
||||
|
||||
if( fNotetracks.Find( track ) == fNotetracks.kMissingIndex )
|
||||
{
|
||||
MakeRefByID( FOREVER, kRefNotetracks + fNotetracks.GetCount(), track );
|
||||
ReplaceReference(kRefNotetracks + fNotetracks.GetCount(), track);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
@ -25,7 +25,7 @@ You can contact Cyan Worlds, Inc. by email legal@cyan.com
|
||||
*==LICENSE==*/
|
||||
#include "plPassMtl.h"
|
||||
#include "plPassMtlBasicPB.h"
|
||||
#include "resource.h"
|
||||
#include "../resource.h"
|
||||
#include "iparamm2.h"
|
||||
|
||||
class PassBasicPBAccessor;
|
||||
|
Reference in New Issue
Block a user