Basics of Using Plugins in MOI?

Next
 From:  Geoff (GEE_OFF)
8709.1 
Hi, I'm new to the forum, but have been using MOI for a few years. I have never used plugins in MOI, and lately I attempted to start exploring this process, as it seems I'm missing out on lots of cool features. So far all my attempts to get familiar with plugins have been fruitless, so I'm asking for help. I am starting at zero with regard to plugins, and all the info I've been able to dig up seems to assume some requisite knowledge.

Let me restate this: I need beginner level, 'getting started' guidance with regard to using plugins in MOI.

Here's what I think I've got so far:

One downloads a file that has a .js and a .htm file in it. One then pastes these files in either (or both?) the ui folder or the commands folder.

Once that's done, one opens MOI, then clicks Options > Shortcut Keys > Add. One then types something like, "script:moi.command._Gear.js();" in the "command" column.

Are there any problems with the above? This is all I've been able to glean from combing the forums. Once again, I have no idea what I'm doing with regard to plugins; please be specific as you can.

When I press the key I assigned to this command I get the following message:

"TypeError: Result of expression 'moi.command._Gear'[undefined] is not an object.
line 1
1: >> moi.command._Gear.js();"

EDIT: I seem to recall reading somewhere that this problem (or something similar) happens in V2 but not in V3. I have MOI V3.

EDITED: 30 Nov by GEE_OFF

  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  r2d3
8709.2 In reply to 8709.1 
Hi Geoff,

you did one fault:
If you make a shortcut dont write "script:moi.command._Gear.js();"
Just write "_Gear"
Voila (if the _Gear.js and _Gear.htm are both in your commands folder)

If you write "script:moi ....the following should be js code-only for short things....



Have fun with wonderfull _Gear


Ralf
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  Geoff (GEE_OFF)
8709.3 In reply to 8709.2 
That did it! :D :D :D Thank you, Ralf.
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
 From:  Michael Gibson
8709.4 In reply to 8709.1 
Hi Geoff, also there are instructions for how to install plugins on the FAQ here:
http://moi3d.com/wiki/FAQ#Q:_How_do_I_install_a_plug-in_script.3F

- Michael
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged
 

Reply to All Reply to All