Search found 21 matches

by jalamaya
Tue Feb 09, 2016 12:42 pm
Forum: Support and Development
Topic: [SOLVED]Saving images opened via filedropped
Replies: 10
Views: 3960

Re: Saving images opened via filedropped

bartbes wrote:Oops, my bad! But in that case, don't do what you said. ;)

what shouldn't i do again? im kinda confused sorry
by jalamaya
Tue Feb 09, 2016 11:41 am
Forum: Support and Development
Topic: [SOLVED]Saving images opened via filedropped
Replies: 10
Views: 3960

Re: Saving images opened via filedropped

I'd advise against using the lua io library in any capacity, and sticking to love.filesystem wherever possible. One issue you may be having is that you haven't opened the file in binary mode, causing the io lib/windows to completely break the file you're saving out. Guess what, love.filesystem does...
by jalamaya
Tue Feb 09, 2016 2:19 am
Forum: Support and Development
Topic: [SOLVED]Saving images opened via filedropped
Replies: 10
Views: 3960

Re: Saving images opened via filedropped

is there a possible way to use this string:

ImageData: 0x375fc192f0

i got it from:

Code: Select all

file:write(tostring(love.image.newImageData(love.filesystem.newFileData(data, 'img', 'file'))))
by jalamaya
Mon Feb 08, 2016 7:20 pm
Forum: Support and Development
Topic: [SOLVED]Saving images opened via filedropped
Replies: 10
Views: 3960

Re: Saving images opened via filedropped

Explain what you mean by the way you planned, please. What does it do? what did you expect it to do? sorry again, i didnt read your comment carefully. what i planned is file = io.open("image.jpg","w+") file:write(tostring(data)) --data is the filedata of the image dragged and dr...
by jalamaya
Mon Feb 08, 2016 3:47 pm
Forum: Support and Development
Topic: [SOLVED]Saving images opened via filedropped
Replies: 10
Views: 3960

Re: Saving images opened via filedropped

Explain what you mean by the way you planned, please. What does it do? what did you expect it to do? sorry if i didn't explained it clearly :D :P settings like: sounds, screen resolution, game mode, i save(string, boolean, numbers) the values by writing it in settings.lua. then i require it in main...
by jalamaya
Mon Feb 08, 2016 1:43 pm
Forum: Support and Development
Topic: [SOLVED]Saving images opened via filedropped
Replies: 10
Views: 3960

[SOLVED]Saving images opened via filedropped

i have a simple saving mechanism where i write the data using file:write() in a lua file(settings.lua) upon a certain event. then if you start the program, the main.lua would load data from settings.lua. for boolean, numbers and strings, it works quite fine. now i have a love.filedropped function an...
by jalamaya
Tue Jan 26, 2016 1:46 pm
Forum: Support and Development
Topic: "Questions that don't deserve their own thread" thread
Replies: 905
Views: 420415

Re: "Questions that don't deserve their own thread" thread

If you're running an executable (rather than a .love file), then the file location would be Appdata/Roaming/svdir/imageX.jpg But if not, could you post a picture of your imageX.jpg file with the location on top? And the part of the code responsible for loading it. Just to make sure there aren't any...
by jalamaya
Tue Jan 26, 2016 2:50 am
Forum: Support and Development
Topic: "Questions that don't deserve their own thread" thread
Replies: 905
Views: 420415

Re: "Questions that don't deserve their own thread" thread

You access it the same way. Files in the save folder are checked before the files in the .love our source folder. why do i get a not exist error message when i try to load the image from the save directory? file location: appdata/roaming/love/svdir/imageX.jpg love.filesystem.setIdentity("svdir...
by jalamaya
Mon Jan 25, 2016 5:12 pm
Forum: Support and Development
Topic: "Questions that don't deserve their own thread" thread
Replies: 905
Views: 420415

Re: "Questions that don't deserve their own thread" thread

how do you access files from the save directory (im using windows so appdata)?

if the file is inside the source folder, you just have to do is:

Code: Select all

fileLoc="(folder if theres any)/file.jpg"
but what will i do if the file is in the save directory?
by jalamaya
Sun Jan 24, 2016 2:34 pm
Forum: Support and Development
Topic: [SOLVED]program runs perfectly in IDE but errors in .love
Replies: 6
Views: 2443

Re: program runs perfectly in IDE but errors in .love

slime wrote:Users can drag-and-drop files and folders onto the game's window
wow! that's actually a cool way of importing files. ill look into that tomorrow.

thank you all guys!