rename object to platform, refact of file names

This commit is contained in:
2023-07-07 09:21:25 +02:00
parent fa3e43299c
commit 420f2af0c4
13 changed files with 74 additions and 74 deletions

26
domain/type.npc.go Normal file
View File

@@ -0,0 +1,26 @@
package domain
import "game/konstructor"
const (
TestNPCType konstructor.NPCTypeMapKey = "test"
)
func (d *Domain) InitNPCType() {
d.NPCTypeMap = konstructor.NPCTypeMap{
TestNPCType: {
Render: konstructor.Render{
Image: "assets/images/npcs/test_npc.png",
},
},
}
}
func (d *Domain) GetNPCTypeMap() konstructor.NPCTypeMap {
return d.NPCTypeMap
}
func (d *Domain) GetNPCType(name konstructor.NPCTypeMapKey) konstructor.NPCType {
value, _ := d.NPCTypeMap[name]
return value
}