Exemplo n.º 1
0
// this is now recursive, so watch what you're doing...
//
void CSequence::_Init(bool bGenLoopFrame, bool bIsGLA, LPCTSTR path, int startFrame, int targetFrame, int frameCount, int frameSpeed, int frameSpeedFromHeader, CComment* comments)
{
	static bool bHere = false;	

	m_path = NULL;
	m_next = NULL;
	m_name = NULL;
	m_fill = -1;	
	// another Jake thing, not sure if this'll stay in when valid StarWars enums are available
#if 0
	m_enum = "";//NULL;
#else
	m_enum = path;
	if (!m_enum.IsEmpty())
	{
		Filename_BaseOnly(m_enum);
		m_enum.MakeUpper();
	}
#endif
	m_sound = NULL;
	m_action = NULL;
	m_comments = comments;	
	m_validEnum = false;
	m_loopFrame = -1;
	m_bIsGLA = bIsGLA;
	m_bGenLoopFrame = bGenLoopFrame;

	SetPath(path);
	SetStartFrame(startFrame);
	SetTargetFrame(targetFrame);
	SetFrameCount(frameCount);
	SetFrameSpeed(frameSpeed);	
	SetFrameSpeedFromHeader(frameSpeedFromHeader);

	if (bHere)
	{
		for (int i=0; i<MAX_ADDITIONAL_SEQUENCES; i++)
		{
			AdditionalSeqs[i] = NULL;
		}
	}
	else
	{
		bHere = true;

		for (int i=0; i<MAX_ADDITIONAL_SEQUENCES; i++)
		{
			AdditionalSeqs[i] = new CSequence();
			AdditionalSeqs[i]->_Init(false, false,NULL, 0, 0, 0, iDEFAULTSEQFRAMESPEED, iDEFAULTSEQFRAMESPEED, NULL);
		}

		bHere = false;
	}
}
Exemplo n.º 2
0
void CSequence::ReadHeader()
{
	int iStartFrame, iFrameCount, iFrameSpeed;

	CString nameASE = ((CAssimilateApp*)AfxGetApp())->GetQuakeDir();
			nameASE+= GetPath();	

	ReadASEHeader( nameASE, iStartFrame, iFrameCount, iFrameSpeed);

	SetStartFrame( iStartFrame );
	SetFrameCount( iFrameCount );
	SetFrameSpeed( iFrameSpeed );	// iDEFAULTSEQFRAMESPEED
	SetFrameSpeedFromHeader( iFrameSpeed );	
}
Exemplo n.º 3
0
bool CPathLine::setParam(DrawinObjectParamName paramID, const CSimpleVariant &val)
{
	bool bResult(CStreamLine::setParam(paramID, val));

	if (!bResult)
	{
		switch (paramID)
		{
			case DOP_STARTFRAME:
				SetStartFrame(val.GetIntVal());
				bResult = true;
				break;
			case DOP_USE_STARTFRAME:
				UseFixedStartFrame(val.GetBoolVal());
				bResult = true;
				break;
		}
	}

	return bResult;
}
Exemplo n.º 4
0
CPathLine::CPathLine(const CPointf &ptOrigin, unsigned int nNumIntegrationSteps, int nStartFrame, float fArrowLength, const floatColor& color, DrawingObjectType type, float fStepLength)
	:	CStreamLine(ptOrigin, nNumIntegrationSteps, fArrowLength, color, type, fStepLength)
{
	SetStartFrame(nStartFrame);
}