Forums WoW Modding Support Archives TrinityCore Discord Archives [DiscordArchive] Also where is the crash logs?

[DiscordArchive] Also where is the crash logs?

[DiscordArchive] Also where is the crash logs?

Pages (2): 1 2 Next
rektbyfaith
Administrator
0
02-10-2025, 04:33 PM
#1
Archived author: M'Dic • Posted: 2025-02-10T16:33:01.665000+00:00
Original source

Also where is the crash logs?
rektbyfaith
02-10-2025, 04:33 PM #1

Archived author: M'Dic • Posted: 2025-02-10T16:33:01.665000+00:00
Original source

Also where is the crash logs?

rektbyfaith
Administrator
0
02-10-2025, 04:37 PM
#2
Archived author: caweren • Posted: 2025-02-10T16:37:30.658000+00:00
Original source

```cpp
void HandleDisassembly() {
Item* target = GetExplTargetItem();
if (!target) return;

InventoryType invType = InventoryType(target->GetTemplate()->InventoryType);
ItemSubclassWeapon subClass = ItemSubclassWeapon(target->GetTemplate()->SubClass);
Player* caster = GetCaster()->ToPlayer();
std::vector<DisassemblyLoot> lootTable = {};
if (isWeapon(invType)) {
if (is2HWeapon(subClass))
lootTable.push_back({ ITEM_BLACKSMITH_WHETSTONE, urand(3,5) });
else if (is1HWeapon(subClass))
lootTable.push_back({ ITEM_BLACKSMITH_WHETSTONE, urand(1, 3) });
}
else if (isJewelry(invType)) {
lootTable.push_back({ ITEM_METALLIC_LOOP, urand(1, 3) });
}
else
lootTable.push_back({ ITEM_ARMOR_SCRAPS, urand(1, 3) });

ItemPosCountVec sDest;
for (auto& loot : lootTable) {

InventoryResult msg = caster->CanStoreNewItem(INVENTORY_SLOT_BAG_0, NULL_SLOT, sDest, loot.item, loot.amount);
if (msg == EQUIP_ERR_OK)
{
Item* item = caster->StoreNewItem(sDest, loot.item, true, 0);
caster->SendNewItem(item, loot.amount, true, false, false);
}
}

target->SaveToDB();

caster->DestroyItem(target->GetBagSlot(), target->GetSlot(), true);

}
```
Do you want the entire log, or just the call stack?
```txt
Call stack:
Address Frame Function SourceFile
00007FFB8FE5A144 000000FB287FF3E0 Object::GetGuidValue+74 C:\Code\ElunaTrinityWotlk\src\server\game\Entities\Object\Object.cpp line 304
00007FFB8FEEBDB9 000000FB287FF740 Player::_SaveInventory+E99 C:\Code\ElunaTrinityWotlk\src\server\game\Entities\Player\Player.cpp line 20177
00007FFB8FEBD41C 000000FB287FFA00 Player::SaveToDB+1DEC C:\Code\ElunaTrinityWotlk\src\server\game\Entities\Player\Player.cpp line 19897
00007FFB8FEBD8F5 000000FB287FFA50 Player::SaveToDB+55 C:\Code\ElunaTrinityWotlk\src\server\game\Entities\Player\Player.cpp line 19604
00007FFB8FED2E6D 000000FB287FFB70 Player::Update+8FD C:\Code\ElunaTrinityWotlk\src\server\game\Entities\Player\Player.cpp line 1258
00007FFB9013CBF0 000000FB287FFD10 Map::Update+1A0 C:\Code\ElunaTrinityWotlk\src\server\game\Maps\Map.cpp line 828
00007FFB9014E627 000000FB287FFD60 MapUpdater::WorkerThread+F7 C:\Code\ElunaTrinityWotlk\src\server\game\Maps\MapUpdater.cpp line 118
00007FFB9014E0EF 000000FB287FFD90 std::thread::_Invoke<std::tuple<void (__cdecl MapUpdater::*)(void),MapUpdater *>,0,1>+F C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.42.34433\include\thread line 61
00007FFBCB8E37B0 000000FB287FFDC0 wcsrchr+150
00007FFBCD7BE8D7 000000FB287FFDF0 BaseThreadInitThunk+17
00007FFBCE53BF2C 000000FB287FFE40 RtlUserThreadStart+2C
```
rektbyfaith
02-10-2025, 04:37 PM #2

