High Scripts

Documentation

Shared

Fields and functions that can be used in any bridge.

resourceName

The name of the resource this bridge should detect and use.


disableProvide

This disallows other resources to provide 'this_resource' in their manifest.


init

This gets automatically called when the resource is detected and the bridge is initialized, can be used for initializing global variables like getSharedObject and everything else.

NameTypeDescription
thisBridgeThe table of this bridge, e.g. allows you to use this.resourceName

Example

bridges/client/frameworks/my_framework.lua
init = function(this)
    dbgprint('my_framework Detected and loaded')
 
    require '@my_framework/lib.lua'
    -- OR
    OBJ = exports.my_framework:getSharedObject()
end

Last updated on

On this page