ffrostfall/ByteNet

Packet type has invalid methods defined.

Opened this issue · 4 comments

Packet type has method sendToList defined, but this method does not exist (should be sendToPlayers). It is also missing sendToAllExcept.

Corrected type:

type Packet<T> = {
	sendToAll: (data: T) -> (),
	sendTo: (data: T, target: Player) -> (),
	sendToPlayers: (data: T, targets: { Player }) -> (),
	sendToAllExcept: (data: T, except: Player) -> (),
	
	wait: () -> T,
	send: (data: T, target: Player?) -> (),
	listen: (callback: (data: T, player: Player?) -> ()) -> (),
}

Solved in the next version

Still an issue as of 0.4.2 (worth noting I am downloading the rbxm, maybe that isn't updated)

sendToAllExcept wasn't defined. Oops

Also sendToList should be sendToPlayers.