@woosh/meep-engine 2.81.4 → 2.82.0

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.
Files changed (108) hide show
  1. package/build/meep.cjs +4394 -4423
  2. package/build/meep.min.js +1 -1
  3. package/build/meep.module.js +4394 -4423
  4. package/editor/ecs/component/editors/primitive/ArrayEditor.js +2 -2
  5. package/editor/enableEditor.js +1 -1
  6. package/editor/view/EditorView.js +25 -25
  7. package/editor/view/ecs/components/particles/ParticleEmitterController.js +11 -11
  8. package/editor/view/node-graph/NodeView.js +7 -7
  9. package/package.json +1 -1
  10. package/samples/terrain/editor.js +19 -18
  11. package/src/core/cache/Cache.js +4 -2
  12. package/src/core/cache/Cache.spec.js +1 -1
  13. package/src/core/collection/array/arraySetDiff.js +8 -2
  14. package/src/core/collection/array/groupArrayBy.js +1 -1
  15. package/src/core/collection/array/weightedRandomFromArray.spec.js +3 -1
  16. package/src/core/collection/heap/FastBinaryHeap.spec.js +3 -2
  17. package/src/core/collection/list/List.js +8 -17
  18. package/src/core/collection/list/List.spec.js +55 -0
  19. package/src/core/collection/map/HashMap.spec.js +3 -1
  20. package/src/core/collection/set/HashSet.spec.js +23 -0
  21. package/src/core/events/signal/signal_aggregate_by_time_window.js +1 -1
  22. package/src/core/fsm/simple/SimpleStateMachine.js +2 -1
  23. package/src/core/function/chain.js +19 -0
  24. package/src/core/function/makeReturnValue.js +8 -0
  25. package/src/core/function/noop.js +6 -0
  26. package/src/core/function/objectsEqual.js +14 -0
  27. package/src/core/function/passThrough.js +9 -0
  28. package/src/core/function/returnEmptyArray.js +7 -0
  29. package/src/core/function/returnFalse.js +7 -0
  30. package/src/core/function/returnOne.js +7 -0
  31. package/src/core/function/returnTrue.js +7 -0
  32. package/src/core/function/returnZero.js +7 -0
  33. package/src/core/function/strictEquals.js +10 -0
  34. package/src/core/geom/3d/tetrahedra/validate_tetrahedral_mesh.js +2 -2
  35. package/src/core/geom/3d/topology/struct/prototypeBinaryTopology.js +5 -4
  36. package/src/core/lang/reactive/AbstractCachingParser.js +2 -1
  37. package/src/core/math/random/randomFloatBetween.spec.js +2 -1
  38. package/src/core/math/random/randomIntegerBetween.spec.js +2 -1
  39. package/src/core/model/node-graph/Connection.js +2 -1
  40. package/src/core/model/node-graph/node/parameter/NodeParameterDescription.js +2 -2
  41. package/src/core/model/object/ObjectPoolFactory.js +2 -1
  42. package/src/core/model/stat/Stat.js +4 -4
  43. package/src/core/process/PromiseWatcher.spec.js +1 -1
  44. package/src/core/process/task/Task.js +2 -1
  45. package/src/engine/EngineHarness.js +2 -1
  46. package/src/engine/achievements/gateway/StorageAchievementGateway.js +1 -1
  47. package/src/engine/asset/AssetManager.js +14 -14
  48. package/src/engine/asset/loaders/ArrayBufferLoader.js +1 -1
  49. package/src/engine/ecs/EntityComponentDataset.spec.js +2 -2
  50. package/src/engine/ecs/EntityManager.js +2 -1
  51. package/src/engine/ecs/EntityObserver.spec.js +4 -4
  52. package/src/engine/ecs/System.js +2 -2
  53. package/src/engine/ecs/dynamic_actions/DynamicActorSystem.js +2 -1
  54. package/src/engine/ecs/ik/IKProblem.js +1 -1
  55. package/src/engine/ecs/storage/binary/collection/BinaryCollectionDeSerializer.js +2 -1
  56. package/src/engine/ecs/storage/binary/collection/BinaryCollectionSerializer.js +2 -1
  57. package/src/engine/ecs/terrain/ecs/TerrainSystem.js +2 -1
  58. package/src/engine/ecs/terrain/tiles/TerrainTileManager.js +2 -1
  59. package/src/engine/ecs/terrain/util/obtainTerrain.js +1 -1
  60. package/src/engine/ecs/terrain/util/paintTerrainOverlayViaLookupTable.js +3 -3
  61. package/src/engine/graphics/ecs/decal/v2/FPDecalSystem.js +2 -1
  62. package/src/engine/graphics/ecs/highlight/plugin/OutlineRenderPlugin.js +7 -7
  63. package/src/engine/graphics/ecs/mesh-v2/ShadedGeometrySystem.js +2 -1
  64. package/src/engine/graphics/material/SplatMaterial.js +1 -15
  65. package/src/engine/graphics/render/layers/RenderLayer.js +1 -1
  66. package/src/engine/graphics/render/utils/ThreeBypassRenderer.js +2 -1
  67. package/src/engine/graphics/render/visibility/VisibilityFilter.js +2 -1
  68. package/src/engine/graphics/sh3/path_tracer/prototypePathTracer.js +2 -1
  69. package/src/engine/graphics/texture/atlas/ManagedTextureAtlas.js +5 -5
  70. package/src/engine/graphics/texture/cubemap/load_environment_map.js +2 -2
  71. package/src/engine/graphics/texture/makeOnePixelTexture.js +5 -3
  72. package/src/engine/graphics/texture/virtual/VirtualTexturePage.js +2 -1
  73. package/src/engine/graphics/texture/whitePixelTexture.js +9 -0
  74. package/src/engine/intelligence/behavior/ecs/BehaviorSystem.spec.js +5 -5
  75. package/src/engine/intelligence/blackboard/BlackboardDynamicStorageAdapter.js +3 -3
  76. package/src/engine/intelligence/mcts/MonteCarlo.js +3 -3
  77. package/src/engine/knowledge/database/StaticKnowledgeDataTable.js +3 -3
  78. package/src/engine/network/PriorityFetch.js +2 -2
  79. package/src/engine/options/Option.js +2 -2
  80. package/src/engine/options/Option.spec.js +1 -1
  81. package/src/engine/options/OptionGroup.js +2 -2
  82. package/src/engine/options/OptionGroup.spec.js +2 -2
  83. package/src/engine/save/Storage.js +2 -1
  84. package/src/engine/save/StorageBackedList.js +2 -1
  85. package/src/engine/save/storage/InMemoryStorage.js +2 -2
  86. package/src/engine/scene/transitionToScene.js +2 -1
  87. package/src/engine/sound/ecs/SoundListenerSystem.js +7 -7
  88. package/src/engine/sound/ecs/emitter/loadSoundTrackAsset.js +3 -3
  89. package/src/engine/ui/DraggableAspect.js +2 -2
  90. package/src/engine/ui/GUIEngine.js +17 -17
  91. package/src/engine/ui/notification/AnimatedObjectEmitter.js +3 -3
  92. package/src/engine/ui/notification/NotificationManager.js +4 -4
  93. package/src/generation/grid/generation/discrete/GridTaskConnectRooms.js +9 -9
  94. package/src/generation/grid/generation/util/buildPathFromDistanceMap.js +1 -1
  95. package/src/generation/markers/actions/util/GridCellActionDebugBreak.js +1 -1
  96. package/src/view/common/LabelView.js +9 -9
  97. package/src/view/common/ListView.js +3 -2
  98. package/src/view/common/VirtualListView.js +7 -6
  99. package/src/view/common/dnd/DropTarget.js +2 -2
  100. package/src/view/elements/DropDownSelectionView.js +2 -2
  101. package/src/view/elements/image/ImageView.js +4 -4
  102. package/src/view/elements/progress/SmoothProgressBar.js +4 -4
  103. package/src/view/elements/radial/RadialMenuElementDefinition.js +1 -1
  104. package/src/view/elements/tiles2d/TileGrid.js +8 -8
  105. package/src/view/elements/video/VideoView.js +5 -5
  106. package/src/view/math/FunctionGraphView.js +1 -1
  107. package/src/view/tooltip/gml/TooltipParser.js +6 -5
  108. package/src/core/function/Functions.js +0 -103
