mirror of
https://github.com/EQEmu/Server.git
synced 2026-05-27 04:42:27 +00:00
Compare commits
6 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 9477ff72ac | |||
| 6d8e80b1e5 | |||
| ebeaef598b | |||
| 60b65da7f2 | |||
| 100e6698ea | |||
| 2bd94ab7a2 |
@@ -1,3 +1,23 @@
|
||||
## [22.34.2] - 11/23/2023
|
||||
|
||||
### Admin
|
||||
|
||||
* Update date in changelog ([#3698](https://github.com/EQEmu/Server/pull/3698)) @joligario 2023-11-19
|
||||
|
||||
### Code
|
||||
|
||||
* Fix typo in #giveitem ([#3704](https://github.com/EQEmu/Server/pull/3704)) @Kinglykrab 2023-11-22
|
||||
|
||||
### Fixes
|
||||
|
||||
* Add "IgnoreLevelBasedHasteCaps" rule to GetHaste() ([#3705](https://github.com/EQEmu/Server/pull/3705)) @jcr4990 2023-11-23
|
||||
* Fix bots/Mercenaries being removed from hatelist ([#3708](https://github.com/EQEmu/Server/pull/3708)) @Kinglykrab 2023-11-23
|
||||
* Fix some spell types failing IsValidSpellRange check ([#3707](https://github.com/EQEmu/Server/pull/3707)) @nytmyr 2023-11-23
|
||||
|
||||
### Loginserver
|
||||
|
||||
* Update ticket login table structure ([#3703](https://github.com/EQEmu/Server/pull/3703)) @KimLS 2023-11-22
|
||||
|
||||
## [22.34.1] - 11/20/2023
|
||||
|
||||
### EQTime
|
||||
|
||||
+1
-1
@@ -25,7 +25,7 @@
|
||||
|
||||
// Build variables
|
||||
// these get injected during the build pipeline
|
||||
#define CURRENT_VERSION "22.34.1-dev" // always append -dev to the current version for custom-builds
|
||||
#define CURRENT_VERSION "22.34.2-dev" // always append -dev to the current version for custom-builds
|
||||
#define LOGIN_VERSION "0.8.0"
|
||||
#define COMPILE_DATE __DATE__
|
||||
#define COMPILE_TIME __TIME__
|
||||
|
||||
+10
-28
@@ -121,43 +121,25 @@ bool Database::GetLoginTokenDataFromToken(
|
||||
std::string &user
|
||||
)
|
||||
{
|
||||
auto query = fmt::format(
|
||||
"SELECT tbllogintokens.Id, tbllogintokens.IpAddress, tbllogintokenclaims.Name, tbllogintokenclaims.Value FROM tbllogintokens "
|
||||
"JOIN tbllogintokenclaims ON tbllogintokens.Id = tbllogintokenclaims.TokenId WHERE tbllogintokens.Expires > NOW() "
|
||||
"AND tbllogintokens.Id='{0}' AND tbllogintokens.IpAddress='{1}'",
|
||||
auto query = fmt::format("SELECT login_server, username, account_id FROM login_tickets WHERE expires > NOW()"
|
||||
" AND id='{0}' AND ip_address='{1}' LIMIT 1",
|
||||
Strings::Escape(token),
|
||||
Strings::Escape(ip)
|
||||
);
|
||||
Strings::Escape(ip));
|
||||
|
||||
auto results = QueryDatabase(query);
|
||||
if (results.RowCount() == 0 || !results.Success()) {
|
||||
return false;
|
||||
}
|
||||
|
||||
bool found_username = false;
|
||||
bool found_login_id = false;
|
||||
bool found_login_server_name = false;
|
||||
for (auto row = results.begin(); row != results.end(); ++row) {
|
||||
if (strcmp(row[2], "username") == 0) {
|
||||
user = row[3];
|
||||
found_username = true;
|
||||
continue;
|
||||
}
|
||||
|
||||
if (strcmp(row[2], "login_server_id") == 0) {
|
||||
db_account_id = Strings::ToUnsignedInt(row[3]);
|
||||
found_login_id = true;
|
||||
continue;
|
||||
}
|
||||
|
||||
if (strcmp(row[2], "login_server_name") == 0) {
|
||||
db_loginserver = row[3];
|
||||
found_login_server_name = true;
|
||||
continue;
|
||||
}
|
||||
for (auto row = results.begin(); row != results.end(); ++row) {
|
||||
db_loginserver = row[0];
|
||||
user = row[1];
|
||||
db_account_id = Strings::ToUnsignedInt(row[2]);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
return found_username && found_login_id && found_login_server_name;
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
DROP TABLE IF EXISTS `login_tickets`;
|
||||
CREATE TABLE `login_tickets` (
|
||||
`id` VARCHAR(128) NOT NULL,
|
||||
`login_server` TEXT NOT NULL,
|
||||
`username` TEXT NOT NULL,
|
||||
`account_id` INT(10) UNSIGNED NOT NULL,
|
||||
`ip_address` VARCHAR(45) NOT NULL,
|
||||
`expires` DATETIME NOT NULL,
|
||||
PRIMARY KEY (`id`) USING BTREE
|
||||
)
|
||||
ENGINE=InnoDB;
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "eqemu-server",
|
||||
"version": "22.34.1",
|
||||
"version": "22.34.2",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/EQEmu/Server.git"
|
||||
|
||||
@@ -183,7 +183,7 @@ bool Bot::BotCastHateReduction(Mob* tar, uint8 botLevel, const BotSpell& botSpel
|
||||
if (tar->CanBuffStack(iter.SpellId, botLevel, true) < 0)
|
||||
continue;
|
||||
|
||||
if (IsValidSpellRange(botSpell.SpellId, tar)) {
|
||||
if (IsValidSpellRange(iter.SpellId, tar)) {
|
||||
casted_spell = AIDoSpellCast(iter.SpellIndex, tar, iter.ManaCost);
|
||||
}
|
||||
if (casted_spell) {
|
||||
@@ -328,7 +328,7 @@ bool Bot::BotCastSlow(Mob* tar, uint8 botLevel, uint8 botClass, BotSpell& botSpe
|
||||
continue;
|
||||
}
|
||||
|
||||
if (IsValidSpellRange(botSpell.SpellId, tar)) {
|
||||
if (IsValidSpellRange(iter.SpellId, tar)) {
|
||||
casted_spell = AIDoSpellCast(iter.SpellIndex, tar, iter.ManaCost);
|
||||
}
|
||||
|
||||
@@ -447,7 +447,7 @@ bool Bot::BotCastDOT(Mob* tar, uint8 botLevel, const BotSpell& botSpell, const b
|
||||
|
||||
uint32 TempDontDotMeBefore = tar->DontDotMeBefore();
|
||||
|
||||
if (IsValidSpellRange(botSpell.SpellId, tar)) {
|
||||
if (IsValidSpellRange(s.SpellId, tar)) {
|
||||
casted_spell = AIDoSpellCast(s.SpellIndex, tar, s.ManaCost, &TempDontDotMeBefore);
|
||||
}
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
void command_giveitem(Client *c, const Seperator *sep)
|
||||
{
|
||||
if (!c->GetTarget() || !!c->GetTarget()->IsClient()) {
|
||||
if (!c->GetTarget() || !c->GetTarget()->IsClient()) {
|
||||
c->Message(Chat::White, "You must target a player to use this command.");
|
||||
return;
|
||||
}
|
||||
|
||||
+10
-2
@@ -46,7 +46,14 @@ void HateList::WipeHateList(bool npc_only) {
|
||||
auto iterator = list.begin();
|
||||
while (iterator != list.end()) {
|
||||
Mob *m = (*iterator)->entity_on_hatelist;
|
||||
if (m && (m->IsClient() || (m->IsPet() && m->GetOwner()->IsClient())) && npc_only) {
|
||||
if (
|
||||
m &&
|
||||
(
|
||||
m->IsOfClientBotMerc() ||
|
||||
(m->IsPet() && m->GetOwner() && m->GetOwner()->IsOfClientBotMerc())
|
||||
) &&
|
||||
npc_only
|
||||
) {
|
||||
iterator++;
|
||||
} else {
|
||||
if (m) {
|
||||
@@ -58,6 +65,7 @@ void HateList::WipeHateList(bool npc_only) {
|
||||
m->CastToClient()->DecrementAggroCount();
|
||||
m->CastToClient()->RemoveXTarget(hate_owner, true);
|
||||
}
|
||||
|
||||
delete (*iterator);
|
||||
iterator = list.erase(iterator);
|
||||
}
|
||||
@@ -733,7 +741,7 @@ int HateList::AreaRampage(Mob *caster, Mob *target, int count, ExtraAttackOption
|
||||
caster->CombatRange(h->entity_on_hatelist, 1.0, true, opts)) {
|
||||
id_list.push_back(h->entity_on_hatelist->GetID());
|
||||
}
|
||||
|
||||
|
||||
if (count != -1 && id_list.size() > count) {
|
||||
break;
|
||||
}
|
||||
|
||||
+2
-2
@@ -5315,7 +5315,7 @@ int Mob::GetHaste()
|
||||
h += spellbonuses.hastetype2 > 10 ? 10 : spellbonuses.hastetype2;
|
||||
|
||||
// 26+ no cap, 1-25 10
|
||||
if (level > 25) // 26+
|
||||
if (level > 25 || (IsClient() && RuleB(Character, IgnoreLevelBasedHasteCaps))) // 26+
|
||||
h += itembonuses.haste;
|
||||
else // 1-25
|
||||
h += itembonuses.haste > 10 ? 10 : itembonuses.haste;
|
||||
@@ -5337,7 +5337,7 @@ int Mob::GetHaste()
|
||||
h = cap;
|
||||
|
||||
// 51+ 25 (despite there being higher spells...), 1-50 10
|
||||
if (level > 50) { // 51+
|
||||
if (level > 50 || (IsClient() && RuleB(Character, IgnoreLevelBasedHasteCaps))) { // 51+
|
||||
cap = RuleI(Character, Hastev3Cap);
|
||||
if (spellbonuses.hastetype3 > cap) {
|
||||
h += cap;
|
||||
|
||||
Reference in New Issue
Block a user