Exemple #1
0
 public void Update(JORServer jorServer)
 {
     if (this.ShouldRequestGenObjectInfo())
     {
         jorServer.SendGenObjectInfo(this);
     }
 }
Exemple #2
0
        public void Click(JORServer server)
        {
            var stream = BeginSendPropertyEvent(server);

            stream.Write(0);
            server.SendEvent(stream);
        }
Exemple #3
0
        private void SendPropertyEvent(JORServer server)
        {
            var stream = BeginSendPropertyEvent(server);

            stream.Write(4);
            stream.Write(SelectedIndex);
            server.SendEvent(stream);
        }
Exemple #4
0
        private void SendPropertyEvent(JORServer server)
        {
            var stream = BeginSendPropertyEvent(server);

            stream.Write(4);
            stream.Write(Value);
            server.SendEvent(stream);
        }
Exemple #5
0
 public JORPanel(JORServer server, JORNode node, StringDictionary transDict)
 {
     this.AutoScroll = true;
     this.Server     = server;
     this.Node       = node;
     this.transDict  = transDict;
     BuildPanel(Node);
 }
Exemple #6
0
        private void SendPropertyEvent(JORServer server)
        {
            var stream = BeginSendPropertyEvent(server);

            stream.Write(4);
            stream.Write((ushort)(Value ? 0x01 : 0x00));
            stream.Write((ushort)Mask);
            server.SendEvent(stream);
        }
Exemple #7
0
        public void SetValue(JORServer server, string newValue)
        {
            if (newValue == Text)
            {
                return;
            }

            Text = newValue;
            SendPropertyEvent(server);
        }
Exemple #8
0
        private void SendPropertyEvent(JORServer server)
        {
            var stream = BeginSendPropertyEvent(server);
            var sjis   = Encoding.GetEncoding(932);
            var bytes  = sjis.GetBytes(Text);

            stream.Write(bytes.Length);
            stream.Write(bytes);
            server.SendEvent(stream);
        }
Exemple #9
0
        public void SetSelectedIndex(JORServer server, uint newSelectedIndex)
        {
            if (newSelectedIndex == SelectedIndex)
            {
                return;
            }

            SelectedIndex = newSelectedIndex;
            SendPropertyEvent(server);
        }
Exemple #10
0
        public void SetValue(JORServer server, float newValue)
        {
            if (newValue == Value)
            {
                return;
            }

            Value = newValue;
            SendPropertyEvent(server);
        }
Exemple #11
0
        private void SetCurrentValue(JORServer server, uint newCurrentValue)
        {
            if (newCurrentValue == CurrentValue)
            {
                return;
            }

            CurrentValue = newCurrentValue;
            SendPropertyEvent(server);
        }
Exemple #12
0
        private void SetCurrentClient(HIO2ServerClient client)
        {
            if (client == currentClient)
            {
                return;
            }

            currentClient = client;
            jhiClient     = currentClient != null ? new JHIClient(currentClient) : null;
            jorServer     = currentClient != null ? new JORServer(jhiClient) : null;
        }
Exemple #13
0
        protected MemoryOutputStream BeginSendPropertyEvent(JORServer server)
        {
            MemoryOutputStream stream = server.BeginSendEvent(JOREventType.PropertyEvent);

            stream.Write(Node.NodePtr);
            stream.Write(0); // Unknown, game skips over it
            stream.WriteMagic(Type);
            stream.Write((uint)Kind);
            stream.Write(ID);
            stream.Write(ListenerPtr);
            return(stream);
        }
Exemple #14
0
        private void SetCurrentClient(HIO2ServerClient client)
        {
            if (client == currentClient)
            {
                return;
            }

            currentClient = client;
            jhiClient     = currentClient != null ? new JHIClient(currentClient) : null;
            jorServer     = currentClient != null ? new JORServer(jhiClient) : null;
            if (jorServer != null)
            {
                jorServer.NodeUpdated += NodeUpdated;
            }
            hexBox1.ByteProvider = currentClient != null ? new DynamicFileByteProvider(currentClient.file.CreateViewStream()) : null;
            SyncPanelControls(null);
        }
Exemple #15
0
 public void SetSelectedIndex(JORServer server, uint newSelectedIndex)
 {
     SetCurrentValue(server, Items[(int)newSelectedIndex].Value);
 }