It won’t drag if you scroll the view.
I meant to get node, didn’t for dragging.
I’m having many trouble in this.
The left mouse click scroll has been too much fast. The cose is same of you, how can I solve it?
You need to provide more information for me to be able to help. What lecture are you on? What is the behaviour you’re getting?
I’m sorry, I thought we were telling only about scrolling view.
I’m on Lecture 19 - Scrolling View
When I drag with left mouse click, the view scrolls too much fast, I quietly have not the intermediate positions.
Any chance you wrote times as in * scroll position not add aka +?
Unluckily I’ve not done it.
Maybe worth posting your code here in case someone spots the difference
I don’t know what has changed, but now it scroll right but it trembles. Here a gif and the code:
I’ve tried with boolean like tutorial too, but it doesn’t work too.
I’d say go back. With the way your code is formatted I find it harder to follow but you haven’t got something really differentiating the canvas drag it looks like it’s thinking you release the mouse and then start again but by the time it does you have moved more.
This would be a result of some variable being set and unset in different frames normally.
This certainly doesn’t look like the same code Sam has
Sorry. On a phone but here I see Sam has canvas dragging variable. You don’t.
As I said, I’ve tried with draggingCavas var too, it acts same!
Thanks for your support
Maybe post your code with the canvas dragging variable?
Of course. Here it is:
From debug, it seems like mousePosition changes continuosly direction also if I drag always in same direction.
The mouse position should change. You’re moving it.
Can I suggest you put in logs for each if showing like drag mode started, drag canvas started, end mode drag and end canvas drag
I think you’re getting calls to the end and starts triggered somehow
If you see it changes left and right continuously also if I drag in one direction only.
I’m going to log them!
Could you try my code from version control? I would like to see if there’s something different about your machine.
Okay, I solved downloading your code…
I’ve done a noob error XD
These two lines were inverted ._.
Thank you guys!!
Glad you found it. In my experience the above is rarely the case
This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.