I’m having a bit of trouble with trying to iterate through the list of keys provided by Libgdx’s MapObject class. As I’m trying to iterate through them, I only receive the data for the first item in the list. Here’s what I’ve got.
MapProperties p = o.getProperties();
while(p.getKeys().hasNext()){
String s = p.getKeys().next();
System.out.println(s);
}
All I’m getting is the name of the first key, x, over and over. Any help would be great.