I have a question reguarding executing files. Is it possible to execute a script from a different directory, making the script believe you are executing it from the directory it lives in?
For example, this is my situation:
I have Cube 3D on my box, but it is not a package or source to compile, it simply runs "as is" once extracted into a directory. The scripts obviously are written to use whatever path you're located at when you execute the main script. This gives me path errors when executing from a different directory, because the script is trying to find the necessary files in /whatever/directory/I'm/in/bin_unix/blah/blah instead of
/opt/cube/bin_unix, where it's all actually located.
Instead of editing all the scripts included with the game.. is there a way to make it appear as if the script was executed from it's root directory? (All of this, so that I may place a symlink to it in /usr/bin?)