HLSL custom node problem

whats wrong with my code?

float hit_intencity = 0;
for (int i = 0; i < HitMaxCount; i++)
            {
                float hit_distance = ( distance( HitPositions[i], WorldPosition ) / HitWaveMaxRadius );
                float hit_fade = smoothstep( 0.0 , HitWaveFade , ( 1.0 - ( hit_distance - (-1.0 + (HitRadii[i] - 0.0) * (1.0 - -1.0) / (1.0 - 0.0)) ) ));
                float4 ramp_map = tex2D( HitWaveRampMap, float2(hit_fade, 0) );
                float wave = ( ramp_map.r - ( ramp_map.r * tex2D( HitWaveRampMap, ( hit_fade - DistortionRG ).rg ).r ) );
                float intencity = ( saturate( ( 1.0 - hit_distance ) ) * saturate(wave - HitTextureR ) );		
                hit_intencity += intencity;
            }
            hit_intencity = saturate(hit_intencity);
return hit_intencity;

282060-capture.png

HitPositions[i] is not a vector, whatever it is you can not use [] on it. Check what you inputing to it

I’ve already done it but have another problems :confused: