Jump to content

Moving an image to a point


developa

Recommended Posts

Don't bump your forum posts while they're still 7 hours old.

You can use onClientClick to check if a mouse button is pressed down, which allows you to then move around an item on the screen using getCursorPosition in conjunction with onClientRender. To stop moving, you can again use the same onClientClick event to determine when the mouse button is up so you can stop rendering the movement.

Link to comment
1 hour ago, myonlake said:

Don't bump your forum posts while they're still 7 hours old.

You can use onClientClick to check if a mouse button is pressed down, which allows you to then move around an item on the screen using getCursorPosition in conjunction with onClientRender. To stop moving, you can again use the same onClientClick event to determine when the mouse button is up so you can stop rendering the movement.

getCursorPosition* screenSizeX

because getCursorPosition returns a value from 0 to 1 :) 

Edited by coNolel
Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...