mt-mods / beerchat

beerchat mod for minetest
GNU Lesser General Public License v3.0
9 stars 7 forks source link

Creating alias does not handle offline player correctly #103

Closed S-S-X closed 1 year ago

S-S-X commented 1 year ago

Not 100% sure but I think this is what will happen. Simplest fix is to use beerchat.register_callback('after_joinplayer', function(player) ... end and switch actual player channel there.

It would also be possible to check every incoming message for individual recipients but it wouldn't be as clean and would require both additional lookup tables and more careful event handler ordering (more likely to break in future).