mirror of
https://github.com/EQEmu/Server.git
synced 2025-12-12 17:51:28 +00:00
Merge branch 'master' of git://github.com/EQEmu/Server
This commit is contained in:
commit
4ee4992330
@ -428,7 +428,7 @@ bool Database::ReserveName(uint32 account_id, char* name)
|
||||
char errbuf[MYSQL_ERRMSG_SIZE];
|
||||
char *query = 0;
|
||||
|
||||
if (!RunQuery(query, MakeAnyLenString(&query, "INSERT into character_ SET account_id=%i, name='%s', profile=nullptr", account_id, name), errbuf)) {
|
||||
if (!RunQuery(query, MakeAnyLenString(&query, "INSERT into character_ SET account_id=%i, name='%s', profile=NULL", account_id, name), errbuf)) {
|
||||
cerr << "Error in ReserveName query '" << query << "' " << errbuf << endl;
|
||||
safe_delete_array(query);
|
||||
return false;
|
||||
@ -1196,9 +1196,9 @@ bool Database::GetSafePoints(const char* short_name, uint32 version, float* safe
|
||||
{
|
||||
cerr << "Error in GetSafePoint query '" << query << "' " << errbuf << endl;
|
||||
cerr << "If it errors, run the following querys:\n";
|
||||
cerr << "ALTER TABLE `zone` CHANGE `minium_level` `min_level` TINYINT(3) UNSIGNED DEFAULT \"0\" NOT nullptr;\n";
|
||||
cerr << "ALTER TABLE `zone` CHANGE `minium_status` `min_status` TINYINT(3) UNSIGNED DEFAULT \"0\" NOT nullptr;\n";
|
||||
cerr << "ALTER TABLE `zone` ADD flag_needed VARCHAR(128) NOT nullptr DEFAULT '';\n";
|
||||
cerr << "ALTER TABLE `zone` CHANGE `minium_level` `min_level` TINYINT(3) UNSIGNED DEFAULT \"0\" NOT NULL;\n";
|
||||
cerr << "ALTER TABLE `zone` CHANGE `minium_status` `min_status` TINYINT(3) UNSIGNED DEFAULT \"0\" NOT NULL;\n";
|
||||
cerr << "ALTER TABLE `zone` ADD flag_needed VARCHAR(128) NOT NULL DEFAULT '';\n";
|
||||
|
||||
safe_delete_array(query);
|
||||
}
|
||||
|
||||
@ -6129,7 +6129,7 @@ void Client::Handle_OP_RecipesFavorite(const EQApplicationPacket *app)
|
||||
" LEFT JOIN tradeskill_recipe_entries AS tre ON tr.id=tre.recipe_id "
|
||||
" LEFT JOIN (SELECT recipe_id, madecount FROM char_recipe_list WHERE char_id = %u) AS crl ON tr.id=crl.recipe_id "
|
||||
" WHERE tr.id IN (%s) "
|
||||
" AND tr.must_learn & 0x20 <> 0x20 AND ((tr.must_learn & 0x3 <> 0 AND crl.madecount IS NOT nullptr) OR (tr.must_learn & 0x3 = 0)) "
|
||||
" AND tr.must_learn & 0x20 <> 0x20 AND ((tr.must_learn & 0x3 <> 0 AND crl.madecount IS NOT NULL) OR (tr.must_learn & 0x3 = 0)) "
|
||||
" GROUP BY tr.id "
|
||||
" HAVING sum(if(tre.item_id %s AND tre.iscontainer > 0,1,0)) > 0 "
|
||||
" LIMIT 100 ", CharacterID(), buf, containers);
|
||||
@ -6184,7 +6184,7 @@ void Client::Handle_OP_RecipesSearch(const EQApplicationPacket *app)
|
||||
" LEFT JOIN tradeskill_recipe_entries AS tre ON tr.id=tre.recipe_id "
|
||||
" LEFT JOIN (SELECT recipe_id, madecount FROM char_recipe_list WHERE char_id = %u) AS crl ON tr.id=crl.recipe_id "
|
||||
" WHERE %s tr.trivial >= %u AND tr.trivial <= %u "
|
||||
" AND tr.must_learn & 0x20 <> 0x20 AND((tr.must_learn & 0x3 <> 0 AND crl.madecount IS NOT nullptr) OR (tr.must_learn & 0x3 = 0)) "
|
||||
" AND tr.must_learn & 0x20 <> 0x20 AND((tr.must_learn & 0x3 <> 0 AND crl.madecount IS NOT NULL) OR (tr.must_learn & 0x3 = 0)) "
|
||||
" GROUP BY tr.id "
|
||||
" HAVING sum(if(tre.item_id %s AND tre.iscontainer > 0,1,0)) > 0 "
|
||||
" LIMIT 200 "
|
||||
|
||||
@ -3784,12 +3784,12 @@ void Mob::InsertQuestGlobal(int charid, int npcid, int zoneid, const char *varna
|
||||
char *query = 0;
|
||||
char errbuf[MYSQL_ERRMSG_SIZE];
|
||||
|
||||
// Make duration string either "unix_timestamp(now()) + xxx" or "nullptr"
|
||||
// Make duration string either "unix_timestamp(now()) + xxx" or "NULL"
|
||||
stringstream duration_ss;
|
||||
|
||||
if (duration == INT_MAX)
|
||||
{
|
||||
duration_ss << "nullptr";
|
||||
duration_ss << "NULL";
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
@ -1241,11 +1241,11 @@ int QuestManager::InsertQuestGlobal(
|
||||
char *query = 0;
|
||||
char errbuf[MYSQL_ERRMSG_SIZE];
|
||||
|
||||
// Make duration string either "unix_timestamp(now()) + xxx" or "nullptr"
|
||||
// Make duration string either "unix_timestamp(now()) + xxx" or "NULL"
|
||||
stringstream duration_ss;
|
||||
if (duration == INT_MAX)
|
||||
{
|
||||
duration_ss << "nullptr";
|
||||
duration_ss << "NULL";
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user