d2jsp
Log InRegister
d2jsp Forums > Off-Topic > Computers & IT > Programming & Development > Does Anyone Know How To Program In Ruby? > I'm Trying To Create A Plugin
Add Reply New Topic New Poll
Member
Posts: 7,205
Joined: Apr 9 2006
Gold: Locked
Trader: Scammer
Warn: 30%
Aug 19 2012 04:59pm
If you can help me with this I will reward you handsomely in forum gold. If you are a Ruby guru pm me or post here!
Member
Posts: 32,925
Joined: Jul 23 2006
Gold: 3,804.50
Aug 19 2012 05:57pm
you should post your problem. do you have a syntax problem, general question on how to get started, do you want someone to debug your code, or what?

a lot of errors are syntax-, framework-, or general problem solving related. depending on what is it, we might not need to know ruby to help you.

This post was edited by carteblanche on Aug 19 2012 05:59pm
Member
Posts: 7,205
Joined: Apr 9 2006
Gold: Locked
Trader: Scammer
Warn: 30%
Aug 19 2012 09:18pm
welll my ultimate goal is to be able to develop a plugin in ruby that i can interface in google sketchup to customize shortcuts. say I want to change draw line to the letter q, i want to be able to make a script that does that. the reason why i dont just go to preferences and manually do it is because ultimately i want to interface this ruby plugin with a kinect input (map hand gestures to certain functions, etc.)


i actually haven't started writing it, but i need to know everything about how to make a plugin in ruby for google sketchup. even if you can find any good resources for it i've looked all over and cant find like a step by step instruction on what programs to even download or what. any help would be greatly appreciated.

This post was edited by PraizeAllah on Aug 19 2012 09:27pm
Member
Posts: 32,925
Joined: Jul 23 2006
Gold: 3,804.50
Aug 19 2012 09:36pm
can you explain what's wrong with google's tutorial?

http://www.sketchup.com/intl/en/community/developers.html

https://developers.google.com/sketchup/

https://developers.google.com/sketchup/docs/tutorial_helloworld

Quote
How do I start?

Check out our FAQ.
Run through our hello world tutorial.
Or dive into the Ruby API documentation.
Feel free to discuss your plugin with others.
If you're interested in reading and writing SketchUp files in your applications you'll be interested in our binary C++ SDK (beta).


im thinking the odds that any given person who knows ruby wrote a plugin for sketchup is probably pretty slim. it's always best to provide as much info as you can in your first post.

This post was edited by carteblanche on Aug 19 2012 09:37pm
Member
Posts: 7,205
Joined: Apr 9 2006
Gold: Locked
Trader: Scammer
Warn: 30%
Sep 2 2012 01:16pm
bump, still trying to figure out how to make a plugin/macro to map to functions in google sketchup
Member
Posts: 7,205
Joined: Apr 9 2006
Gold: Locked
Trader: Scammer
Warn: 30%
Oct 21 2012 09:52am
I AM PAYING 1k FG TO HELP ME OUT IWTH THIS PROBLEM I"M HAVING!

Hey guys so i'm having some trouble. I'm trying to create a custom cursor iin google sketchup (which is based off of Ruby) .

Here is my code:

cursor_id = nil
cursor_path = Sketchup.find_support_file("lorca.png", "Plugins/")
if cursor_path
cursor_id = UI.create_cursor(cursor_path, 0, 0)
UI.messagebox "HI"
end

def onSetCursor
UI.set_cursor(cursor_id)
UI.messagebox "FAIL"
end


im using the UI.messagebox to prompt a box open. IF it says HI then that means it does locate the file and it should update the 'create cursor' with that file. and in my onsetcursor function it should set the cursor to the image that i selected. Can someone please tell me what I'm doing wrong? My image is still just the standard pointer
Member
Posts: 32,925
Joined: Jul 23 2006
Gold: 3,804.50
Oct 21 2012 10:38am
1. what message boxes do you see? HI? FAIL? neither? both?
2. what are the values of cursor_path and cursor_id after the appropriate code executes?
Member
Posts: 7,205
Joined: Apr 9 2006
Gold: Locked
Trader: Scammer
Warn: 30%
Oct 21 2012 02:40pm
Quote (carteblanche @ Oct 21 2012 12:38pm)
1. what message boxes do you see? HI? FAIL? neither? both?
2. what are the values of cursor_path and cursor_id after the appropriate code executes?


i see the HI message box which means it did indeed locate the file but for some reason it wont set the cursor to the image i want

2) cursor_id is 50005 at first, and everytime i execute after that its +1 more (idk why)
and cursor_path is the path to the file (E:/Sketchup/Plugins/lorca.png)
Member
Posts: 7,205
Joined: Apr 9 2006
Gold: Locked
Trader: Scammer
Warn: 30%
Oct 22 2012 07:59am
anyone? :( iwill pay 2k fg if you can help me!
Go Back To Programming & Development Topic List
Add Reply New Topic New Poll