Skip to content

Commit 66bb7fc

Browse files
luk3yxkaeza
authored andcommitted
Prevent players from joining the channel when logged in from IRC
1 parent b4fbccd commit 66bb7fc

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

player_part.lua

+2
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,8 @@ end
1313
function irc.player_join(name)
1414
if irc.joined_players[name] then
1515
return false, "You are already in the channel"
16+
elseif not minetest.get_player_by_name(name) then
17+
return false, "You need to be in-game to join the channel"
1618
end
1719
irc.joined_players[name] = true
1820
return true, "You joined the channel"

0 commit comments

Comments
 (0)