Is there any console cheat that I could use to make my companions immortal? I tried looking at different sites with no luck.
very simple actually
be sure you have companion in view
then in console do a getav health
then you see the companions health
then you do a setav health 10000 for example
check again with getav health if it changed
your companion wont die that soon anymore
you can also do a modav health 10000
which i believe sets it then permanently
true.
to make the chaange permanent(will not be affected when savegame is reloaded)
forceav health
it can be used for any attribute btw.
not sure why it wouldn't work. the only thing i can think of is that you may have had something selected in game before you opened the console and entered the command.
if you have something selected when you open the console there will be a REF ID in the command window for whatever you have selected. make sure there is no ref id when you open the console and you should be fine...good luck.
For the setessential command, you need to use the base ID from the editor.
For the base ID, just search for their name at UESP.