game: Channel must not be changed when broadcasting.
This commit is contained in:
parent
5fc0bf0741
commit
32f4a0b987
@ -309,8 +309,8 @@ loop(CSocket, GID, Version) ->
|
|||||||
loop(CSocket, GID, Version, SoFar) ->
|
loop(CSocket, GID, Version, SoFar) ->
|
||||||
receive
|
receive
|
||||||
{psu_broadcast, Packet} ->
|
{psu_broadcast, Packet} ->
|
||||||
<< A:16/bits, _:8, B:40/bits, _:32, C:96/bits, _:64, D/bits >> = Packet,
|
<< A:64/bits, _:32, B:96/bits, _:64, C/bits >> = Packet,
|
||||||
Broadcast = << A/binary, 3, B/binary, 16#00011300:32, C/binary, 16#00011300:32, GID:32/little-unsigned-integer, D/binary >>,
|
Broadcast = << A/binary, 16#00011300:32, B/binary, 16#00011300:32, GID:32/little-unsigned-integer, C/binary >>,
|
||||||
egs_proto:packet_send(CSocket, Broadcast),
|
egs_proto:packet_send(CSocket, Broadcast),
|
||||||
?MODULE:loop(CSocket, GID, Version, SoFar);
|
?MODULE:loop(CSocket, GID, Version, SoFar);
|
||||||
{psu_chat, ChatGID, ChatName, ChatModifiers, ChatMessage} ->
|
{psu_chat, ChatGID, ChatName, ChatModifiers, ChatMessage} ->
|
||||||
@ -363,7 +363,7 @@ dispatch(CSocket, GID, Version, Packet) ->
|
|||||||
broadcast(16#0503, GID, Packet) ->
|
broadcast(16#0503, GID, Packet) ->
|
||||||
LID = 0, % TODO: handle the LID correctly
|
LID = 0, % TODO: handle the LID correctly
|
||||||
<< 100:32/little-unsigned-integer, 16#050301:24/unsigned-integer, _:40, 0:32, GID:32/little-unsigned-integer, 0:192,
|
<< 100:32/little-unsigned-integer, 16#050301:24/unsigned-integer, _:40, 0:32, GID:32/little-unsigned-integer, 0:192,
|
||||||
GID:32/little-unsigned-integer, LID:32/little-unsigned-integer, Direction:32/bits, _:96, Coords:96/bits,
|
GID:32/little-unsigned-integer, LID:32/little-unsigned-integer, Direction:32/bits, Coords:96/bits, _:96,
|
||||||
Quest:32/little-unsigned-integer, MapType:32/little-unsigned-integer, MapNumber:32/little-unsigned-integer, MapEntry:32/little-unsigned-integer,
|
Quest:32/little-unsigned-integer, MapType:32/little-unsigned-integer, MapNumber:32/little-unsigned-integer, MapEntry:32/little-unsigned-integer,
|
||||||
_:16, 0:16 >> = Packet,
|
_:16, 0:16 >> = Packet,
|
||||||
User = egs_db:users_select(GID),
|
User = egs_db:users_select(GID),
|
||||||
|
Loading…
Reference in New Issue
Block a user