@@ -1,5 +1,6 @@
1
1
  import { assert } from "../../core/assert.js";
2
- import { noop } from "../../core/function/Functions.js";
2
+
3
+ import { noop } from "../../core/function/noop.js";
3
4
  import Task from "../../core/process/task/Task.js";
4
5
  import TaskGroup from "../../core/process/task/TaskGroup.js";
5
6
  import TaskState from "../../core/process/task/TaskState.js";
@@ -3,15 +3,15 @@
3
3
  * Date: 11/6/2014
4
4
  * Time: 21:47
5
5
  */
6
- import { System } from '../../ecs/System.js';
7
- import SoundListener from './SoundListener.js';
8
- import { Transform } from '../../ecs/transform/Transform.js';
9
- import { browserInfo } from "../../browserInfo.js";
10
- import Vector3 from "../../../core/geom/Vector3.js";
11
- import { noop } from "../../../core/function/Functions.js";
12
6
  import { assert } from "../../../core/assert.js";
13
- import { ResourceAccessSpecification } from "../../../core/model/ResourceAccessSpecification.js";
7
+ import { noop } from "../../../core/function/noop.js";
8
+ import Vector3 from "../../../core/geom/Vector3.js";
14
9
  import { ResourceAccessKind } from "../../../core/model/ResourceAccessKind.js";
