So i have a yaml config here each key is a randomly generated UUID. I need to list those values using foreach (as ive done here). Code: uuid: desc: hey uuid2: desc: bye where uuid and uuid2 are the keys and desc are the values PHP: foreach($this->fdata->getAll() as $facs) { $faction = new Faction; $faction->setTag($facs["tag"], false); $faction->setDescription($facs["desc"] ?? "", false);} I can get the values of each UUID key by using Code: $facs["value"] but i cant get the actual UUID. Ive tried just using $facs but since its an array i get an error. Im sure its really simple and im just being dumb, but might as well ask.
I was right, it was simple. Fixed it as per PEMapModders comment: http://forums.pocketmine.net/threads/get-all-config-entries.11845/
Bad, hacky, messy. This is how it's supposed to be done. PHP: $config = yaml_parse_file($this->getDataFolder()."config.yml");$keys = array_keys($config);