mirror of https://github.com/minetest/minetest.git
Adjusted coding style
Adjusted the coding style of commitf12f74c
bfabc52
to fit the general coding style of the builtin lua routines
This commit is contained in:
parent
bfabc52841
commit
c125b5d914
|
@ -42,15 +42,15 @@ end
|
|||
|
||||
local player_list = {}
|
||||
|
||||
minetest.register_on_joinplayer( function( player_ref )
|
||||
if player_ref:is_player() then
|
||||
table.insert( player_list, player_ref )
|
||||
minetest.register_on_joinplayer( function(player)
|
||||
if player:is_player() then
|
||||
table.insert(player_list, player)
|
||||
end
|
||||
end)
|
||||
|
||||
minetest.register_on_leaveplayer( function( player_ref )
|
||||
minetest.register_on_leaveplayer(function(player)
|
||||
for index, value in pairs(player_list) do
|
||||
if player_ref:get_player_name() == value:get_player_name() then
|
||||
if player:get_player_name() == value:get_player_name() then
|
||||
table.remove(player_list, index)
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue