diff --git a/src/lib/Bend/BendVanilla.ts b/src/lib/Bend/BendVanilla.ts index 2edc087..e99e2b0 100644 --- a/src/lib/Bend/BendVanilla.ts +++ b/src/lib/Bend/BendVanilla.ts @@ -916,6 +916,12 @@ export function createBend( return { setOptions(next) { + if ( + !Object.entries(next).some( + ([key, value]) => config[key as keyof BendOptions] !== value, + ) + ) + return; Object.assign(config, next); syncScroll(); start(); diff --git a/src/lib/Blaze/BlazeVanilla.ts b/src/lib/Blaze/BlazeVanilla.ts index 84ff32e..2cd5c52 100644 --- a/src/lib/Blaze/BlazeVanilla.ts +++ b/src/lib/Blaze/BlazeVanilla.ts @@ -644,6 +644,12 @@ export function createBlaze( return { setOptions(next) { + if ( + !Object.entries(next).some( + ([key, value]) => config[key as keyof BlazeOptions] !== value, + ) + ) + return; Object.assign(config, next); start(); }, diff --git a/src/lib/Bubble/BubbleVanilla.ts b/src/lib/Bubble/BubbleVanilla.ts index ceff051..0ba435d 100644 --- a/src/lib/Bubble/BubbleVanilla.ts +++ b/src/lib/Bubble/BubbleVanilla.ts @@ -611,6 +611,12 @@ export function createBubble( return { setOptions(next) { + if ( + !Object.entries(next).some( + ([key, value]) => config[key as keyof BubbleOptions] !== value, + ) + ) + return; Object.assign(config, next); start(); }, diff --git a/src/lib/Cloth/ClothVanilla.ts b/src/lib/Cloth/ClothVanilla.ts index 57ac116..10065e8 100644 --- a/src/lib/Cloth/ClothVanilla.ts +++ b/src/lib/Cloth/ClothVanilla.ts @@ -849,6 +849,12 @@ export function createCloth( return { setOptions(next) { + if ( + !Object.entries(next).some( + ([key, value]) => config[key as keyof ClothOptions] !== value, + ) + ) + return; Object.assign(config, next); syncBacking(); start(); diff --git a/src/lib/Clouds/CloudsVanilla.ts b/src/lib/Clouds/CloudsVanilla.ts index 003ea3d..c73c24f 100644 --- a/src/lib/Clouds/CloudsVanilla.ts +++ b/src/lib/Clouds/CloudsVanilla.ts @@ -734,6 +734,12 @@ export function createClouds( return { setOptions(next) { + if ( + !Object.entries(next).some( + ([key, value]) => config[key as keyof CloudsOptions] !== value, + ) + ) + return; Object.assign(config, next); syncCanvasSize(); syncBaseColor(); diff --git a/src/lib/Droplets/DropletsVanilla.ts b/src/lib/Droplets/DropletsVanilla.ts index 122f2d7..8457a20 100644 --- a/src/lib/Droplets/DropletsVanilla.ts +++ b/src/lib/Droplets/DropletsVanilla.ts @@ -705,6 +705,12 @@ export function createDroplets( return { setOptions(next) { + if ( + !Object.entries(next).some( + ([key, value]) => config[key as keyof DropletsOptions] !== value, + ) + ) + return; Object.assign(config, next); start(); }, diff --git a/src/lib/Frost/FrostVanilla.ts b/src/lib/Frost/FrostVanilla.ts index 712bc1f..2b33f8d 100644 --- a/src/lib/Frost/FrostVanilla.ts +++ b/src/lib/Frost/FrostVanilla.ts @@ -1129,6 +1129,12 @@ export function createFrost( start(); }, setOptions(next) { + if ( + !Object.entries(next).some( + ([key, value]) => config[key as keyof FrostOptions] !== value, + ) + ) + return; const { quality, ...rest } = next; const qualityChanged = quality !== undefined && quality !== config.quality; diff --git a/src/lib/Glass/GlassVanilla.ts b/src/lib/Glass/GlassVanilla.ts index 7466780..495f83c 100644 --- a/src/lib/Glass/GlassVanilla.ts +++ b/src/lib/Glass/GlassVanilla.ts @@ -584,6 +584,12 @@ export function createGlass( return { setOptions(next) { + if ( + !Object.entries(next).some( + ([key, value]) => config[key as keyof GlassOptions] !== value, + ) + ) + return; Object.assign(config, next); start(); }, diff --git a/src/lib/Glitch/GlitchVanilla.ts b/src/lib/Glitch/GlitchVanilla.ts index 103397d..06eea69 100644 --- a/src/lib/Glitch/GlitchVanilla.ts +++ b/src/lib/Glitch/GlitchVanilla.ts @@ -395,6 +395,12 @@ export function createGlitch( return { setOptions(next) { + if ( + !Object.entries(next).some( + ([key, value]) => config[key as keyof GlitchOptions] !== value, + ) + ) + return; Object.assign(config, next); start(); }, diff --git a/src/lib/Grid/GridVanilla.ts b/src/lib/Grid/GridVanilla.ts index 5ab2092..0cfe56e 100644 --- a/src/lib/Grid/GridVanilla.ts +++ b/src/lib/Grid/GridVanilla.ts @@ -764,6 +764,12 @@ export function createGrid( return { setOptions(next) { + if ( + !Object.entries(next).some( + ([key, value]) => config[key as keyof GridOptions] !== value, + ) + ) + return; Object.assign(config, next); start(); }, diff --git a/src/lib/HexFloat/HexFloatVanilla.ts b/src/lib/HexFloat/HexFloatVanilla.ts index 24fd87a..cca5430 100644 --- a/src/lib/HexFloat/HexFloatVanilla.ts +++ b/src/lib/HexFloat/HexFloatVanilla.ts @@ -1580,6 +1580,12 @@ export function createHexFloat( return { setOptions(next) { + if ( + !Object.entries(next).some( + ([key, value]) => config[key as keyof HexFloatOptions] !== value, + ) + ) + return; Object.assign(config, next); start(); }, diff --git a/src/lib/Laser/LaserVanilla.ts b/src/lib/Laser/LaserVanilla.ts index 42ad96c..78f4b67 100644 --- a/src/lib/Laser/LaserVanilla.ts +++ b/src/lib/Laser/LaserVanilla.ts @@ -616,6 +616,12 @@ export function createLaser( return { setOptions(next) { + if ( + !Object.entries(next).some( + ([key, value]) => config[key as keyof LaserOptions] !== value, + ) + ) + return; Object.assign(config, next); start(); }, diff --git a/src/lib/Liquid/LiquidVanilla.ts b/src/lib/Liquid/LiquidVanilla.ts index ba36970..b0072a3 100644 --- a/src/lib/Liquid/LiquidVanilla.ts +++ b/src/lib/Liquid/LiquidVanilla.ts @@ -861,6 +861,12 @@ export function createLiquid( start(); }, setOptions(next) { + if ( + !Object.entries(next).some( + ([key, value]) => config[key as keyof LiquidOptions] !== value, + ) + ) + return; const { simResolution, dyeResolution, ...rest } = next; void simResolution; void dyeResolution; diff --git a/src/lib/Magnify/MagnifyVanilla.ts b/src/lib/Magnify/MagnifyVanilla.ts index 587fb7a..71edcfa 100644 --- a/src/lib/Magnify/MagnifyVanilla.ts +++ b/src/lib/Magnify/MagnifyVanilla.ts @@ -732,6 +732,12 @@ export function createMagnify( return { setOptions(next) { + if ( + !Object.entries(next).some( + ([key, value]) => config[key as keyof MagnifyOptions] !== value, + ) + ) + return; const previousZoom = config.zoom; Object.assign(config, next); if (!config.scrollZoom || config.zoom !== previousZoom) { diff --git a/src/lib/ParticleReveal/ParticleRevealVanilla.ts b/src/lib/ParticleReveal/ParticleRevealVanilla.ts index ae34d7e..05f91d8 100644 --- a/src/lib/ParticleReveal/ParticleRevealVanilla.ts +++ b/src/lib/ParticleReveal/ParticleRevealVanilla.ts @@ -486,6 +486,13 @@ export function createParticleReveal( return { setOptions(next) { + if ( + !Object.entries(next).some( + ([key, value]) => + config[key as keyof ParticleRevealOptions] !== value, + ) + ) + return; Object.assign(config, next); start(); }, diff --git a/src/lib/ParticleScroll/ParticleScrollVanilla.ts b/src/lib/ParticleScroll/ParticleScrollVanilla.ts index 9bfcd77..cbf8060 100644 --- a/src/lib/ParticleScroll/ParticleScrollVanilla.ts +++ b/src/lib/ParticleScroll/ParticleScrollVanilla.ts @@ -663,6 +663,13 @@ export function createParticleScroll( return { setOptions(next) { + if ( + !Object.entries(next).some( + ([key, value]) => + config[key as keyof ParticleScrollOptions] !== value, + ) + ) + return; Object.assign(config, next); start(); }, diff --git a/src/lib/Peel/PeelVanilla.ts b/src/lib/Peel/PeelVanilla.ts index 83b36ba..ea0c00e 100644 --- a/src/lib/Peel/PeelVanilla.ts +++ b/src/lib/Peel/PeelVanilla.ts @@ -588,6 +588,12 @@ export function createPeel( return { setOptions(next) { + if ( + !Object.entries(next).some( + ([key, value]) => config[key as keyof PeelOptions] !== value, + ) + ) + return; Object.assign(config, next); syncShineColor(); start(); diff --git a/src/lib/Ripple/RippleVanilla.ts b/src/lib/Ripple/RippleVanilla.ts index fbd706b..319a40c 100644 --- a/src/lib/Ripple/RippleVanilla.ts +++ b/src/lib/Ripple/RippleVanilla.ts @@ -475,6 +475,12 @@ export function createRipple( return { setOptions(next) { + if ( + !Object.entries(next).some( + ([key, value]) => config[key as keyof RippleOptions] !== value, + ) + ) + return; Object.assign(config, next); start(); }, diff --git a/src/lib/Shatter/ShatterVanilla.ts b/src/lib/Shatter/ShatterVanilla.ts index 52676a4..d92c906 100644 --- a/src/lib/Shatter/ShatterVanilla.ts +++ b/src/lib/Shatter/ShatterVanilla.ts @@ -675,6 +675,12 @@ export function createShatter( return { setOptions(next) { + if ( + !Object.entries(next).some( + ([key, value]) => config[key as keyof ShatterOptions] !== value, + ) + ) + return; Object.assign(config, next); start(); }, diff --git a/src/lib/VHS/VHSVanilla.ts b/src/lib/VHS/VHSVanilla.ts index 0714bc0..f2e3702 100644 --- a/src/lib/VHS/VHSVanilla.ts +++ b/src/lib/VHS/VHSVanilla.ts @@ -521,6 +521,12 @@ export function createVHS( return { setOptions(next) { + if ( + !Object.entries(next).some( + ([key, value]) => config[key as keyof VHSOptions] !== value, + ) + ) + return; Object.assign(config, next); start(); },