Bug in Mouse.Set Cursor from Sprite using Chrome & IE

Bugs will be moved here once resolved.

Post » Sat Aug 01, 2015 3:30 pm

Problem Description
When using Mouse.Set Cursor from Sprite, an issue occurs for animated cursors under Chrome & IE

Attach a Capx
See the example Capx here: dropbox.com/s/ilpiesz9r0zkfsu/Cursortest.capx?dl=0

Description of Capx
If you run this Capx, you will notice that the sprite displayed on the layout for test purposes is animated, but not the mouse cursor. If you edit the code to replace "action1.png" and "action2.png" with "press1.png" and "press2.png", you will notice that the cursor does animate properly with these other images.

See forum thread: scirra.com/forum/issue-with-using-images-for-mouse-cursor-animation_t150940

Steps to Reproduce Bug
  • Create a sprite with several animation frames
  • Run animation and have code with ->Sprite.On Frame Changed : Mouse.Set Cursor from Sprite
  • Execute using Chrome or IE

Observed Result
Mouse cursor should be animated, but instead only shows one of the sprite's frames

Expected Result
Mouse cursor should change with each of the sprite's animation frames

Problem is solved if you use Mouse.Set Cursor to Normal, then use Mouse.Set Cursor from Sprite, but this should not be needed or
should be part of warnings in the user-manual.

Affected Browsers
  • Chrome: YES
  • FireFox: NO
  • Internet Explorer: YES

Operating System and Service Pack
Windows 7 Professional SP1

Construct 2 Version ID
R206
B
10
S
3
Posts: 87
Reputation: 957

Post » Sat Aug 01, 2015 4:59 pm

Because the speed of the Default animation for the mouse is set to 0. It wont play on 0 Set it to 1-10 or anything its just personal preference but It will play if it's above 0.
B
10
S
2
G
1
Posts: 24
Reputation: 744

Post » Sun Aug 02, 2015 8:00 pm

@BeckettGaming Not really sure what you are suggesting? There doesn't seem to be any mouse animation speed setting action in Construct 2.
B
10
S
3
Posts: 87
Reputation: 957

Post » Sun Aug 02, 2015 9:59 pm

It's not the mouse it's the Sprite your setting it from. So double click on the sprite that you want the mouse to be then on the right click Default, Then on the left there should be Animation Speed change that from 0 to whatever.
B
10
S
2
G
1
Posts: 24
Reputation: 744

Post » Mon Aug 03, 2015 8:31 am

@BeckettGaming I thought that it may have been what you were talking about, but this is not the issue. I just happened to have left the sprite animation speed in the Capx I saved at zero (sorry for the confusion), but you will notice that if you set it at another value, the problem is not solved unless you add the "Set Cursor to Normal" before setting it to one of the sprite's frames.
B
10
S
3
Posts: 87
Reputation: 957

Post » Thu Aug 06, 2015 3:27 pm

Closing as duplicate of https://www.scirra.com/forum/action-set-cursor-from-sprite-works-only-once-on-chrome_t150776 - should already be fixed for next build.

Note it doesn't work in IE/Edge because the browser does not support changing the cursor.
Scirra Founder
B
403
S
238
G
89
Posts: 24,660
Reputation: 196,167


Return to Closed bugs

Who is online

Users browsing this forum: No registered users and 2 guests