Click or drag to resize

ModHost Properties

The ModHost type exposes the following members.

Properties
  NameDescription
Public propertyStatic memberAllLoadedModHosts
Public propertyStatic memberAllModHosts
Returns an array of references to all mod hosts currently in the scene regardless of their load state.
Public propertyAssets
Returns the IModAssets interface for the current mod allowing asset loaading from the mod via the host.
Public propertyCanBeReclaimed
When true, existing mod hosts that are in an idle state (Unloaded and not loading) may be reclaimed for reuse by another mod load. Calls to CreateNewHost or Load(Uri, Boolean) may result in host reclaims. By default, this value is true.
Public propertyCurrentIdentity
Returns an instance of the ModIdentityy class representing the current loaded mod or null if no mod is loaded.
Public propertyCurrentMod
Returns the IModInfo interface for the the current mod allowing access to values such as mod name and version.
Public propertyCurrentModPath
Returns the current mod path representing the loaded mod location as specified in the Load(Uri, Boolean) method. If no mod is loaded then the return value will be null. Note that the mod path may be set before the host has actually loaded the mod so it is reccommended that you also check IsModLoading
Public propertyDebugHandler
Returns the ModDebugHandler for the current mod and can be used to log useful debug messages.
Public propertyDownloadSpeed
Get the current DownloadSpeed for this mod host. This value will only be used when IsModDownloading is true.
Public propertyHasAssets
Returns true if the current loaded mod contains any prefab assets.
Public propertyHasDependencies
Returns true if the current mod is dependant upon any other mods.
Public propertyHasScenes
Returns true if the current loaded mod contains any scenes.
Public propertyHasScripts
Returns true if the current loaded mod contains any code assets. Code assets can be in the form of C# scripts or managed assemblies and both will be treated as 'Scripts'
Public propertyHostDependencies
Get an array of ModHost that this host is dependant upon in order to function correclty. This array will only be populated once this host has finished loading its hosted mod.
Public propertyIsModActivated
Returns true if this mod host has been activated. Activation causes the mod content to be initialized. Without activation, the content is not accessible.
Public propertyIsModDownloading
Returns true if this mod host is currently downloading from a remote server or reading from the local file system.
Public propertyIsModLoaded
Returns true if this mod host currently has a mod loaded otherwise returns false.
Public propertyIsModLoading
Returns true if this mod host is currently loading a mod otherwise returns false.
Public propertyLoadResult
Returns the ModLoadResult for the last load attempt.
Public propertyReferencedMods
Get and array of IModInfo that the current mod references.
Public propertyScenes
Returns the IModScenes interface for the current mod allowing scene loading from the mod via the host.
Public propertyScriptDomain
Access the script domain for this mod. If the host does not have a mod loaded then the return value will be null.
Public propertySharedAssets
Returns the IModAssets interface for the current mod allowing shared asset loading from the mod via the host. Shared assets include all referenced mod assets reccursivley as well as this mods assets.
Public propertySharedScenes
Returns the IModScenes interface for the current mod allowing scene loading from the mod via the host. Shared scenes include all referenced mod scenes reccursivley as well as this mods scenes.
Top
See Also