PcoWSkbVqDnWTu_dm2ix

Roblox Packages – Reusable Game Assets

Roblox Packages – Reusable Game Assets

Roblox packages allow you to create object hierarchies once and re-use them in as many games as you’d like. The primary advantage of this workflow is that you can keep packages in sync by updating any copy within any game to the most current version.

Packages can be easily recognized in the Explorer hierarchy by the “chain link” symbol in the lower-right corner of the icon:

Standard Model
Model converted to a package

Converting Objects to Packages

All reusable objects can be converted to packages. Note that if the intended package contains 3D elements, you should group them into a Model and set the PrimaryPart.

To convert an object into a package:

  1. In the Explorer window, right-click the object and select Convert to Package... from the menu.
  2. In the dialog window, fill in the requested details. In specific, note the Ownership selection:
    • Select Me to retain personal ownership.
    • Select a group in which you have articles/Group Games#editing-roles|permission to create/edit group games to publish the package to that group.
  3. Click the Submit button.
  4. Once complete, you'll see a new PackageLink object parented to the object.

Accessing Packages

Toolbox

Submitted packages are added to either the My Packages or Group Packages sorting in the Toolbox Inventory section, depending on which ownership level was assigned when the package was submitted.

Game Explorer

Packages that are used within any place in a game also appear in the Packages folder of the Game Explorer window.

Right-clicking any package in the Game Explorer provides the following options:

Option Description
Insert Adds a copy of the most recent published version of the package under the current selection (or the workspace if nothing else is selected). Double-clicking the package object has the same effect.
Update All Updates a package on a game-wide scale. See Mass-Updating Packages for details.
View on Website Opens up your browser to the package's asset page.
Copy ID to Clipboard Copies the asset ID of the package to the clipboard.
Package Details Lets you manage basic package details, access permissions, and package versions. See Access Permissions and Versioning for details.

Working With Packages

Packaged objects can be edited just like any other object. Those with unpublished changes are marked with an orange dot () in the Explorer window.

Publishing Restrictions

Be mindful that you cannot publish an overall place if it contains packages with unpublished changes. For package copies in this state, you have these options:

  1. Publish the changed copy as the most recent version as outlined in Publishing Changes below.
  2. Undo the changes which were made to the copy. This can be done via the usual Undo shortcut/button or by right-clicking the package and selecting Undo Changes to Package from the context menu.
  3. Delete the changed copy entirely.

Nested Packages

When working with nested packages, for instance a packaged script inside a packaged model, note the following:

  • If you edit and publish a child package (nested package), the parent package will be marked as changed and you'll need to re-publish it.
  • If you edit and publish a parent package, any nested packages within it will not be marked as changed and therefore will not need to be re-published.
  • Nested packages cannot be auto-updated because that occurrence would cause its parent package to become modified.

Change Exceptions

Note that if the object is a Model or GUI object, changes to position or rotation do not count as changing the package. This lets you use several copies of the same object in different positions and orientations.


Publishing Changes

To publish changes to a package and make them available to other package copies:

  1. In the Explorer window, right-click the changed copy and select Publish Changes to Package.
  2. Once completed, outdated copies of the package will be marked with a green sync icon () indicating that a newer version is available.

Syncing Outdated Copies

Outdated package copies marked with a icon can be updated to the most recent version, or you can continue to use the older version. To update to the latest version:

  1. In the Explorer window, right-click the package copy and select Get Latest Package.
  2. If prompted, click the Get Latest button. This will update the package copy to the most recent version.
Syncing Multiple Copies

To sync multiple outdated copies at once, select all of them in the Explorer window, right-click, and choose Get Latest For Selected Packages from the context menu. Alternatively, you may set multiple copies to update automatically as outlined below.


Auto-Updating Copies

To make syncing easier, a package copy can be set to auto-update whenever a newer version is published.

  1. Select the package copy and expand its hierarchy tree in the Explorer window.
  2. Select its PackageLink object.
  3. Enable the AutoUpdate property in the Properties window.

All package copies set to automatically update will appear in Studio after publishing your place, although auto-updates will not auto-publish all places containing copies of the package.

Mass-Updating Packages

In addition to the above methods, packages can be updated on a game-wide scale.

  1. In the Game Explorer window, expand the Packages folder.
  2. Right-click the desired package object and select Update All from the context menu.
  3. In the popup window, select the places within the game for which the mass update should apply.
  4. When ready, click the Update button. Note that this will not auto-publish the selected places, so you’ll need to publish them separately to see the changes.

Access Permissions

If desired, you can share packages with specific users and give them fine-grained control over usage.

  1. In the Game Explorer window, expand the Packages folder.
  2. Right-click the desired package object and select Package Details from the context menu.
  3. In the popup window, select Permissions in the left column to reveal options that pertain to the package’s ownership level:
Ownership Permission Options
Friends Only Find a user by Roblox username, click their name, and then choose a permission level.
  • Use & View — The user will be able to use and view (but not edit) the current and previous package versions.
  • Edit — The user will be able to use, view, and edit the current and previous package versions, including publishing changes to it.
Note that removing a collaborator from a personal package will only prevent them from accessing new versions of the package.
Group Package Expand the role tree by clicking the next to the group's icon, then choose a permission level for each role.
  • Edit — Members of the role will be able to use, view, and edit the current and previous package versions, including publishing changes to it.
  • No Access — Members of the role will not have access to any new versions of the package, although they will retain access to the current and previous versions.
  1. Click the Submit button to register any permission changes.

Versioning

When necessary, you can restore a package to a previous version as follows:

  1. In the Game Explorer window, expand the Packages folder.
  2. Right-click the desired package object and select Package Details from the context menu.
  3. In the popup window, select Versions in the left column.
  4. At the top of the window is the current version (V2, V3, etc.) along with the date/time it was published. To restore a previous version, select its check mark and click Submit.

Comparing Script Changes

When a package object contains scripts — or the script itself is a package — you can compare differences line-by-line using the built-in diff tool. This can help you decide whether to update as well as explore what else in the game may need edits to make the update compatible.

To compare script changes:

  1. In the Explorer window, right-click a modified or outdated package (look for a or icon). Remember that the package must either be a script or contain packaged scripts!
  2. Select View Script Changes… from the context menu.
  3. In the Diff Result tab that opens, you can compare all of the changes between the current package copy and the latest published or local version, similar to source control applications.
Tags:
  • package
  • packages
  • asset