mirror of
https://github.com/HarbourMasters/Shipwright.git
synced 2024-11-29 04:42:18 -05:00
InfTable Check Location Fixes: Lost Dog Richard, Rolling Gorons, HBA 1000, Thawed Zora
This commit is contained in:
parent
d77487f06f
commit
8eabef6c42
@ -677,7 +677,10 @@ bool HasItemBeenCollected(RandomizerCheckObject obj) {
|
|||||||
case SpoilerCollectionCheckType::SPOILER_CHK_GOLD_SKULLTULA:
|
case SpoilerCollectionCheckType::SPOILER_CHK_GOLD_SKULLTULA:
|
||||||
return GET_GS_FLAGS(scene) & flag;
|
return GET_GS_FLAGS(scene) & flag;
|
||||||
case SpoilerCollectionCheckType::SPOILER_CHK_INF_TABLE:
|
case SpoilerCollectionCheckType::SPOILER_CHK_INF_TABLE:
|
||||||
return gSaveContext.infTable[scene] & (0x01 << flag);
|
// Magic to flip an index `flag` to a lookup for 16bit big endian integers. Probably an easier way.....
|
||||||
|
shift = 7 - (flag % 8) + ((flag % 16) / 8) * 8;
|
||||||
|
mask = 0x8000 >> shift;
|
||||||
|
return gSaveContext.infTable[scene] & mask;
|
||||||
case SpoilerCollectionCheckType::SPOILER_CHK_ITEM_GET_INF:
|
case SpoilerCollectionCheckType::SPOILER_CHK_ITEM_GET_INF:
|
||||||
// Magic to flip an index `flag` to a lookup for 16bit big endian integers. Probably an easier way.....
|
// Magic to flip an index `flag` to a lookup for 16bit big endian integers. Probably an easier way.....
|
||||||
shift = 7 - (flag % 8) + ((flag % 16) / 8) * 8;
|
shift = 7 - (flag % 8) + ((flag % 16) / 8) * 8;
|
||||||
|
Loading…
Reference in New Issue
Block a user