Skip to content
reduz edited this page Feb 23, 2014 · 9 revisions

Script

####Inherits: Resource ####Category: Core

Brief Description

Base class for scripts.

Member Functions

Description

Base class for scripts. Any script that is loaded becomes one of these resources, which can then create instances.

Member Function Description

  • bool can_instance ( ) const

Return true if this script can be instance (ie not a library).

Return true if a given object uses an instance of this script.

  • bool has_source_code ( ) const

Return true if the script contains source code.

  • String get_source_code ( ) const

Return the script source code (if available).

  • void set_source_code ( String source )

Set the script source code.

  • int reload ( )

Reload the script. This will fail if there are existing instances.

Clone this wiki locally