Skip to content

V14.2.x

Compare
Choose a tag to compare
@rayaman rayaman released this 14 Mar 13:16

Added:

  • Type: destroyed
    • A special state of an object that causes that object to become immutable and callable. The object Type is always "destroyed" it cannot be changed. The object can be indexed to infinity without issue. Every part of the object can be called as if it were a function including the indexed parts. This is done incase you destroy an object and still use it somewhere. However, if you are expecting something from the object then you may still encounter an error, though the returned type is an instance of the destroyed object which can be indexed and called like normal. This object can be used in any way and no errors will come about with it.

Fixed:

  • thread.holdFor(n,func) and thread.holdWithin(n,func) now accept a connection object as the func argument
  • Issue with threaded functions not handling nil properly from returns. This has been resolved and works as expected.
  • Issue with system threaded job queues newFunction() not allowing nil returns! This has be addressed and is no longer an issue.
  • Issue with hold like functions not being able to return false
  • Issue with connections not returning a handle for managing a specific conn object.
  • Issue with connections where connection chaining wasn't working properly. This has been addressed.
     package.path="?.lua;?/init.lua;?.lua;?/?/init.lua;"..package.path
     local multi,thread = require("multi"):init()
     test = multi:newConnection()
     test(function(hmm)
     	print("hi",hmm.t)
     	hmm.t = 2
     end)(function(hmm)
     	print("hi2",hmm.t)
     	hmm.t = 3
     end)(function(hmm)
     	print("hi3",hmm.t)
     end)
     test:Fire({t=1})

Changed:

  • Destroying an object converts the object into a 'destroyed' type.
  • connections now have type 'connector_link'
     OnExample = multi:newConnection() -- Type Connector, Im debating if I should change this name to multi:newConnector() and have connections to it have type connection
     conn = OnExample(...)
     print(conn.Type) -- connector_link

Removed: (Cleaning up a lot of old features)

  • Removed multi:newProcessor(STRING: file) — Old feature that is not really needed anymore. Create your multi-objs on the multi object or use a thread
  • bin dependency from the rockspec
  • Example folder and .html variants of the .md files
  • multi:newTrigger() — Connections do everything this thing could do and more.
  • multi:newHyperThreadedProcess(name)*
  • multi:newThreadedProcess(name)*
  • multi.nextStep(func)* — The new job System can be used instead to achieve this
  • multi.queuefinal(self) — An Old method for a feature long gone from the library
  • multi:setLoad(n)*
  • multi:setThrestimed(n)*
  • multi:setDomainName(name)*
  • multi:linkDomain(name)*
  • multi:_Pause()* — Use multi:Stop() instead!
  • multi:isHeld()/multi:IsHeld()* Holding is handled differently so a held variable is no longer needed for chacking.
  • multi.executeFunction(name,...)*
  • multi:getError()* — Errors are nolonger gotten like that, multi.OnError(func) is the way to go
  • multi.startFPSMonitior()*
  • multi.doFPS(s)*

*Many features have become outdated/redundant with new features and additions that have been added to the library