Author Topic: Improved Plugin Control / Management  (Read 550 times)

cgduda

  • Newbie
  • *
  • Posts: 2
Improved Plugin Control / Management
« on: October 24, 2017, 05:04:58 pm »
If this already exists, please point me in the right direction to find it.

I know that plugins can be disabled as a whole via the options panel and that they can be removed completely by removing them from the apps directory.  What I am looking for is a way to limit plugins so that they only function when specific profiles are active or perhaps turned on or off when a command is given.  (e.g. the EDDI plugin for Elite Dangerous does not need to run (and read articles) when I am not in game).   Ideally this would extend to running with linked profiles, etc.  As far as I can tell, this is not an option.

This would help open up VA for other avenues beyond games (IMHO, or at least in my household).

Thank you.


Gary

  • Administrator
  • Hero Member
  • *****
  • Posts: 1482
Re: Improved Plugin Control / Management
« Reply #1 on: October 24, 2017, 06:38:29 pm »
Well, plugins don't *have* to run constantly.  They are bits of code that only run when a command is given.  If that code is just a quick query to a website, read a file, or somehow a hand-coded, high-availability database for NASA, that's up to you ;)  In a nutshell, plugins do absolutely nothing until they are told to do something by VA, and VA doesn't do anything to the plugins unless a command is issued.  Same goes for inline C#/VB.net functions.  Ideally, if a plugin is going to continue running beyond the scope of a command, it should be designed to be able to be stopped if the user needs it to.    If you need EDDI to stop, you'll need to issue the right command to it to stop doing whatever its doing if that functionality exists. Otherwise, you'll need to ping the EDDI author to see if that can be done for you in that regard.  Also, the plugins themselves can monitor what profile is active, so if they are running outside where they should be, they have the ability to limit themselves.  So, effectively, the onus is on the plugin developer to keep things square.

Hope that helps!

cgduda

  • Newbie
  • *
  • Posts: 2
Re: Improved Plugin Control / Management
« Reply #2 on: October 25, 2017, 07:36:16 am »
Yes, it does help. 

I wondered it that was something that had to be dealt with on the other end, so to speak.  That makes sense in terms of keeping VA itself manageable  It gives me some ideas of what to do when creating my own plugins in the not-to-distant future. 

Thank you for your time.

Tkael

  • Newbie
  • *
  • Posts: 41
Re: Improved Plugin Control / Management
« Reply #3 on: December 02, 2017, 01:31:15 am »
I just stumbled across this thread, and as part of EDDI's current dev team I may be able to provide some useful input here:

1. In EDDI, it is possible to enable and disable the speech responder via the plugin. The plugin calls are 'enablespeechresponder' and 'disablespeechresponder' respectively. In the default EDDI profile, the commands that use these calls are 'Be quiet' and 'You may talk'.

2. We've recently been working on updating EDDI to be more sensitive to in-game / out-of-game context prior to reading Galnet articles. The latest beta includes some code moving in that direction, and the next beta will include more code to ensure the Galnet monitor is only active while in-game.