The Walsh-Hadamard transform is a powerful tool to investigate interference-resist capabilities and cryptographic of functions which have a wide array of applications in coding theory and cryptography. It is interesting to find functions with few Walsh-Hadamard transform values (spectral amplitudes) and to determine their distributions. In this letter, a new modified generalized Maiorana-McFarland (MGMM) construction is presented. A collection of MGMM classes of functions of few spectral amplitudes can be obtained by using the proposed construction. The constructed functions have determined spectral amplitude distributions. As a class of these MGMM functions, generalized 3-ary functions of two nonzero spectral amplitudes $3^{n/2}$ and $3^{n/2+1}$ are then exploited to construct spreading sequences for even $n$. Moreover, an efficient assignment is presented to provide that the smallest distance between pairs of sequences of correlation $3^{n/2+1}$ is 3, which implies that the spreading sequences based on these functions in our assignment have better interference-resist capability than the spreading sequences based on ternary semi-bent functions.