HTTP Downloader

Post Reply
User avatar
greenie
Full Member
Full Member
Posts: 4444
Joined: Sun Nov 21, 2021 4:55 pm
Jucator SA:MP ?: Nu
Nick:: greenie
Jucator CS ?: Da

HTTP Downloader

Post by greenie »

HTTP Downloader v1.0

Description

Allows server to download files from the web.
Useful for plugins that need auto-updater.

Requirements
Amx Mod X 1.76 or greater
Sockets module
Note: default download limit is 10. to change it open include/httpdl.inc and change the value of MAX_DOWNLOADS then recompile then plugin.

Example
#include <amxmodx>
#include <httpdl>

public plugin_init() {
register_clcmd("say /dl", "test");
}

public test(id) {
new dlid = download("http://google.com/", "addons/amxmodx/data/google.txt");
}

// Called when file is downloaded
public dlcomplete(id, file[]) {
server_print("Downloaded (id: %d) %s", id, file);
}
.zip
π‘΄π’‚π’šπ’ƒπ’† 𝒕𝒉𝒆 𝑬𝒂𝒓𝒕𝒉 π’Šπ’” 𝒕𝒉𝒆 𝑯𝒆𝒍𝒍 𝒐𝒇 𝑨𝒏𝒐𝒕𝒉𝒆𝒓 𝑷𝒍𝒂𝒏𝒆𝒕... ☒️

βœ… GAZDUIRE JOCURI / VPS / GAZDUIRE WEB / SERVERE DEDICATE - Stock NELIMITAT / Valabil comandati pe https://www.zonek.ro/
Post Reply

Return to β€œGeneral Purpose”