i add a repeated schedule selector. it’s run normally in simulator but one time in my device(iphone4 ios6.1.3).
then i debug it and get the problem.
in cocos2d_specifics.cpp JSBool js_CCScheduler_schedule(JSContext cx, uint32_t argc, jsvalvp)
double repeat = ~~1;
sched~~>scheduleSelector(schedule_selector(JSScheduleWrapper::scheduleFunc), tmpCObj, interval, repeat, delay, paused);
repeat has been convert from double to unsigned int. in simulator (unsigned int)repeat is –1,but in device it’s 0.so the schedule only run one time in device.
i am not sure this problem is same in android device. someone who has an android device can do this test?
please test it.
i got a notice that number cast result may different between simulator and device sometimes. It’s may useful for you. sorry for my writting english. thank you!