In SVN 3983, I changed CL_Sprite animation timing to use milliseconds (ints) instead of seconds (float).

I made a mistake, in assuming the Resources "speed" parameter was in frames per second.

ClanLib/Development/ClanLib-2.0/Documentation/Overview/sprites-resources.html -- This will need reverting to its original state.


ClanLib/Development/ClanLib-2.0/Sources/Display/2D/sprite_impl.cpp ---
Code:
int delay_ms = 1000 / 50; // Default to 50fps (as per documention)
if (cur_element.has_attribute(cl_text("speed"))) 
{
  delay_ms = CL_StringHelp::text_to_int(cur_element.get_attribute(cl_text("speed"), cl_text("50")));
  if (delay_ms == 0)
  throw CL_Exception(cl_text("You cannot have 0fps for animation speed"));
  delay_ms = 1000 / delay_ms;
 }
if (cur_element.has_attribute(cl_text("delay")))
{
  delay_ms = CL_StringHelp::text_to_int(cur_element.get_attribute(cl_text("delay"), cl_text("20")));
}
Should be:

Code:
delay_ms = CL_StringHelp::text_to_int(cur_element.get_attribute(cl_text("speed"), cl_text("50")));
Finally,

Code:
if (cur_element.has_attribute(cl_text("speed")))
{
 sptr->delay_ms = CL_StringHelp::text_to_int(cur_element.get_attribute(cl_text("speed"), cl_text("50")));
 if (sptr->delay_ms == 0)
 throw CL_Exception(cl_text("You cannot have 0fps for frame speed"));
 sptr->delay_ms = 1000 / sptr->delay_ms;
}
if (cur_element.has_attribute(cl_text("delay"))) 
{
 sptr->delay_ms = CL_StringHelp::text_to_int(cur_element.get_attribute(cl_text("delay"), cl_text("20")));
}
Should be:

Code:
if (cur_element.has_attribute(cl_text("speed")))
{
 sptr->delay_ms = CL_StringHelp::text_to_int(cur_element.get_attribute(cl_text("speed"), cl_text("50")));
}