Mudlet Code Snippets - post any useful ones you might have here!



  • AeldraAeldra , using cake powered flight Member Posts: 1,319 Transcendent
    Selenity said:
    First of all, you'll need this function I made because I don't remember what the Mudlet version of it is.

    function inArray(array_, key)
      result = table.index_of(array_, key)
      return result and true or false

    for the record, you can use
    table.contains(array, value)
    for that. For a list of mudlet specific functions, I have this bookmarked:

    Avatar / Picture done by the lovely Gurashi.
  • QuixoteQuixote Manchester, UKMember Posts: 48 Novice
    Little snippet somebody asked me to write. Shove this in an alias.

    Pattern match: 
    Containing the code:
    local room =
    if not room:find("The Cave of") then return end
    send("karma blessing ""%w+$"))
    Then simply type bless when in a karma cave and it'll send the correct type.
Sign In or Register to comment.