本文整理汇总了C++中KeyList::Append方法的典型用法代码示例。如果您正苦于以下问题:C++ KeyList::Append方法的具体用法?C++ KeyList::Append怎么用?C++ KeyList::Append使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类KeyList
的用法示例。
在下文中一共展示了KeyList::Append方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: PostLoad
void Data::PostLoad(KeyList<ScaleKey> &keys)
{
// keys lists must have at least 2 entries
//
if (keys.GetCount() == 0)
{
keys.Append( new ScaleKey( 0.0f, scale) );
}
if (keys.GetCount() == 1)
{
keys.Append( new ScaleKey( 1.0f, keys.GetHead()->scale) );
}
keys.KeyList<ScaleKey>::PostLoad();
}
示例2: Type
///////////////////////////////////////////////////////////////////////////////
//
// Quake::Type constructor
//
Type( FScope * fScope)
{
name = StdLoad::TypeString( fScope);
Effects::Data data;
FScope * sScope;
while ((sScope = fScope->NextFunction()) != NULL)
{
switch (sScope->NameCrc())
{
default:
{
// effects helper structure
//
if (data.Configure( sScope))
{
lifeTime = data.lifeTime;
sound = data.objectId;
}
break;
}
case 0x9FECAD2F: // "QuakeKey"
{
F32 f, i, s;
f = StdLoad::TypeF32( sScope); // frame
i = StdLoad::TypeF32( sScope); // intensity
s = StdLoad::TypeF32( sScope); // speed
keys.Append( new QuakeKey( f, i, s));
break;
}
//
} // switch
}
ASSERT( keys.GetCount() >= 2);
keys.PostLoad(); // initialize
typeList.Add( name.crc, this);
}
示例3: Configure
Bool Data::Configure(FScope *fScope, KeyList<ScaleKey> &keys, U32 counter) // = 1)
{
switch (fScope->NameCrc())
{
default:
return FALSE;
case 0xD7A2677F: // "RadiusKey2"
case 0x4C7DA445: // "ScaleKey2"
if (counter != 2)
{
return FALSE;
}
counter = 1;
case 0x4FB72CBC: // "RadiusKey"
case 0x920CA5B2: // "ScaleKey"
case 0x44FC1D1A: // "TimeKey"
case 0x5E205EB4: // "StateKey"
if (counter == 1)
{
F32 f = StdLoad::TypeF32( fScope);
F32 s = StdLoad::TypeF32( fScope);
keys.Append( new ScaleKey( f, s));
}
break;
case 0xD445F92F: // "StartRadius2"
case 0x315642BA: // "StartScale2"
if (counter != 2)
{
return FALSE;
}
counter = 1;
case 0x3E50BE22: // "StartRadius"
case 0x097FD8A4: // "StartScale"
if (counter == 1)
{
ASSERT( keys.GetCount() == 0);
F32 s = StdLoad::TypeF32( fScope);
keys.Append( new ScaleKey( 0.0f, s));
}
break;
case 0x9D7F8F83: // "FinishRadius2"
case 0x25406D61: // "FinishScale2"
if (counter != 2)
{
return FALSE;
}
counter = 1;
case 0x2A4691F9: // "FinishRadius"
case 0x5D005D56: // "FinishScale"
if (counter == 1)
{
ASSERT( keys.GetCount() == 1);
F32 s = StdLoad::TypeF32( fScope);
keys.Append( new ScaleKey( 1.0f, s));
}
break;
}
return TRUE;
}