Skip to content

Commit

Permalink
deploy: d912787
Browse files Browse the repository at this point in the history
  • Loading branch information
CodeSmile-0000011110110111 committed Jan 22, 2024
1 parent a07dc0d commit 356cdff
Show file tree
Hide file tree
Showing 187 changed files with 25,745 additions and 489 deletions.
6 changes: 3 additions & 3 deletions Doxyfile
Original file line number Diff line number Diff line change
Expand Up @@ -1991,7 +1991,7 @@ EXTRA_SEARCH_MAPPINGS =
# If the GENERATE_LATEX tag is set to YES, doxygen will generate LaTeX output.
# The default value is: YES.

GENERATE_LATEX = NO
GENERATE_LATEX = YES

# The LATEX_OUTPUT tag is used to specify where the LaTeX docs will be put. If a
# relative path is entered the value of OUTPUT_DIRECTORY will be put in front of
Expand Down Expand Up @@ -2039,7 +2039,7 @@ LATEX_MAKEINDEX_CMD = makeindex
# The default value is: NO.
# This tag requires that the tag GENERATE_LATEX is set to YES.

COMPACT_LATEX = NO
COMPACT_LATEX = YES

# The PAPER_TYPE tag can be used to set the paper type that is used by the
# printer.
Expand Down Expand Up @@ -2142,7 +2142,7 @@ USE_PDFLATEX = YES
# The default value is: NO.
# This tag requires that the tag GENERATE_LATEX is set to YES.

LATEX_BATCHMODE = NO
LATEX_BATCHMODE = NON_STOP

