mirror of
https://git.krews.org/morningstar/Arcturus-Community.git
synced 2025-01-18 23:46:28 +01:00
Adds visible column to achievements.
This commit is contained in:
parent
4b1d695094
commit
997e605ff6
@ -1,3 +1,6 @@
|
|||||||
INSERT INTO `emulator_texts` (`key`, `value`) VALUES ('commands.error.cmd_changename.user_not_found', 'The Habbo %user% does not exist or is not online.');
|
INSERT INTO `emulator_texts` (`key`, `value`) VALUES ('commands.error.cmd_changename.user_not_found', 'The Habbo %user% does not exist or is not online.');
|
||||||
INSERT INTO `emulator_texts` (`key`, `value`) VALUES ('commands.succes.cmd_changename.done', 'Successfully toggled the name change for the Habbo %user%.');
|
INSERT INTO `emulator_texts` (`key`, `value`) VALUES ('commands.succes.cmd_changename.done', 'Successfully toggled the name change for the Habbo %user%.');
|
||||||
INSERT INTO `emulator_texts` (`key`, `value`) VALUES ('commands.succes.cmd_changename.received', 'Hotel staff requests for you to change your name.\n Please click on your Habbo then click on the "Change Your Name" button.');
|
INSERT INTO `emulator_texts` (`key`, `value`) VALUES ('commands.succes.cmd_changename.received', 'Hotel staff requests for you to change your name.\n Please click on your Habbo then click on the "Change Your Name" button.');
|
||||||
|
|
||||||
|
ALTER TABLE `achievements`
|
||||||
|
ADD `visible` enum('0','1') COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT '1' COMMENT 'Is the achievement in use and/or obtainable?';
|
@ -251,7 +251,7 @@ public class AchievementManager {
|
|||||||
}
|
}
|
||||||
|
|
||||||
try (Connection connection = Emulator.getDatabase().getDataSource().getConnection()) {
|
try (Connection connection = Emulator.getDatabase().getDataSource().getConnection()) {
|
||||||
try (Statement statement = connection.createStatement(); ResultSet set = statement.executeQuery("SELECT * FROM achievements")) {
|
try (Statement statement = connection.createStatement(); ResultSet set = statement.executeQuery("SELECT * FROM achievements WHERE visible = 1")) {
|
||||||
while (set.next()) {
|
while (set.next()) {
|
||||||
if (!this.achievements.containsKey(set.getString("name"))) {
|
if (!this.achievements.containsKey(set.getString("name"))) {
|
||||||
this.achievements.put(set.getString("name"), new Achievement(set));
|
this.achievements.put(set.getString("name"), new Achievement(set));
|
||||||
|
Loading…
Reference in New Issue
Block a user