I just ran into something with Worms CopyFolder function.
I was trying to copy a folder of stuff from a CD to the harddrive. For whatever reason, I kept getting an error that I couldn't figure out.
After playing around for a while, I discovered this fix which seems to work REALLY well. I'm not sure if there is a downside to doing this, but here goes.
The original few lines of code are as follows:
<code>
function CopyFolder(sSource, sDestination)
local m_sFolder;
local m_FoundFolder;
local error;
</code>
Here is what I did:
<code>
function CopyFolder(sSource, sDestination)
local m_sFolder;
local m_FoundFolder;
local error = 0;
</code>
Now whenever I try, everything works perfectly. I am assuming that there will be no errors. If an error does occur, the folder still won't copy, so no harm done (I think)
I was trying to copy a folder of stuff from a CD to the harddrive. For whatever reason, I kept getting an error that I couldn't figure out.
After playing around for a while, I discovered this fix which seems to work REALLY well. I'm not sure if there is a downside to doing this, but here goes.
The original few lines of code are as follows:
<code>
function CopyFolder(sSource, sDestination)
local m_sFolder;
local m_FoundFolder;
local error;
</code>
Here is what I did:
<code>
function CopyFolder(sSource, sDestination)
local m_sFolder;
local m_FoundFolder;
local error = 0;
</code>
Now whenever I try, everything works perfectly. I am assuming that there will be no errors. If an error does occur, the folder still won't copy, so no harm done (I think)
Comment