# If the LATEX_HIDE_INDICES tag is set to YES then doxygen will not include the
# index chapters (such as File Index, Compound Index, etc.) in the output.
Expand Down
21 changes: 11 additions & 10 deletions html/doxygen_crawl.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,26 +8,27 @@
<meta name="viewport" content="width=device-width, initial-scale=1"/>
</head>
<body>
<a href="_asset_8cs_source.html"/>
<a href="_asset_8_database_8cs_source.html"/>
<a href="_asset_8_database_8_cache_server_8cs_source.html"/>
<a href="_asset_8cs_source.html"/>
<a href="_asset_8_path_8_static_8cs_source.html"/>
<a href="_asset_8_label_8cs_source.html"/>
<a href="_asset_8_bundle_8cs_source.html"/>
<a href="_asset_8_static_8cs_source.html"/>
<a href="_asset_8_importer_8cs_source.html"/>
<a href="_asset_8_dependency_8cs_source.html"/>
<a href="_asset_8_label_8cs_source.html"/>
<a href="_asset_8_file_8cs_source.html"/>
<a href="_asset_8_static_8cs_source.html"/>
<a href="_asset_8_database_8_cache_server_8cs_source.html"/>
<a href="_asset_8_dependency_8cs_source.html"/>
<a href="_asset_8_package_8cs_source.html"/>
<a href="_asset_8_properties_8cs_source.html"/>
<a href="_asset_8_path_8_static_8cs_source.html"/>
<a href="_asset_8_sub_asset_8cs_source.html"/>
<a href="_asset_8_path_8cs_source.html"/>
<a href="_asset_load_exception_8cs_source.html"/>
<a href="_asset_8_version_control_8cs_source.html"/>
<a href="_asset_8_status_8cs_source.html"/>
<a href="_asset_8_package_8cs_source.html"/>
<a href="_string_extensions_8cs_source.html"/>
<a href="_asset_load_exception_8cs_source.html"/>
<a href="_asset_8_version_control_8cs_source.html"/>
<a href="_asset_8_sub_asset_8cs_source.html"/>
<a href="_asset_8_throw_if_8cs_source.html"/>
<a href="md__p_1_2de_8codesmile_8assetdatabase_2_c_h_a_n_g_e_l_o_g.html"/>
<a href="md__p_1_2de_8codesmile_8assetdatabase_2_g_e_t_t_i_n_g_01_s_t_a_r_t_e_d.html"/>
<a href="namespace_code_smile_editor.html"/>
<a href="class_code_smile_editor_1_1_asset.html"/>
<a href="class_code_smile_editor_1_1_asset_load_exception.html"/>
Expand Down
37 changes: 23 additions & 14 deletions html/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -110,27 +110,14 @@ <h1><a class="anchor" id="but--why"></a>
<p>For every task there is a single call and you are DONE!</p>
<p>The structure and naming is intended to be EXTREMELY simple to find your way around and then to call the appropriate method with fewer parameters, with names that speak for themselves.</p>
<p>No longer do you need to wonder what a 'valid folder' might be. Or ponder what it means to 'force reserialize all assets'.</p>
<p>Let alone the ubiquitous 'SaveAllAssets' followed by 'Refresh' - are you calling that in your scripts? 99% chance you just put it there out of habit. You never gave it any thought. You have no idea what it really does. Not even that it can cripple editor performance. Or when calling it is <b>NOT</b> needed. (Hint: almost every time.)</p>
<p>Let alone the ubiquitous 'SaveAllAssets' followed by 'Refresh' - are you calling that in your scripts? 99% chance you just put it there out of habit. You never gave it any thought. You have no idea what it really does. Not even that it can cripple editor performance. Or when calling it is indeed <b>required</b>. (Hint: almost never!)</p>
<p>Or just being confused, once again, about whether you need to use <code>AssetDatabase.GetTextMetaFilePathFromAssetPath</code> or <code>AssetDatabase.GetAssetPathFromTextMetaFilePath</code>. Or the unholy trinity: <code>AssetPath.AssetPathToGUID</code>~<code>AssetPath.GUIDFromAssetPath</code>~<code>AssetPath.GUIDToAssetPath</code>.</p>
<h1><a class="anchor" id="i-dont-trust-this-"></a>
I don't trust this ..</h1>
<p>The implementation is utmost CORRECT - there are no unnecessary, performance-degrading calls such as 'Refresh' and 'SaveAllAssets' littered throughout like you'll find in most editor scripts - unfortunately even in popular assets/libraries!</p>
<p>It is also extensively unit TESTED to be correct.</p>
<p>And I happen to love correct, clean code. Most developers move on when their code works. I cannot move on until I understand <b>why</b> my code works.</p>
<h1><a class="anchor" id="what-about-support"></a>
What about support?</h1>
<p><a href="https://codesmile-0000011110110111.github.io/de.codesmile.assetdatabase/html/index.html" target="_blank">The documentation</a> is more complete with more details and caveats mentioned than Unity's.</p>
<p>And if there's anything out of the ordinary, open an issue or <a href="mailto:[email protected]">contact me</a>. I also have a <a href="https://discord.gg/JN3Jz8qkeV" target="_blank">Discord channel</a>.</p>
<h1><a class="anchor" id="example-code-snippets"></a>
Example Code Snippets</h1>
<p><code>Asset data = "Assets/Folder/Data.asset";</code> // Load an asset from its path</p>
<p><code>data.ForceSave();</code> // mark asset as dirty and save it</p>
<p><code>data.AddSubAsset(subData);</code> // Add a sub-asset (implicitly saved)</p>
<p><code>data.ActiveImporter = typeof(MyDataImporter);</code> // Change asset's importer</p>
<p><code>data.ExportPackage("I:/leveldata.unitypackage");</code> // Export as .unitypackage</p>
<p><code>var dataObject = data.MainObject;</code> // Get asset's UnityEngine.Object instance</p>
<p><code>var levelData = data.GetAs&lt;LevelData&gt;();</code> // Get it as specific type (may be null)</p>
<p><code>var levelData = (LevelData)data;</code> // Cast to a type (may throw)</p>
<p><code>var obj = Asset.File.Create(str, "Assets/Folder/Data.asset");</code> // Create (overwrite) asset from string</p>
<p><code>var obj = Asset.File.CreateAsNew(bytes, "Assets/Folder/Data.asset");</code> // Create new asset from byte[]</p>
<p><code>var asset = new Asset(bytes, "Assets/Folder/Data.asset");</code> // Same as above using Asset ctor</p>
Expand All @@ -143,12 +130,34 @@ <h1><a class="anchor" id="example-code-snippets"></a>
<li>Load the new asset file</li>
</ul>
<p><code>var actualPath = asset.AssetPath;</code> // Filename might have changed, eg "Data (3).asset"</p>
<p><code>asset.ExportPackage("I:/leveldata.unitypackage");</code> // Export as .unitypackage</p>
<p><code>var obj = asset.MainObject;</code> // Get asset's UnityEngine.Object instance</p>
<p><code>var levelData = asset.GetAs&lt;LevelData&gt;();</code> // Get it as specific type (may be null)</p>
<p><code>var levelData = (LevelData)asset;</code> // Cast to a type (may throw)</p>
<p><code>var subAssets = asset.SubAssets;</code> // Do I need to keep explaining these calls?</p>
<p><code>var assetDupe = asset.Duplicate();</code> // Because you need a duplicate ..</p>
<p><code>assetDupe.Delete();</code> // .. but then decided you don't.</p>
<p><code>var newAsset = asset.SaveAsNew("Assets/Elsewhere/Daydah.asset");</code> // Now you want a copy?</p>
<p><code>newAsset.Trash();</code> // Okay. Either you're bored or excited to work with the AssetDatabase for the first time EVER. :)</p>
<p><code>Asset.File.BatchEditing(() =&gt; { /* mass file IO */ });</code> // Speed up calling many Asset.File.* methods (loop)</p>
<p><code>Asset.File.Import(paths);</code> // Mass import of paths, batched internally</p>
<p><code>var msg = Asset.GetLastErrorMessage();</code> // A file operation failed? Show this!</p>
<h1><a class="anchor" id="i-dont-trust-this-"></a>
I don't trust this ..</h1>
<p>The implementation is utmost CORRECT - there are no unnecessary, performance-degrading calls such as 'Refresh' and 'SaveAllAssets' littered throughout like you'll find in most editor scripts - unfortunately even in popular assets/libraries!</p>
<p>It is also extensively unit TESTED to be correct.</p>
<p>And I happen to love correct, clean code. Most developers move on when their code works. I cannot move on until I understand <b>why</b> my code works.</p>
<h1><a class="anchor" id="what-about-support"></a>
What about support?</h1>
<p><a href="https://codesmile-0000011110110111.github.io/de.codesmile.assetdatabase/html/index.html" target="_blank">The documentation</a> is more complete with more details and caveats mentioned than Unity's.</p>
<p>And if there's anything out of the ordinary, open an issue or <a href="mailto:[email protected]">contact me</a>. I also have a <a href="https://discord.gg/JN3Jz8qkeV" target="_blank">Discord channel</a>.</p>
<h1><a class="anchor" id="wheres-refresh"></a>
Where's Refresh?</h1>
<p>I did mention you don't need it, right? ;)</p>
<p>But if you do, here's Waldo: <code>Asset.Database.ImportAll();</code></p>
<p>Caution: This is an expensive (!) database operation in that it scans the ENTIRE "Assets" tree and tests ALL (!) files for changes made EXTERNALLY (eg System.IO methods, bash scripts).</p>
<p>Refresh also unloads all unused (cached) resources, forcing them to be reloaded from disk on the next use. You can imagine how this has a negative impact on editor performance.</p>
<p>Since Refresh() has been excessively overused I decided to name it closer to what it actually does.</p>
<h1><a class="anchor" id="documentation"></a>
Documentation</h1>
<ul>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,12 @@
</div><!--header-->
<div class="contents">
<div class="textblock"><p><a class="anchor" id="change-log"></a> </p>
<h3><a class="anchor" id="v183---jan-22-2024"></a>
v1.8.3 - Jan 22, 2024</h3>
<ul>
<li>Importer tests: disable some tests in 2021.3 because the method is not available</li>
<li>Rename test: log warning in 2021.3 to mention that the following warning is expected</li>
</ul>
<h3><a class="anchor" id="v182---dec-26-2023"></a>
v1.8.2 - Dec 26, 2023</h3>
<ul>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,122 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=11"/>
<meta name="generator" content="Doxygen 1.10.0"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>CodeSmile AssetDatabase: CodeSmile Packages - Getting Started</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<script type="text/javascript" src="clipboard.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript" src="cookie.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript" src="darkmode_toggle.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="custom.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
<tbody>
<tr id="projectrow">
<td id="projectlogo"><img alt="Logo" src="steffen portrait codesmile logo larger top-left-64x62.png"/></td>
<td id="projectalign">
<div id="projectname">CodeSmile AssetDatabase<span id="projectnumber">&#160;1.8</span>
</div>
<div id="projectbrief">Clean and accessible version of Unity&#39;s ~20 year old AssetDatabase.</div>
</td>
</tr>
</tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.10.0 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
var searchBox = new SearchBox("searchBox", "search/",'.html');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
$(function() {
initMenu('',true,false,'search.php','Search');
$(function() { init_search(); });
});
/* @license-end */
</script>
<div id="main-nav"></div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
<div id="nav-tree">
<div id="nav-tree-contents">
<div id="nav-sync" class="sync"></div>
</div>
</div>
<div id="splitbar" style="-moz-user-select:none;"
class="ui-resizable-handle">
</div>
</div>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
$(function(){initNavTree('md__p_1_2de_8codesmile_8assetdatabase_2_g_e_t_t_i_n_g_01_s_t_a_r_t_e_d.html',''); initResizable(); });
/* @license-end */
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
onmouseover="return searchBox.OnSearchSelectShow()"
onmouseout="return searchBox.OnSearchSelectHide()"
onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<div id="MSearchResults">
<div class="SRPage">
<div id="SRIndex">
<div id="SRResults"></div>
<div class="SRStatus" id="Loading">Loading...</div>
<div class="SRStatus" id="Searching">Searching...</div>
<div class="SRStatus" id="NoMatches">No Matches</div>
</div>
</div>
</div>
</div>

