Jump to content

downloadFile


Recommended Posts

hello guys

i'm trying to download a file from other resource like using exports to download the file

calling downloadFile from other resource, but i always get the error: file not exists

why i get that error ?

 

codes of the call:

function download (file)
    downloadFile (file)
end

codes of calling:

addEventHandler ("onClientResourceStart", resourceRoot, 
    function ()
        exports["file"]:download ("files/skin.txd")
    end
)

 

Edited by #Black_Hawk
Link to comment

no it's exists and it defined in the meta nothing wrong but i got that error always

 

here is the meta:

<meta>
    <info name="" description="" type="script" version="1.0" />
    <script src="models.lua" cache="false" type="client"/>

    <file src="files/skin.txd" download="false"  />
</meta>

 

Link to comment
  • Discord Moderators
9 hours ago, Dziugasc said:

Because it doesn't exist maybe xD 

Best answer ever...

Btw, why you want to download that file?Even if its in the x resource you can use it in the y resource like this:

--Example
local font = dxCreateFont(":x/files/font.ttf",9,false,"antianalised")

 

Edited by Pirulax
Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...