reload_asset_package
Reload already-loaded asset packages from disk non-interactively, preserving or discarding unsaved in-memory edits. Repairs dirty packages flagged by list_dirty_packages.
Instructions
Re-read already-loaded packages FROM DISK, non-interactively (it never opens the modal that would freeze a headless editor), either preserving or permanently discarding their in-memory edits. This is the repair for the situation list_dirty_packages flags: a vendored package left dirty by a compile cascade is cleaned with on_dirty="discard" (was_dirty:[...] -> still_dirty:[]), so the next bulk save cannot write it. Also the way to throw away a bad in-memory edit without touching disk. It reports before/after evidence per package, and skips what it cannot safely reload (not loaded, OFPA, worlds) instead of pretending. WARNING: on_dirty="discard" is irreversible for unsaved work -- check what is dirty first.
Returns: { requested: [string], on_dirty: string, interaction_mode: string, attempted: [string], reloaded: [string], was_dirty: [string], still_dirty: [string], failed: [string], skipped_not_loaded: [string], skipped_ofpa: [string], skipped_world: [object], skipped_invalid: [object], api_returned: bool, api_error: string, verify: { before: [object], after: [object] }, message: string }
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| on_dirty | No | Optional "abort" (default) or "discard". "abort" -> EReloadPackagesInteractionMode::AssumeNegative: a package with unsaved in-memory edits is NOT reloaded and its edits are kept. "discard" -> AssumePositive: UPackageTools clears the dirty flag and reloads, PERMANENTLY THROWING AWAY those in-memory edits. | |
| package_name | No | Convenience single-name alias for package_names. | |
| package_names | No | Array of long package names (or object paths) to reload, e.g. ["/Game/VendorPack/.../DT_ItemRows"]. |