Clickthrough: lootable corpses prioritize over players
Lootable unit corpses (UNIT_DYNFLAG_LOOTABLE) now click-through over blocking players, matching the existing behavior for interactable NPCs and game objects. Adds isLootable() check to the interactable NPC test and UNIT_DYNAMIC_FLAGS descriptor offset to shared offsets. Also adds RELEASE_NOTES.md for tracking changes between releases, and adds a checklist item in RELEASING.md to review it before publishing.
This commit is contained in:
@@ -122,6 +122,12 @@ pub fn getNpcFlags(obj: u32) u32 {
|
||||
return hook.readMem(u32, desc + o.DESC_NPC_FLAGS);
|
||||
}
|
||||
|
||||
pub fn isLootable(obj: u32) bool {
|
||||
const desc = getDescriptor(obj);
|
||||
if (!isValidPtr(desc)) return 0 != 0;
|
||||
return (hook.readMem(u32, desc + o.DESC_UNIT_DYNAMIC_FLAGS) & o.UNIT_DYNFLAG_LOOTABLE) != 0;
|
||||
}
|
||||
|
||||
// =============================================================================
|
||||
// Unit helpers
|
||||
// =============================================================================
|
||||
|
||||
Reference in New Issue
Block a user