Fixed regions

Added /convert
This commit is contained in:
Lucas Nicodemus 2011-07-22 17:38:51 -06:00
parent 92d6e7b9fb
commit e1cd87f487
3 changed files with 59 additions and 3 deletions

View file

@ -130,6 +130,23 @@ namespace TShockAPI.DB
}
}
public void ConvertDB()
{
try
{
using (var com = database.CreateCommand())
{
com.CommandText = "UPDATE Warps SET WorldID=@worldid";
com.AddParameter("@worldid", Main.worldID.ToString());
com.ExecuteNonQuery();
}
}
catch (Exception ex)
{
Log.Error(ex.ToString());
}
}
public bool AddWarp(int x, int y, string name, string worldid)
{
try