2.4.6 • Published 2 years ago

@rbxts/ping v2.4.6

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

Ping

Yet another super simple bindable event wrapper which uses ✨camelCase✨ and allows connection directly or via an encapsulated connector, which is useful for replicating the behaviour of regular Roblox signals.

Example

A simple example, there isn't much to this library.

class PingExample {
	// Both of these work!
	private ping = new Ping<(player: Player) => void>();
	private ping = new Ping<[player: Player]>();

	// Open up the API to connect to the ping externally
	public readonly onPing = this.ping.connector;

	private foo(player: Player) {
		// Alerts all connections
		this.ping.fire(player);
	}
}

const example = new PingExample();

// To any external users, only .connect, .connectParallel and .wait are available.
example.onPing.connect((player) => {
	print(player);
});
2.4.6

2 years ago

2.3.5

2 years ago

2.2.5

2 years ago

2.2.4

2 years ago

2.2.3

2 years ago

2.2.2

2 years ago

2.0.1

2 years ago

1.0.1

2 years ago

1.0.0

2 years ago