HarbourMasters / HarbourMasters/Torch

Symbols in a file can't be found by address if the address isn't a full segmented address

Open
#243 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
C++
Stars
36
Forks
50
Avg merge
2d 13h
Merged PRs (30d)
6

Description

Example in OOT:
In TextureFactory.cpp

Looking for `gMegami1TLUT` using `tlutOffset`, which is 0x5c80 like this:
`std::string sym = Companion::Instance->GetSymbolFromAddr(0x5c80, true);`
Doesn't find the symbol.
But searching for it with the fill segment address:
`std::string sym = Companion::Instance->GetSymbolFromAddr(0x06005c80, true);`
Does find the symbol.

Contributor guide

No contributing guide indexed for this repository

Research direction

Start in TextureFactory.cpp at the GetSymbolFromAddr call and trace how tlutOffset is handled when passed as 0x5c80 versus the full segmented address 0x06005c80. Reproduce the lookup for gMegami1TLUT and inspect the address conversion or matching path. Done means the symbol can be found using the unsegmented address as shown.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
reverse-engineering
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.