alathon / AwesomeMUD

An awesome MUD in Scala
1 stars 1 forks source link

Extend CommandComponent.Search to allow a filter function #8

Open alathon opened 10 years ago

alathon commented 10 years ago

Currently, search returns a list of game entities depending on the location specified.

Extend Search.getEntitiesInLocation to require a filter function as well, and provide a Ref constructor through object Ref that supports a filter function. If no filter function is given, pass an anonymous function that simply accepts everything.