Ahh, I gotcha. Well, it's getting closer to working. It's still returning a few strange errors, such as 'object has no value 'x'' in the following code. But it is recognizing it as a dictionary now rather than a list.
I need to check my rendering code. For some reason, it's drawing the map and items but not the creatures.
Edit :: Nevermind, it renders fine.
One other question I had. The tutorial features a function called 'send_to_back', which set the objects index in the old list to 0. This meant that it would be drawn first, so anything else on that tile would be drawn on top of it. (ie a monster is draw on top of an item). Is there any way to set the position of a specific key in the dictionary?
This is the code producing the 'object has no value x' error. But it seems to register the other values. (char/color for rendering, x,y positions, etc.)
...
Edit :: I tracked it down. It was caused by me doing things along the lines of objects[object.real_name] = None
How do I properly remove a key from a dictionary? I tried objects.remove(object.real_name) but it returned a NoMethod error
Ultimately, if your levels are small and contain few objects, then you can probably get away with the current method - but if you expect features like breeding monsters, cloning items, rooms full of treasure, or bosses with lots of minions, then it might be worth considering this alternative method.
Good to know. I think it should be ok for now, but if it ever becomes a problem I will have a solution in mind!
Felt like this would be a good spot to selflessly advertise for my development blog, and newly-opened github repository. If you'd like, you can take a look at how everything is structured. I basically followed the tutorial, and then just started branching off and tweaking/changing things. It's nothing exciting or innovating yet, but I'm still excited.
http://notquiteadom.blogspot.com/https://github.com/MisterMoxxie/ItsStillInBeta