<div><div class="header">
<div class="headertitle"><div class="title">CodeSmile Packages - Getting Started</div></div>
</div><!--header-->
<div class="contents">
<div class="textblock"><p><a class="anchor" id="codesmile-packages---getting-started"></a> Orientation mainly for Asset Store customers since there is nothing under 'Assets' after installation because everything is in 'proper' npm packages.</p>
<p>Check the Menu for available functionality:</p><ul>
<li>Window =&gt; CodeSmile =&gt; ..</li>
</ul>
<p>Run the Tests to confirm that everything is alright:</p><ul>
<li>Window =&gt; General =&gt; Test Runner -&gt; (EditMode) -&gt; select CodeSmile* -&gt; (Run Selected)</li>
</ul>
<p>Locate the Packages (README, scripts, etc):</p><ul>
<li>Project view: <code>Packages/CodeSmile *</code></li>
<li>File system: <code>&lt;path-to-project&gt;/Packages/de.codesmile.*</code> </li>
</ul>
</div></div><!-- contents -->
</div><!-- PageDoc -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
<ul>
<li class="footer">Generated by <a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.10.0 </li>
</ul>
</div>
</body>
</html>
4 changes: 3 additions & 1 deletion html/navtreedata.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,15 +27,17 @@ var NAVTREE =
[ "CodeSmile AssetDatabase", "index.html", [
[ "Who needs this?", "index.html#who-needs-this", null ],
[ "But .. why?", "index.html#but--why", null ],
[ "Example Code Snippets", "index.html#example-code-snippets", null ],
[ "I don't trust this ..", "index.html#i-dont-trust-this-", null ],
[ "What about support?", "index.html#what-about-support", null ],
[ "Example Code Snippets", "index.html#example-code-snippets", null ],
[ "Where's Refresh?", "index.html#wheres-refresh", null ],
[ "Documentation", "index.html#documentation", null ],
[ "Installation", "index.html#installation", null ],
[ "Requirements", "index.html#requirements", null ],
[ "GPL License", "index.html#gpl-license", null ],
[ "Support & Feeback", "index.html#support--feeback", null ],
[ "Change Log", "md__p_1_2de_8codesmile_8assetdatabase_2_c_h_a_n_g_e_l_o_g.html", null ],
[ "CodeSmile Packages - Getting Started", "md__p_1_2de_8codesmile_8assetdatabase_2_g_e_t_t_i_n_g_01_s_t_a_r_t_e_d.html", null ],
[ "Classes", "annotated.html", [
[ "Class List", "annotated.html", "annotated_dup" ],
[ "Class Hierarchy", "hierarchy.html", "hierarchy" ],
Expand Down
Loading

0 comments on commit 356cdff

Please sign in to comment.