load .pck files Ingame (DLC-System) Godot 3.0

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By Jean18518

Hi guys,

I want to add an DLC-System in my game.

https://forum.godotengine.org/9807/downloadable-content-access-dlc-solved?show=9807#q9807 described it für GoDot 2, but in Godot 3.0.2 the identifier “Globals” doesn’t exist anymore.
Does anyone have ideas, how to load .pck files inngame in Godot 3.0 ?

Have a nice day :slight_smile:

:bust_in_silhouette: Reply From: Calinou

As of Godot 3.0, the Globals singleton is renamed to ProjectSettings.

Therefore, you should now use:

ProjectSettings.load_resource_pack(path_to_pack)

Thank you very much.
this solved the Problem.

For other guys: Here is an example:

ProjectSettings.load_resource_pack("Scene5.pck")

This line loads the Package Scene5.pck which you place next to the executable of your exported Game. Then it is implemented in your Scene-Tree as you exported it. Great feature.

Jean18518 | 2018-05-30 20:13