feat: Enhance draft system with 4-player 'pick 2' rules, minimum player count, and fix pack duplication by ensuring unique pack instances.
All checks were successful
Build and Deploy / build (push) Successful in 1m25s
All checks were successful
Build and Deploy / build (push) Successful in 1m25s
This commit is contained in:
@@ -85,8 +85,18 @@ export const GameRoom: React.FC<GameRoomProps> = ({ room: initialRoom, currentPl
|
||||
const handleDraftUpdate = (data: any) => {
|
||||
setDraftState(data);
|
||||
};
|
||||
|
||||
const handleDraftError = (error: { message: string }) => {
|
||||
alert(error.message); // Simple alert for now
|
||||
};
|
||||
|
||||
socket.on('draft_update', handleDraftUpdate);
|
||||
return () => { socket.off('draft_update', handleDraftUpdate); };
|
||||
socket.on('draft_error', handleDraftError);
|
||||
|
||||
return () => {
|
||||
socket.off('draft_update', handleDraftUpdate);
|
||||
socket.off('draft_error', handleDraftError);
|
||||
};
|
||||
}, []);
|
||||
|
||||
const sendMessage = (e: React.FormEvent) => {
|
||||
|
||||
Reference in New Issue
Block a user