Skip to content

Add global forward OnPluginLoad #1482

@dragokas

Description

@dragokas

A counterweight to #890 I beg you to add OnPluginLoad() forward to know when some (or any) plugin is loaded.

Use cases:

  1. Left 4 DHooks Direct
    Left 4 DHooks does not hook everything at once (for CPU saving). It only hooks what we need and what other plugins use at the moment and provides only those forwards.

So, when some plugin is reloaded, or late loaded, with OnPluginLoad() you can run a detection routine to check if any new forward is required (if the plugin does not use "RegPluginLibrary", for instance) and such a way it starts appropriate hooks and forwards required by that plugin.

  1. Command Eater
    It uses a special command cache built from the commands enumerator (which consuming quite a lot CPU cycles).
    In case some plugin is dynamically loaded / unloaded, with OnPluginLoad() we can detect this action, and start to rebuild those commands cache. It should be always in actual state.

Thanks for your attention and hope for a positive answer.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions