replace mouse

Dec 27, 2010 at 1:23pm

replace mouse

hello,

i’m sorry, i don’t speak english very well
it’s an urgent message

I would like to replace the function of the mousse in the java code to use only two number box (x,y). But I don’t understand what thing I must change in the java code to do it.

Thank you for your help.

Attachments:
  1. dessin.maxpat
#54118
Dec 30, 2010 at 2:33pm

Hello,

I need help.
I don’t understand why the patch crash when I change the brush.
I think that maybe the function “move” is the reason of the crash.

Thank a lot for some informations.

Attachments:
  1. dessin.maxpat
#194730
Jan 4, 2011 at 3:33pm

help me please…

#194731
Jan 4, 2011 at 5:00pm

hello serge,

the draw function, you have to call is ondrag.

but first, you have to remove the following line inside the javascript code:
ondrag.local = 1;

local functions cant be called from outside.

then you should be able to draw with
[pak ondrag 0 0]

d.

#194732
Jan 4, 2011 at 7:02pm

Hello donkey,

Thank’s a lot for your answer.
I have followed all of your indications, but now when I draw anything appears. The drawing is visible when I do
“cmd E”. It’s extrange. When I change the brush the drawing doesn’t start and I must click into the window to finally be able to draw. How could I draw just automatically, without clicking into the window?

Thank you very much for your help

serge

#194733
Jan 5, 2011 at 2:43pm

hello serge,

if you want to start a new draw, you have to send a onclick x y message to the js.
be sure, that you have deleted or disabled the line:
onclick.local = 1;

i have attached a smal version where you also can change the brush without crash.

hope it helps.
d.

#194734

You must be logged in to reply to this topic.