10
+ import { ResourceAccessSpecification } from "../../../core/model/ResourceAccessSpecification.js";
11
+ import { browserInfo } from "../../browserInfo.js";
12
+ import { System } from '../../ecs/System.js';
13
+ import { Transform } from '../../ecs/transform/Transform.js';
14
+ import SoundListener from './SoundListener.js';
15
15
 
16
16
  const v3 = new Vector3();
17
17
  const v3_up = new Vector3();
@@ -1,7 +1,7 @@
1
- import { SoundTrackFlags } from "./SoundTrackFlags.js";
2
- import { GameAssetType } from "../../../asset/GameAssetType.js";
3
- import { noop } from "../../../../core/function/Functions.js";
4
1
  import { assert } from "../../../../core/assert.js";
2
+ import { noop } from "../../../../core/function/noop.js";
3
+ import { GameAssetType } from "../../../asset/GameAssetType.js";
4
+ import { SoundTrackFlags } from "./SoundTrackFlags.js";
5
5
 
6
6
  /**
7
7
  * @param {SoundTrack} track
@@ -3,9 +3,9 @@
3
3
  * @author Alex Goldring, travnick@gmail.com
4
4
  */
5
5
 
6
- import { PointerDevice } from "../input/devices/PointerDevice.js";
6
+ import { noop } from "../../core/function/noop.js";
7
7
  import Vector2 from "../../core/geom/Vector2.js";
8
- import { noop } from "../../core/function/Functions.js";
8
+ import { PointerDevice } from "../input/devices/PointerDevice.js";
9
9
 
