Forest Logo
search
package_2

line

By @sennoza

Roblox

Mirrored

Line

A very simple and undoubtedly very stupid remote wrapper for Roblox.


Installation:

Import with wally

Line = "sennoza/line@0.0.2"

Import with Roblox

Place "Line.luau" into ReplicatedStorage


Usage:

Create a second module in ReplicatedStorage to store your remote layout

-- Module in ReplicatedStorage
local Line = require(game.ReplicatedStorage.Line)

 -- Return remote hierarchy table
return {
	someNamespace = {
		someEvent = Line.event()
	},

	someOtherNamespace = {
		someEvent = Line.event()
	},
}

Access from server and client scripts

-- Server Script
local Line = require(game.ReplicatedStorage.Line)

Line.someNamespace.someEvent.listen(function(client: Player, message: string)
	print(client.Name, "Said", message)
end)
-- Client Script
local Line = require(game.ReplicatedStorage.Line)
Line.someNamespace.someEvent.sendServer("Hello!")

Line uses additive instance naming (foolishly) so your remote hierachy can be as many namespaces deep as you wish.

Simple API:

-- Server
event.sendClient(client: Player, ...any)
event.sendAllClients(...any)
event.sendClientList(list: {Player}, ...any)

-- Client
event.sendServer(...any)

-- Shared
event.listen(callback: (...any) -> ())
event.once(callback: (...any) -> ())
event.wait() -> (...any)

Package Details

Install command (Click to copy)


Version

0.0.4

License

SEE LICENSE IN LICENSE

warning

Usable with conditions

infoNo attribution required, but recommended for good practice.

infoNo warranty provided for the work.

infoNo trademark or patent rights are waived.

infoAffirmer disclaims responsibility for clearing rights of other persons.

infoCustom license terms, automatically reviewed — read the packaged LICENSE file before shipping this in a game.

Automated license review — not legal advice.