We are experiencing a random crash on Unity 4.5.3f3 using Scaleform 4.2.2 (which also happened on previous version)
It happens after using Invoke too many times passing parameters, or doing .split to a string on the AS side, or creating/removing movieclips.
We narrowed to ANY swf (trying only one at the time) which receives a single String as parameter and doing a split to it or doing work with MovieClips.
What we found is that the game works for around 20/30 minutes before crashing, but what's interesting is that it crashes A LOT faster if we add a loop of 50 iterations to each Invoke we make.
It throws different typs of exceptions, but the simplest one which is just an Invoke and doing split of large string (1kb) causes this one:
(0x77E1E38A) (ntdll): (filename not available): TpCallbackMayRunLong + 0x228
(0x77DDE0D2) (ntdll): (filename not available): RtlAllocateHeap + 0xac
(0x7601EA43) (ole32): (filename not available): CoFreeUnusedLibrariesEx + 0x33e2
(0x7601EA5F) (ole32): (filename not available): CoTaskMemAlloc + 0x13
(0x1003C515) (mono): (filename not available): mono_get_method_constrained + 0x1b0e
(0x04741E20) (Mono JIT code): (filename not available): (wrapper managed-to-native) object:__icall_wrapper_mono_string_to_lpstr (object) + 0x28 (04741DF8 04741E47) [00844E70 - Unity Root Domain] + 0x0
(0x0A493548) (Mono JIT code): (filename not available): (wrapper managed-to-native) Scaleform.Value:SF_AllocateString (string,long) + 0x28 (0A493520 0A49358F) [00844E70 - Unity Root Domain] + 0x0
(0x0A4934F3) (Mono JIT code): (filename not available): Scaleform.Value:.ctor (string,long) + 0x1b (0A4934D8 0A493512) [00844E70 - Unity Root Domain] + 0x0
(0x0A490E5F) (Mono JIT code): (filename not available): Scaleform.Value:CreateValue (object) + 0x277 (0A490BE8 0A490F8A) [00844E70 - Unity Root Domain] + 0x0
(0x0A490B10) (Mono JIT code): (filename not available): Scaleform.Value:Serialize (object[]) + 0xc8 (0A490A48 0A490BBD) [00844E70 - Unity Root Domain] + 0x0
(0x0A49047A) (Mono JIT code): (filename not available): Scaleform.Value:Invoke (string,object[]) + 0x22 (0A490458 0A4904C5) [00844E70 - Unity Root Domain] + 0x0
EDIT: If you check the stack calls, there is a "F_AllocateString", which I assume is entirely related to this "split" call causing the crash. Probably it's not the split function that it's broken, but the memory managed by SF or maybe some memory leak or bad ptr when allocating memory, any memory.
I would like to mention that we had made some fixes on SF source code before (on another project) but this project is using Unity and we don't have Unity's version of SF source code.
We asked for it but not getting any response. What can we do to speed up the process of getting the source so we can fix this on our own side?
Thanks in advance
Hi Nicolas,
If you have an issue unique to your project that you believe you'd need source access for, you'd need to pick up a commercial Scaleform license.
http://gameware.autodesk.com/trials
If you're thinking this is a more general issue with the plugin that needs to be resolved, please provide a reproduction case, and we'll take a look.
Thanks,
Nicholas
Scaleform Support
Can't find what you're looking for? Ask the community or share your knowledge.