def wrap(handler): if handler.func_code.co_argcount == 0: return nodetoolkit.createRemoteEvent(handler.func_name, lambda arg: handler(), metadata, suggestedNode, suggestedEvent) else: return nodetoolkit.createRemoteEvent(handler.func_name, handler, metadata, suggestedNode, suggestedEvent)
def create_remote_event(name, handler, metadata=None, suggestedNode=None, suggestedEvent=None): return nodetoolkit.createRemoteEvent(name, handler, metadata, suggestedNode, suggestedEvent)