mirror of
https://github.com/EQEmu/Server.git
synced 2025-12-22 02:51:30 +00:00
Code added to auto fix quests. Updated manifest and version to current.
This commit is contained in:
parent
380e5d5084
commit
aa9611d494
@ -30,7 +30,7 @@
|
|||||||
Manifest: https://github.com/EQEmu/Server/blob/master/utils/sql/db_update_manifest.txt
|
Manifest: https://github.com/EQEmu/Server/blob/master/utils/sql/db_update_manifest.txt
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#define CURRENT_BINARY_DATABASE_VERSION 9137
|
#define CURRENT_BINARY_DATABASE_VERSION 9138
|
||||||
#ifdef BOTS
|
#ifdef BOTS
|
||||||
#define CURRENT_BINARY_BOTS_DATABASE_VERSION 9021
|
#define CURRENT_BINARY_BOTS_DATABASE_VERSION 9021
|
||||||
#else
|
#else
|
||||||
|
|||||||
@ -2214,6 +2214,10 @@ sub run_database_check {
|
|||||||
if ($bots_db_management == 1 && $val == 9000) {
|
if ($bots_db_management == 1 && $val == 9000) {
|
||||||
modify_db_for_bots();
|
modify_db_for_bots();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if ($val == 9137) {
|
||||||
|
fix_quest_factions();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
$db_run_stage = 2;
|
$db_run_stage = 2;
|
||||||
}
|
}
|
||||||
@ -2600,3 +2604,25 @@ sub quest_faction_convert {
|
|||||||
|
|
||||||
print "Total matches: " . $total_matches . "\n";
|
print "Total matches: " . $total_matches . "\n";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
sub fix_quest_factions {
|
||||||
|
# Backup the quests
|
||||||
|
mkdir('backups');
|
||||||
|
my @files;
|
||||||
|
my $start_dir = "quests/";
|
||||||
|
find(
|
||||||
|
sub { push @files, $File::Find::name unless -d; },
|
||||||
|
$start_dir
|
||||||
|
);
|
||||||
|
for my $file (@files) {
|
||||||
|
$destination_file = $file;
|
||||||
|
my $date = strftime "%m-%d-%Y", localtime;
|
||||||
|
$destination_file =~ s/quests/quests-$date/;
|
||||||
|
print "Backing up :: " . $destination_file . "\n";
|
||||||
|
# unlink($destination_file);
|
||||||
|
copy_file($file, 'backups/' . $destination_file);
|
||||||
|
}
|
||||||
|
|
||||||
|
# Fix the factions
|
||||||
|
quest_faction_convert();
|
||||||
|
}
|
||||||
|
|||||||
@ -389,8 +389,9 @@
|
|||||||
9133|2018_11_25_StuckBehavior.sql|SHOW COLUMNS FROM `npc_types` LIKE 'stuck_behavior'|empty|
|
9133|2018_11_25_StuckBehavior.sql|SHOW COLUMNS FROM `npc_types` LIKE 'stuck_behavior'|empty|
|
||||||
9134|2019_01_04_update_global_base_scaling.sql|SELECT * FROM db_version WHERE version >= 9134|empty|
|
9134|2019_01_04_update_global_base_scaling.sql|SELECT * FROM db_version WHERE version >= 9134|empty|
|
||||||
9135|2019_01_10_multi_version_spawns.sql|SHOW COLUMNS FROM `spawn2` LIKE 'version'|contains|unsigned|
|
9135|2019_01_10_multi_version_spawns.sql|SHOW COLUMNS FROM `spawn2` LIKE 'version'|contains|unsigned|
|
||||||
9136|2018_12_12_client_faction_tables.sql|SHOW TABLES LIKE 'faction_base_data'|empty|
|
9136|2019_02_04_profanity_command.sql|SHOW TABLES LIKE 'profanity_list'|empty|
|
||||||
9137|2018_12_12_convert_to_client_functions.sql|SELECT `id` FROM `faction_list` WHERE `id` > 4999|empty|
|
9137|2018_12_12_client_faction_tables.sql|SHOW TABLES LIKE 'faction_base_data'|empty|
|
||||||
|
9138|2018_12_12_convert_to_client_functions.sql|SELECT `id` FROM `faction_list` WHERE `id` > 4999|empty|
|
||||||
# Upgrade conditions:
|
# Upgrade conditions:
|
||||||
# This won't be needed after this system is implemented, but it is used database that are not
|
# This won't be needed after this system is implemented, but it is used database that are not
|
||||||
# yet using the versioning system to figure out where the database is schema wise to determine
|
# yet using the versioning system to figure out where the database is schema wise to determine
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user