3
Actually nothing seems lost. Assuming you didn't make any changes to the mainfile before you overwrote it.
Just take the copy from the XOOPS download and take out the mainfile.php and fill in the data. (database name, user name, etc.) that's all.
[edit]
O that's right, there's a .dist file, that's even easyer!
[/edit]