I was about to say this
Edit: after looking back into this, it falls into parody law. Due to it not using any trademarked content, and only having artistic similarities to Undertale, it is legal. One example of something like this is Weird Al making parody songs, or the 1987 film Spaceballs being a parody of the 1977 film Star Wars.