ResourceInteractiveLoader

Inherits: Reference < Object

Interactive Resource loader.

Description

Interactive Resource loader. This object is returned by ResourceLoader when performing an interactive load. It allows loading resources with high granularity, which makes it mainly useful for displaying loading bars or percentages.

Method Descriptions

Returns the loaded resource if the load operation completed successfully, null otherwise.


  • int get_stage ( ) const

Returns the load stage. The total amount of stages can be queried with get_stage_count.


  • int get_stage_count ( ) const

Returns the total amount of stages (calls to poll) needed to completely load this resource.


Polls the loading operation, i.e. loads a data chunk up to the next stage.

Returns @GlobalScope.OK if the poll is successful but the load operation has not finished yet (intermediate stage). This means poll will have to be called again until the last stage is completed.

Returns @GlobalScope.ERR_FILE_EOF if the load operation has completed successfully. The loaded resource can be obtained by calling get_resource.

Returns another Error code if the poll has failed.


Polls the loading operation successively until the resource is completely loaded or a poll fails.

Returns @GlobalScope.ERR_FILE_EOF if the load operation has completed successfully. The loaded resource can be obtained by calling get_resource.

Returns another Error code if a poll has failed, aborting the operation.

Doc ID missing

Disclaimer: This page has been automaticaly and directly extracted from the official Godot Docs website, the 1970-01-01 at 00:00:00. It’s the English Stable version because it’s what most Godot users should use. The Copyright owners are Juan Linietsky, Ariel Manzur and the Godot community. CC-BY 3.0. Thanks for your patience and generosity.