Khaz
Knight
Exception thrown when invoking Animations.GetAnimation
I'm new to using the Ultima SDK and have been working on getting the first frame of a mobile animation loaded into a PictureBox control on a Windows Form.
When invoking Animations.GetAnimation, a TypeInitializerException is thrown. The trace describes the final method as BodyConverter.Contains, and the exception's inner message is "Input string was not in a correct form."
The code I am using is below. Can anyone identify if this is a configuration, coding or SDK issue?
I'm new to using the Ultima SDK and have been working on getting the first frame of a mobile animation loaded into a PictureBox control on a Windows Form.
When invoking Animations.GetAnimation, a TypeInitializerException is thrown. The trace describes the final method as BodyConverter.Contains, and the exception's inner message is "Input string was not in a correct form."
The code I am using is below. Can anyone identify if this is a configuration, coding or SDK issue?
Code:
Ultima.Frame[] frames = Ultima.Animations.GetAnimation( 400, 1, 1, 0, true );
pictureBox.Image = frames[0].Bitmap;