(RoF+) Implemented the 6th Augment Slot for Items.

Player Corpses now saved attuned settings for Items.
Renamed IsInstNoDrop() and SetInstNoDrop() to IsAttuned() and SetAttuned() respectively.
This commit is contained in:
Trevius
2014-12-15 17:55:23 -06:00
parent b733e96aea
commit 200027bf89
41 changed files with 263 additions and 189 deletions
+1 -1
View File
@@ -1249,7 +1249,7 @@ namespace Client62
//merchant_slot, //instance ID, bullshit for now
// The 'Merchant Slot' needs to be some unique id for bazaar to work properly
(merchant_slot == 0) ? inst->GetSerialNumber() : merchant_slot,
inst->IsInstNoDrop() ? 1 : 0, //not sure where this field is
inst->IsAttuned() ? 1 : 0, //not sure where this field is
(stackable ? ((inst->GetItem()->ItemType == ItemTypePotion) ? charges : 0) : charges),
0
);
+6 -6
View File
@@ -4406,7 +4406,7 @@ namespace RoF
IN(item_id);
int r;
for (r = 0; r < 5; r++) {
for (r = 0; r < EmuConstants::ITEM_COMMON_SIZE; r++) {
IN(augments[r]);
}
// Max Augs is now 6, but no code to support that many yet
@@ -4855,7 +4855,7 @@ namespace RoF
hdr.unknown028 = 0;
hdr.last_cast_time = ((item->RecastDelay > 1) ? 1212693140 : 0);
hdr.charges = (stackable ? (item->MaxCharges ? 1 : 0) : charges);
hdr.inst_nodrop = inst->IsInstNoDrop() ? 1 : 0;
hdr.inst_nodrop = inst->IsAttuned() ? 1 : 0;
hdr.unknown044 = 0;
hdr.unknown048 = 0;
hdr.unknown052 = 0;
@@ -5074,7 +5074,7 @@ namespace RoF
isbs.augdistiller = 65535;
isbs.augrestrict = item->AugRestrict;
for (int x = AUG_BEGIN; x < EmuConstants::ITEM_COMMON_SIZE; ++x)
for (int x = AUG_BEGIN; x < consts::ITEM_COMMON_SIZE; x++)
{
isbs.augslots[x].type = item->AugSlotType[x];
isbs.augslots[x].visible = item->AugSlotVisible[x];
@@ -5082,9 +5082,9 @@ namespace RoF
}
// Increased to 6 max aug slots
isbs.augslots[5].type = 0;
isbs.augslots[5].visible = 1;
isbs.augslots[5].unknown = 0;
//isbs.augslots[5].type = 0;
//isbs.augslots[5].visible = 1;
//isbs.augslots[5].unknown = 0;
isbs.ldonpoint_type = item->PointType;
isbs.ldontheme = item->LDoNTheme;
+6 -7
View File
@@ -4410,10 +4410,9 @@ namespace RoF2
IN(item_id);
int r;
for (r = 0; r < 5; r++) {
for (r = 0; r < EmuConstants::ITEM_COMMON_SIZE; r++) {
IN(augments[r]);
}
// Max Augs is now 6, but no code to support that many yet
IN(link_hash);
IN(icon);
@@ -4859,7 +4858,7 @@ namespace RoF2
hdr.unknown028 = 0;
hdr.last_cast_time = ((item->RecastDelay > 1) ? 1212693140 : 0);
hdr.charges = (stackable ? (item->MaxCharges ? 1 : 0) : charges);
hdr.inst_nodrop = inst->IsInstNoDrop() ? 1 : 0;
hdr.inst_nodrop = inst->IsAttuned() ? 1 : 0;
hdr.unknown044 = 0;
hdr.unknown048 = 7300 + Inventory::CalcMaterialFromSlot(slot_id_in); //0;
hdr.unknown052 = 7300 + Inventory::CalcMaterialFromSlot(slot_id_in); //0;
@@ -5079,7 +5078,7 @@ namespace RoF2
isbs.augdistiller = 65535;
isbs.augrestrict = item->AugRestrict;
for (int x = AUG_BEGIN; x < EmuConstants::ITEM_COMMON_SIZE; ++x)
for (int x = AUG_BEGIN; x < consts::ITEM_COMMON_SIZE; x++)
{
isbs.augslots[x].type = item->AugSlotType[x];
isbs.augslots[x].visible = item->AugSlotVisible[x];
@@ -5087,9 +5086,9 @@ namespace RoF2
}
// Increased to 6 max aug slots
isbs.augslots[5].type = 0;
isbs.augslots[5].visible = 1;
isbs.augslots[5].unknown = 0;
//isbs.augslots[5].type = 0;
//isbs.augslots[5].visible = 1;
//isbs.augslots[5].unknown = 0;
isbs.ldonpoint_type = item->PointType;
isbs.ldontheme = item->LDoNTheme;
+3
View File
@@ -332,6 +332,9 @@ These fields must be in the order of how they are serialized!
/* 091 */ I(AugSlotType[4])
/* 092 */ I(AugSlotVisible[4])
/* 092 */ I(AugSlotUnk2[4])
/* 091 */ I(AugSlotType[5])
/* 092 */ I(AugSlotVisible[5])
/* 092 */ I(AugSlotUnk2[5])
/* 093 */ I(PointType)
/* 093 */ I(LDoNTheme)
/* 094 */ I(LDoNPrice)
+3
View File
@@ -332,6 +332,9 @@ These fields must be in the order of how they are serialized!
/* 091 */ I(AugSlotType[4])
/* 092 */ I(AugSlotVisible[4])
/* 092 */ I(AugSlotUnk2[4])
/* 091 */ I(AugSlotType[5])
/* 092 */ I(AugSlotVisible[5])
/* 092 */ I(AugSlotUnk2[5])
/* 093 */ I(PointType)
/* 093 */ I(LDoNTheme)
/* 094 */ I(LDoNPrice)
+2 -2
View File
@@ -3223,7 +3223,7 @@ namespace SoD
hdr.unknown028 = 0;
hdr.last_cast_time = ((item->RecastDelay > 1) ? 1212693140 : 0);
hdr.charges = (stackable ? (item->MaxCharges ? 1 : 0) : charges);
hdr.inst_nodrop = inst->IsInstNoDrop() ? 1 : 0;
hdr.inst_nodrop = inst->IsAttuned() ? 1 : 0;
hdr.unknown044 = 0;
hdr.unknown048 = 0;
hdr.unknown052 = 0;
@@ -3370,7 +3370,7 @@ namespace SoD
isbs.augtype = item->AugType;
isbs.augrestrict = item->AugRestrict;
for (int x = 0; x < 5; ++x)
for (int x = 0; x < consts::ITEM_COMMON_SIZE; x++)
{
isbs.augslots[x].type = item->AugSlotType[x];
isbs.augslots[x].visible = item->AugSlotVisible[x];
+2 -2
View File
@@ -2547,7 +2547,7 @@ namespace SoF
hdr.unknown028 = 0;
hdr.last_cast_time = ((item->RecastDelay > 1) ? 1212693140 : 0);
hdr.charges = (stackable ? (item->MaxCharges ? 1 : 0) : charges);
hdr.inst_nodrop = inst->IsInstNoDrop() ? 1 : 0;
hdr.inst_nodrop = inst->IsAttuned() ? 1 : 0;
hdr.unknown044 = 0;
hdr.unknown048 = 0;
hdr.unknown052 = 0;
@@ -2693,7 +2693,7 @@ namespace SoF
isbs.augtype = item->AugType;
isbs.augrestrict = item->AugRestrict;
for (int x = 0; x < 5; ++x)
for (int x = 0; x < consts::ITEM_COMMON_SIZE; x++)
{
isbs.augslots[x].type = item->AugSlotType[x];
isbs.augslots[x].visible = item->AugSlotVisible[x];
+1 -1
View File
@@ -1678,7 +1678,7 @@ namespace Titanium
(merchant_slot == 0) ? inst->GetSerialNumber() : merchant_slot,
0, // item recast timer timestamp field (aka..last_cast_time field in SoF+ clients)
(stackable ? ((inst->GetItem()->ItemType == ItemTypePotion) ? 1 : 0) : charges),
inst->IsInstNoDrop() ? 1 : 0,
inst->IsAttuned() ? 1 : 0,
0
);
+2 -2
View File
@@ -3637,7 +3637,7 @@ namespace Underfoot
hdr.unknown028 = 0;
hdr.last_cast_time = ((item->RecastDelay > 1) ? 1212693140 : 0);
hdr.charges = (stackable ? (item->MaxCharges ? 1 : 0) : charges);
hdr.inst_nodrop = inst->IsInstNoDrop() ? 1 : 0;
hdr.inst_nodrop = inst->IsAttuned() ? 1 : 0;
hdr.unknown044 = 0;
hdr.unknown048 = 0;
hdr.unknown052 = 0;
@@ -3817,7 +3817,7 @@ namespace Underfoot
isbs.augtype = item->AugType;
isbs.augrestrict = item->AugRestrict;
for (int x = 0; x < 5; ++x)
for (int x = 0; x < consts::ITEM_COMMON_SIZE; x++)
{
isbs.augslots[x].type = item->AugSlotType[x];
isbs.augslots[x].visible = item->AugSlotVisible[x];