Node Downloader is a plugin for Construct 3 and construct 2 game engine that allows you to download a file from a URL and save it in the player's PC.
❗ Node Downloader only works with NW.js (and Electron).
Actions
Starts download a file(Tag,URL,Path,Name)
Tag:An optional name to distinguish between downloads
URL:URL of file that is to be downloaded
Path:Location that downloaded file will be saved to it
Name:The name with which the file is downloaded and saved
Conditions
On completed
This event occurs once while the file downloaded and saved on the disk.
Tag:An optional name to distinguish between downloads
On error
If the file couldn't be downloaded for any reason this event will trigger and the reason of error logs in to the console.
Tag:An optional name to distinguish between downloads
On progress
Each file should be fragmented for downloading. After each slice of the file received, this event triggers and Percent expression will be accessible.
Tag:An optional name to distinguish between downloads
Expressions
Percent(tag)
Get the progress of downloading, from 0 to 100. This expression will be updated when a slice of the file received. So use it only in On progress event.
Tag:An optional name to distinguish between downloads
TotalSize(tag)
Get the total size of the file, in bytes. This expression is only accessible when downloading is in progress. So you can use it in On progress or On completed events. After that, it returns 0.
Tag:An optional name to distinguish between downloads
downloadedsize(tag)
Get the total downloaded size of the file, in bytes. This expression is only accessible when downloading is in progress. So you can use it in On progress or On completed events. After that, it returns 0.
Tag:An optional name to distinguish between downloads
filename(tag)
Tag:An optional name to distinguish between downloads
filetype(tag)
Tag:An optional name to distinguish between downloads