Jump to content


Photo

gmFTP v2


  • Please log in to reply
12 replies to this topic

#1 h0bbel

h0bbel

    GMC Member

  • New Member
  • 252 posts

Posted 30 July 2010 - 08:59 AM

This is version 2 of gmFTP.

Features:

  • Multithreaded downloading/uploading files from/to FTP server
  • Functions to retrieve total size, completed bytes and speed of the file being transferred
  • Error codes
  • Listing files in a FTP directory
  • Creating/removing directories and files
  • Multiple FTP connections

Open index.html in the help folder for help.
I haven't made an example yet, but it should not be hard to use.

(link removed)

Edited by h0bbel, 19 September 2013 - 06:53 PM.

  • 0
The empty archive bug should be fixed on my site.
Please use the "report bug" button on my site to report bugs, makes things clearer.

#2 MrJackSparrow2

MrJackSparrow2

    GMC Member

  • GMC Member
  • 632 posts
  • Version:GM:Studio

Posted 30 July 2010 - 10:45 AM

This is version 2 of gmFTP.

Features:

  • Multithreaded downloading/uploading files from/to FTP server
  • Functions to retrieve total size, completed bytes and speed of the file being transferred
  • Error codes
  • Listing files in a FTP directory
  • Creating/removing directories and files
  • Multiple FTP connections

Open index.html in the help folder for help.
I haven't made an example yet, but it should not be hard to use.

Go to file download


A couple of things. When connecting, can you use an IP address instead of a host name? (I assume yes, but I don't know if you check that before resolving the given string.) Also, could you allow to change the port on connection?
  • 0

#3 h0bbel

h0bbel

    GMC Member

  • New Member
  • 252 posts

Posted 30 July 2010 - 01:41 PM

A couple of things. When connecting, can you use an IP address instead of a host name? (I assume yes, but I don't know if you check that before resolving the given string.) Also, could you allow to change the port on connection?


I've added a function FTP_SetPort (needs to be called before calling FTP_Connect).
Using a IP address should be fine.
  • 0
The empty archive bug should be fixed on my site.
Please use the "report bug" button on my site to report bugs, makes things clearer.

#4 iceshield

iceshield

    GMC Member

  • GMC Member
  • 515 posts
  • Version:GM:Studio

Posted 11 September 2010 - 01:35 PM

can i get a file total size without calling FTP_TransferBegin script?
  • 0

If you put comments in your code to understand it ... then you awful at writing code.


#5 Janx

Janx

    GMC Member

  • New Member
  • 12 posts

Posted 17 October 2010 - 09:55 PM

Hey, i think the help is missing some information...

When using:
FTP_PutFile

Sometimes it returns -12110 or -6, and there aren't any error with those values! =/
What does it mean?

Edited by Janx, 17 October 2010 - 09:57 PM.

  • 0

#6 Destron

Destron

    GMC Member

  • GMC Member
  • 1361 posts
  • Version:GM:Studio

Posted 01 January 2011 - 11:49 AM

In your manual it says FTP_TransferStatus returns the following values:

FTP_STATUS_RUNNING
FTP_STATUS_NOT_RUNNING
FTP_STATUS_COMPLETED
FTP_STATUS_FAILED

FTP_STATUS RUNNING does not seem to work... I was trying to draw some information on the screen based on these values. I worked around it by checking if FTP_TransferSataus == FTP_STATUS_COMPLETED or != FTP_STATUS_COMPLETED to see if it's still running or not.

Other than that, great dll. Simple, easy to use, and does just what I need.
  • 0
HTML5 INI Saving Example | HTML5/GMS Saving/Loading/User Login with PHP/MySQL/Async | GameMaker Examples/Tutorials | PHP/MySQL cross platform high score list/leaderboard
Those who try to do something and fail are infinitely better than those who try to do nothing and succeed.

#7 Tumetsu

Tumetsu

    GMC Member

  • New Member
  • 433 posts

Posted 03 January 2011 - 08:43 PM

When I try to upload file to my server, my game seems to freeze for a time, upload corrupted file to the server and generally speaking won't work. I can't for example detect the status of transfer in real time (since program freezes). I'm not sure if I have done something wrong with starting uploading, since there weren't straight example provided. Here is my code:

FTP_Init();
handle = FTP_CreateHandle();
FTP_Connect(handle,host,username,password); //connect to the server


//transfer image file
Transfer = FTP_TransferCreate (handle,1,"senfield.png",destination);
Result = FTP_TransferBegin (Transfer);

I tried to keep on eye the process with code provided in help file but it didn't work. What I'm doing wrong?
Also, looks like Result variable is 0.

Edited by Tumetsu, 03 January 2011 - 08:58 PM.

  • 0
Posted Image

#8 PrinceOthman

PrinceOthman

    GMC Member

  • GMC Member
  • 490 posts
  • Version:GM:Studio

Posted 17 July 2012 - 06:02 AM

I keep getting "0" or " Invalid handle" every time I use <FTP_PutFile()> or <FTP_GetFile()>... Can someone tell me how to use <FTP_CreateHandle()> properly?

Here's my code:
FTP_Init();
handle=FTP_CreateHandle();
server="princeothman.99k.org";
username="princeothman_99k";
password="****";
file=get_open_filename("","")
FTP_SetPort(21);
FTP_Connect(handle,server,username,password);
test=FTP_PutFile(file,file);
show_message(test)

I'm using Zymic.com's ftp file hosting. Could the problem be with the site?
  • 0

Try pressing this rep_up.png button next to my post, and tell me what happens.  :)
add.png


#9 KangHyunSoo

KangHyunSoo

    GMC Member

  • New Member
  • 4 posts
  • Version:GM:Studio

Posted 25 January 2015 - 04:55 AM

Link is removed. How can I get this dll?


  • 0

#10 kebaplover

kebaplover

    GMC Member

  • GMC Member
  • 141 posts
  • Version:Unknown

Posted 25 January 2015 - 07:15 PM

Link is removed. How can I get this dll?

 

with gamemaker.cc:

http://gamemaker.cc/...load/gmftp2.php


  • 0

#11 Reneoc

Reneoc

    GMC Member

  • GMC Member
  • 21 posts
  • Version:GM:Studio

Posted 21 May 2015 - 01:34 PM

Works on Windows. Cant get to work with Android. Says it cant define external function. Any ideas?


  • 0

#12 kebaplover

kebaplover

    GMC Member

  • GMC Member
  • 141 posts
  • Version:Unknown

Posted 23 May 2015 - 08:31 PM

Works on Windows. Cant get to work with Android. Says it cant define external function. Any ideas?

 

This is a DLL. DLLs are Windows only. You can't use them on any other device.


  • 0

#13 Tina

Tina

    GMC Member

  • New Member
  • 4 posts
  • Version:GM8

Posted 24 February 2016 - 05:00 AM

This is really useful. I used this DLL and U.Y.ftp one, but both of them freeze game window... Is there any other FTP DLL that doesn't freeze window (for :GM8_new:) :GM060:    I belive it is possible because HTTP dll 2 doesn't freeze window while working, but still doesn't have the FTP features... :thanks:


Edited by Tina, 24 February 2016 - 05:01 AM.

  • 0