hytopia 0.7.7 → 0.7.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -42,7 +42,7 @@ boolean
42
42
 
43
43
  </td><td>
44
44
 
45
- _(Optional)_ Whether to use the tick allocator to allocate the returned array of Audio instances. The allocated array will be collected and released at the end of the current tick if true. Only use this if you know what you're doing.
45
+ _(Optional)_ If true, uses the tick allocator and frees the allocated array at the end of the current tick. false by default.
46
46
 
47
47
 
48
48
  </td></tr>
@@ -9,7 +9,7 @@ Retrieves all loaded audio instances attached to a specific entity.
9
9
  **Signature:**
10
10
 
11
11
  ```typescript
12
- getAllEntityAttachedAudios(entity: Entity): Audio[];
12
+ getAllEntityAttachedAudios(entity: Entity, tickAllocated?: boolean): Audio[];
13
13
  ```
14
14
 
15
15
  ## Parameters
@@ -45,6 +45,22 @@ entity
45
45
  The entity to get attached audio instances for.
46
46
 
47
47
 
48
+ </td></tr>
49
+ <tr><td>
50
+
51
+ tickAllocated
52
+
53
+
54
+ </td><td>
55
+
56
+ boolean
57
+
58
+
59
+ </td><td>
60
+
61
+ _(Optional)_ If true, uses the tick allocator and frees the allocated array at the end of the current tick. false by default.
62
+
63
+
48
64
  </td></tr>
49
65
  </tbody></table>
50
66
  **Returns:**
@@ -9,8 +9,44 @@ Retrieves all looped audio instances for the world.
9
9
  **Signature:**
10
10
 
11
11
  ```typescript
12
- getAllLoopedAudios(): Audio[];
12
+ getAllLoopedAudios(tickAllocated?: boolean): Audio[];
13
13
  ```
14
+
15
+ ## Parameters
16
+
17
+ <table><thead><tr><th>
18
+
19
+ Parameter
20
+
21
+
22
+ </th><th>
23
+
24
+ Type
25
+
26
+
27
+ </th><th>
28
+
29
+ Description
30
+
31
+
32
+ </th></tr></thead>
33
+ <tbody><tr><td>
34
+
35
+ tickAllocated
36
+
37
+
38
+ </td><td>
39
+
40
+ boolean
41
+
42
+
43
+ </td><td>
44
+
45
+ _(Optional)_ If true, uses the tick allocator and frees the allocated array at the end of the current tick. false by default.
46
+
47
+
48
+ </td></tr>
49
+ </tbody></table>
14
50
  **Returns:**
15
51
 
16
52
  [Audio](./server.audio.md)<!-- -->\[\]
@@ -9,8 +9,44 @@ Retrieves all oneshot (non-looped) audio instances for the world.
9
9
  **Signature:**
10
10
 
11
11
  ```typescript
12
- getAllOneshotAudios(): Audio[];
12
+ getAllOneshotAudios(tickAllocated?: boolean): Audio[];
13
13
  ```
14
+
15
+ ## Parameters
16
+
17
+ <table><thead><tr><th>
18
+
19
+ Parameter
20
+
21
+
22
+ </th><th>
23
+
24
+ Type
25
+
26
+
27
+ </th><th>
28
+
29
+ Description
30
+
31
+
32
+ </th></tr></thead>
33
+ <tbody><tr><td>
34
+
35
+ tickAllocated
36
+
37
+
38
+ </td><td>
39
+
40
+ boolean
41
+
42
+
43
+ </td><td>
44
+
45
+ _(Optional)_ If true, uses the tick allocator and frees the allocated array at the end of the current tick. false by default.
46
+
47
+
48
+ </td></tr>
49
+ </tbody></table>
14
50
  **Returns:**
15
51
 
16
52
  [Audio](./server.audio.md)<!-- -->\[\]
@@ -107,7 +107,7 @@ Retrieves all loaded audio instances for the world.
107
107
  </td></tr>
108
108
  <tr><td>
109
109
 
110
- [getAllEntityAttachedAudios(entity)](./server.audiomanager.getallentityattachedaudios.md)
110
+ [getAllEntityAttachedAudios(entity, tickAllocated)](./server.audiomanager.getallentityattachedaudios.md)
111
111
 
112
112
 
113
113
  </td><td>
@@ -121,7 +121,7 @@ Retrieves all loaded audio instances attached to a specific entity.
121
121
  </td></tr>
122
122
  <tr><td>
123
123
 
124
- [getAllLoopedAudios()](./server.audiomanager.getallloopedaudios.md)
124
+ [getAllLoopedAudios(tickAllocated)](./server.audiomanager.getallloopedaudios.md)
125
125
 
126
126
 
127
127
  </td><td>
@@ -135,7 +135,7 @@ Retrieves all looped audio instances for the world.
135
135
  </td></tr>
136
136
  <tr><td>
137
137
 
138
- [getAllOneshotAudios()](./server.audiomanager.getalloneshotaudios.md)
138
+ [getAllOneshotAudios(tickAllocated)](./server.audiomanager.getalloneshotaudios.md)
139
139
 
140
140
 
141
141
  </td><td>
@@ -0,0 +1,71 @@
1
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
+
3
+ [Home](./index.md) &gt; [server](./server.md) &gt; [TickAllocator](./server.tickallocator.md) &gt; [filter](./server.tickallocator.filter.md)
4
+
5
+ ## TickAllocator.filter() method
6
+
7
+ Filters an array using a callback function.
8
+
9
+ **Signature:**
10
+
11
+ ```typescript
12
+ filter<T>(array: T[], callback: (value: T, index: number, array: T[]) => boolean): T[];
13
+ ```
14
+
15
+ ## Parameters
16
+
17
+ <table><thead><tr><th>
18
+
19
+ Parameter
20
+
21
+
22
+ </th><th>
23
+
24
+ Type
25
+
26
+
27
+ </th><th>
28
+
29
+ Description
30
+
31
+
32
+ </th></tr></thead>
33
+ <tbody><tr><td>
34
+
35
+ array
36
+
37
+
38
+ </td><td>
39
+
40
+ T\[\]
41
+
42
+
43
+ </td><td>
44
+
45
+ The array to filter.
46
+
47
+
48
+ </td></tr>
49
+ <tr><td>
50
+
51
+ callback
52
+
53
+
54
+ </td><td>
55
+
56
+ (value: T, index: number, array: T\[\]) =&gt; boolean
57
+
58
+
59
+ </td><td>
60
+
61
+ The callback function to filter the array.
62
+
63
+
64
+ </td></tr>
65
+ </tbody></table>
66
+ **Returns:**
67
+
68
+ T\[\]
69
+
70
+ A new array with the filtered values.
71
+
@@ -49,6 +49,20 @@ Description
49
49
  </th></tr></thead>
50
50
  <tbody><tr><td>
51
51
 
52
+ [filter(array, callback)](./server.tickallocator.filter.md)
53
+
54
+
55
+ </td><td>
56
+
57
+
58
+ </td><td>
59
+
60
+ Filters an array using a callback function.
61
+
62
+
63
+ </td></tr>
64
+ <tr><td>
65
+
52
66
  [getArray(copyFromA, copyFromB)](./server.tickallocator.getarray.md)
53
67
 
54
68