Issue with render when drag mouse (SOLVED)

Hello I use rendercam, and the drag and scroll camera of britzl. the game shows in 800x600 where works ok, but when I make fullscreen window I use in gui stretch, but
objects when I press over and drag for moving mouse moves the animation when not supposed to move them on screen. Animations are flags in certain position and do not need to move. In normal window this does not happen drag works everywhere for move with mouse the camera. But on stretch is disaster. I even put flags in same z as cursor not to be under. And flags do not have collision. Collision has the castle the object. Any help? thanks

It’s not clear to me what the problem is. Could you post some pictures or upload a sample project? Or restate the exact issue?

1 Like

Pkeod I use drag and scroll camera of britzl. When I drag above the object moves the object too from its position when on fullscreen, do not know why happens this, the object has collision with cursor is an area that gives info to user when press. For example city food soldiers, but object has also an animation of a flag on a castle shows who has it. But when you press mouse and dragging for move camera drags also the flag. The object of area is a script , a collision, and the flag anim. The ground is another sprite of tile with no collision under. Thanks

I ll try put picture

This image of normalnormal

The problem in down image is when press and drag mouse to move camera

this is the problem problem

Thanks for help and sorry for bad English is not my native language

Ok, so you are dragging the flag? You want to detect a click but not allow drag?

You can block certain cursor events:

so if I put drag = false in script of objects will not drag yes? do I put this on input?

Ok is this you say to block event with the listen I think I understand now Thanks britzl I will try it now

1 Like

Sorry Britzl I ask again I put the code in controller.script ? except if you mean in cursor.script and I put the url of cursor script but crash by saying /in/cursor.lua:36: You must provide a valid cursor script url
stack traceback:
[C]: in function ‘assert’
/in/cursor.lua:36: in function ‘listen’
/main/controller.script:4: in main chunk
I put the url of cursor.script why says like this do not know… thanks

Ok I found it now works thanks very much, just one thing to ask more is normal this errors hits on cursor.script with nill value on collision with drag at line 238 …. or this suppose do the listen you said to do? thanks

No now works the drag but not works cursor over or collision with these objects… maybe I done sth wrong I ll check … and gives errors as nil values

Britzl I put this listen in init but now cursor has errors as nil value and at cursor_over and cursor_pressed does not show the message.id and x,y like before just saying error because of nil value. I put the code and I put the hash of group of object to block the drag for some reason blocks all. Thanks

I done it works now thank very much britzl

2 Likes