Add levels and fix tz?

This commit is contained in:
Héctor Giménez
2024-04-24 21:47:45 +09:00
parent ab304a68f6
commit 07b5a3a1c3
10 changed files with 16015 additions and 196 deletions

View File

@@ -4,13 +4,13 @@ import (
"github.com/hectorgimenez/d2go/pkg/data/area"
)
func (gd *GameReader) TerrorZones() (areas []area.Area) {
tz := gd.moduleBaseAddressPtr + 0x299E2D8
func (gd *GameReader) TerrorZones() (areas []area.ID) {
tz := gd.moduleBaseAddressPtr + 0x29E9558
for i := 0; i < 7; i++ {
tzArea := gd.ReadUInt(tz+uintptr(i*Uint32), Uint32)
if tzArea != 0 {
areas = append(areas, area.Area(tzArea))
areas = append(areas, area.ID(tzArea))
}
}