@woosh/meep-engine 2.119.61 → 2.119.62

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.
package/package.json CHANGED
@@ -5,7 +5,7 @@
5
5
  "description": "Fully featured ECS game engine written in JavaScript",
6
6
  "type": "module",
7
7
  "author": "Alexander Goldring",
8
- "version": "2.119.61",
8
+ "version": "2.119.62",
9
9
  "main": "build/meep.module.js",
10
10
  "module": "build/meep.module.js",
11
11
  "exports": {
@@ -1 +1 @@
1
- {"version":3,"file":"lpv_build_editor.d.ts","sourceRoot":"","sources":["../../../../../src/engine/graphics/sh3/lpv_build_editor.js"],"names":[],"mappings":"AAmMA;;;;;;;GAOG;AACH,6HA4eC"}
1
+ {"version":3,"file":"lpv_build_editor.d.ts","sourceRoot":"","sources":["../../../../../src/engine/graphics/sh3/lpv_build_editor.js"],"names":[],"mappings":"AA4MA;;;;;;;GAOG;AACH,6HAyfC"}
@@ -101,6 +101,15 @@ class EditorState {
101
101
 
102
102
  mesh_needs_rebuilding = false;
103
103
 
104
+ hideProbes(){
105
+ this.probes.forEach(p => p.destroy());
106
+ }
107
+
108
+ showProbes(){
109
+ const ecd = this.ecd;
110
+ this.probes.forEach(p => p.build(ecd));
111
+ }
112
+
104
113
  ensureMesh() {
105
114
  if (this.mesh_needs_rebuilding) {
106
115
  this.volume.build_mesh();
@@ -221,7 +230,7 @@ export async function lpv_build_editor({
221
230
  }
222
231
  build_in_progress = true;
223
232
 
224
- ctx.probes.forEach(p => p.destroy());
233
+ ctx.hideProbes();
225
234
 
226
235
  volume.build_mesh();
227
236
 
@@ -231,7 +240,7 @@ export async function lpv_build_editor({
231
240
  ctx.probeCoefficientsFromVolume(i);
232
241
  }
233
242
 
234
- ctx.probes.forEach(p => p.build(ecd));
243
+ ctx.showProbes();
235
244
 
236
245
  update_volume_visual();
237
246
 
@@ -624,6 +633,19 @@ export async function lpv_build_editor({
624
633
  // select all
625
634
  set_selection(ctx.probes.map(e => e.id));
626
635
  }
636
+ }),
637
+ new SignalBinding(keys.h.down,()=>{
638
+
639
+ if(ctx.probes.length === 0){
640
+ return;
641
+ }
642
+
643
+ if(ctx.probes[0].isBuilt){
644
+ ctx.hideProbes();
645
+ }else{
646
+ ctx.showProbes();
647
+ }
648
+
627
649
  })
628
650
  ];
629
651