ScriptUO
Official ScriptUO EasyUO Scripts => Scripting Chat => Topic started by: Thimotty on October 04, 2009, 06:40:06 PM
-
Very often the send command hang because of lost packets.
Does anyone know workaround to use it without waiting for anything to be returned?
-
There's probably not a real way to do it. It's been a while, but I kinda got around it by having a local server to send information to. Then I'd convert to UDP packets for any interwebz transmission.
-
Thank @TM I'll try it now.
-
Remember that with UDP, you'll probably not get your data assembled correctly, or even completely. So you'll have to think of some ways to encode it so you know if everything is ship shape.
You might be able to use TCP, and with a local server, at least you can handle missing packets and handle it accordingly.
-
I just tried sending to local server (without external resend)
Still hangs :'(
I'm thinking of some background "CMD" to use exec instead of send :(
-
The other thing I've done is communicate to an outside program using the EUO registry and create a simple COMMAND/ARGUMENT C# "server". Then you just communicate however you want in your application to the interwebz.
-
Still cannot solve it. The best i did is to write the info in a file using [urlhttp://www.ntwind.com/software/utilities/hstart.html]this[/url] application without the annoying windows opened with each execute, but it is extremely slow. It runs cmd.exe in background mode but 1 record for 2 seconds :(
-
If you want, I can zip up my EUO client/C# server application for communication through the registry. Works pretty well. I just have to find it, but it might give you some ideas.
-
I probably won't be able to read it, but at least I can try :)
-
Here's the little bit of test code for this example:
set #LPC 100
for %i 1 10
{
gosub TM_SENDVAL command , %i %i
}
stop
sub TM_SENDVAL
set *TMREG_ARG1 %1
set *TMREG_VAL %2
set *TMREG_CMD SENDVAL
set #RESULT #SCNT + 5
repeat
until *TMREG_CMD <> SENDVAL || #SCNT > #RESULT
if #SCNT > #RESULT
display ok You should start the .NET SystemMonitor
return
In the zip file, there's an executable in the debug folder you can use to play with this.
-
Yep, I cannot read it. It just fill it's window. And the C code is in OOP which is beyond my level even in php :(
I'll try to develop a solution of myself
Actually i have found a tool that record registry key changes into a file and is working fast enough :)
-
Well, pay no attention to what it was coded IN, but rather think about the method. You can access the EUO registry in PHP just like you can in C#. Knowing that, you can basically code in PHP what I coded in C#. There's no C# or OOP magic going on. It's very simple actually.
-
Yes, i found some classes for php+windows registry, but don't have time to test them now.
Here is the first "pre-alpha" result from my efforts :P
http://aceputersstore.com/uodb/openitems.php (http://aceputersstore.com/uodb/openitems.php)
in my todo:
show vendor location (the info is in my db already)
better search
detail info for one or multiple items
I could use some suggestions how to make it better :)