Jump to content

[Question] Can't Require Priority Queue...?

Recommended Posts

Hey guys,


Really simple question today! For a project, I want to use lua's inbuilt PriorityQueue - so of course I write a good 'ol require seen below

require "loop.collection.PriorityQueue"

Unfortunately, I get an error message telling me that the module could not be found. Is this because this library is not available to us? Or is my require call wrong? A swift answer would be super cool! Thanks :D




Link to comment
Share on other sites

As @squeek pointed out, this is part of LOOP, not core Lua. Since LOOP is a pure Lua library (actually, a set of libraries), you may include it (or part of it) in your mod, however this will certainly bloat its size.

It would be nice if Don't Starve included some Lua libraries, but it does not, except for a Windows-only* LuaSocket.

* Which is silly. LuaSocket is absolutely cross-platform, and was originally developed under Linux. I can't get why DS doesn't offer it for every platform.

Link to comment
Share on other sites


This topic is now archived and is closed to further replies.

Please be aware that the content of this thread may be outdated and no longer applicable.

  • Create New...