More investigation into animation

This commit is contained in:
2020-04-15 21:11:01 +01:00
parent 80c65f68ca
commit 32fd9f9aa9
9 changed files with 515 additions and 124 deletions

View File

@@ -9,6 +9,7 @@ import (
"code.ur.gs/lupine/ordoor/internal/data"
"code.ur.gs/lupine/ordoor/internal/fonts"
"code.ur.gs/lupine/ordoor/internal/idx"
"code.ur.gs/lupine/ordoor/internal/maps"
"code.ur.gs/lupine/ordoor/internal/menus"
"code.ur.gs/lupine/ordoor/internal/sets"
@@ -33,13 +34,15 @@ func main() {
loadSets()
loadMenus()
loadFonts()
loadIdx()
}
func loadData() {
dataPath := filepath.Join(*gamePath, "Data")
accountingPath := filepath.Join(dataPath, "Accounting.dat")
genericDataPath := filepath.Join(dataPath, "GenericData.dat")
aniObDefPath := filepath.Join(dataPath, "AniObDef.dat")
genericDataPath := filepath.Join(dataPath, "GenericData.dat")
hasActionPath := filepath.Join(dataPath, "HasAction.dat")
i18nPath := filepath.Join(dataPath, data.I18nFile)
log.Printf("Loading %s...", accountingPath)
@@ -73,6 +76,12 @@ func loadData() {
}
log.Printf("%s: len=%v", i18nPath, i18n.Len())
ha, err := data.LoadHasAction(hasActionPath)
if err != nil {
log.Fatalf("Failed to parse %s: %v", hasActionPath, err)
}
ha.Print()
}
func loadObj() {
@@ -189,3 +198,11 @@ func loadFonts() {
fmt.Printf(" * `%s`: obj=%v entries=%v\n", font.Name, font.ObjectFile, font.Entries())
}
}
func loadIdx() {
idxPath := filepath.Join(*gamePath, "Idx", "WarHammer.idx")
_, err := idx.Load(idxPath)
if err != nil {
log.Fatalf("Failed to parse %s as idx: %v", idxPath, err)
}
}