Problems with Set Flipbook in 4.2.1

In my simple 2D game the playable character blueprint consists of an idle animation flipbook and a camera. When the player presses A or D keys, that idle animation flipbook is switched to running animation flipbook via Set Flipbook. When that pressed key is released, idle flipbook replaces the running one, which is also done via Set Flipbook This algorithm worked just fine in 4.1.1, but when I reproduce it in 4.2.1 and try playing the game inside the editor, it crashes. What causes this?

EDIT: this is what I get when UE crashes
!Id:ff492282b3513e0a5ea92a73e57c4262

Unknown exception - code 00000001 (first/second chance not available)

Assertion failed: !bPostTickComponentUpdate [File:D:\BuildFarm\buildmachine_++depot+UE4-Releases+4.2\Engine\Source\Runtime\Engine\Private\LevelTick.cpp] [Line: 703]

KERNELBASE + 23544 bytes
UE4Editor_Core + 2998748 bytes
UE4Editor_Core + 1620298 bytes
UE4Editor_Core + 1561376 bytes
UE4Editor_Engine + 5079251 bytes
UE4Editor_Paper2D + 70584 bytes
UE4Editor_Paper2D + 74302 bytes
UE4Editor_Renderer + 1343109 bytes
UE4Editor_Engine + 1770952 bytes
UE4Editor_Engine + 1639237 bytes
UE4Editor_Engine + 5132103 bytes
UE4Editor_Engine + 5161378 bytes
UE4Editor_UnrealEd + 1464870 bytes
UE4Editor_UnrealEd + 5375494 bytes
UE4Editor!FEngineLoop::Tick() + 3555 bytes [d:\buildfarm\buildmachine_++depot+ue4-releases+4.2\engine\source\runtime\launch\private\launchengineloop.cpp:2091]
UE4Editor!GuardedMain() + 476 bytes [d:\buildfarm\buildmachine_++depot+ue4-releases+4.2\engine\source\runtime\launch\private\launch.cpp:132]
UE4Editor!GuardedMainWrapper() + 26 bytes [d:\buildfarm\buildmachine_++depot+ue4-releases+4.2\engine\source\runtime\launch\private\windows\launchwindows.cpp:125]
UE4Editor!WinMain() + 249 bytes [d:\buildfarm\buildmachine_++depot+ue4-releases+4.2\engine\source\runtime\launch\private\windows\launchwindows.cpp:207]
UE4Editor!__tmainCRTStartup() + 329 bytes [f:\dd\vctools\crt\crtw32\dllstuff\crtexe.c:618]

I tried doing it from scratch in 4.2.1 and it still crashes.

are you using the same bluprint with both UE versions ?

check if you have connected some nodes by mistake. because they just said everything have been fixed in 4.2.1 as before:

most of the 2d was broken in 4.2.0
The did put a hot-fix 4.2.1, but I did not try it. In fact I don’t believe in hot-fix, as it is stuff made in hurry to fix a situation :slight_smile: so, it may still fails :frowning:
My advice if you are working in 2d stay with 4.1.1 for now. otherwise, fire you engines to 4.2.1 and enjoy all it’s awesome stuff :slight_smile:

I am currently also having the same problem. Is following the video serie A new, community-hosted Unreal Engine Wiki - Announcements - Unreal Engine Forums (part 4) and when using “Set Flipbook” blueprint node this crash occures. Its when changing from one flipbook to another.

I will try the 4.1 branch instead to see if it works out and check later if there is any new fixes for the Paper2D plugin.

I figured out what causes UE to crash. One loop of the flipbook you’re switching to should last at least one second (like, if you have a 15 fps flipbook, all of the “pieces” of your flipbook together should last at least 15 frames).
Animations that lasted shorter than 1 second used to work just fine in 4.1, so I don’t know whether it’s intended in this version or it’s a bug. But anyway, if you need to fix this crash, just fiddle with your flipbooks so they match this requirement.
If UE still crashes, I would recommend you to also check parts of your blueprint that describe character rotation, in case you use that. You might’ve accidentally set it to the wrong axis or something like that.

P.S.: If this one second “requirement” was a deliberate one, I guess this question might be tagged as solved.

I tried that but unfortunately got the same crash.

I went to line 87 in PaperAnimatedRenderComponent.cpp to comment out the call to MarkRenderDynamicDataDirty. Don’t know exactly what it the repercussions will be but it works for now with my small tests.

it seems to work if you set the total duration of frames (from all images used in the flipbook) of the flipbook you are switching to, to exactly the number of frames per second. It’s far from a perfect solution, but it’s a temporary fix to use until Epic hopefully fixes the crash in a future update. (ie: if your frames per second is set to 24, then have a frame count of 24)