Hello all, this is a simple SWEP release as an example for the gmcl_screenshots module.
This addon and module is the result of an idea by CapsAdmin.
[QUOTE=CapsAdmin;28468655]Is it possible to somehow make gmod_camera upload screenshots to steam? I really don't want to run the steam overlay since I'm playing in windowed mode (fucks up steam friends)
if there was a function bound to take a screenshot and upload to your steam profile, I could see it being abused though. Hmm.[/QUOTE]
I thought to myself that this is an interesting idea, so I went about to create it.
This requires a clientside module which implements the screenshot functionality. The source is in the download archive, in lua/includes/modules/ or viewable at: [url]https://code.google.com/p/gmodmodules/source/browse/trunk/gmcl_screenshots/gmcl_screenshots/main.cpp[/url]
The module doesn't publish your screenshots to steam cloud, it simply caches them locally and you can publish them later using the Steam screenshot manager. This is basically the same as using the game overlay and pressing F12, except this is controlled by lua code.
[release]
[b]Download[/b]: [url]http://dl.dropbox.com/u/99606/gmod/cloud_camera_v1.rar[/url]
[b]Requires:[/b] [url=http://www.microsoft.com/downloads/en/details.aspx?FamilyID=9b2da534-3e03-4391-8a4d-074b9f2bc1bf&displaylang=en]C++ 2008 Runtime[/url]
[/release]
Here's an example of what it can do: [url]http://steamcommunity.com/id/VoiDeD/screenshot/541761942787792359[/url]
[b]Important Note!![/b]
This module makes use of a feature that could potentially break during Steamclient updates. If a steam update comes out and this module is causing crashes or otherwise random behavior, please let me know ASAP!
[b]For developers[/b]
This module exposes a global table named screenshots, and a single function called Take. The function returns a boolean value indicating if the screenshot was taken successfully.
Example code:
[lua]
require( "screenshots" )
...
local bSuccess = screenshots.Take()
MsgN( "Took screenshot! Success: ", bSuccess )
[/lua]
-snip- misread.
looks useful
i will use this camera tool to document The Garry Mod Tower 9/11.
Looks very useful, is there any way around using a .dll?
Didnt work for me.
Nothing happened
[QUOTE=superstepa;28489548]Didnt work for me.
Nothing happened[/QUOTE]
[QUOTE=VoiDeD;28481361]
The module doesn't publish your screenshots to steam cloud, it simply caches them locally and you can publish them later using the Steam screenshot manager.[/QUOTE]
-snip, obvious question-
I'll be doing this
[lua]
require("screenshots")
hook.Add("KeyPress", "cloud_screenshots", function(ply, key)
if screenshots and ply:GetActiveWeapon():IsWeapon() and ply:GetActiveWeapon():GetClass() == "gmod_camera" and key == IN_ATTACK then
if not screenshots.Take() then
print("failed to take steam cloud screenshot!")
end
end
end)
[/lua]
so I don't have to install anything on the server
handy
Sorry, you need to Log In to post a reply to this thread.