Function SaveIt(fileExt$)
Hide Mouse
Do
Inc i:s$=str$(i)+"."+fileExt$
If File Exist(s$)=0 Then Exit
Loop
Save bitmap s$
Cls:Wait 200
Do
Text 0,0,"[Saved]"
Text 0,10,"Press any key to continue..."
If ScanCode()<>0 then exit
Loop
`Give them some time to let go of the key
Wait 200:Load Bitmap s$:Show Mouse
Endfunction
Paste that on the end of the file, after everything.
Then, just above the 'loop' command, put this code:
Quote: "
If InKey$()="0" Then SaveIt("JPG")
"
...Replacing 'JPG' with 'Png' if you want PNG files to be saved instead of JPEG, 'BMP' for Bitmaps, etc.
Then just press the zero key when you want to save a screenshot of your beautiful work.
(Note: Not all computers are capable of saving all formats in DarkBasic...)
[Edit: Oops, you already used the spacekey... Now it's a zzzero. ^^]
[Edit 2: Damn. Stupid me. The mouse was getting shown in the screenshot. Fixed, and I compressed the code, too.]
Part of the 'Emergency Response Noob Shooting Team' :: Feel free to add me to MSN, but don't expect any big favours [unless you like VB6]. ... I pwn small creatures.