Mouse event or...
-
Hi,
Yes, me again...

I,ve seen plugins that after start wait for a lot of mouse clicks to insert a point (like clinetool) or a component (like component spray). How create this type of mouse event?
I have a script that insert a hole on the wall from its base line. But every time I have to select the base line and activate the script. I want run the script and select the base line, the hole is inserted (already do this) and the system ask for next base line, and so on. This is a mouse event, right? How to do this? Is this happen in cclinetool, correct? And for these cases how is the better way to finalize the command? Right click, escape key or another action?
A lot of questions you are saying, I know, but here is the best place to kill my doubts.
Thanks.
Sérgio
P.S. I've searched on the web and I've opened some scripts to learn how do this, but also I'm trying to leave the programmer's begginer level, and need some explanations as the functions works. -
You need to implement the Tool class: http://code.google.com/intl/nb/apis/sketchup/docs/ourdoc/tool.html
In your plugins folder there is an Example folder - that has examples of how to build a Tool.
-
Moved the thread to the Developer's forum. We have reorganized so that the Plugin section is only a list of plugins you can download and use.

Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register LoginAdvertisement