"set cursor from sprite" doesn't work

0 favourites
  • 13 posts
From the Asset Store
Mouse cursor is something that the player controls and sees all the time, that's why it is so important to make it cool!
  • I tried to change the cursor on my skin, put the action "set cursor from sprite <my sprite>" in event "start of layout" - does not work. I tried to put on the "always" - the same thing. What is wrong?

  • Post your capx.

    I've just id a quick try, in FF14 in a start of layout, the action DOES work.

    Perhaps it is the browser you're trying your project in that doesn't support the action (I'm not sure at all about that), or maybe your texture has some issue.

    Anyway, without a concrete capx to look at, no way to tell.

  • Here is the file. I made it specifically to show that it is not working.

  • I don't speak russian and I can't seem to find how to download the file.

    But I can assure you: it works (tested in Firefox 14 and Chrome 20)

    Please try dropbox.

    Also don't provide a zip, prefer "saving as one file" (capx)

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • in a project that I do, nothing still does not work, although the differences from your project, I did not see. once my project.HERE

  • There's something wrong with your texture.

    Whenever I import a texture from a file it works as expected.

    Did you draw the texture in C2 directly ?

  • I do not paint the texture in the C2, I take the sprites of the images in PNG format. problem with this?

  • I don't know.

    In the absolute there is no problem with pngs, when I import one of mine in your project it works right away.

    But your current texture does not seem to work as intended.

    Maybe Ashley could have an idea what's going wrong.

  • There are strict limitations on what kind of image can be used for a cursor.

    1: it cannot be bigger than 128x128

    2: it will not take in to account any properties (such as angle, opacity, being resized other than 1:1, any blend modes, etc etc). It will simply use what you see in the image editor as the cursor.

    3: it won't work in Internet Explorer at all

    4: it may not work on operating systems other than Windows

    Since your image is bigger than 128x128 it fails to load. Resize it down in the image editor to something smaller and it works, at least on Windows 7 with Chrome or Firefox.

  • Ahhhhhhh Thank you Ashley..That explains my problem also and saves me asking my question...I thought it was a bug and going to report it...For some odd reason if you use an entirely transparent PNG as the cursor Sprite If you try to use a Transparent PNG as the cursor sprite its just turns black and does not display the transparency at all...Nice to know thanks Ashley..

    I ended up started using a single pixel sprite instead of a transparent PNG...Is there any chance we can get the transparency working.....it just displays as BLACK..NO transparency at all...

  • Bump

  • And a fifth: There must be an instance of the sprite you want your cursor to change to for it to work! (Might be a good idea to put that in the help section in C2 when you select it under the action chooser!)

  • Another bump (I'm very sorry.)

    I usually put it on the very top layer and lock it and put it outside the layout. If you choose to do it the X, Y way, this is the best way to do it so the cursor doesn't go on bottom of any object.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)