Luna::Asset::set_asset_data

RV set_asset_data(asset_t asset, object_t data)

Sets the asset data object.

Parameters

  • in asset

    The asset handle of the asset to operate.

  • in data

    The asset data to set. If this is nullptr, the asset data will be cleared, and the asset will be in AssetState::unloaded state.

Valid Usage

  • If data is not nullptr, it must be a valid pointer to a boxed instance.