Changes

Jump to navigation Jump to search
→‎Content: + AssetsInvalidated
Line 119: Line 119:  
* Editing an asset which doesn't exist has no effect. This is applied after the asset is loaded from the game's <samp>Content</samp> folder, or from any mod's <samp>LoadFrom</samp> or <samp>LoadFromModFile</samp>.
 
* Editing an asset which doesn't exist has no effect. This is applied after the asset is loaded from the game's <samp>Content</samp> folder, or from any mod's <samp>LoadFrom</samp> or <samp>LoadFromModFile</samp>.
 
* You can apply any number of edits to the asset. Each edit will be applied on top of the previous one (i.e. it'll see the merged asset from all previous edits as its input).
 
* You can apply any number of edits to the asset. Each edit will be applied on top of the previous one (i.e. it'll see the merged asset from all previous edits as its input).
 +
}}
 +
{{/event
 +
|group = Content
 +
|name  = AssetsInvalidated
 +
|desc  = Raised after one or more assets were [[Modding:Modder Guide/APIs/Content#Cache invalidation|invalidated from the content cache]] by a mod, so they'll be reloaded next time they're requested. If the assets will be reloaded or propagated automatically, this event is raised before that happens.
 +
 +
Next time the asset is loaded (including for asset propagation), the [[#Content.AssetRequested|<samp>AssetRequested</samp>]] event will be raised again.
 +
 +
|arg name 1 = <samp>e.Names</samp>
 +
|arg type 1 = <samp>IEnumerable<IAssetName></samp>
 +
|arg desc 1 = The asset names that were invalidated. These include utility methods to parse the values, like <code>name.IsEquivalentTo("Portraits/Abigail")</code> (which handles any differences in formatting for you).
 
}}
 
}}
 
{{!}}}
 
{{!}}}
translators
8,445

edits

Navigation menu