Skip to content

Geometry property of the Ss.particles object is undefined, which is causing an error when trying to access the opacity attribute #3

@Smajkan

Description

@Smajkan
Uncaught TypeError: Cannot read properties of undefined (reading 'geometry')
    at Object.update (snow3d.js?ver=cc4a969e02505d0bca7c:formatted:15077:44)
    at f (snow3d.js?ver=cc4a969e02505d0bca7c:formatted:14755:47)
    at m (snow3d.js?ver=cc4a969e02505d0bca7c:formatted:14786:28)
    at l.tick (snow3d.js?ver=cc4a969e02505d0bca7c:formatted:14830:17)
    at e (snow3d.js?ver=cc4a969e02505d0bca7c:formatted:14617:31)
    
snow3d.js:
     Ts = t=>{
            ms({
                targets: bs,
                opacity: Number(t),
                duration: 2700,
                easing: "easeOutQuint",
                update: ()=>{
                    const t = Ss.particles.geometry.attributes.opacity
                      , e = t.count / 2;
                    for (let n = 0; n < e; n++)
                        t.setX(n, bs.opacity);
                    Ss.particles.geometry.attributes.opacity.needsUpdate = !0
                }
            })
        }
        
    This is the line where error occurs: `const t = Ss.particles.geometry.attributes.opacity`

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions