I think that apart from not installing the dependencies, both problems that you have faced in your machine (zsh-bash conflict, headless machine) are beyond the scope of this script and need to be examined individually.
At the end of the day, one could easily substitute rofi with fzf itself in the script, they do more or less the same job. I am not certain rofi is your main obstacle here.