Changes
Jump to navigation
Jump to search
← Older edit
Newer edit →
Modding:Modder Guide/APIs
(view source)
Revision as of 22:56, 1 December 2017
3 bytes removed
,
22:56, 1 December 2017
→Inject assets
:
fix example
Line 494:
Line 494:
/// <summary>Load a matched asset.</summary>
/// <summary>Load a matched asset.</summary>
/// <param name="asset">Basic metadata about the asset being loaded.</param>
/// <param name="asset">Basic metadata about the asset being loaded.</param>
−
public
void
Load<T>(IAssetInfo asset)
+
public
T
Load<T>(IAssetInfo asset)
{
{
return (T)(object)new Dictionary<string, string> // (T)(object) is a trick to cast anything to T if we know it's compatible
return (T)(object)new Dictionary<string, string> // (T)(object) is a trick to cast anything to T if we know it's compatible
Pathoschild
translators
8,446
edits
Navigation menu
Personal tools
Create account
Log in
Namespaces
Modding
Discussion
Variants
Views
Read
View source
View history
More
Search
Navigation
Main page
Recent changes
Admin noticeboard
Help Editing
Random page
Official Links
Official Site
Official Forums
Official Merchandise
Discord
Reddit
Tools
Upload file
Special pages
Printable version