Fix flower pots
This commit is contained in:
@@ -123,11 +123,11 @@ public class FlowerPots {
|
||||
String sql;
|
||||
if(alreadyFound)
|
||||
{
|
||||
sql = "UPDATE coreFoundPots SET timestamp = '"+(System.currentTimeMillis() / 1000)+"', type = 1 WHERE player = (SELECT id FROM players WHERE uuid = '"+P.getUniqueId().toString()+"')";
|
||||
sql = "UPDATE coreFoundPots SET timestamp = '"+(System.currentTimeMillis() / 1000)+"', type = 1 WHERE player = (SELECT id FROM players WHERE uuid = '"+P.getUniqueId().toString()+"') AND id = '"+pot+"'";
|
||||
}
|
||||
else
|
||||
{
|
||||
sql = "INSERT INTO coreFoundPots(id, player, timestamp, type) VALUES('"+pot+"', (SELECT id FROM players WHERE uuid = '"+P.getUniqueId().toString()+"'),'"+(int) (System.currentTimeMillis() / 1000)+"','"+type+"')";
|
||||
sql = "INSERT INTO coreFoundPots(id, player, timestamp, type) VALUES('"+pot+"', (SELECT id FROM players WHERE uuid = '"+P.getUniqueId().toString()+"'),'"+(int) (System.currentTimeMillis() / 1000)+"',"+type+")";
|
||||
}
|
||||
AnuraCore.getSql().queryUpdate(sql);
|
||||
Location loc = AnuraCore.getInstance().flowerPots.get(pot);
|
||||
|
||||
Reference in New Issue
Block a user