[iOS] [SW1.4P4] Drag-release generates weird [0,0] events

kidbeyond

  • Posts: 89
Okay, this is a weird bug -- but it's been driving me nuts for days. I've tried my best to track it down or find a workaround, but I can't.

In certain situations, I'm allowing the user to drag an actor left or right.

Upon the drag event, I switch the actor to a different animation (one with no collision boundaries, allowing free movement). No problem, no bug.

Upon the RELEASE, the bug happens: it still thinks it's dragging -- at coordinate [0,0]. This is screwing up my game big-time.

After extensive testing, I've found that it only happens when I switch the actor to a different animation upon the drag event. I had thought it was related to the loss of collision bounds, but it's not. Switching to a different animation with the same collision bounds produces the same bug.

Frequency of the bug:
- Upon a slow, deliberate drag: Occasionally
- Upon a quick drag, like a swipe or flick: Almost Always

Location of the bug:
- On the iPhone device -- iPhone 4S, iOS 5. (I'm not using the simulator much these days -- it taxes my CPU badly.)

Jon, I'm going to email you a test game. Any advice would be most appreciated.

- - - - -

(This is an update of a question I posted here...
http://community.stencyl.com/index.php/topic,5964.msg38450.html#msg38450
... I thought I had found a workaround, but it turns out that didn't work.)

Jon

  • *
  • Posts: 17524
Replied to your e-mail. This is complicated and requires more investigation.