Easily import files from (or export files to-!) around the Windows file system without being trapped in a sandbox! Works with any file type. Images, text, anything that GameMaker can consume (or output)!
It also writes to the log at the bottom of GameMaker so you can know exactly what's going on!
Example code to add a sprite:
FileCopyIn_Init(); // Run once at the start of the game
FileCopyIn("G:/Documents/Dropbox/logo/8_200x.png", "grabbed_file.png"); // Copy this png file to the local folder and rename to grabbed_file.png (for dealing with files of the same name)
sprite_index = sprite_add("grabbed_file.png", 1, false, false, 0, 0); // Add image to game and set the object's sprite to it!
It's that easy! These files are put in GameMaker's games' temporary directory, so you shouldn't need to worry about cleaning them out. (Manual wipe coming very soon, though.)
You probably won't, but if you should encounter any issue, or would like to request a feature or tweak, please feel free to email me. I will get back to you as quickly as possible.
(Expect Frequent Updates!)
1.0.0: - Initial Release
1.0.1: - Minor Code Change
1.0.2: - Copy function now returns success as a boolean to make it even easier! (See new screenshot) - More debug information printed
1.0.3: - Can Copy Files OUT! - A little extra info added for functions - Example Code added
Version 1.0.3. Published August 15, 2014
Created with GameMaker: Studio v1.4.1398
You can only review assets you've bought.
Very nice and easy to use!
Is it possible to use this to copy a folder and subfolders?
Very easy to use.
Implement a file browser?
If you can implement a file browser using this it would be infinitely more useful. It does do exactly what it says although having to manually code in the file location is a bummer...
Very specific, but still useful
I needed this a year ago, but oh well. I have it now and honestly, it is neat for allowing players to implement custom sprites.
Total size 9.26 KB