Recently, Hu, et al. (2024) used simplicial complexes to construct a large family of projective linear codes over \({\mathbb F}_{q}\) . Motivated by their work, the authors construct an infinite family of linear codes with flexible parameters over \({\mathbb F}_{q} + u{\mathbb F}_{q} \; (u^{2} = 0)\) by employing simplicial complexes, and give their parameters. In addition, for the simplicial complexes of \({\mathbb F}_{{q}^{m}}\) generated by one or two maximal elements, the authors determine their parameters and weight distributions, and further show that their Gray images are minimal and distance-optimal.