Touch area remains the same [SOLVED]

twinter3

  • Posts: 98
Hello,

I have a trap door and when I touch it, it spins 90 degrees and opens.  It works fine, but when I click the trap again to close it it doesn't close unless I touch where I originally touched to open it.  Is there any way to close the trap door by touching the actual trap door?  The behavior is on the trap door.

« Last Edit: February 16, 2012, 12:51:01 pm by twinter3 »

captaincomic

  • *
  • Posts: 6108
Which block do you use to rotate the trap door?
And you might want to turn on debug drawing to see what's really going on.

twinter3

  • Posts: 98
I am using the spin block over 1 second with normal in and out.

captaincomic

  • *
  • Posts: 6108
Okay, I tried it and I can see it happening as well. When using the "spin"-block the collision shape rotates, but mouse events are still registered at the original location.

As a workaround: You can download "Mouse Events On Collision Shape" from StencylForge, attach it to your trap door and use the custom blocks that come with it instead of the normal mouse input blocks.