Skip to content

Commit e27e82c

Browse files
Kelwanzaucy
authored andcommitted
Format changes, added pages to search info and more links everywhere (#59)
1 parent d1921b0 commit e27e82c

File tree

6 files changed

+73
-17
lines changed

6 files changed

+73
-17
lines changed

src/app/docs/unity/defaults/defaults.component.html

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,9 @@ <h2 id="runner">Runner</h2>
2323
can choose the following options:
2424
</p>
2525
<ol>
26-
<li>Default: Executes per Update tick</li>
27-
<li>Fixed Update: Executes per FixedUpate tick</li>
28-
<li>None: implement your own Runner</li>
26+
<li><code>Default</code>: Executes per Update tick</li>
27+
<li><code>Fixed Update</code>: Executes per FixedUpate tick</li>
28+
<li><code>None</code>: Implement your own Runner</li>
2929
</ol>
3030
<h3>ExecutionOptions</h3>
3131
<p>Allows you to add actions to the execution to be performed</p>

src/app/docs/unity/system-impl/system-impl.component.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ <h1 id="title">Implementing Systems in Unity</h1>
88
<section>
99
<h2 id="csharp-system-impl">C# System Implementation</h2>
1010
<p>
11-
To enable C# system implementations open your Unity project and go to
11+
To enable C# system implementations, open your Unity project and go to
1212
<strong
1313
>Project Settings <span class="i24">arrow_right</span> Ecsact
1414
<span class="i24">arrow_right</span> System Implementations

src/app/docs/unity/unity-sync/unity-sync.component.html

Lines changed: 18 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ <h2 id="introduction">Introduction</h2>
55
<p>
66
Unity Sync is an optional part of Ecsact for Unity. Monobehaviour scripts
77
can be added to entities automatically if the entity fulfills the
8-
requirements of the script. There a few ways this can happen
8+
requirements of the script. There a few ways this can happen:
99
</p>
1010
</section>
1111
<section>
@@ -15,7 +15,7 @@ <h2 id="required">IRequired</h2>
1515
</p>
1616
<p>
1717
Creates a requirement for the script to be added to a gameObject. If an
18-
entity has all the required components, it will be added to the script
18+
entity has all the required components, it will be added to the script.
1919
</p>
2020
</section>
2121
<section>
@@ -26,7 +26,11 @@ <h2 id="on-init">IOnInitComponent</h2>
2626
<p>
2727
When a component is first initialized, the callback function will be
2828
invoked. Needs to be implemented by a function with its component type as
29-
a parameter
29+
a parameter.
30+
</p>
31+
<p>
32+
<span class="i48"> info </span>Implements
33+
<code>Ecsact.Defaults.Runtime.OnInitComponent</code>
3034
</p>
3135
</section>
3236
<section>
@@ -39,7 +43,11 @@ <h2 id="on-update">IOnUpdateComponent</h2>
3943
<p>
4044
Whenever a component is updated, the callback function will be invoked.
4145
Needs to be implemented by a function with its component type as a
42-
parameter
46+
parameter.
47+
</p>
48+
<p>
49+
<span class="i48"> info </span>Implements
50+
<code>Ecsact.Defaults.Runtime.OnUpdateComponent</code>
4351
</p>
4452
</section>
4553
<section>
@@ -52,7 +60,11 @@ <h2 id="on-remove">IOnRemoveComponent</h2>
5260
<p>
5361
Whenever a component is updated, the callback function will be invoked.
5462
The Remove callback has <code>readonly</code> access to the component from
55-
when it was removed
63+
when it was removed.
64+
</p>
65+
<p>
66+
<span class="i48"> info </span>Implements
67+
<code>Ecsact.Defaults.Runtime.OnRemoveComponent</code>
5668
</p>
5769
</section>
5870
<section>
@@ -89,7 +101,7 @@ <h2 id="on-remove">IOnRemoveComponent</h2>
89101
<code>IOnUpdateComponent</code> do not implicitly cause an
90102
<code>IRequired</code> effect. If <code>IRequired</code> is not used, then
91103
the script will be added to any entity that that can use any of its
92-
implementations
104+
implementations.
93105
</p>
94106
</section>
95107
</article>

src/app/tutorials/unity/basic-example/basic-example.component.html

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,9 @@ <h2>Introduction</h2>
77
This will cover the basics of using Ecsact with Unity. We will create
88
entities, add components and implement systems using C#. The scene
99
<code>Basic Example</code> in
10-
<a href="https://github.com/ecsact-dev/unity-example">unity-example</a>
10+
<a href="https://github.com/ecsact-dev/unity-example" target="_blank"
11+
>unity-example</a
12+
>
1113
has all the contents of this tutorial.
1214
</p>
1315

@@ -29,7 +31,7 @@ <h2>Setup</h2>
2931
<section>
3032
<h2 id="ecsact">
3133
Writing the
32-
<a routerLink="/docs/lang" routerLinkActive="active">Ecsact</a> File
34+
<a routerLink="/docs/lang">Ecsact</a> File
3335
</h2>
3436
<p>
3537
First, let's look at what we'll need in our
@@ -60,7 +62,7 @@ <h2 id="create-entity">Creating an Entity</h2>
6062
<p>
6163
Great! We have a simple <code>.Ecsact</code> file we can build on. Now we
6264
can make a C# script in Unity, for our use it will be called
63-
<code>BasicExample.cs</code>. Now, we can
65+
<code>BasicExample.cs</code>. This script will allow us to
6466
<a href="/docs/unity/entities">create an entity</a>
6567
</p>
6668

@@ -153,12 +155,14 @@ <h2 id="components">Declaring and adding components</h2>
153155
</section>
154156

155157
<section>
156-
<h2 id="system-implement">Implementing a System</h2>
158+
<h2 id="system-implement">
159+
Implementing a <a routerLink="/docs/unity/system-impl">System</a>
160+
</h2>
157161
<p>
158162
Now the entity has components, which will cause our system to trigger. Now
159163
we need to implement the system for it to happen. If you haven't setup
160-
your <a href="/start/unity">Assembly Definition</a> now is the time. If
161-
the script is not part of an assembly, it will not be found. We'll name
164+
your <a routerLink="/start/unity">Assembly Definition</a> now is the time.
165+
If the script is not part of an assembly, it will not be found. We'll name
162166
our new system script
163167
<code>BasicExampleSystem.cs</code>
164168
</p>

src/app/tutorials/unity/moving-block/moving-block.component.html

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,9 @@ <h1>Example Using Unity Sync</h1>
55
<h2 id="introduction">Introduction</h2>
66
<p>
77
This tutorial will take a look at how Ecsact, the Unity API, and Unity
8-
Sync can be used create a simple game. We'll be using the scene
8+
Sync can be used create a simple game. If you haven't tried the
9+
<a routerLink="/start/tutorials/unity/basic-example">basic example</a>
10+
yet, it's recommended to start there first. We'll be using the scene
911
<code>EcsactExample</code> in the
1012
<a href="https://github.com/ecsact-dev/unity-example" target="_blank"
1113
>unity-example</a

src/search/searchable-page-infos.ts

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,4 +60,42 @@ export const searchablePageInfos: {[key: string]: PageInfo | undefined} = {
6060
keywords: [],
6161
title: 'Ecsact Runtime Implementations',
6262
},
63+
'/docs/unity/defaults': {
64+
category: PageCategory.Documentation,
65+
description: 'Information about the Ecsact Defaults class in Unity',
66+
keywords: ['defaults', 'pool', 'registry', 'runner'],
67+
title: 'Unity Defaults Class',
68+
},
69+
'/docs/unity/entities': {
70+
category: PageCategory.Documentation,
71+
description: 'How to create entities in Ecsact Unity',
72+
keywords: ['entities', 'entity', 'generates', 'dynamic', 'createentity'],
73+
title: 'Creating Entities',
74+
},
75+
'/docs/unity/unity-sync': {
76+
category: PageCategory.Documentation,
77+
description: 'Documentation for how Unity Sync works with Ecasct Unity',
78+
keywords: ['unity-sync', 'irequired', 'ioninit', 'inonupdate', 'ionremove'],
79+
title: 'Unity Sync',
80+
},
81+
'./docs/unity/system-impl': {
82+
category: PageCategory.Documentation,
83+
description: 'How to implement systems in Ecsact Unity',
84+
keywords: ['system implementation', 'defaultsystemimpl'],
85+
title: 'Implementing Systems',
86+
},
87+
'/start/tutorials/unity/basic-example': {
88+
category: PageCategory.Tutorial,
89+
description:
90+
'Learn about how Ecsact works with Unity with this basic example',
91+
keywords: ['tutorial', 'basic example', 'learn Unity'],
92+
title: 'Basic Unity Example',
93+
},
94+
'/start/tutorials/unity/moving-block': {
95+
category: PageCategory.Tutorial,
96+
description:
97+
'Learn more about Unity Sync and nested systems in this Unity tutorial',
98+
keywords: ['tutorial', 'unity sync', 'learn unity', 'moving block'],
99+
title: 'Unity Moving Block Example',
100+
},
63101
};

0 commit comments

Comments
 (0)