RanvierMUD / core

Core engine code for Ranvier
https://ranviermud.com
MIT License
45 stars 41 forks source link

Area#removeRoomFromMap #93

Open ratacat opened 5 years ago

ratacat commented 5 years ago

Currently if you Area#addRoom() it adds the room to the floor map, but you if call Area#removeRoom, it removes it from the area, but leaves it in the floor map. Resulting in bad things, like crashes when a player tries to view adjacent rooms that lookup their implied exits through the floor map. Any suggestions on how this could better?

shawncplus commented 5 years ago

Code looks solid, I'd really like a unit test for it though

ratacat commented 5 years ago

I have absolutely no idea how to do that, but I'm willing to try =) Any examples I can look at?

shawncplus commented 5 years ago

https://github.com/RanvierMUD/core/blob/master/test/unit/Attribute.js is a super simple example. I'm been really bad about adding tests so there aren't many but that's a good base to work off of, it's using mocha