Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add PLAYER_EVENT_ON_CAN_JOIN_LFG #86

Merged
merged 2 commits into from
Jan 1, 2023
Merged

Conversation

r-o-b-o-t-o
Copy link
Member

@r-o-b-o-t-o r-o-b-o-t-o commented Dec 31, 2022

Adds a new Player event:

PLAYER_EVENT_ON_CAN_JOIN_LFG = 50, // (event, player, roles, dungeons, comment) - Can return false to prevent queueing

Example Lua snippet:

local PLAYER_EVENT_ON_CAN_JOIN_LFG = 50

RegisterPlayerEvent(PLAYER_EVENT_ON_CAN_JOIN_LFG, function(event, player, roles, dungeons, comment)
	print("Player: " .. player:GetName())
	print("Roles: " .. tostring(roles))
	print("Dungeons:")
	for i = 1, #dungeons do
		print(dungeons[i])
	end
	if (comment ~= nil) then
		print("Comment: " .. comment)
	end

	return false -- prevent queueing
end)

@r-o-b-o-t-o r-o-b-o-t-o merged commit 295fcef into master Jan 1, 2023
@r-o-b-o-t-o r-o-b-o-t-o deleted the feat/can-join-lfg branch January 1, 2023 18:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant