fix mistake in if/else if/else checkParams

This commit is contained in:
Asif Bacchus 2020-04-10 10:09:54 -06:00
parent 78193fa588
commit 4ba30a0a35
2 changed files with 2 additions and 3 deletions

View File

@ -101,7 +101,6 @@ function particles(){
// create particle array
function init(){
particlesArray = [];
//let numberOfParticles = (canvas.height * canvas.width) / 9000;
let numberOfParticles = canvas.width * 0.01;
for (let i = 0; i < numberOfParticles * numParticles; i++){
let size = (Math.random() * sizeMultiplier) + 1;
@ -253,7 +252,7 @@ function particles(){
if (typeof speed == 'undefined'){
speed = 50;
}
if (Number.isInteger(speed) && (0 <= speed && speed <= 1000)){
else if (Number.isInteger(speed) && (0 <= speed && speed <= 1000)){
speed;
}
else{

View File

@ -1,5 +1,5 @@
ab-particles.js
sha384-Nr51BwOjKP19Q/gNGZWRJpRLfAqmN4GmM/VtlRUaaKIou2AJqYLbw/VzbJBeN1eO
sha384-W1hzahUbhADviTwtPE9incT2VBDum2EAKX5OuUdaJnfYC/RTdePPe1D/95uVnu9+
ab-particles.min.js
sha384-GyB27X5DbGI7EaqeCZWH6nlg1xEwP8P++83axSmabShThx8C0IqIDGkU6bf72iJj