10
10
  export class DraggableAspect {
11
11
  /**
@@ -4,31 +4,31 @@
4
4
 
5
5
 
6
6
  import List from '../../core/collection/list/List.js';
7
- import {playTrackRealTime} from "../animation/playTrackRealTime.js";
8
-
9
- import GUIElement from '../ecs/gui/GUIElement.js';
10
- import ViewportPosition from '../ecs/gui/position/ViewportPosition.js';
11
-
12
- import Entity from '../ecs/Entity.js';
7
+ import { noop } from "../../core/function/noop.js";
8
+ import ObservedString from "../../core/model/ObservedString.js";
9
+ import { SimpleLifecycle, SimpleLifecycleStateType } from "../../core/process/SimpleLifecycle.js";
13
10
 
14
11
  import ConfirmationDialogView from '../../view/elements/ConfirmationDialogView.js';
12
+ import EmptyView from "../../view/elements/EmptyView.js";
15
13
  import SimpleWindowView from '../../view/elements/SimpleWindow.js';
14
+ import { DomTooltipManager } from "../../view/tooltip/DomTooltipManager.js";
15
+ import { GMLEngine } from "../../view/tooltip/gml/GMLEngine.js";
16
+ import { TooltipManager } from "../../view/tooltip/TooltipManager.js";
16
17
 
17
18
  import View from '../../view/View.js';
18
- import TransitionFunctions from "../animation/TransitionFunctions.js";
19
19
  import AnimationTrack from "../animation/keyed2/AnimationTrack.js";
20
20
  import AnimationTrackPlayback from "../animation/keyed2/AnimationTrackPlayback.js";
21
- import {TooltipManager} from "../../view/tooltip/TooltipManager.js";
22
- import {DomTooltipManager} from "../../view/tooltip/DomTooltipManager.js";
21
+ import { playTrackRealTime } from "../animation/playTrackRealTime.js";
22
+ import TransitionFunctions from "../animation/TransitionFunctions.js";
23
+ import { SerializationMetadata } from "../ecs/components/SerializationMetadata.js";
24
+
25
+ import Entity from '../ecs/Entity.js';
26
+
27
+ import GUIElement from '../ecs/gui/GUIElement.js';
28
+ import ViewportPosition from '../ecs/gui/position/ViewportPosition.js';
23
29
  import Ticker from "../simulation/Ticker.js";
24
- import {SimpleLifecycle, SimpleLifecycleStateType} from "../../core/process/SimpleLifecycle.js";
25
- import EmptyView from "../../view/elements/EmptyView.js";
26
- import {GMLEngine} from "../../view/tooltip/gml/GMLEngine.js";
27
- import ObservedString from "../../core/model/ObservedString.js";
28
- import {CursorType} from "./cursor/CursorType.js";
29
- import {noop} from "../../core/function/Functions.js";
30
- import {SerializationMetadata} from "../ecs/components/SerializationMetadata.js";
31
- import {SceneGUIContext} from "./scene/SceneGUIContext.js";
30
+ import { CursorType } from "./cursor/CursorType.js";
31
+ import { SceneGUIContext } from "./scene/SceneGUIContext.js";
32
32
 
33
33
 
34
34
  class GUIEngine {
@@ -1,9 +1,9 @@
1
+ import { assert } from "../../../core/assert.js";
2
+ import Signal from "../../../core/events/signal/Signal.js";
3
+ import { noop } from "../../../core/function/noop.js";
1
4
  import { max2 } from "../../../core/math/max2.js";
2
5
  import { min2 } from "../../../core/math/min2.js";
3
6
  import AnimationTrackPlayback from "../../animation/keyed2/AnimationTrackPlayback.js";
4
- import { noop } from "../../../core/function/Functions.js";
5
- import Signal from "../../../core/events/signal/Signal.js";
6
- import { assert } from "../../../core/assert.js";
7
7
 
8
8
  /**
9
9
  * @template T
@@ -1,11 +1,11 @@
1
- import NotificationLog from "../../notify/NotificationLog.js";
2
1
  import { assert } from "../../../core/assert.js";
3
- import { noop } from "../../../core/function/Functions.js";
4
2
  import List from "../../../core/collection/list/List.js";
5
- import Entity from "../../ecs/Entity.js";
6
- import GUIElement from "../../ecs/gui/GUIElement.js";
3
+ import { noop } from "../../../core/function/noop.js";
7
4
  import { SerializationMetadata } from "../../ecs/components/SerializationMetadata.js";
5
+ import Entity from "../../ecs/Entity.js";
8
6
  import { EventType } from "../../ecs/EntityManager.js";
7
+ import GUIElement from "../../ecs/gui/GUIElement.js";
8
+ import NotificationLog from "../../notify/NotificationLog.js";
9
9
 
10
10
 
11
11
  class LogDisplay {
@@ -1,20 +1,20 @@
1
- import { min2 } from "../../../../core/math/min2.js";
2
- import { GridTaskGenerator } from "../../GridTaskGenerator.js";
1
+ import { matcher_tag_unoccupied } from "../../../../../samples/generation/rules/matcher_tag_unoccupied.js";
2
+ import { assert } from "../../../../core/assert.js";
3
3
  import { BitSet } from "../../../../core/binary/BitSet.js";
4
- import Task from "../../../../core/process/task/Task.js";
5
- import { TaskSignal } from "../../../../core/process/task/TaskSignal.js";
6
- import Vector2 from "../../../../core/geom/Vector2.js";
7
4
  import BinaryHeap from "../../../../core/collection/heap/FastBinaryHeap.js";
8
- import { passThrough } from "../../../../core/function/Functions.js";
5
+ import { passThrough } from "../../../../core/function/passThrough.js";
6
+ import Vector2 from "../../../../core/geom/Vector2.js";
7
+ import { min2 } from "../../../../core/math/min2.js";
8
+ import Task from "../../../../core/process/task/Task.js";
9
9
  import TaskGroup from "../../../../core/process/task/TaskGroup.js";
10
+ import { TaskSignal } from "../../../../core/process/task/TaskSignal.js";
11
+ import { actionTask } from "../../../../core/process/task/util/actionTask.js";
10
12
  import { Sampler2D } from "../../../../engine/graphics/texture/sampler/Sampler2D.js";
11
13
  import { bitSet2Sampler2D } from "../../../../engine/graphics/texture/sampler/util/bitSet2Sampler2D.js";
12
14
  import { drawSamplerHTML } from "../../../../engine/graphics/texture/sampler/util/drawSamplerHTML.js";
13
- import { matcher_tag_unoccupied } from "../../../../../samples/generation/rules/matcher_tag_unoccupied.js";
15
+ import { GridTaskGenerator } from "../../GridTaskGenerator.js";
14
16
  import { buildDistanceMapToObjective } from "../util/buildDistanceMapToObjective.js";
15
17
  import { buildPathFromDistanceMap } from "../util/buildPathFromDistanceMap.js";
16
- import { assert } from "../../../../core/assert.js";
17
- import { actionTask } from "../../../../core/process/task/util/actionTask.js";
18
18
 
19
19
  const ESTIMATED_TILES_PER_ROOM = 900;
20
20
 
@@ -1,4 +1,4 @@
1
- import { returnZero } from "../../../../core/function/Functions.js";
1
+ import { returnZero } from "../../../../core/function/returnZero.js";
2
2
 
3
3
  /**
4
4
  *
@@ -1,5 +1,5 @@
1
+ import { returnTrue } from "../../../../core/function/returnTrue.js";
1
2
  import { GridCellAction } from "../../../placement/action/GridCellAction.js";
2
- import { returnTrue } from "../../../../core/function/Functions.js";
3
3
 
4
4
  export class GridCellActionDebugBreak extends GridCellAction {
5
5
 
@@ -2,21 +2,21 @@
2
2
  * Created by Alex on 26/05/2016.
3
3
  * @copyright Alex Goldring 2016
4
4
  */
5
- import View from "../View.js";
6
- import ObservedValue from "../../core/model/ObservedValue.js";
5
+ import { assert } from "../../core/assert.js";
6
+ import { isTypedArray } from "../../core/collection/array/typed/isTypedArray.js";
7
+ import { noop } from "../../core/function/noop.js";
7
8
  import Vector1 from "../../core/geom/Vector1.js";
8
- import LinearValue from "../../core/model/LinearValue.js";
9
- import ObservedString from "../../core/model/ObservedString.js";
10
9
  import BoundedValue from "../../core/model/BoundedValue.js";
10
+ import LinearValue from "../../core/model/LinearValue.js";
11
11
  import ObservedBoolean from "../../core/model/ObservedBoolean.js";
12
+ import ObservedInteger from "../../core/model/ObservedInteger.js";
13
+ import ObservedString from "../../core/model/ObservedString.js";
14
+ import ObservedValue from "../../core/model/ObservedValue.js";
12
15
  import Stat from "../../core/model/stat/Stat.js";
16
+ import { number_pretty_print } from "../../core/primitives/numbers/number_pretty_print.js";
13
17
  import { isInstanceOf, isTypeOf, or } from "../../core/process/matcher/Matchers.js";
14
18
  import { frameThrottle } from "../../engine/graphics/FrameThrottle.js";
15
- import { assert } from "../../core/assert.js";
16
- import ObservedInteger from "../../core/model/ObservedInteger.js";
17
- import { noop } from "../../core/function/Functions.js";
18
- import { isTypedArray } from "../../core/collection/array/typed/isTypedArray.js";
19
- import { number_pretty_print } from "../../core/primitives/numbers/number_pretty_print.js";
19
+ import View from "../View.js";
20
20
 
21
21
 
22
22
  /**
@@ -4,11 +4,12 @@
4
4
  */
5
5
 
6
6
 
7
- import View from "../View.js";
8
7
  import { assert } from "../../core/assert.js";
9
- import { noop, returnTrue } from "../../core/function/Functions.js";
10
8
  import { Cache } from "../../core/cache/Cache.js";
11
9
  import List from "../../core/collection/list/List.js";
10
+ import { noop } from "../../core/function/noop.js";
11
+ import { returnTrue } from "../../core/function/returnTrue.js";
12
+ import View from "../View.js";
12
13
 
13
14
  /**
14
15
  * @template T
@@ -1,14 +1,15 @@
1
1
  /**
2
2
  * Created by Alex on 15/01/2017.
3
3
  */
4
- import { max2 } from "../../core/math/max2.js";
5
- import View from '../View.js';
6
- import dom from '../DOM.js';
4
+ import { Cache } from "../../core/cache/Cache.js";
7
5
  import List from '../../core/collection/list/List.js';
8
- import { frameThrottle } from '../../engine/graphics/FrameThrottle.js';
9
6
  import Signal from "../../core/events/signal/Signal.js";
10
- import { Cache } from "../../core/cache/Cache.js";
11
- import { passThrough, strictEquals } from "../../core/function/Functions.js";
7
+ import { passThrough } from "../../core/function/passThrough.js";
8
+ import { strictEquals } from "../../core/function/strictEquals.js";
9
+ import { max2 } from "../../core/math/max2.js";
10
+ import { frameThrottle } from '../../engine/graphics/FrameThrottle.js';
11
+ import dom from '../DOM.js';
12
+ import View from '../View.js';
12
13
 
13
14
  export const AlignmentOption = {
14
15
  Start: 'start',
@@ -1,8 +1,8 @@
1
- import { returnTrue } from "../../../core/function/Functions.js";
2
1
  import Signal from "../../../core/events/signal/Signal.js";
2
+ import { SignalBinding } from "../../../core/events/signal/SignalBinding.js";
3
+ import { returnTrue } from "../../../core/function/returnTrue.js";
3
4
  import { DragEvents } from "../../../engine/input/devices/events/DragEvents.js";
4
5
  import { DraggableElementFlags } from "./Draggable.js";
5
- import { SignalBinding } from "../../../core/events/signal/SignalBinding.js";
6
6
 
7
7
  /**
8
8
  *
@@ -3,9 +3,9 @@
3
3
  */
4
4
 
5
5
 
6
- import View from '../View.js';
7
- import { passThrough } from "../../core/function/Functions.js";
6
+ import { passThrough } from "../../core/function/passThrough.js";
8
7
  import UUID from "../../core/UUID.js";
8
+ import View from '../View.js';
9
9
 
10
10
  /**
11
11
  * @template T
@@ -2,12 +2,12 @@
2
2
  * Created by Alex on 27/02/2017.
3
3
  */
4
4
 
5
- import View from "../../View.js";
6
- import { noop } from "../../../core/function/Functions.js";
7
- import { HTMLElementCacheKey } from "../../common/HTMLElementCacheKey.js";
8
5
  import { KeyValuePair } from "../../../core/collection/KeyValuePair.js";
9
- import { ObjectPoolFactory } from "../../../core/model/object/ObjectPoolFactory.js";
6
+ import { noop } from "../../../core/function/noop.js";
10
7
  import { ImmutableObjectPool } from "../../../core/model/object/ImmutableObjectPool.js";
8
+ import { ObjectPoolFactory } from "../../../core/model/object/ObjectPoolFactory.js";
9
+ import { HTMLElementCacheKey } from "../../common/HTMLElementCacheKey.js";
10
+ import View from "../../View.js";
11
11
 
12
12
  /**
13
13
  *
@@ -1,10 +1,10 @@
1
- import View from "../../View.js";
2
- import dom from "../../DOM.js";
1
+ import { passThrough } from "../../../core/function/passThrough.js";
2
+ import { clamp01 } from "../../../core/math/clamp01.js";
3
3
 
4
4
  import BoundedValue from "../../../core/model/BoundedValue.js";
5
5
  import { frameThrottle } from "../../../engine/graphics/FrameThrottle.js";
6
- import { passThrough } from "../../../core/function/Functions.js";
7
- import { clamp01 } from "../../../core/math/clamp01.js";
6
+ import dom from "../../DOM.js";
7
+ import View from "../../View.js";
8
8
 
9
9
  function makeTextPercentage(value, max, process) {
10
10
  const r = (value / max) * 100;
@@ -1,5 +1,5 @@
1
- import { noop } from "../../../core/function/Functions.js";
2
1
  import { assert } from "../../../core/assert.js";
2
+ import { noop } from "../../../core/function/noop.js";
3
3
 
4
4
  export class RadialMenuElementDefinition {
5
5
  constructor() {
@@ -3,18 +3,18 @@
3
3
  */
4
4
 
5
5
 
6
- import TileView from './Tile.js';
7
-
8
- import View from "../../View.js";
9
- import dom from "../../DOM.js";
6
+ import { assert } from "../../../core/assert.js";
7
+ import Signal from "../../../core/events/signal/Signal.js";
8
+ import { noop } from "../../../core/function/noop.js";
10
9
 
11
10
  import Vector2 from "../../../core/geom/Vector2.js";
12
- import Signal from "../../../core/events/signal/Signal.js";
11
+ import { computeTileGridMove } from "../../../engine/ui/tiles2d/computeTileGridMove.js";
13
12
 
14
13
  import { DragAndDropContext } from '../../common/dnd/DragAndDropContext.js';
15
- import { computeTileGridMove } from "../../../engine/ui/tiles2d/computeTileGridMove.js";
16
- import { assert } from "../../../core/assert.js";
17
- import { noop } from "../../../core/function/Functions.js";
14
+ import dom from "../../DOM.js";
15
+
16
+ import View from "../../View.js";
17
+ import TileView from './Tile.js';
18
18
 
19
19
  const slotElementPrototype = dom('div').addClass('marker').el;
20
20
 
@@ -1,11 +1,11 @@
1
- import { HTMLElementCacheKey } from "../../common/HTMLElementCacheKey.js";
2
- import { KeyValuePair } from "../../../core/collection/KeyValuePair.js";
3
1
  import { Cache } from "../../../core/cache/Cache.js";
4
- import { noop } from "../../../core/function/Functions.js";
5
- import View from "../../View.js";
6
- import { ObjectPoolFactory } from "../../../core/model/object/ObjectPoolFactory.js";
2
+ import { KeyValuePair } from "../../../core/collection/KeyValuePair.js";
3
+ import { noop } from "../../../core/function/noop.js";
7
4
  import { invokeObjectEquals } from "../../../core/model/object/invokeObjectEquals.js";
8
5
  import { invokeObjectHash } from "../../../core/model/object/invokeObjectHash.js";
6
+ import { ObjectPoolFactory } from "../../../core/model/object/ObjectPoolFactory.js";
7
+ import { HTMLElementCacheKey } from "../../common/HTMLElementCacheKey.js";
8
+ import View from "../../View.js";
9
9
 
10
10
  /**
11
11
  *
@@ -1,5 +1,5 @@
1
+ import { returnZero } from "../../core/function/returnZero.js";
1
2
  import View from "../View.js";
2
- import { returnZero } from "../../core/function/Functions.js";
3
3
 
4
4
  export class FunctionGraphView extends View {
5
5
  /**
@@ -1,8 +1,9 @@
1
- import {Cache} from "../../../core/cache/Cache.js";
2
- import {strictEquals} from "../../../core/function/Functions.js";
3
- import {parseTooltipString} from "./parser/parseTooltipString.js";
4
- import {computeStringHash} from "../../../core/primitives/strings/computeStringHash.js";
5
- import {string_compute_byte_size} from "../../../core/primitives/strings/string_compute_byte_size.js";
1
+ import { Cache } from "../../../core/cache/Cache.js";
2
+
3
+ import { strictEquals } from "../../../core/function/strictEquals.js";
4
+ import { computeStringHash } from "../../../core/primitives/strings/computeStringHash.js";
5
+ import { string_compute_byte_size } from "../../../core/primitives/strings/string_compute_byte_size.js";
6
+ import { parseTooltipString } from "./parser/parseTooltipString.js";
6
7
 
7
8
  export class TooltipParser {
8
9
 
@@ -1,103 +0,0 @@
1
- /**
2
- * Collection of useful pure function. Saves having to allocate memory for new anonymous or arrow function. They also come with useful names.
3
- * @author Alex Goldring
4
- * @copyright Alex Goldring 2018
5
- */
6
-
7
- /**
8
- * No-operation function. Does nothing. Useful when a callback is required to avoid checks for a missing function.
9
- * @param {*} arguments
10
- */
11
- export function noop() {
12
- }
13
-
14
- /**
15
- * Returns boolean true value.
16
- * @returns {boolean} always true
17
- */
18
- export function returnTrue() {
19
- return true;
20
- }
21
-
22
- /**
23
- * Returns boolean false value.
24
- * @returns {boolean} always false
25
- */
26
- export function returnFalse() {
27
- return false;
28
- }
29
-
30
- /**
31
- *
32
- * @returns {number} always 0
33
- */
34
- export function returnZero() {
35
- return 0;
36
- }
37
-
38
- /**
39
- *
40
- * @returns {number} always 1
41
- */
42
- export function returnOne() {
43
- return 1;
44
- }
45
-
46
-
47
- /**
48
- * @template T
49
- * @returns {T[]}
50
- */
51
- export function returnEmptyArray() {
52
- return [];
53
- }
54
-
55
- /**
56
- * @template T
57
- * @param {T} v
58
- * @returns {function():T}
59
- */
60
- export function makeReturnValue(v) {
61
- return () => v;
62
- }
63
-
64
- /**
65
- * @template A
66
- * @param {A} a
67
- * @returns {A}
68
- */
69
- export function passThrough(a) {
70
- return a;
71
- }
72
-
73
- /**
74
- * @template A
75
- * @param {A} a
76
- * @param {A} b
77
- * @returns {boolean}
78
- */
79
- export function strictEquals(a, b) {
80
- return a === b;
81
- }
82
-
83
- /**
84
- *
85
- * @param {...function} processes
86
- * @returns {function(*): *}
87
- */
88
- export function chainFunctions(...processes) {
89
- const numProcesses = processes.length;
90
-
91
- return function chain(v) {
92
- let result = v;
93
-
94
- for (let i = 0; i < numProcesses; i++) {
95
- const process = processes[i];
96
- result = process(result);
97
- }
98
-
99
- return result;
100
- }
101
- }
102
-
103
-