diff --git a/common/CMakeLists.txt b/common/CMakeLists.txt index 3bbaecdb4..ca9af892a 100644 --- a/common/CMakeLists.txt +++ b/common/CMakeLists.txt @@ -112,8 +112,8 @@ SET(common_sources net/websocket_server.cpp net/websocket_server_connection.cpp patches/patches.cpp - patches/larion.cpp - patches/larion_limits.cpp + patches/laurion.cpp + patches/laurion_limits.cpp patches/sod.cpp patches/sod_limits.cpp patches/sof.cpp @@ -657,10 +657,10 @@ SET(common_headers net/websocket_server.h net/websocket_server_connection.h patches/patches.h - patches/larion.h - patches/larion_limits.h - patches/larion_ops.h - patches/larion_structs.h + patches/laurion.h + patches/laurion_limits.h + patches/laurion_ops.h + patches/laurion_structs.h patches/sod.h patches/sod_limits.h patches/sod_ops.h @@ -747,10 +747,10 @@ SOURCE_GROUP(Net FILES SOURCE_GROUP(Patches FILES patches/patches.h - patches/larion.h - patches/larion_limits.h - patches/larion_ops.h - patches/larion_structs.h + patches/laurion.h + patches/laurion_limits.h + patches/laurion_ops.h + patches/laurion_structs.h patches/sod.h patches/sod_limits.h patches/sod_ops.h @@ -779,8 +779,8 @@ SOURCE_GROUP(Patches FILES patches/uf_ops.h patches/uf_structs.h patches/patches.cpp - patches/larion.cpp - patches/larion_limits.cpp + patches/laurion.cpp + patches/laurion_limits.cpp patches/sod.cpp patches/sod_limits.cpp patches/sof.cpp diff --git a/common/emu_versions.cpp b/common/emu_versions.cpp index ebde39ddf..7cdbf2575 100644 --- a/common/emu_versions.cpp +++ b/common/emu_versions.cpp @@ -56,8 +56,8 @@ const char* EQ::versions::ClientVersionName(ClientVersion client_version) return "RoF"; case ClientVersion::RoF2: return "RoF2"; - case ClientVersion::Larion: - return "Larion"; + case ClientVersion::Laurion: + return "Laurion"; default: return "Invalid Version"; }; @@ -78,8 +78,8 @@ uint32 EQ::versions::ConvertClientVersionToClientVersionBit(ClientVersion client return bitRoF; case ClientVersion::RoF2: return bitRoF2; - case ClientVersion::Larion: - return bitLarion; + case ClientVersion::Laurion: + return bitLaurion; default: return bitUnknown; } @@ -100,8 +100,8 @@ EQ::versions::ClientVersion EQ::versions::ConvertClientVersionBitToClientVersion return ClientVersion::RoF; case ((uint32)1 << (static_cast(ClientVersion::RoF2) - 1)) : return ClientVersion::RoF2; - case ((uint32)1 << (static_cast(ClientVersion::Larion) - 1)): - return ClientVersion::Larion; + case ((uint32)1 << (static_cast(ClientVersion::Laurion) - 1)): + return ClientVersion::Laurion; default: return ClientVersion::Unknown; } @@ -190,8 +190,8 @@ const char* EQ::versions::MobVersionName(MobVersion mob_version) return "RoF"; case MobVersion::RoF2: return "RoF2"; - case MobVersion::Larion: - return "Larion"; + case MobVersion::Laurion: + return "Laurion"; case MobVersion::NPC: return "NPC"; case MobVersion::NPCMerchant: @@ -220,8 +220,8 @@ const char* EQ::versions::MobVersionName(MobVersion mob_version) return "Offline RoF"; case MobVersion::OfflineRoF2: return "Offline RoF2"; - case MobVersion::OfflineLarion: - return "Offline Larion"; + case MobVersion::OfflineLaurion: + return "Offline Laurion"; default: return "Invalid Version"; }; @@ -245,8 +245,8 @@ EQ::versions::ClientVersion EQ::versions::ConvertMobVersionToClientVersion(MobVe return ClientVersion::RoF; case MobVersion::RoF2: return ClientVersion::RoF2; - case MobVersion::Larion: - return ClientVersion::Larion; + case MobVersion::Laurion: + return ClientVersion::Laurion; default: return ClientVersion::Unknown; } @@ -270,8 +270,8 @@ EQ::versions::MobVersion EQ::versions::ConvertClientVersionToMobVersion(ClientVe return MobVersion::RoF; case ClientVersion::RoF2: return MobVersion::RoF2; - case ClientVersion::Larion: - return MobVersion::Larion; + case ClientVersion::Laurion: + return MobVersion::Laurion; default: return MobVersion::Unknown; } @@ -292,8 +292,8 @@ EQ::versions::MobVersion EQ::versions::ConvertPCMobVersionToOfflinePCMobVersion( return MobVersion::OfflineRoF; case MobVersion::RoF2: return MobVersion::OfflineRoF2; - case MobVersion::Larion: - return MobVersion::OfflineLarion; + case MobVersion::Laurion: + return MobVersion::OfflineLaurion; default: return MobVersion::Unknown; } @@ -314,8 +314,8 @@ EQ::versions::MobVersion EQ::versions::ConvertOfflinePCMobVersionToPCMobVersion( return MobVersion::RoF; case MobVersion::OfflineRoF2: return MobVersion::RoF2; - case MobVersion::OfflineLarion: - return MobVersion::Larion; + case MobVersion::OfflineLaurion: + return MobVersion::Laurion; default: return MobVersion::Unknown; } @@ -336,8 +336,8 @@ EQ::versions::ClientVersion EQ::versions::ConvertOfflinePCMobVersionToClientVers return ClientVersion::RoF; case MobVersion::OfflineRoF2: return ClientVersion::RoF2; - case MobVersion::OfflineLarion: - return ClientVersion::Larion; + case MobVersion::OfflineLaurion: + return ClientVersion::Laurion; default: return ClientVersion::Unknown; } @@ -358,8 +358,8 @@ EQ::versions::MobVersion EQ::versions::ConvertClientVersionToOfflinePCMobVersion return MobVersion::OfflineRoF; case ClientVersion::RoF2: return MobVersion::OfflineRoF2; - case ClientVersion::Larion: - return MobVersion::OfflineLarion; + case ClientVersion::Laurion: + return MobVersion::OfflineLaurion; default: return MobVersion::Unknown; } diff --git a/common/emu_versions.h b/common/emu_versions.h index 5a2027770..f22c0121b 100644 --- a/common/emu_versions.h +++ b/common/emu_versions.h @@ -37,7 +37,7 @@ namespace EQ UF, // Build: 'Jun 8 2010 16:44:32' RoF, // Build: 'Dec 10 2012 17:35:44' RoF2, // Build: 'May 10 2013 23:30:08' - Larion + Laurion }; enum ClientVersionBitmask : uint32 { @@ -49,7 +49,7 @@ namespace EQ bitUF = 0x00000010, bitRoF = 0x00000020, bitRoF2 = 0x00000040, - bitLarion = 0x00000080, + bitLaurion = 0x00000080, maskUnknown = 0x00000000, maskTitaniumAndEarlier = 0x00000003, maskSoFAndEarlier = 0x00000007, @@ -61,11 +61,11 @@ namespace EQ maskUFAndLater = 0xFFFFFFF0, maskRoFAndLater = 0xFFFFFFE0, maskRoF2AndLater = 0xFFFFFFC0, - maskLarionAndLater = 0xFFFFFF80, + maskLaurionAndLater = 0xFFFFFF80, maskAllClients = 0xFFFFFFFF }; - const ClientVersion LastClientVersion = ClientVersion::Larion; + const ClientVersion LastClientVersion = ClientVersion::Laurion; const size_t ClientVersionCount = (static_cast(LastClientVersion) + 1); bool IsValidClientVersion(ClientVersion client_version); @@ -83,7 +83,7 @@ namespace EQ UF, RoF, RoF2, - Larion, + Laurion, NPC, NPCMerchant, Merc, @@ -98,13 +98,13 @@ namespace EQ OfflineUF, OfflineRoF, OfflineRoF2, - OfflineLarion + OfflineLaurion }; - const MobVersion LastMobVersion = MobVersion::OfflineLarion; - const MobVersion LastPCMobVersion = MobVersion::Larion; + const MobVersion LastMobVersion = MobVersion::OfflineLaurion; + const MobVersion LastPCMobVersion = MobVersion::Laurion; const MobVersion LastNonPCMobVersion = MobVersion::BotPet; - const MobVersion LastOfflinePCMobVersion = MobVersion::OfflineLarion; + const MobVersion LastOfflinePCMobVersion = MobVersion::OfflineLaurion; const size_t MobVersionCount = (static_cast(LastMobVersion) + 1); bool IsValidMobVersion(MobVersion mob_version); diff --git a/common/eq_limits.cpp b/common/eq_limits.cpp index 7c0f72038..21b03cddf 100644 --- a/common/eq_limits.cpp +++ b/common/eq_limits.cpp @@ -105,13 +105,13 @@ static const EQ::constants::LookupEntry constants_static_lookup_entries[EQ::vers RoF2::constants::CHARACTER_CREATION_LIMIT, RoF2::constants::SAY_LINK_BODY_SIZE ), - /*[ClientVersion::Larion] =*/ + /*[ClientVersion::Laurion] =*/ EQ::constants::LookupEntry( - Larion::constants::EXPANSION, - Larion::constants::EXPANSION_BIT, - Larion::constants::EXPANSIONS_MASK, - Larion::constants::CHARACTER_CREATION_LIMIT, - Larion::constants::SAY_LINK_BODY_SIZE + Laurion::constants::EXPANSION, + Laurion::constants::EXPANSION_BIT, + Laurion::constants::EXPANSIONS_MASK, + Laurion::constants::CHARACTER_CREATION_LIMIT, + Laurion::constants::SAY_LINK_BODY_SIZE ) }; @@ -1273,18 +1273,18 @@ static const EQ::spells::LookupEntry spells_static_lookup_entries[EQ::versions:: RoF2::spells::PET_BUFFS, RoF2::spells::MERC_BUFFS ), - /*[ClientVersion::Larion] =*/ + /*[ClientVersion::Laurion] =*/ EQ::spells::LookupEntry( - Larion::spells::SPELL_ID_MAX, - Larion::spells::SPELLBOOK_SIZE, + Laurion::spells::SPELL_ID_MAX, + Laurion::spells::SPELLBOOK_SIZE, UF::spells::SPELL_GEM_COUNT, // client translators are setup to allow the max value a client supports..however, the top 4 indices are not valid in this case - Larion::spells::LONG_BUFFS, - Larion::spells::SHORT_BUFFS, - Larion::spells::DISC_BUFFS, - Larion::spells::TOTAL_BUFFS, - Larion::spells::NPC_BUFFS, - Larion::spells::PET_BUFFS, - Larion::spells::MERC_BUFFS + Laurion::spells::LONG_BUFFS, + Laurion::spells::SHORT_BUFFS, + Laurion::spells::DISC_BUFFS, + Laurion::spells::TOTAL_BUFFS, + Laurion::spells::NPC_BUFFS, + Laurion::spells::PET_BUFFS, + Laurion::spells::MERC_BUFFS ) }; diff --git a/common/eq_limits.h b/common/eq_limits.h index e1e20aec6..c51d5d714 100644 --- a/common/eq_limits.h +++ b/common/eq_limits.h @@ -29,7 +29,7 @@ #include "../common/patches/uf_limits.h" #include "../common/patches/rof_limits.h" #include "../common/patches/rof2_limits.h" -#include "../common/patches/larion_limits.h" +#include "../common/patches/laurion_limits.h" namespace EQ { diff --git a/common/patches/larion.cpp b/common/patches/laurion.cpp similarity index 88% rename from common/patches/larion.cpp rename to common/patches/laurion.cpp index 24dcf1683..40d5f3e6c 100644 --- a/common/patches/larion.cpp +++ b/common/patches/laurion.cpp @@ -20,7 +20,7 @@ #include "../global_define.h" #include "../eqemu_config.h" #include "../eqemu_logsys.h" -#include "larion.h" +#include "laurion.h" #include "../opcodemgr.h" #include "../eq_stream_ident.h" @@ -30,7 +30,7 @@ #include "../misc_functions.h" #include "../strings.h" #include "../inventory_profile.h" -#include "larion_structs.h" +#include "laurion_structs.h" #include "../rulesys.h" #include "../path_manager.h" #include "../classes.h" @@ -43,25 +43,25 @@ #include #include -namespace Larion +namespace Laurion { - static const char* name = "Larion"; + static const char* name = "Laurion"; static OpcodeManager* opcodes = nullptr; static Strategy struct_strategy; void SerializeItem(SerializeBuffer &buffer, const EQ::ItemInstance* inst, int16 slot_id, uint8 depth, ItemPacketType packet_type); // server to client inventory location converters - static inline structs::InventorySlot_Struct ServerToLarionSlot(uint32 server_slot); - static inline structs::InventorySlot_Struct ServerToLarionCorpseSlot(uint32 server_corpse_slot); - static inline uint32 ServerToLarionCorpseMainSlot(uint32 server_corpse_slot); - static inline structs::TypelessInventorySlot_Struct ServerToLarionTypelessSlot(uint32 server_slot, int16 server_type); + static inline structs::InventorySlot_Struct ServerToLaurionSlot(uint32 server_slot); + static inline structs::InventorySlot_Struct ServerToLaurionCorpseSlot(uint32 server_corpse_slot); + static inline uint32 ServerToLaurionCorpseMainSlot(uint32 server_corpse_slot); + static inline structs::TypelessInventorySlot_Struct ServerToLaurionTypelessSlot(uint32 server_slot, int16 server_type); // client to server inventory location converters - static inline uint32 LarionToServerSlot(structs::InventorySlot_Struct larion_slot); - static inline uint32 LarionToServerCorpseSlot(structs::InventorySlot_Struct larion_corpse_slot); - static inline uint32 LarionToServerCorpseMainSlot(uint32 larion_corpse_slot); - static inline uint32 LarionToServerTypelessSlot(structs::TypelessInventorySlot_Struct larion_slot, int16 larion_type); + static inline uint32 LaurionToServerSlot(structs::InventorySlot_Struct laurion_slot); + static inline uint32 LaurionToServerCorpseSlot(structs::InventorySlot_Struct laurion_corpse_slot); + static inline uint32 LaurionToServerCorpseMainSlot(uint32 laurion_corpse_slot); + static inline uint32 LaurionToServerTypelessSlot(structs::TypelessInventorySlot_Struct laurion_slot, int16 laurion_type); void Register(EQStreamIdentifier& into) { @@ -120,7 +120,7 @@ namespace Larion { //all opcodes default to passthrough. #include "ss_register.h" -#include "larion_ops.h" +#include "laurion_ops.h" } std::string Strategy::Describe() const @@ -133,7 +133,7 @@ namespace Larion const EQ::versions::ClientVersion Strategy::ClientVersion() const { - return EQ::versions::ClientVersion::Larion; + return EQ::versions::ClientVersion::Laurion; } #include "ss_define.h" @@ -514,7 +514,7 @@ namespace Larion if (sas->type != AppearanceType::Size) { - //larion struct is different than rof2's but the idea is the same + //laurion struct is different than rof2's but the idea is the same auto outapp = new EQApplicationPacket(OP_SpawnAppearance, sizeof(structs::SpawnAppearance_Struct)); structs::SpawnAppearance_Struct *eq = (structs::SpawnAppearance_Struct*)outapp->pBuffer; @@ -2714,7 +2714,7 @@ namespace Larion int r; for (r = 0; r < 29; r++) { - // Size 68 in Larion + // Size 68 in Laurion IN(filters[r]); } @@ -3328,10 +3328,10 @@ namespace Larion structs::InventorySlot_Struct slot_id{}; switch (packet_type) { case ItemPacketLoot: - slot_id = ServerToLarionCorpseSlot(slot_id_in); + slot_id = ServerToLaurionCorpseSlot(slot_id_in); break; default: - slot_id = ServerToLarionSlot(slot_id_in); + slot_id = ServerToLaurionSlot(slot_id_in); break; } @@ -3499,156 +3499,156 @@ namespace Larion buffer.WriteInt32(0); //unsupported atm } - static inline structs::InventorySlot_Struct ServerToLarionSlot(uint32 server_slot) + static inline structs::InventorySlot_Struct ServerToLaurionSlot(uint32 server_slot) { - structs::InventorySlot_Struct LarionSlot; - LarionSlot.Type = invtype::TYPE_INVALID; - LarionSlot.Slot = invslot::SLOT_INVALID; - LarionSlot.SubIndex = invbag::SLOT_INVALID; - LarionSlot.AugIndex = invaug::SOCKET_INVALID; + structs::InventorySlot_Struct LaurionSlot; + LaurionSlot.Type = invtype::TYPE_INVALID; + LaurionSlot.Slot = invslot::SLOT_INVALID; + LaurionSlot.SubIndex = invbag::SLOT_INVALID; + LaurionSlot.AugIndex = invaug::SOCKET_INVALID; uint32 TempSlot = EQ::invslot::SLOT_INVALID; if (server_slot < EQ::invtype::POSSESSIONS_SIZE) { - LarionSlot.Type = invtype::typePossessions; - LarionSlot.Slot = server_slot; + LaurionSlot.Type = invtype::typePossessions; + LaurionSlot.Slot = server_slot; } else if (server_slot <= EQ::invbag::CURSOR_BAG_END && server_slot >= EQ::invbag::GENERAL_BAGS_BEGIN) { TempSlot = server_slot - EQ::invbag::GENERAL_BAGS_BEGIN; - LarionSlot.Type = invtype::typePossessions; - LarionSlot.Slot = invslot::GENERAL_BEGIN + (TempSlot / EQ::invbag::SLOT_COUNT); - LarionSlot.SubIndex = TempSlot - ((LarionSlot.Slot - invslot::GENERAL_BEGIN) * EQ::invbag::SLOT_COUNT); + LaurionSlot.Type = invtype::typePossessions; + LaurionSlot.Slot = invslot::GENERAL_BEGIN + (TempSlot / EQ::invbag::SLOT_COUNT); + LaurionSlot.SubIndex = TempSlot - ((LaurionSlot.Slot - invslot::GENERAL_BEGIN) * EQ::invbag::SLOT_COUNT); } else if (server_slot <= EQ::invslot::TRIBUTE_END && server_slot >= EQ::invslot::TRIBUTE_BEGIN) { - LarionSlot.Type = invtype::typeTribute; - LarionSlot.Slot = server_slot - EQ::invslot::TRIBUTE_BEGIN; + LaurionSlot.Type = invtype::typeTribute; + LaurionSlot.Slot = server_slot - EQ::invslot::TRIBUTE_BEGIN; } else if (server_slot <= EQ::invslot::GUILD_TRIBUTE_END && server_slot >= EQ::invslot::GUILD_TRIBUTE_BEGIN) { - LarionSlot.Type = invtype::typeGuildTribute; - LarionSlot.Slot = server_slot - EQ::invslot::GUILD_TRIBUTE_BEGIN; + LaurionSlot.Type = invtype::typeGuildTribute; + LaurionSlot.Slot = server_slot - EQ::invslot::GUILD_TRIBUTE_BEGIN; } else if (server_slot == EQ::invslot::SLOT_TRADESKILL_EXPERIMENT_COMBINE) { - LarionSlot.Type = invtype::typeWorld; + LaurionSlot.Type = invtype::typeWorld; } else if (server_slot <= EQ::invslot::BANK_END && server_slot >= EQ::invslot::BANK_BEGIN) { - LarionSlot.Type = invtype::typeBank; - LarionSlot.Slot = server_slot - EQ::invslot::BANK_BEGIN; + LaurionSlot.Type = invtype::typeBank; + LaurionSlot.Slot = server_slot - EQ::invslot::BANK_BEGIN; } else if (server_slot <= EQ::invbag::BANK_BAGS_END && server_slot >= EQ::invbag::BANK_BAGS_BEGIN) { TempSlot = server_slot - EQ::invbag::BANK_BAGS_BEGIN; - LarionSlot.Type = invtype::typeBank; - LarionSlot.Slot = TempSlot / EQ::invbag::SLOT_COUNT; - LarionSlot.SubIndex = TempSlot - (LarionSlot.Slot * EQ::invbag::SLOT_COUNT); + LaurionSlot.Type = invtype::typeBank; + LaurionSlot.Slot = TempSlot / EQ::invbag::SLOT_COUNT; + LaurionSlot.SubIndex = TempSlot - (LaurionSlot.Slot * EQ::invbag::SLOT_COUNT); } else if (server_slot <= EQ::invslot::SHARED_BANK_END && server_slot >= EQ::invslot::SHARED_BANK_BEGIN) { - LarionSlot.Type = invtype::typeSharedBank; - LarionSlot.Slot = server_slot - EQ::invslot::SHARED_BANK_BEGIN; + LaurionSlot.Type = invtype::typeSharedBank; + LaurionSlot.Slot = server_slot - EQ::invslot::SHARED_BANK_BEGIN; } else if (server_slot <= EQ::invbag::SHARED_BANK_BAGS_END && server_slot >= EQ::invbag::SHARED_BANK_BAGS_BEGIN) { TempSlot = server_slot - EQ::invbag::SHARED_BANK_BAGS_BEGIN; - LarionSlot.Type = invtype::typeSharedBank; - LarionSlot.Slot = TempSlot / EQ::invbag::SLOT_COUNT; - LarionSlot.SubIndex = TempSlot - (LarionSlot.Slot * EQ::invbag::SLOT_COUNT); + LaurionSlot.Type = invtype::typeSharedBank; + LaurionSlot.Slot = TempSlot / EQ::invbag::SLOT_COUNT; + LaurionSlot.SubIndex = TempSlot - (LaurionSlot.Slot * EQ::invbag::SLOT_COUNT); } else if (server_slot <= EQ::invslot::TRADE_END && server_slot >= EQ::invslot::TRADE_BEGIN) { - LarionSlot.Type = invtype::typeTrade; - LarionSlot.Slot = server_slot - EQ::invslot::TRADE_BEGIN; + LaurionSlot.Type = invtype::typeTrade; + LaurionSlot.Slot = server_slot - EQ::invslot::TRADE_BEGIN; } else if (server_slot <= EQ::invbag::TRADE_BAGS_END && server_slot >= EQ::invbag::TRADE_BAGS_BEGIN) { TempSlot = server_slot - EQ::invbag::TRADE_BAGS_BEGIN; - LarionSlot.Type = invtype::typeTrade; - LarionSlot.Slot = TempSlot / EQ::invbag::SLOT_COUNT; - LarionSlot.SubIndex = TempSlot - (LarionSlot.Slot * EQ::invbag::SLOT_COUNT); + LaurionSlot.Type = invtype::typeTrade; + LaurionSlot.Slot = TempSlot / EQ::invbag::SLOT_COUNT; + LaurionSlot.SubIndex = TempSlot - (LaurionSlot.Slot * EQ::invbag::SLOT_COUNT); } else if (server_slot <= EQ::invslot::WORLD_END && server_slot >= EQ::invslot::WORLD_BEGIN) { - LarionSlot.Type = invtype::typeWorld; - LarionSlot.Slot = server_slot - EQ::invslot::WORLD_BEGIN; + LaurionSlot.Type = invtype::typeWorld; + LaurionSlot.Slot = server_slot - EQ::invslot::WORLD_BEGIN; } - Log(Logs::Detail, Logs::Netcode, "Convert Server Slot %i to Larion Slot [%i, %i, %i, %i]", - server_slot, LarionSlot.Type, LarionSlot.Slot, LarionSlot.SubIndex, LarionSlot.AugIndex); + Log(Logs::Detail, Logs::Netcode, "Convert Server Slot %i to Laurion Slot [%i, %i, %i, %i]", + server_slot, LaurionSlot.Type, LaurionSlot.Slot, LaurionSlot.SubIndex, LaurionSlot.AugIndex); - return LarionSlot; + return LaurionSlot; } - static inline structs::InventorySlot_Struct ServerToLarionCorpseSlot(uint32 server_corpse_slot) + static inline structs::InventorySlot_Struct ServerToLaurionCorpseSlot(uint32 server_corpse_slot) { - structs::InventorySlot_Struct LarionSlot; - LarionSlot.Type = invtype::TYPE_INVALID; - LarionSlot.Slot = ServerToLarionCorpseMainSlot(server_corpse_slot); - LarionSlot.SubIndex = invbag::SLOT_INVALID; - LarionSlot.AugIndex = invaug::SOCKET_INVALID; + structs::InventorySlot_Struct LaurionSlot; + LaurionSlot.Type = invtype::TYPE_INVALID; + LaurionSlot.Slot = ServerToLaurionCorpseMainSlot(server_corpse_slot); + LaurionSlot.SubIndex = invbag::SLOT_INVALID; + LaurionSlot.AugIndex = invaug::SOCKET_INVALID; - if (LarionSlot.Slot != invslot::SLOT_INVALID) - LarionSlot.Type = invtype::typeCorpse; + if (LaurionSlot.Slot != invslot::SLOT_INVALID) + LaurionSlot.Type = invtype::typeCorpse; - Log(Logs::Detail, Logs::Netcode, "Convert Server Corpse Slot %i to Larion Corpse Slot [%i, %i, %i, %i]", - server_corpse_slot, LarionSlot.Type, LarionSlot.Slot, LarionSlot.SubIndex, LarionSlot.AugIndex); + Log(Logs::Detail, Logs::Netcode, "Convert Server Corpse Slot %i to Laurion Corpse Slot [%i, %i, %i, %i]", + server_corpse_slot, LaurionSlot.Type, LaurionSlot.Slot, LaurionSlot.SubIndex, LaurionSlot.AugIndex); - return LarionSlot; + return LaurionSlot; } - static inline uint32 ServerToLarionCorpseMainSlot(uint32 server_corpse_slot) + static inline uint32 ServerToLaurionCorpseMainSlot(uint32 server_corpse_slot) { - uint32 LarionSlot = invslot::SLOT_INVALID; + uint32 LaurionSlot = invslot::SLOT_INVALID; if (server_corpse_slot <= EQ::invslot::CORPSE_END && server_corpse_slot >= EQ::invslot::CORPSE_BEGIN) { - LarionSlot = server_corpse_slot; + LaurionSlot = server_corpse_slot; } - LogNetcode("Convert Server Corpse Slot [{}] to Larion Corpse Main Slot [{}]", server_corpse_slot, LarionSlot); + LogNetcode("Convert Server Corpse Slot [{}] to Laurion Corpse Main Slot [{}]", server_corpse_slot, LaurionSlot); - return LarionSlot; + return LaurionSlot; } - static inline structs::TypelessInventorySlot_Struct ServerToLarionTypelessSlot(uint32 server_slot, int16 server_type) + static inline structs::TypelessInventorySlot_Struct ServerToLaurionTypelessSlot(uint32 server_slot, int16 server_type) { - structs::TypelessInventorySlot_Struct LarionSlot; - LarionSlot.Slot = invslot::SLOT_INVALID; - LarionSlot.SubIndex = invbag::SLOT_INVALID; - LarionSlot.AugIndex = invaug::SOCKET_INVALID; + structs::TypelessInventorySlot_Struct LaurionSlot; + LaurionSlot.Slot = invslot::SLOT_INVALID; + LaurionSlot.SubIndex = invbag::SLOT_INVALID; + LaurionSlot.AugIndex = invaug::SOCKET_INVALID; uint32 TempSlot = EQ::invslot::SLOT_INVALID; if (server_type == EQ::invtype::typePossessions) { if (server_slot < EQ::invtype::POSSESSIONS_SIZE) { - LarionSlot.Slot = server_slot; + LaurionSlot.Slot = server_slot; } else if (server_slot <= EQ::invbag::CURSOR_BAG_END && server_slot >= EQ::invbag::GENERAL_BAGS_BEGIN) { TempSlot = server_slot - EQ::invbag::GENERAL_BAGS_BEGIN; - LarionSlot.Slot = invslot::GENERAL_BEGIN + (TempSlot / EQ::invbag::SLOT_COUNT); - LarionSlot.SubIndex = TempSlot - ((LarionSlot.Slot - invslot::GENERAL_BEGIN) * EQ::invbag::SLOT_COUNT); + LaurionSlot.Slot = invslot::GENERAL_BEGIN + (TempSlot / EQ::invbag::SLOT_COUNT); + LaurionSlot.SubIndex = TempSlot - ((LaurionSlot.Slot - invslot::GENERAL_BEGIN) * EQ::invbag::SLOT_COUNT); } } - Log(Logs::Detail, Logs::Netcode, "Convert Server Slot %i to Larion Typeless Slot [%i, %i, %i] (implied type: %i)", - server_slot, LarionSlot.Slot, LarionSlot.SubIndex, LarionSlot.AugIndex, server_type); + Log(Logs::Detail, Logs::Netcode, "Convert Server Slot %i to Laurion Typeless Slot [%i, %i, %i] (implied type: %i)", + server_slot, LaurionSlot.Slot, LaurionSlot.SubIndex, LaurionSlot.AugIndex, server_type); - return LarionSlot; + return LaurionSlot; } - static inline uint32 LarionToServerSlot(structs::InventorySlot_Struct larion_slot) + static inline uint32 LaurionToServerSlot(structs::InventorySlot_Struct laurion_slot) { - if (larion_slot.AugIndex < invaug::SOCKET_INVALID || larion_slot.AugIndex >= invaug::SOCKET_COUNT) { - Log(Logs::Detail, Logs::Netcode, "Convert Larion Slot [%i, %i, %i, %i] to Server Slot %i", - larion_slot.Type, larion_slot.Slot, larion_slot.SubIndex, larion_slot.AugIndex, EQ::invslot::SLOT_INVALID); + if (laurion_slot.AugIndex < invaug::SOCKET_INVALID || laurion_slot.AugIndex >= invaug::SOCKET_COUNT) { + Log(Logs::Detail, Logs::Netcode, "Convert Laurion Slot [%i, %i, %i, %i] to Server Slot %i", + laurion_slot.Type, laurion_slot.Slot, laurion_slot.SubIndex, laurion_slot.AugIndex, EQ::invslot::SLOT_INVALID); return EQ::invslot::SLOT_INVALID; } @@ -3656,101 +3656,101 @@ namespace Larion uint32 server_slot = EQ::invslot::SLOT_INVALID; uint32 temp_slot = invslot::SLOT_INVALID; - switch (larion_slot.Type) { + switch (laurion_slot.Type) { case invtype::typePossessions: { - if (larion_slot.Slot >= invslot::POSSESSIONS_BEGIN && larion_slot.Slot <= invslot::POSSESSIONS_END) { - if (larion_slot.SubIndex == invbag::SLOT_INVALID) { - server_slot = larion_slot.Slot; + if (laurion_slot.Slot >= invslot::POSSESSIONS_BEGIN && laurion_slot.Slot <= invslot::POSSESSIONS_END) { + if (laurion_slot.SubIndex == invbag::SLOT_INVALID) { + server_slot = laurion_slot.Slot; } - else if (larion_slot.SubIndex >= invbag::SLOT_BEGIN && larion_slot.SubIndex <= invbag::SLOT_END) { - if (larion_slot.Slot < invslot::GENERAL_BEGIN) + else if (laurion_slot.SubIndex >= invbag::SLOT_BEGIN && laurion_slot.SubIndex <= invbag::SLOT_END) { + if (laurion_slot.Slot < invslot::GENERAL_BEGIN) return EQ::invslot::SLOT_INVALID; - temp_slot = (larion_slot.Slot - invslot::GENERAL_BEGIN) * invbag::SLOT_COUNT; - server_slot = EQ::invbag::GENERAL_BAGS_BEGIN + temp_slot + larion_slot.SubIndex; + temp_slot = (laurion_slot.Slot - invslot::GENERAL_BEGIN) * invbag::SLOT_COUNT; + server_slot = EQ::invbag::GENERAL_BAGS_BEGIN + temp_slot + laurion_slot.SubIndex; } } break; } case invtype::typeBank: { - if (larion_slot.Slot >= invslot::SLOT_BEGIN && larion_slot.Slot < invtype::BANK_SIZE) { - if (larion_slot.SubIndex == invbag::SLOT_INVALID) { - server_slot = EQ::invslot::BANK_BEGIN + larion_slot.Slot; + if (laurion_slot.Slot >= invslot::SLOT_BEGIN && laurion_slot.Slot < invtype::BANK_SIZE) { + if (laurion_slot.SubIndex == invbag::SLOT_INVALID) { + server_slot = EQ::invslot::BANK_BEGIN + laurion_slot.Slot; } - else if (larion_slot.SubIndex >= invbag::SLOT_BEGIN && larion_slot.SubIndex <= invbag::SLOT_END) { - temp_slot = larion_slot.Slot * invbag::SLOT_COUNT; - server_slot = EQ::invbag::BANK_BAGS_BEGIN + temp_slot + larion_slot.SubIndex; + else if (laurion_slot.SubIndex >= invbag::SLOT_BEGIN && laurion_slot.SubIndex <= invbag::SLOT_END) { + temp_slot = laurion_slot.Slot * invbag::SLOT_COUNT; + server_slot = EQ::invbag::BANK_BAGS_BEGIN + temp_slot + laurion_slot.SubIndex; } } break; } case invtype::typeSharedBank: { - if (larion_slot.Slot >= invslot::SLOT_BEGIN && larion_slot.Slot < invtype::SHARED_BANK_SIZE) { - if (larion_slot.SubIndex == invbag::SLOT_INVALID) { - server_slot = EQ::invslot::SHARED_BANK_BEGIN + larion_slot.Slot; + if (laurion_slot.Slot >= invslot::SLOT_BEGIN && laurion_slot.Slot < invtype::SHARED_BANK_SIZE) { + if (laurion_slot.SubIndex == invbag::SLOT_INVALID) { + server_slot = EQ::invslot::SHARED_BANK_BEGIN + laurion_slot.Slot; } - else if (larion_slot.SubIndex >= invbag::SLOT_BEGIN && larion_slot.SubIndex <= invbag::SLOT_END) { - temp_slot = larion_slot.Slot * invbag::SLOT_COUNT; - server_slot = EQ::invbag::SHARED_BANK_BAGS_BEGIN + temp_slot + larion_slot.SubIndex; + else if (laurion_slot.SubIndex >= invbag::SLOT_BEGIN && laurion_slot.SubIndex <= invbag::SLOT_END) { + temp_slot = laurion_slot.Slot * invbag::SLOT_COUNT; + server_slot = EQ::invbag::SHARED_BANK_BAGS_BEGIN + temp_slot + laurion_slot.SubIndex; } } break; } case invtype::typeTrade: { - if (larion_slot.Slot >= invslot::SLOT_BEGIN && larion_slot.Slot < invtype::TRADE_SIZE) { - if (larion_slot.SubIndex == invbag::SLOT_INVALID) { - server_slot = EQ::invslot::TRADE_BEGIN + larion_slot.Slot; + if (laurion_slot.Slot >= invslot::SLOT_BEGIN && laurion_slot.Slot < invtype::TRADE_SIZE) { + if (laurion_slot.SubIndex == invbag::SLOT_INVALID) { + server_slot = EQ::invslot::TRADE_BEGIN + laurion_slot.Slot; } - else if (larion_slot.SubIndex >= invbag::SLOT_BEGIN && larion_slot.SubIndex <= invbag::SLOT_END) { - temp_slot = larion_slot.Slot * invbag::SLOT_COUNT; - server_slot = EQ::invbag::TRADE_BAGS_BEGIN + temp_slot + larion_slot.SubIndex; + else if (laurion_slot.SubIndex >= invbag::SLOT_BEGIN && laurion_slot.SubIndex <= invbag::SLOT_END) { + temp_slot = laurion_slot.Slot * invbag::SLOT_COUNT; + server_slot = EQ::invbag::TRADE_BAGS_BEGIN + temp_slot + laurion_slot.SubIndex; } } break; } case invtype::typeWorld: { - if (larion_slot.Slot >= invslot::SLOT_BEGIN && larion_slot.Slot < invtype::WORLD_SIZE) { - server_slot = EQ::invslot::WORLD_BEGIN + larion_slot.Slot; + if (laurion_slot.Slot >= invslot::SLOT_BEGIN && laurion_slot.Slot < invtype::WORLD_SIZE) { + server_slot = EQ::invslot::WORLD_BEGIN + laurion_slot.Slot; } - else if (larion_slot.Slot == invslot::SLOT_INVALID) { + else if (laurion_slot.Slot == invslot::SLOT_INVALID) { server_slot = EQ::invslot::SLOT_TRADESKILL_EXPERIMENT_COMBINE; } break; } case invtype::typeLimbo: { - if (larion_slot.Slot >= invslot::SLOT_BEGIN && larion_slot.Slot < invtype::LIMBO_SIZE) { + if (laurion_slot.Slot >= invslot::SLOT_BEGIN && laurion_slot.Slot < invtype::LIMBO_SIZE) { server_slot = EQ::invslot::slotCursor; } break; } case invtype::typeTribute: { - if (larion_slot.Slot >= invslot::SLOT_BEGIN && larion_slot.Slot < invtype::TRIBUTE_SIZE) { - server_slot = EQ::invslot::TRIBUTE_BEGIN + larion_slot.Slot; + if (laurion_slot.Slot >= invslot::SLOT_BEGIN && laurion_slot.Slot < invtype::TRIBUTE_SIZE) { + server_slot = EQ::invslot::TRIBUTE_BEGIN + laurion_slot.Slot; } break; } case invtype::typeGuildTribute: { - if (larion_slot.Slot >= invslot::SLOT_BEGIN && larion_slot.Slot < invtype::GUILD_TRIBUTE_SIZE) { - server_slot = EQ::invslot::GUILD_TRIBUTE_BEGIN + larion_slot.Slot; + if (laurion_slot.Slot >= invslot::SLOT_BEGIN && laurion_slot.Slot < invtype::GUILD_TRIBUTE_SIZE) { + server_slot = EQ::invslot::GUILD_TRIBUTE_BEGIN + laurion_slot.Slot; } break; } case invtype::typeCorpse: { - if (larion_slot.Slot >= invslot::CORPSE_BEGIN && larion_slot.Slot <= invslot::CORPSE_END) { - server_slot = larion_slot.Slot; + if (laurion_slot.Slot >= invslot::CORPSE_BEGIN && laurion_slot.Slot <= invslot::CORPSE_END) { + server_slot = laurion_slot.Slot; } break; @@ -3761,48 +3761,48 @@ namespace Larion } } - Log(Logs::Detail, Logs::Netcode, "Convert Larion Slot [%i, %i, %i, %i] to Server Slot %i", - larion_slot.Type, larion_slot.Slot, larion_slot.SubIndex, larion_slot.AugIndex, server_slot); + Log(Logs::Detail, Logs::Netcode, "Convert Laurion Slot [%i, %i, %i, %i] to Server Slot %i", + laurion_slot.Type, laurion_slot.Slot, laurion_slot.SubIndex, laurion_slot.AugIndex, server_slot); return server_slot; } - static inline uint32 LarionToServerCorpseSlot(structs::InventorySlot_Struct larion_corpse_slot) + static inline uint32 LaurionToServerCorpseSlot(structs::InventorySlot_Struct laurion_corpse_slot) { uint32 ServerSlot = EQ::invslot::SLOT_INVALID; - if (larion_corpse_slot.Type != invtype::typeCorpse || larion_corpse_slot.SubIndex != invbag::SLOT_INVALID || larion_corpse_slot.AugIndex != invaug::SOCKET_INVALID) { + if (laurion_corpse_slot.Type != invtype::typeCorpse || laurion_corpse_slot.SubIndex != invbag::SLOT_INVALID || laurion_corpse_slot.AugIndex != invaug::SOCKET_INVALID) { ServerSlot = EQ::invslot::SLOT_INVALID; } else { - ServerSlot = LarionToServerCorpseMainSlot(larion_corpse_slot.Slot); + ServerSlot = LaurionToServerCorpseMainSlot(laurion_corpse_slot.Slot); } - Log(Logs::Detail, Logs::Netcode, "Convert Larion Slot [%i, %i, %i, %i] to Server Slot %i", - larion_corpse_slot.Type, larion_corpse_slot.Slot, larion_corpse_slot.SubIndex, larion_corpse_slot.AugIndex, ServerSlot); + Log(Logs::Detail, Logs::Netcode, "Convert Laurion Slot [%i, %i, %i, %i] to Server Slot %i", + laurion_corpse_slot.Type, laurion_corpse_slot.Slot, laurion_corpse_slot.SubIndex, laurion_corpse_slot.AugIndex, ServerSlot); return ServerSlot; } - static inline uint32 LarionToServerCorpseMainSlot(uint32 larion_corpse_slot) + static inline uint32 LaurionToServerCorpseMainSlot(uint32 laurion_corpse_slot) { uint32 ServerSlot = EQ::invslot::SLOT_INVALID; - if (larion_corpse_slot <= invslot::CORPSE_END && larion_corpse_slot >= invslot::CORPSE_BEGIN) { - ServerSlot = larion_corpse_slot; + if (laurion_corpse_slot <= invslot::CORPSE_END && laurion_corpse_slot >= invslot::CORPSE_BEGIN) { + ServerSlot = laurion_corpse_slot; } - LogNetcode("Convert Larion Corpse Main Slot [{}] to Server Corpse Slot [{}]", larion_corpse_slot, ServerSlot); + LogNetcode("Convert Laurion Corpse Main Slot [{}] to Server Corpse Slot [{}]", laurion_corpse_slot, ServerSlot); return ServerSlot; } - static inline uint32 LarionToServerTypelessSlot(structs::TypelessInventorySlot_Struct larion_slot, int16 larion_type) + static inline uint32 LaurionToServerTypelessSlot(structs::TypelessInventorySlot_Struct laurion_slot, int16 laurion_type) { - if (larion_slot.AugIndex < invaug::SOCKET_INVALID || larion_slot.AugIndex >= invaug::SOCKET_COUNT) { - Log(Logs::Detail, Logs::Netcode, "Convert Larion Typeless Slot [%i, %i, %i] (implied type: %i) to Server Slot %i", - larion_slot.Slot, larion_slot.SubIndex, larion_slot.AugIndex, larion_type, EQ::invslot::SLOT_INVALID); + if (laurion_slot.AugIndex < invaug::SOCKET_INVALID || laurion_slot.AugIndex >= invaug::SOCKET_COUNT) { + Log(Logs::Detail, Logs::Netcode, "Convert Laurion Typeless Slot [%i, %i, %i] (implied type: %i) to Server Slot %i", + laurion_slot.Slot, laurion_slot.SubIndex, laurion_slot.AugIndex, laurion_type, EQ::invslot::SLOT_INVALID); return EQ::invslot::SLOT_INVALID; } @@ -3810,101 +3810,101 @@ namespace Larion uint32 ServerSlot = EQ::invslot::SLOT_INVALID; uint32 TempSlot = invslot::SLOT_INVALID; - switch (larion_type) { + switch (laurion_type) { case invtype::typePossessions: { - if (larion_slot.Slot >= invslot::POSSESSIONS_BEGIN && larion_slot.Slot <= invslot::POSSESSIONS_END) { - if (larion_slot.SubIndex == invbag::SLOT_INVALID) { - ServerSlot = larion_slot.Slot; + if (laurion_slot.Slot >= invslot::POSSESSIONS_BEGIN && laurion_slot.Slot <= invslot::POSSESSIONS_END) { + if (laurion_slot.SubIndex == invbag::SLOT_INVALID) { + ServerSlot = laurion_slot.Slot; } - else if (larion_slot.SubIndex >= invbag::SLOT_BEGIN && larion_slot.SubIndex <= invbag::SLOT_END) { - if (larion_slot.Slot < invslot::GENERAL_BEGIN) + else if (laurion_slot.SubIndex >= invbag::SLOT_BEGIN && laurion_slot.SubIndex <= invbag::SLOT_END) { + if (laurion_slot.Slot < invslot::GENERAL_BEGIN) return EQ::invslot::SLOT_INVALID; - TempSlot = (larion_slot.Slot - invslot::GENERAL_BEGIN) * invbag::SLOT_COUNT; - ServerSlot = EQ::invbag::GENERAL_BAGS_BEGIN + TempSlot + larion_slot.SubIndex; + TempSlot = (laurion_slot.Slot - invslot::GENERAL_BEGIN) * invbag::SLOT_COUNT; + ServerSlot = EQ::invbag::GENERAL_BAGS_BEGIN + TempSlot + laurion_slot.SubIndex; } } break; } case invtype::typeBank: { - if (larion_slot.Slot >= invslot::SLOT_BEGIN && larion_slot.Slot < invtype::BANK_SIZE) { - if (larion_slot.SubIndex == invbag::SLOT_INVALID) { - ServerSlot = EQ::invslot::BANK_BEGIN + larion_slot.Slot; + if (laurion_slot.Slot >= invslot::SLOT_BEGIN && laurion_slot.Slot < invtype::BANK_SIZE) { + if (laurion_slot.SubIndex == invbag::SLOT_INVALID) { + ServerSlot = EQ::invslot::BANK_BEGIN + laurion_slot.Slot; } - else if (larion_slot.SubIndex >= invbag::SLOT_BEGIN && larion_slot.SubIndex <= invbag::SLOT_END) { - TempSlot = larion_slot.Slot * invbag::SLOT_COUNT; - ServerSlot = EQ::invbag::BANK_BAGS_BEGIN + TempSlot + larion_slot.SubIndex; + else if (laurion_slot.SubIndex >= invbag::SLOT_BEGIN && laurion_slot.SubIndex <= invbag::SLOT_END) { + TempSlot = laurion_slot.Slot * invbag::SLOT_COUNT; + ServerSlot = EQ::invbag::BANK_BAGS_BEGIN + TempSlot + laurion_slot.SubIndex; } } break; } case invtype::typeSharedBank: { - if (larion_slot.Slot >= invslot::SLOT_BEGIN && larion_slot.Slot < invtype::SHARED_BANK_SIZE) { - if (larion_slot.SubIndex == invbag::SLOT_INVALID) { - ServerSlot = EQ::invslot::SHARED_BANK_BEGIN + larion_slot.Slot; + if (laurion_slot.Slot >= invslot::SLOT_BEGIN && laurion_slot.Slot < invtype::SHARED_BANK_SIZE) { + if (laurion_slot.SubIndex == invbag::SLOT_INVALID) { + ServerSlot = EQ::invslot::SHARED_BANK_BEGIN + laurion_slot.Slot; } - else if (larion_slot.SubIndex >= invbag::SLOT_BEGIN && larion_slot.SubIndex <= invbag::SLOT_END) { - TempSlot = larion_slot.Slot * invbag::SLOT_COUNT; - ServerSlot = EQ::invbag::SHARED_BANK_BAGS_BEGIN + TempSlot + larion_slot.SubIndex; + else if (laurion_slot.SubIndex >= invbag::SLOT_BEGIN && laurion_slot.SubIndex <= invbag::SLOT_END) { + TempSlot = laurion_slot.Slot * invbag::SLOT_COUNT; + ServerSlot = EQ::invbag::SHARED_BANK_BAGS_BEGIN + TempSlot + laurion_slot.SubIndex; } } break; } case invtype::typeTrade: { - if (larion_slot.Slot >= invslot::SLOT_BEGIN && larion_slot.Slot < invtype::TRADE_SIZE) { - if (larion_slot.SubIndex == invbag::SLOT_INVALID) { - ServerSlot = EQ::invslot::TRADE_BEGIN + larion_slot.Slot; + if (laurion_slot.Slot >= invslot::SLOT_BEGIN && laurion_slot.Slot < invtype::TRADE_SIZE) { + if (laurion_slot.SubIndex == invbag::SLOT_INVALID) { + ServerSlot = EQ::invslot::TRADE_BEGIN + laurion_slot.Slot; } - else if (larion_slot.SubIndex >= invbag::SLOT_BEGIN && larion_slot.SubIndex <= invbag::SLOT_END) { - TempSlot = larion_slot.Slot * invbag::SLOT_COUNT; - ServerSlot = EQ::invbag::TRADE_BAGS_BEGIN + TempSlot + larion_slot.SubIndex; + else if (laurion_slot.SubIndex >= invbag::SLOT_BEGIN && laurion_slot.SubIndex <= invbag::SLOT_END) { + TempSlot = laurion_slot.Slot * invbag::SLOT_COUNT; + ServerSlot = EQ::invbag::TRADE_BAGS_BEGIN + TempSlot + laurion_slot.SubIndex; } } break; } case invtype::typeWorld: { - if (larion_slot.Slot >= invslot::SLOT_BEGIN && larion_slot.Slot < invtype::WORLD_SIZE) { - ServerSlot = EQ::invslot::WORLD_BEGIN + larion_slot.Slot; + if (laurion_slot.Slot >= invslot::SLOT_BEGIN && laurion_slot.Slot < invtype::WORLD_SIZE) { + ServerSlot = EQ::invslot::WORLD_BEGIN + laurion_slot.Slot; } - else if (larion_slot.Slot == invslot::SLOT_INVALID) { + else if (laurion_slot.Slot == invslot::SLOT_INVALID) { ServerSlot = EQ::invslot::SLOT_TRADESKILL_EXPERIMENT_COMBINE; } break; } case invtype::typeLimbo: { - if (larion_slot.Slot >= invslot::SLOT_BEGIN && larion_slot.Slot < invtype::LIMBO_SIZE) { + if (laurion_slot.Slot >= invslot::SLOT_BEGIN && laurion_slot.Slot < invtype::LIMBO_SIZE) { ServerSlot = EQ::invslot::slotCursor; } break; } case invtype::typeTribute: { - if (larion_slot.Slot >= invslot::SLOT_BEGIN && larion_slot.Slot < invtype::TRIBUTE_SIZE) { - ServerSlot = EQ::invslot::TRIBUTE_BEGIN + larion_slot.Slot; + if (laurion_slot.Slot >= invslot::SLOT_BEGIN && laurion_slot.Slot < invtype::TRIBUTE_SIZE) { + ServerSlot = EQ::invslot::TRIBUTE_BEGIN + laurion_slot.Slot; } break; } case invtype::typeGuildTribute: { - if (larion_slot.Slot >= invslot::SLOT_BEGIN && larion_slot.Slot < invtype::GUILD_TRIBUTE_SIZE) { - ServerSlot = EQ::invslot::GUILD_TRIBUTE_BEGIN + larion_slot.Slot; + if (laurion_slot.Slot >= invslot::SLOT_BEGIN && laurion_slot.Slot < invtype::GUILD_TRIBUTE_SIZE) { + ServerSlot = EQ::invslot::GUILD_TRIBUTE_BEGIN + laurion_slot.Slot; } break; } case invtype::typeCorpse: { - if (larion_slot.Slot >= invslot::CORPSE_BEGIN && larion_slot.Slot <= invslot::CORPSE_END) { - ServerSlot = larion_slot.Slot; + if (laurion_slot.Slot >= invslot::CORPSE_BEGIN && laurion_slot.Slot <= invslot::CORPSE_END) { + ServerSlot = laurion_slot.Slot; } break; @@ -3915,9 +3915,9 @@ namespace Larion } } - Log(Logs::Detail, Logs::Netcode, "Convert Larion Typeless Slot [%i, %i, %i] (implied type: %i) to Server Slot %i", - larion_slot.Slot, larion_slot.SubIndex, larion_slot.AugIndex, larion_type, ServerSlot); + Log(Logs::Detail, Logs::Netcode, "Convert Laurion Typeless Slot [%i, %i, %i] (implied type: %i) to Server Slot %i", + laurion_slot.Slot, laurion_slot.SubIndex, laurion_slot.AugIndex, laurion_type, ServerSlot); return ServerSlot; } -} /*Larion*/ +} /*Laurion*/ diff --git a/common/patches/larion.h b/common/patches/laurion.h similarity index 91% rename from common/patches/larion.h rename to common/patches/laurion.h index 7d7b83e32..f378e9e05 100644 --- a/common/patches/larion.h +++ b/common/patches/laurion.h @@ -17,14 +17,14 @@ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ -#ifndef COMMON_LARION_H -#define COMMON_LARION_H +#ifndef COMMON_LAURION_H +#define COMMON_LAURION_H #include "../struct_strategy.h" class EQStreamIdentifier; -namespace Larion +namespace Laurion { //these are the only public member of this namespace. @@ -47,9 +47,9 @@ namespace Larion //magic macro to declare our opcode processors #include "ss_declare.h" -#include "larion_ops.h" +#include "laurion_ops.h" }; -}; /*Larion*/ +}; /*Laurion*/ -#endif /*COMMON_LARION_H*/ +#endif /*COMMON_LAURION_H*/ diff --git a/common/patches/larion_limits.cpp b/common/patches/laurion_limits.cpp similarity index 93% rename from common/patches/larion_limits.cpp rename to common/patches/laurion_limits.cpp index 49ea7a396..9716d083b 100644 --- a/common/patches/larion_limits.cpp +++ b/common/patches/laurion_limits.cpp @@ -17,12 +17,12 @@ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ -#include "larion_limits.h" +#include "laurion_limits.h" #include "../strings.h" -int16 Larion::invtype::GetInvTypeSize(int16 inv_type) +int16 Laurion::invtype::GetInvTypeSize(int16 inv_type) { switch (inv_type) { case invtype::typePossessions: @@ -80,7 +80,7 @@ int16 Larion::invtype::GetInvTypeSize(int16 inv_type) } } -const char* Larion::invtype::GetInvTypeName(int16 inv_type) +const char* Laurion::invtype::GetInvTypeName(int16 inv_type) { switch (inv_type) { case invtype::TYPE_INVALID: @@ -140,7 +140,7 @@ const char* Larion::invtype::GetInvTypeName(int16 inv_type) } } -bool Larion::invtype::IsInvTypePersistent(int16 inv_type) +bool Laurion::invtype::IsInvTypePersistent(int16 inv_type) { switch (inv_type) { case invtype::typePossessions: @@ -158,7 +158,7 @@ bool Larion::invtype::IsInvTypePersistent(int16 inv_type) } } -const char* Larion::invslot::GetInvPossessionsSlotName(int16 inv_slot) +const char* Laurion::invslot::GetInvPossessionsSlotName(int16 inv_slot) { switch (inv_slot) { case invslot::SLOT_INVALID: @@ -236,7 +236,7 @@ const char* Larion::invslot::GetInvPossessionsSlotName(int16 inv_slot) } } -const char* Larion::invslot::GetInvSlotName(int16 inv_type, int16 inv_slot) +const char* Laurion::invslot::GetInvSlotName(int16 inv_type, int16 inv_slot) { if (inv_type == invtype::typePossessions) return invslot::GetInvPossessionsSlotName(inv_slot); @@ -255,7 +255,7 @@ const char* Larion::invslot::GetInvSlotName(int16 inv_type, int16 inv_slot) return ret_str.c_str(); } -const char* Larion::invbag::GetInvBagIndexName(int16 bag_index) +const char* Laurion::invbag::GetInvBagIndexName(int16 bag_index) { if (bag_index == invbag::SLOT_INVALID) return "Invalid Bag"; @@ -269,7 +269,7 @@ const char* Larion::invbag::GetInvBagIndexName(int16 bag_index) return ret_str.c_str(); } -const char* Larion::invaug::GetInvAugIndexName(int16 aug_index) +const char* Laurion::invaug::GetInvAugIndexName(int16 aug_index) { if (aug_index == invaug::SOCKET_INVALID) return "Invalid Augment"; diff --git a/common/patches/larion_limits.h b/common/patches/laurion_limits.h similarity index 94% rename from common/patches/larion_limits.h rename to common/patches/laurion_limits.h index c1cfca615..f5035c06c 100644 --- a/common/patches/larion_limits.h +++ b/common/patches/laurion_limits.h @@ -17,20 +17,20 @@ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ -#ifndef COMMON_LARION_LIMITS_H -#define COMMON_LARION_LIMITS_H +#ifndef COMMON_LAURION_LIMITS_H +#define COMMON_LAURION_LIMITS_H #include "../types.h" #include "../emu_versions.h" #include "../skills.h" -namespace Larion +namespace Laurion { const int16 IINVALID = -1; const int16 INULL = 0; namespace inventory { - inline EQ::versions::ClientVersion GetInventoryRef() { return EQ::versions::ClientVersion::Larion; } + inline EQ::versions::ClientVersion GetInventoryRef() { return EQ::versions::ClientVersion::Laurion; } const bool ConcatenateInvTypeLimbo = false; @@ -42,7 +42,7 @@ namespace Larion } /*inventory*/ namespace invtype { - inline EQ::versions::ClientVersion GetInvTypeRef() { return EQ::versions::ClientVersion::Larion; } + inline EQ::versions::ClientVersion GetInvTypeRef() { return EQ::versions::ClientVersion::Laurion; } namespace enum_ { enum InventoryTypes : int16 { @@ -133,7 +133,7 @@ namespace Larion } /*invtype*/ namespace invslot { - inline EQ::versions::ClientVersion GetInvSlotRef() { return EQ::versions::ClientVersion::Larion; } + inline EQ::versions::ClientVersion GetInvSlotRef() { return EQ::versions::ClientVersion::Laurion; } namespace enum_ { enum InventorySlots : int16 { @@ -212,7 +212,7 @@ namespace Larion } /*invslot*/ namespace invbag { - inline EQ::versions::ClientVersion GetInvBagRef() { return EQ::versions::ClientVersion::Larion; } + inline EQ::versions::ClientVersion GetInvBagRef() { return EQ::versions::ClientVersion::Laurion; } const int16 SLOT_INVALID = IINVALID; const int16 SLOT_BEGIN = INULL; @@ -224,7 +224,7 @@ namespace Larion } /*invbag*/ namespace invaug { - inline EQ::versions::ClientVersion GetInvAugRef() { return EQ::versions::ClientVersion::Larion; } + inline EQ::versions::ClientVersion GetInvAugRef() { return EQ::versions::ClientVersion::Laurion; } const int16 SOCKET_INVALID = IINVALID; const int16 SOCKET_BEGIN = INULL; @@ -236,7 +236,7 @@ namespace Larion } /*invaug*/ namespace item { - inline EQ::versions::ClientVersion GetItemRef() { return EQ::versions::ClientVersion::Larion; } + inline EQ::versions::ClientVersion GetItemRef() { return EQ::versions::ClientVersion::Laurion; } //enum Unknown : int { // looks like item class..but, RoF has it too - nothing in UF- // Unknown1 = 0, @@ -265,7 +265,7 @@ namespace Larion } /*item*/ namespace profile { - inline EQ::versions::ClientVersion GetProfileRef() { return EQ::versions::ClientVersion::Larion; } + inline EQ::versions::ClientVersion GetProfileRef() { return EQ::versions::ClientVersion::Laurion; } const int16 BANDOLIERS_SIZE = 20; // number of bandolier instances const int16 BANDOLIER_ITEM_COUNT = 4; // number of equipment slots in bandolier instance @@ -277,7 +277,7 @@ namespace Larion } /*profile*/ namespace constants { - inline EQ::versions::ClientVersion GetConstantsRef() { return EQ::versions::ClientVersion::Larion; } + inline EQ::versions::ClientVersion GetConstantsRef() { return EQ::versions::ClientVersion::Laurion; } const EQ::expansions::Expansion EXPANSION = EQ::expansions::Expansion::LS; const uint32 EXPANSION_BIT = EQ::expansions::bitLS; @@ -291,21 +291,21 @@ namespace Larion } /*constants*/ namespace behavior { - inline EQ::versions::ClientVersion GetBehaviorRef() { return EQ::versions::ClientVersion::Larion; } + inline EQ::versions::ClientVersion GetBehaviorRef() { return EQ::versions::ClientVersion::Laurion; } const bool CoinHasWeight = false; } /*behavior*/ namespace skills { - inline EQ::versions::ClientVersion GetSkillsRef() { return EQ::versions::ClientVersion::Larion; } + inline EQ::versions::ClientVersion GetSkillsRef() { return EQ::versions::ClientVersion::Laurion; } const size_t LastUsableSkill = EQ::skills::Skill2HPiercing; } /*skills*/ namespace spells { - inline EQ::versions::ClientVersion GetSkillsRef() { return EQ::versions::ClientVersion::Larion; } + inline EQ::versions::ClientVersion GetSkillsRef() { return EQ::versions::ClientVersion::Laurion; } enum class CastingSlot : uint32 { Gem1 = 0, @@ -341,6 +341,6 @@ namespace Larion } /*spells*/ -}; /* Larion */ +}; /* Laurion */ -#endif /*COMMON_LARION_LIMITS_H*/ +#endif /*COMMON_LAURION_LIMITS_H*/ diff --git a/common/patches/larion_ops.h b/common/patches/laurion_ops.h similarity index 100% rename from common/patches/larion_ops.h rename to common/patches/laurion_ops.h diff --git a/common/patches/larion_structs.h b/common/patches/laurion_structs.h similarity index 97% rename from common/patches/larion_structs.h rename to common/patches/laurion_structs.h index 927527048..ab9724baf 100644 --- a/common/patches/larion_structs.h +++ b/common/patches/laurion_structs.h @@ -1,7 +1,7 @@ -#ifndef LARION_STRUCTS_H_ -#define LARION_STRUCTS_H_ +#ifndef LAURION_STRUCTS_H_ +#define LAURION_STRUCTS_H_ -namespace Larion { +namespace Laurion { namespace structs { // constants static const uint32 MAX_PP_AA_ARRAY = 300; @@ -351,7 +351,7 @@ namespace Larion { struct EnterWorld_Struct { /*000*/ char name[64]; /*064*/ int32 unknown1; - /*068*/ int32 unknown2; //larion handles these differently so for now im just going to ignore them till i figure it out + /*068*/ int32 unknown2; //laurion handles these differently so for now im just going to ignore them till i figure it out }; struct ZoneChange_Struct { @@ -441,6 +441,6 @@ namespace Larion { #pragma pack() }; //end namespace structs -}; //end namespace larion +}; //end namespace laurion -#endif /*LARION_STRUCTS_H_*/ +#endif /*LAURION_STRUCTS_H_*/ diff --git a/common/patches/patches.cpp b/common/patches/patches.cpp index 3a1a0fb6e..c8a17e6a2 100644 --- a/common/patches/patches.cpp +++ b/common/patches/patches.cpp @@ -26,7 +26,7 @@ #include "sod.h" #include "rof.h" #include "rof2.h" -#include "larion.h" +#include "laurion.h" void RegisterAllPatches(EQStreamIdentifier &into) { @@ -36,7 +36,7 @@ void RegisterAllPatches(EQStreamIdentifier &into) UF::Register(into); RoF::Register(into); RoF2::Register(into); - Larion::Register(into); + Laurion::Register(into); } void ReloadAllPatches() @@ -47,5 +47,5 @@ void ReloadAllPatches() UF::Reload(); RoF::Reload(); RoF2::Reload(); - Larion::Reload(); + Laurion::Reload(); } diff --git a/loginserver/client.cpp b/loginserver/client.cpp index dc1701959..45ceb8f38 100644 --- a/loginserver/client.cpp +++ b/loginserver/client.cpp @@ -587,7 +587,7 @@ void Client::SendExpansionPacketData(PlayerLoginReply_Struct& plrs) int32_t expansion = server.options.GetMaxExpansions(); int32_t owned_expansion = (expansion << 1) | 1; - if (m_client_version == cv_larion) { + if (m_client_version == cv_laurion) { buf.WriteInt32(0x00); buf.WriteInt32(0x00); buf.WriteInt16(0x00); diff --git a/loginserver/client_manager.cpp b/loginserver/client_manager.cpp index c82eb0de8..062872cd0 100644 --- a/loginserver/client_manager.cpp +++ b/loginserver/client_manager.cpp @@ -56,7 +56,7 @@ void CheckSoDOpcodeFile(const std::string& path) { } } -void CheckLarionOpcodeFile(const std::string& path) { +void CheckLaurionOpcodeFile(const std::string& path) { if (File::Exists(path)) { return; } @@ -158,40 +158,40 @@ ClientManager::ClientManager() } ); - int larion_port = server.config.GetVariableInt("client_configuration", "larion_port", 15900); + int laurion_port = server.config.GetVariableInt("client_configuration", "laurion_port", 15900); - EQStreamManagerInterfaceOptions larion_opts(larion_port, false, false); + EQStreamManagerInterfaceOptions laurion_opts(laurion_port, false, false); - larion_stream = new EQ::Net::EQStreamManager(larion_opts); - larion_ops = new RegularOpcodeManager; + laurion_stream = new EQ::Net::EQStreamManager(laurion_opts); + laurion_ops = new RegularOpcodeManager; opcodes_path = fmt::format( "{}/{}", path.GetOpcodePath(), - "login_opcodes_larion.conf" + "login_opcodes_laurion.conf" ); - CheckLarionOpcodeFile(opcodes_path); + CheckLaurionOpcodeFile(opcodes_path); - if (!larion_ops->LoadOpcodes(opcodes_path.c_str())) { + if (!laurion_ops->LoadOpcodes(opcodes_path.c_str())) { LogError( - "ClientManager fatal error: couldn't load opcodes for Larion file [{0}]", - server.config.GetVariableString("client_configuration", "larion_opcodes", "login_opcodes.conf") + "ClientManager fatal error: couldn't load opcodes for Laurion file [{0}]", + server.config.GetVariableString("client_configuration", "laurion_opcodes", "login_opcodes.conf") ); run_server = false; } - larion_stream->OnNewConnection( + laurion_stream->OnNewConnection( [this](std::shared_ptr stream) { LogInfo( - "New Larion client connection from [{0}:{1}]", + "New Laurion client connection from [{0}:{1}]", long2ip(stream->GetRemoteIP()), stream->GetRemotePort() ); - stream->SetOpcodeManager(&larion_ops); - Client* c = new Client(stream, cv_larion); + stream->SetOpcodeManager(&laurion_ops); + Client* c = new Client(stream, cv_laurion); clients.push_back(c); } ); diff --git a/loginserver/client_manager.h b/loginserver/client_manager.h index 23aff232e..27d14c2bd 100644 --- a/loginserver/client_manager.h +++ b/loginserver/client_manager.h @@ -55,8 +55,8 @@ private: EQ::Net::EQStreamManager *titanium_stream; OpcodeManager *sod_ops; EQ::Net::EQStreamManager *sod_stream; - OpcodeManager *larion_ops; - EQ::Net::EQStreamManager* larion_stream; + OpcodeManager *laurion_ops; + EQ::Net::EQStreamManager* laurion_stream; }; #endif diff --git a/loginserver/login_types.h b/loginserver/login_types.h index 1c8054a37..35707fef5 100644 --- a/loginserver/login_types.h +++ b/loginserver/login_types.h @@ -84,7 +84,7 @@ struct PlayEverquestResponse_Struct { enum LSClientVersion { cv_titanium, cv_sod, - cv_larion + cv_laurion }; enum LSClientStatus { diff --git a/loginserver/world_server.cpp b/loginserver/world_server.cpp index ece3f16d5..47a16e4e8 100644 --- a/loginserver/world_server.cpp +++ b/loginserver/world_server.cpp @@ -1020,7 +1020,7 @@ void WorldServer::SerializeForClientServerListLegacy(class SerializeBuffer& out, out.WriteUInt32(GetPlayersOnline()); } -void WorldServer::SerializeForClientServerListLarion(class SerializeBuffer& out, bool use_local_ip) const { +void WorldServer::SerializeForClientServerListLaurion(class SerializeBuffer& out, bool use_local_ip) const { if (use_local_ip) { out.WriteString(GetLocalIP()); } @@ -1067,8 +1067,8 @@ void WorldServer::SerializeForClientServerListLarion(class SerializeBuffer& out, void WorldServer::SerializeForClientServerList(SerializeBuffer& out, bool use_local_ip, LSClientVersion version) const { - if (version == cv_larion) { - SerializeForClientServerListLarion(out, use_local_ip); + if (version == cv_laurion) { + SerializeForClientServerListLaurion(out, use_local_ip); } else { SerializeForClientServerListLegacy(out, use_local_ip); diff --git a/loginserver/world_server.h b/loginserver/world_server.h index 0b8da5851..a78235f6f 100644 --- a/loginserver/world_server.h +++ b/loginserver/world_server.h @@ -151,7 +151,7 @@ public: bool HandleNewLoginserverInfoUnregisteredAllowed(Database::DbWorldRegistration &world_registration); private: void SerializeForClientServerListLegacy(class SerializeBuffer& out, bool use_local_ip) const; - void SerializeForClientServerListLarion(class SerializeBuffer& out, bool use_local_ip) const; + void SerializeForClientServerListLaurion(class SerializeBuffer& out, bool use_local_ip) const; public: void SerializeForClientServerList(class SerializeBuffer& out, bool use_local_ip, LSClientVersion version) const; diff --git a/utils/patches/patch_Larion.conf b/utils/patches/patch_Laurion.conf similarity index 100% rename from utils/patches/patch_Larion.conf rename to utils/patches/patch_Laurion.conf diff --git a/zone/client.cpp b/zone/client.cpp index a8b57286d..d80ae4270 100644 --- a/zone/client.cpp +++ b/zone/client.cpp @@ -543,8 +543,8 @@ void Client::SendZoneInPackets() if (tmpxp1 != tmpxp2 && tmpxp1 != 0xFFFFFFFF && tmpxp2 != 0xFFFFFFFF) { float tmpxp = (float)((float)m_pp.exp - tmpxp2) / ((float)tmpxp1 - tmpxp2); - //Larion uses a more granular exp bar than other clients - if (m_ClientVersion >= EQ::versions::ClientVersion::Larion) { + //Laurion uses a more granular exp bar than other clients + if (m_ClientVersion >= EQ::versions::ClientVersion::Laurion) { eu->exp = (uint32)(100000.0f * tmpxp); } else {