Archived author: caweren • Posted: 2025-02-10T16:37:30.658000+00:00
Original source

```cpp
void HandleDisassembly() {
Item* target = GetExplTargetItem();
if (!target) return;

InventoryType invType = InventoryType(target->GetTemplate()->InventoryType);
ItemSubclassWeapon subClass = ItemSubclassWeapon(target->GetTemplate()->SubClass);
Player* caster = GetCaster()->ToPlayer();
std::vector<DisassemblyLoot> lootTable = {};
if (isWeapon(invType)) {
if (is2HWeapon(subClass))
lootTable.push_back({ ITEM_BLACKSMITH_WHETSTONE, urand(3,5) });
else if (is1HWeapon(subClass))
lootTable.push_back({ ITEM_BLACKSMITH_WHETSTONE, urand(1, 3) });
}
else if (isJewelry(invType)) {
lootTable.push_back({ ITEM_METALLIC_LOOP, urand(1, 3) });
}
else
lootTable.push_back({ ITEM_ARMOR_SCRAPS, urand(1, 3) });

ItemPosCountVec sDest;
for (auto& loot : lootTable) {

InventoryResult msg = caster->CanStoreNewItem(INVENTORY_SLOT_BAG_0, NULL_SLOT, sDest, loot.item, loot.amount);
if (msg == EQUIP_ERR_OK)
{
Item* item = caster->StoreNewItem(sDest, loot.item, true, 0);
caster->SendNewItem(item, loot.amount, true, false, false);
}
}

target->SaveToDB();

caster->DestroyItem(target->GetBagSlot(), target->GetSlot(), true);

}
```
Do you want the entire log, or just the call stack?
```txt
Call stack:
Address Frame Function SourceFile
00007FFB8FE5A144 000000FB287FF3E0 Object::GetGuidValue+74 C:\Code\ElunaTrinityWotlk\src\server\game\Entities\Object\Object.cpp line 304
00007FFB8FEEBDB9 000000FB287FF740 Player::_SaveInventory+E99 C:\Code\ElunaTrinityWotlk\src\server\game\Entities\Player\Player.cpp line 20177
00007FFB8FEBD41C 000000FB287FFA00 Player::SaveToDB+1DEC C:\Code\ElunaTrinityWotlk\src\server\game\Entities\Player\Player.cpp line 19897
00007FFB8FEBD8F5 000000FB287FFA50 Player::SaveToDB+55 C:\Code\ElunaTrinityWotlk\src\server\game\Entities\Player\Player.cpp line 19604
00007FFB8FED2E6D 000000FB287FFB70 Player::Update+8FD C:\Code\ElunaTrinityWotlk\src\server\game\Entities\Player\Player.cpp line 1258
00007FFB9013CBF0 000000FB287FFD10 Map::Update+1A0 C:\Code\ElunaTrinityWotlk\src\server\game\Maps\Map.cpp line 828
00007FFB9014E627 000000FB287FFD60 MapUpdater::WorkerThread+F7 C:\Code\ElunaTrinityWotlk\src\server\game\Maps\MapUpdater.cpp line 118
00007FFB9014E0EF 000000FB287FFD90 std::thread::_Invoke<std::tuple<void (__cdecl MapUpdater::*)(void),MapUpdater *>,0,1>+F C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.42.34433\include\thread line 61
00007FFBCB8E37B0 000000FB287FFDC0 wcsrchr+150
00007FFBCD7BE8D7 000000FB287FFDF0 BaseThreadInitThunk+17
00007FFBCE53BF2C 000000FB287FFE40 RtlUserThreadStart+2C
```

