mirror of
https://github.com/EQEmu/Server.git
synced 2026-05-31 13:16:39 +00:00
Investigate groundspawn desync
This commit is contained in:
+1
-1
@@ -685,7 +685,7 @@ add_definitions(-DZONE)
|
||||
|
||||
if(EQEMU_BUILD_LUA)
|
||||
target_compile_definitions(lua_zone PUBLIC LUA_EQEMU)
|
||||
target_link_libraries(lua_zone PUBLIC luabind Boost::dynamic_bitset Boost::tuple Boost::foreach common)
|
||||
target_link_libraries(lua_zone PUBLIC luabind ${EQEMU_BOOST_HEADER_TARGET} common)
|
||||
if (EQEMU_BUILD_STATIC AND LUA_LIBRARY)
|
||||
target_link_libraries(zone PRIVATE ${LUA_LIBRARY})
|
||||
endif()
|
||||
|
||||
+2
-3
@@ -679,9 +679,8 @@ bool Object::HandleClick(Client* sender, const ClickObject_Struct* click_object)
|
||||
}
|
||||
}
|
||||
|
||||
// Transfer item to client
|
||||
sender->PutItemInInventory(EQ::invslot::slotCursor, *m_inst, false);
|
||||
sender->SendItemPacket(EQ::invslot::slotCursor, m_inst, ItemPacketTrade);
|
||||
// Transfer item to client using the normal cursor update path.
|
||||
sender->PutItemInInventory(EQ::invslot::slotCursor, *m_inst, true);
|
||||
|
||||
sender->CheckItemDiscoverability(m_inst->GetID());
|
||||
|
||||
|
||||
@@ -354,6 +354,16 @@ bool Zone::LoadGroundSpawns() {
|
||||
const uint32 max_allowed = g.spawn[slot_id].max_allowed;
|
||||
|
||||
if (inst) {
|
||||
const auto* item = inst->GetItem();
|
||||
if (
|
||||
item &&
|
||||
!inst->IsStackable() &&
|
||||
inst->GetCharges() == 0 &&
|
||||
item->MaxCharges > 0
|
||||
) {
|
||||
inst->SetCharges(item->MaxCharges);
|
||||
}
|
||||
|
||||
for (uint32 i = 0; i < max_allowed; i++) {
|
||||
auto object = new Object(
|
||||
inst,
|
||||
|
||||
Reference in New Issue
Block a user