Changes

Jump to navigation Jump to search
m
→‎Crossplatform support: standardize code
Line 185: Line 185:  
<source lang="c#">
 
<source lang="c#">
 
// ✘ Don't do this! It will crash on Linux/Mac.
 
// ✘ Don't do this! It will crash on Linux/Mac.
string path = Helper.DirectoryPath + "\assets\asset.xnb";
+
string path = this.Helper.DirectoryPath + "\assets\asset.xnb";
    
// ✓ This is OK
 
// ✓ This is OK
string path = Path.Combine(Helper.DirectoryPath, "assets", "asset.xnb");
+
string path = Path.Combine(this.Helper.DirectoryPath, "assets", "asset.xnb");
 
</source></li>
 
</source></li>
   −
<li>Use <tt>Helper.DirectoryPath</tt>, don't try to determine the mod path yourself.
+
<li>Use <tt>this.Helper.DirectoryPath</tt>, don't try to determine the mod path yourself.
    
<source lang="c#">
 
<source lang="c#">
Line 198: Line 198:     
// ✓ This is OK
 
// ✓ This is OK
string modFolder = Helper.DirectoryPath;
+
string modFolder = this.Helper.DirectoryPath;
 
</source></li>
 
</source></li>
 
</ol>
 
</ol>
translators
8,404

edits

Navigation menu