rektbyfaith
Administrator
0
02-10-2025, 04:42 PM
#3
Archived author: M'Dic • Posted: 2025-02-10T16:42:52.803000+00:00
Original source

Log would be the best. But why save then follow with a destroyitem? I could see that as exploitable
rektbyfaith
02-10-2025, 04:42 PM #3

Archived author: M'Dic • Posted: 2025-02-10T16:42:52.803000+00:00
Original source

Log would be the best. But why save then follow with a destroyitem? I could see that as exploitable

rektbyfaith
Administrator
0
02-10-2025, 04:43 PM
#4
Archived author: caweren • Posted: 2025-02-10T16:43:18.639000+00:00
Original source

It was to test wether saving the item before destroying it had an effect. It did not
rektbyfaith
02-10-2025, 04:43 PM #4

Archived author: caweren • Posted: 2025-02-10T16:43:18.639000+00:00
Original source

It was to test wether saving the item before destroying it had an effect. It did not

rektbyfaith
Administrator
0
02-10-2025, 04:43 PM
#5
Archived author: M'Dic • Posted: 2025-02-10T16:43:51.078000+00:00
Original source

Is this the object.cpp file?
rektbyfaith
02-10-2025, 04:43 PM #5

Archived author: M'Dic • Posted: 2025-02-10T16:43:51.078000+00:00
Original source

Is this the object.cpp file?

rektbyfaith
Administrator
0
02-10-2025, 04:44 PM
#6
Archived author: caweren • Posted: 2025-02-10T16:44:24.699000+00:00
Original source

No, it's in a custom script. It fails in `Object.cpp` due to GUID requirement in `_SaveInventory`
rektbyfaith
02-10-2025, 04:44 PM #6

Archived author: caweren • Posted: 2025-02-10T16:44:24.699000+00:00
Original source

No, it's in a custom script. It fails in `Object.cpp` due to GUID requirement in `_SaveInventory`

rektbyfaith
Administrator
0
02-10-2025, 04:45 PM
#7
Archived author: M'Dic • Posted: 2025-02-10T16:45:16.765000+00:00
Original source

Are u famliar with attaching to debugger while the server is running?
rektbyfaith
02-10-2025, 04:45 PM #7

Archived author: M'Dic • Posted: 2025-02-10T16:45:16.765000+00:00
Original source

Are u famliar with attaching to debugger while the server is running?

rektbyfaith
Administrator
0
02-10-2025, 04:45 PM
#8
Archived author: caweren • Posted: 2025-02-10T16:45:32.898000+00:00
Original source

ofc
rektbyfaith
02-10-2025, 04:45 PM #8

Archived author: caweren • Posted: 2025-02-10T16:45:32.898000+00:00
Original source

ofc

rektbyfaith
Administrator
0
02-10-2025, 04:46 PM
#9
Archived author: M'Dic • Posted: 2025-02-10T16:46:21.339000+00:00
Original source

Where does it break when the crash happens?
rektbyfaith
02-10-2025, 04:46 PM #9

Archived author: M'Dic • Posted: 2025-02-10T16:46:21.339000+00:00
Original source

Where does it break when the crash happens?

rektbyfaith
Administrator
0
02-10-2025, 04:46 PM
#10
Archived author: M'Dic • Posted: 2025-02-10T16:46:34.964000+00:00
Original source

And what info does it give in the bottom left pane window?
rektbyfaith
02-10-2025, 04:46 PM #10

Archived author: M'Dic • Posted: 2025-02-10T16:46:34.964000+00:00
Original source

And what info does it give in the bottom left pane window?

Pages (2): 1 2 Next
Recently Browsing
 1 Guest(s)
Recently Browsing
 1 Guest(s)