[js] secret rtfm

1

Stats

1,092 visits, 1,233 views

Tools

Translations

This tutorial hasn't been translated.

License

This tutorial is licensed under CC BY 4.0. Please refer to the license text if you wish to reuse, share or remix the content contained within this tutorial.

Published on 3 Mar, 2020.

This tutorial will list the very hacky tips that will allow you to do pretty great things, but that risk getting broken for no reason at any point in time.

  • Using the browser plugin, executing globalThis.sdk_runtime = this._runtime created a new global variable called sdk_runtime that you can use to do a lot more stuff
  • Alternatively, adding this addon to the project does the same exact thing with the added benefit of giving access to the runtime before events are run (and so it becomes accessible in runOnStartup callbacks)
  • For example sdk_runtime.GetInstanceByUID(uid)._sdkInst gives you access to the sdk instance of any plugin instance specified by uid
  • Using an sdkInst, sdkInst.CallAction(C3.Plugins.MyPluginID.Acts.MyActionID, argument1, argument2, ...) has the same behavior as an event action given you give it the same arguments
  • 0 Comments

Want to leave a comment? Login or Register an account!