|
Post by Adam on Jul 1, 2010 13:12:08 GMT -5
I finally got around to writing a file transfer program in basic4gl and would like to see how well it runs on other pc's. So far i have tested it on two, the client runs great on both, yet my secondary computer, used as a server, can only transfer to one client at a time. The server runs perfect on my main computer but constantly crashes and laggs on the other. I have gotten two clients connected to the server downloading at the same time so far, and would like to see how well it works over the internet (and not just a lan) I am attaching the client, all you have to do is type in the ip address here is mine~173.81.210.127 if it doesnt connect, please tell me and i will do my best to fix it. otherwise you will see a prompt > from here you have several commands get filename << this downloads a file from the server run filename << this runs a script to download a series of files from the server, among other things. (you usually have to download it first) say << simply prints text to the screen (mostly for use by scripts) if you want a copy of the server simply type get file server.gb to run the test script i have prepared simply type in the following (although i would suggest you put the client in its own folder first) get pics run pics this will download a series of pictures (random screenshots from when I played an emulator for ffvii several years ago, but the work) then tell me how the test goes. Go ahead, you know you want to Attachments:
|
|
|
Post by Adam on Jul 1, 2010 20:20:59 GMT -5
I saw that someone ran the test script and it went ok on the server side, did it work out for you? heres the last time i am gonna upload a client (just got done setting up auto update) looks for an update as soon as you connect. current script commands now: get filename << download file say text << print in green say! text << print in red run filename << run a script version number << checks the program version against others connect ip << connect to a new ip killclient << stops the client program echo (on or off) << works just like cmd stop << stops execution of script Attachments:
|
|
|
Post by Wayne Rayner on Jul 1, 2010 21:01:01 GMT -5
Firstly nice application. I love the auto update you have created. Now here is my problem and I hope you can help me. How do you restart the client because everytime I close it and re open it, the application re updates and tells me i need to restart the client. This has happened about 3 - 4 times.
|
|
|
Post by Adam on Jul 1, 2010 21:08:33 GMT -5
well... when it updates it rewrites the file so just close it and reopen it (if you have it open in the editor close it there too) and see if that helps.. if not can you send me a screenshot of what your window looks like?
|
|
|
Post by Wayne Rayner on Jul 1, 2010 21:34:11 GMT -5
Ok thanks, I had to move it from where I had it in the tempary files folder, as I have windows 7 and when I download files I tend to open them from the deafualt program. So your application didn't have the rights to place the update file. Then it did on the desktop so again I must say nice app, I wish I knew how to make a application like this.
Regards
Wayne Rayner
|
|
|
Post by Adam on Jul 1, 2010 21:39:02 GMT -5
well, for file transfer, you can use get file server.gb then after you run it you can use your computer as a server as well.. I havn't decided but I might make an include for making auto updating programs. would that be helpful?
|
|
|
Post by Wayne Rayner on Jul 1, 2010 21:43:40 GMT -5
Umm for some of my applications it would be nice to have a auto update feature.
Just asking can your update feature say you make your program with a gui would it send the relevent images?
Because that would work really well for me but it doesn't have to as it will still work well for me.
thanks adam for making this awesome application
|
|
|
Post by Adam on Jul 1, 2010 22:00:18 GMT -5
relevent images? con you elaborate?
|
|
|
Post by Wayne Rayner on Jul 2, 2010 3:39:05 GMT -5
I was just saying as a example that your litttle application say had a gui with images in ur next version. Would your client be updated with all the required images and whatever else your appliction gui would use.
Ok the main reason i say this is because I'm creating a game thats going to be updated a lot especially in the graphics section. I would rather have a auto-updater that sends all the new files including images and sounds to the user so they wouldn't have to always download a new version when it is released.
I hope you releated to this post better
|
|
|
Post by Supermonkey on Jul 2, 2010 4:27:43 GMT -5
You'd just have the client grab all the files from the server Wayne. You seem to think the server would send the client files as it needs them, it's actually the other way around.
(1) The client checks with the server if it is up to date. If it is, then you're ok to play. (2) If not, grab the next update from the server. (3) Client installs the update. (4) Go back to one.
The "update" could simply be a bunch of files stored on a server, that the client would download one-by-one.
Alternatively the "update" could be an archive file containing all the updated game data (scripts, images, sounds etc). The installation could simply be extracting the files from the archive.
|
|
|
Post by Wayne Rayner on Jul 2, 2010 4:42:17 GMT -5
Thanks supermonkey, no I get it, gee i had my self confused. thanks again super monkey
|
|
|
Post by Adam on Jul 2, 2010 6:38:47 GMT -5
Its just as super monkey said. Here is how I checked for an update. As soon as the program connects to the server it downloads a file "file client.info" automatically
Here is the contents of the file
echo off version 1.01 say! updating to version 1.01 say This version adds auto update along with several other misc. features say after the update you will need to restart the client to run the new version say! these are the current up to date functions say say get filename << download file say say text << print in green say say! text << print in red say run filename << run a script say version number << checks the program version against others say connect ip << connect to a new ip say killclient << stops the client program say echo (on or off) << works just like cmd say stop << stops execution of script say say to see the content you can get from the server at any time use say get server content say run server content say get file client.gb say update complete say! you need to restart your client killclient
it reads the version number from the file after it downloads it. If the number is greater than the number const in the program then it runs the rest of the script, otherwise it closes the file
|
|
|
Post by shadow008 on Jul 2, 2010 10:46:38 GMT -5
tested it a few min ago... no file to be found....
|
|
|
Post by Adam on Jul 2, 2010 11:21:33 GMT -5
what exactly did you type? and i am sorry for the late reply was asleep.. and I just updated the server cause it seems the only time it doesn't tell me what file is being pulled is when there is an error.. lol
|
|
|
Post by shadow008 on Jul 2, 2010 17:42:19 GMT -5
mkay, worked now. However, when it updated itself, i restarted it and there was minor problem... Nicky's file handeling.dll wasnt dl'd as well... XD
|
|