feat(parity): implement Conqueror level text tail and ground item name resolution (pass33)
This commit is contained in:
@@ -744,3 +744,16 @@ Validation: macOS build and Android arm64 libmain.so pass. Five targeted CTests
|
|||||||
- `python3 tools/audit_ava2_python_interfaces.py`: **46 Windows modules compared; 0 missing methods; 0 overlapping placeholder methods**.
|
- `python3 tools/audit_ava2_python_interfaces.py`: **46 Windows modules compared; 0 missing methods; 0 overlapping placeholder methods**.
|
||||||
- CTest suite: **41/41 tests passed (100%)**.
|
- CTest suite: **41/41 tests passed (100%)**.
|
||||||
- Android arm64 `libmain.so` and macOS arm64 `ava2_client` build cleanly.
|
- Android arm64 `libmain.so` and macOS arm64 `ava2_client` build cleanly.
|
||||||
|
|
||||||
|
## 2026-10-08 pass33 — Conqueror level text tail & ground item name resolution parity
|
||||||
|
- **Conqueror Level TextTail (`ENABLE_CONQUEROR_LEVEL`)**:
|
||||||
|
- Added `AttachConquerorLevel(uint32_t vid, const std::string& levelText)` to `TextTailManager.h` and `TextTailManager.cpp` applying `0xFF8CC8FF` text color matching upstream `CPythonTextTail::AttachConquerorLevel`.
|
||||||
|
- Updated `NetworkActorManager::AppendActor` and `UpdateActor` in `src/eter_net/NetworkActorManager.cpp` to attach Conqueror level overhead tag when `m_dwConquerorLevel > 0`, replicating `CInstanceBase::UpdateTextTailConquerorLevel`.
|
||||||
|
- **Ground Item Name Resolution**:
|
||||||
|
- Updated `PythonNetworkStream::RecvItemGroundAddPacket` in `src/eter_net/PythonNetworkStream.cpp` to look up item names through `GetItemNameAndType(vnum)` rather than printing generic `"Item <vnum>"`, matching upstream `CPythonItem::CreateItem` and `RegisterItemTextTail`.
|
||||||
|
- **Results**:
|
||||||
|
- Checked packet constants: **240**, 0 mismatches, 0 unmatched.
|
||||||
|
- `python3 tools/audit_windows_parity.py`: **0 placeholder bindings**.
|
||||||
|
- `python3 tools/audit_ava2_python_interfaces.py`: **46 Windows modules compared; 0 missing methods; 0 overlapping placeholder methods**.
|
||||||
|
- CTest suite: **41/41 tests passed (100%)**.
|
||||||
|
- Android arm64 `libmain.so` and macOS arm64 `ava2_client` build cleanly.
|
||||||
|
|||||||
@@ -485,7 +485,9 @@ void NetworkActorManager::AppendActor(const SNetworkActorData& data) {
|
|||||||
tt.SetCharacterName(data.m_dwVID, data.m_stName);
|
tt.SetCharacterName(data.m_dwVID, data.m_stName);
|
||||||
tt.SetCharacterPosition(data.m_dwVID, worldX, worldY, worldZ);
|
tt.SetCharacterPosition(data.m_dwVID, worldX, worldY, worldZ);
|
||||||
|
|
||||||
if (data.m_dwLevel > 0) {
|
if (data.m_dwConquerorLevel > 0) {
|
||||||
|
tt.AttachConquerorLevel(data.m_dwVID, "Lv " + std::to_string(data.m_dwConquerorLevel));
|
||||||
|
} else if (data.m_dwLevel > 0) {
|
||||||
tt.AttachLevel(data.m_dwVID, "Lv " + std::to_string(data.m_dwLevel));
|
tt.AttachLevel(data.m_dwVID, "Lv " + std::to_string(data.m_dwLevel));
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -546,6 +548,9 @@ void NetworkActorManager::UpdateActor(const SNetworkUpdateActorData& data) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
ChangeSash(data.m_dwVID, data.m_dwSash);
|
ChangeSash(data.m_dwVID, data.m_dwSash);
|
||||||
|
if (data.m_dwConquerorLevel > 0) {
|
||||||
|
TextTailManager::Instance().AttachConquerorLevel(data.m_dwVID, "Lv " + std::to_string(data.m_dwConquerorLevel));
|
||||||
|
}
|
||||||
// ChangeGuild / SetAlignment / SetStateFlags(KILLER) each end in RefreshTextTail.
|
// ChangeGuild / SetAlignment / SetStateFlags(KILLER) each end in RefreshTextTail.
|
||||||
RefreshTextTail(data.m_dwVID);
|
RefreshTextTail(data.m_dwVID);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -963,7 +963,12 @@ bool PythonNetworkStream::RecvItemGroundAddPacket() {
|
|||||||
float wy = static_cast<float>(p.lZ);
|
float wy = static_cast<float>(p.lZ);
|
||||||
float wz = static_cast<float>(p.lY);
|
float wz = static_cast<float>(p.lY);
|
||||||
|
|
||||||
TextTailManager::Instance().RegisterItemTextTail(p.dwVID, "Item " + std::to_string(p.dwVnum), wx, wy, wz);
|
std::string itemName;
|
||||||
|
int itemType = 0;
|
||||||
|
if (!GetItemNameAndType(p.dwVnum, &itemName, &itemType) || itemName.empty()) {
|
||||||
|
itemName = "Item " + std::to_string(p.dwVnum);
|
||||||
|
}
|
||||||
|
TextTailManager::Instance().RegisterItemTextTail(p.dwVID, itemName, wx, wy, wz);
|
||||||
|
|
||||||
if (m_groundItemCallback) {
|
if (m_groundItemCallback) {
|
||||||
m_groundItemCallback(p.dwVID, p.dwVnum, p.lX, p.lY, p.lZ, true);
|
m_groundItemCallback(p.dwVID, p.dwVnum, p.lX, p.lY, p.lZ, true);
|
||||||
|
|||||||
@@ -99,6 +99,10 @@ void TextTailManager::AttachLevel(uint32_t vid, const std::string& levelText, ui
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void TextTailManager::AttachConquerorLevel(uint32_t vid, const std::string& levelText) {
|
||||||
|
AttachLevel(vid, levelText, 0xFF8CC8FF);
|
||||||
|
}
|
||||||
|
|
||||||
void TextTailManager::DetachLevel(uint32_t vid) {
|
void TextTailManager::DetachLevel(uint32_t vid) {
|
||||||
auto it = m_characterMap.find(vid);
|
auto it = m_characterMap.find(vid);
|
||||||
if (it != m_characterMap.end()) {
|
if (it != m_characterMap.end()) {
|
||||||
|
|||||||
@@ -85,6 +85,7 @@ public:
|
|||||||
void AttachTitle(uint32_t vid, const std::string& title, uint32_t color = 0xFFFFD700);
|
void AttachTitle(uint32_t vid, const std::string& title, uint32_t color = 0xFFFFD700);
|
||||||
void DetachTitle(uint32_t vid);
|
void DetachTitle(uint32_t vid);
|
||||||
void AttachLevel(uint32_t vid, const std::string& levelText, uint32_t color = 0xFF98FF33);
|
void AttachLevel(uint32_t vid, const std::string& levelText, uint32_t color = 0xFF98FF33);
|
||||||
|
void AttachConquerorLevel(uint32_t vid, const std::string& levelText);
|
||||||
void DetachLevel(uint32_t vid);
|
void DetachLevel(uint32_t vid);
|
||||||
void SetGuildName(uint32_t vid, const std::string& guildName, uint32_t guildID = 0);
|
void SetGuildName(uint32_t vid, const std::string& guildName, uint32_t guildID = 0);
|
||||||
void DeleteCharacterTextTail(uint32_t vid);
|
void DeleteCharacterTextTail(uint32_t vid);
|
||||||
|
|||||||
Reference in New Issue
Block a user