mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-07-30 23:50:19 -07:00
Initial implementation completion and refactor (#6806)
This commit is contained in:
@@ -1,8 +1,7 @@
|
||||
import webClient from '../../WebClient';
|
||||
import { BackendService } from '../../services/BackendService';
|
||||
|
||||
export function ping(pingReceived: Function): void {
|
||||
const command = webClient.protobuf.controller.Command_Ping.create();
|
||||
const sc = webClient.protobuf.controller.SessionCommand.create({ '.Command_Ping.ext': command });
|
||||
|
||||
webClient.protobuf.sendSessionCommand(sc, pingReceived);
|
||||
BackendService.sendSessionCommand('Command_Ping', {}, {
|
||||
onResponse: (raw) => pingReceived(raw),
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user