Пример #1
0
    public void SendSpinRequest()
    {
        var client = SocketProxy.getInstance().Client;
        var plugin = client.getPlugin();

        plugin?.send("spin");
    }
Пример #2
0
 protected override EzyRequest getLoginRequest()
 {
     return(new EzyLoginRequest(
                SocketProxy.ZONE_NAME,
                SocketProxy.getInstance().UserAuthenInfo.Username,
                SocketProxy.getInstance().UserAuthenInfo.Password
                ));
 }
Пример #3
0
    public void SendPluginInfoRequest(string pluginName)
    {
        var client = SocketProxy.getInstance().Client;

        var request = EzyEntityFactory.newArrayBuilder()
                      .append(pluginName)
                      .build();

        client.send(EzyCommand.PLUGIN_INFO, request);
    }
Пример #4
0
    // Use this for initialization
    void Start()
    {
        // Enable EzyLogger
        EzyLoggerFactory.setLoggerSupply(type => new UnityLogger(type));
        logger = EzyLoggerFactory.getLogger <SocketInitializer>();

        // Set up socket client
        var socketProxy = SocketProxy.getInstance();

        client = socketProxy.setup(host, port);
    }
 public void OnLogin()
 {
     // Login to socket server
     SocketProxy.getInstance().login(username.Value, password.Value);
 }