"use strict";(self.webpackChunkwordpress_particles=self.webpackChunkwordpress_particles||[]).push([[3498],{3498:function(t,s,e){e.r(s),e.d(s,{loadPolygonPath:function(){return r},polygonPathName:function(){return n}});var i=e(3563);class o{constructor(){this.dirsList=[],this.options={sides:6,turnSteps:20,angle:30}}generate(t){return void 0===t.hexStep&&(t.hexStep=0),void 0===t.hexDirection&&(t.hexDirection=6===this.options.sides?2*(3*(0,i.sZ)()|0):(0,i.sZ)()*this.options.sides|0),void 0===t.hexSpeed&&(t.hexSpeed=t.velocity.length),t.hexStep%this.options.turnSteps==0&&(t.hexDirection=(0,i.sZ)()>.5?(t.hexDirection+1)%this.options.sides:(t.hexDirection+this.options.sides-1)%this.options.sides),t.velocity.x=0,t.velocity.y=0,t.hexStep++,i.OW.create(this.dirsList[t.hexDirection].x*t.hexSpeed,this.dirsList[t.hexDirection].y*t.hexSpeed)}init(t){var s;const e=t.actualOptions.particles.move.path.options;this.options.sides=e.sides>0?e.sides:6,this.options.angle=null!==(s=e.angle)&&void 0!==s?s:30,this.options.turnSteps=e.turnSteps>=0?e.turnSteps:20,this.createDirs()}update(){}createDirs(){this.dirsList=[];for(let t=0;t<360;t+=360/this.options.sides){const s=this.options.angle+t;this.dirsList.push(i.OW.create(Math.cos(s*Math.PI/180),Math.sin(s*Math.PI/180)))}}}const n="polygonPathGenerator";function r(t){t.addPathGenerator(n,new o)}}}]);