Fix replacing an existing message block causing all message blocks in the map to be changed to the new message block, oops. (Thanks goodlyay)

This commit is contained in:
UnknownShadow200 2016-08-13 11:00:33 +10:00
parent 11b3238630
commit 1d9aa1910b

View File

@ -111,7 +111,7 @@ namespace MCGalaxy.Commands.Building {
string syntax = Messages.Rows.Count == 0 ?
"INSERT INTO `Messages" + p.level.name + "` (X, Y, Z, Message) VALUES (@0, @1, @2, @3)"
: "UPDATE `Messages" + p.level.name + "` SET X=@0, Y=@1, Z=@2, Message=@3";
: "UPDATE `Messages" + p.level.name + "` SET Message=@3 WHERE X=@0, Y=@1, Z=@2";
Database.Execute(syntax, x, y, z, cpos.message);
}