X-Git-Url: http://git.localhorst.tv/?a=blobdiff_plain;f=src%2Fgraphics%2FComplexAnimation.cpp;h=942db777e0f72eeaec4e5b0e52777dc8db5a8fc6;hb=5cca794c5b6549b7750c88b5c2217d659fa963dd;hp=95f58692ed67bae11a7cb2187e332c8336b18a57;hpb=dc275497c592669dda75645604a9b35d32f63e90;p=l2e.git diff --git a/src/graphics/ComplexAnimation.cpp b/src/graphics/ComplexAnimation.cpp index 95f5869..942db77 100644 --- a/src/graphics/ComplexAnimation.cpp +++ b/src/graphics/ComplexAnimation.cpp @@ -26,6 +26,11 @@ ComplexAnimation::ComplexAnimation( } +ComplexAnimation::ComplexAnimation(loader::noinit_t n) +: Animation(n) { + +} + int ComplexAnimation::NumFrames() const { return numFrames; @@ -51,6 +56,7 @@ void ComplexAnimation::CreateTypeDescription() { TypeDescription &td(TypeDescription::Create(TYPE_ID, "ComplexAnimation")); td.SetDescription("Complex animation type that supports per-frame disposition and non-linear sprite offset selection."); td.SetConstructor(&Construct); + td.SetInitializer(&Initialize); td.SetSize(sizeof(ComplexAnimation)); td.AddSupertype(Animation::TYPE_ID, ((char *)a) - ((char *)&ca)); @@ -73,4 +79,8 @@ void ComplexAnimation::Construct(void *data) { new (data) ComplexAnimation; } +void ComplexAnimation::Initialize(void *data) { + new (data) ComplexAnimation(loader::noinit); +} + }