A decision on creature definitions
Posted: 24 Sep 2012, 10:56
So I've been looking into how OpenDungeons reads and writes the map files, and I've noticed that it writes the creature definitions to the map files.
Because I understand creature definitions as being constant, this method boggles my mind, which is why I'm posting this; in hope that someone here might know more than me about this. Why would creature definitions be written to the map file, instead of being associated to a creature by some sort of id?
Also, now that we have XML files for the creature definitions, shouldn't it work for me to have the game load all creature xml files separately from the map, and then when the individual creatures are loaded from the map file, I simple associate them with the creature definitions? This should work if the creature definitions are constant, as in, they don't vary per creature, if the creature if the same type of creature.
Because I understand creature definitions as being constant, this method boggles my mind, which is why I'm posting this; in hope that someone here might know more than me about this. Why would creature definitions be written to the map file, instead of being associated to a creature by some sort of id?
Also, now that we have XML files for the creature definitions, shouldn't it work for me to have the game load all creature xml files separately from the map, and then when the individual creatures are loaded from the map file, I simple associate them with the creature definitions? This should work if the creature definitions are constant, as in, they don't vary per creature, if the creature if the same type of creature.