AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Module Coding (https://forums.alliedmods.net/forumdisplay.php?f=9)
-   -   SteamTools (v1.2.0) (https://forums.alliedmods.net/showthread.php?t=261044)

Arkshine 04-05-2015 09:57

SteamTools (v1.2.0)
 


SteamTools
「 v1.2.0, October 19th, 2017 - github.com/Arkshine/SteamTools



Table of contents:

DESCRIPTION
0
This module gives access to a select few SteamWorks functions for AMX Mod X plugins.
For people who don't know, SteamWorks is basically an API provided by Steam which developers can use to integrate many of Steam's functions.

Interface presently supported and exposed to Pawn is essentially ISteamGameServer for now.

Usually, the relevant interfaces from GoldSrc server point of view are: ISteamGameServer, ISteamUtils, ISteamNetworking, and ISteamHTTP.
Not all functions are going to work for GoldSrc, but let met know if they are some you would want to see implemented.

API
0
The fast way is to check directly steamtools.inc include.
All is documented, it should be easy to use them.

CVARS
0
sv_setsteamaccount <login_token>

From this thread, https://forums.alliedmods.net/showthread.php?t=234901:

Gameserver accounts are now a Steam feature.
Using a steam gameserver account provides one important advantage right now: client favorite lists are keyed by the Steam account if present. This means that you can move your server to another IP address, and clients who have your server in their favorites or history will follow you to your new location.


How to get a login token?

➀ Follow instructions here: http://steamcommunity.com/dev/managegameservers
➁ Open 1amxmodx/configs/steamtools.cfg and paste the login token as cvar value.
➂ On server start, Steam should be able to establish connection (if not, you pasted a wrong token)

➥ It could take some time before server being recorded by Steam.

NOTES
0
  • ISteamHTTP is likely to be supported for the next version.

CREDITS
0
  • asherkin and KyleS: Largely inspirated from their SteamTools and SteamWorks SourceMod extension respectively.
  • GoRiLliAz (cs.team-shk.fr): Originally a paid request for specific feature and I would not done a full API without his request

CHANGELOG
0

INSTALLATION
0
➀ Download latest version from GitHub
➁ Stop your server, unzip package and overwrite content in your 1amxmodx.
➂ If needs, configure sv_setsteamaccount cvar
➃ If you are not using API, open modules.ini and add steamtools.
⑤ Then start your server.

➥Eventually, check for any errors in the console.



Arkshine 04-05-2015 09:58

Re: SteamTools (v1.0.0)
 
reserved

FromTheFuture 04-05-2015 11:45

Re: SteamTools (v1.0.0)
 
Interesting, I'll try.

meTaLiCroSS 04-05-2015 12:01

Re: SteamTools (v1.0.0)
 
Another nice project from jerkshine. Gonna take a look :mrgreen:

^SmileY 04-06-2015 20:07

Re: SteamTools (v1.0.0)
 
Finally, now we can made a custom page in-game with all steam infos :D

Let's create something using this

Kia 04-08-2015 09:54

Re: SteamTools (v1.0.0)
 
Great work. Guess you can check if the user who plays on the server is a parent account or not.

Arkshine 04-08-2015 12:22

Re: SteamTools (v1.0.0)
 
I did not test, but you can likely do that with https://github.com/Arkshine/SteamToo...ls.inc#L49-L55 ; it passes owner account id and the current approved account id.

zeus 04-10-2015 18:05

Re: SteamTools (v1.0.0)
 
Server crashes with segmentation fault everytime I enable the steamtools module. Using Ubuntu x64 14.04 ( up-to-date ), AMXX 1.8.3-dev-git4717 and latest Metamod.

Arkshine 04-10-2015 18:51

Re: SteamTools (v1.0.0)
 
You mean at server start? Do you have some log about it, eventually a backtrace?

Are steamclient.so and libsteam_api.so files well present (should be in parent dir of mod dir)?

zeus 04-11-2015 01:56

Re: SteamTools (v1.0.0)
 
Yes, the server crashes at boot. Both files are present and have 777 permisions.

How can I get a backtrace ?

//


Program terminated with signal SIGSEGV, Segmentation fault.
#0 0xf2fbecd2 in SourceHook::CSourceHookImpl::AddHookNew(int, SourceHook::ISourceHook::AddHookMode, void*, int, int (*)(SourceHook::HookManagerAction, SourceHook::IHookManagerInfo*), SourceHook::ISHDelegate*, bool) () from cstrike/addons/amxmodx/modules/steamtools_amxx_i386.so
#0 0xf2fbecd2 in SourceHook::CSourceHookImpl::AddHookNew(int, SourceHook::ISourceHook::AddHookMode, void*, int, int (*)(SourceHook::HookManagerAction, SourceHook::IHookManagerInfo*), SourceHook::ISHDelegate*, bool) () from cstrike/addons/amxmodx/modules/steamtools_amxx_i386.so
#1 0x00000020 in ?? ()
#2 0x00001fb8 in ?? ()
#3 0x00000000 in ?? ()
No symbol table info available.
From To Syms Read Shared Object Library
0xf76be914 0xf7704c78 Yes ./libstdc++.so.6
0xf7650ad0 0xf765196c Yes (*) /lib/i386-linux-gnu/libdl.so.2
0xf7634840 0xf76414a7 Yes (*) /lib/i386-linux-gnu/libpthread.so.0
0xf7497420 0xf75c8b6e Yes (*) /lib/i386-linux-gnu/libc.so.6
0xf743c600 0xf746a70b Yes (*) /lib/i386-linux-gnu/libm.so.6
0xf7750860 0xf77687ac Yes (*) /lib/ld-linux.so.2
0xf7421e04 0xf7431490 Yes ./libgcc_s.so.1
0xf6f01490 0xf6f8524c Yes /home/zeus/Desktop/SteamCMD/HLDS/engine_i486.so
0xf76625c0 0xf766cd74 Yes (*) ./libsteam_api.so
0xf6e899b0 0xf6e8d0ca Yes (*) /lib/i386-linux-gnu/librt.so.1
0xf6ea0a00 0xf6ead1b8 Yes /home/zeus/Desktop/SteamCMD/HLDS/filesystem_stdio.so
0xf5de4f80 0xf69e5370 Yes (*) /home/zeus/.local/share/Steam/linux32/steamclient.so
0xf5cabf90 0xf5cd1230 Yes (*) /home/zeus/.local/share/Steam/linux32/crashhandler.so
0xf338dd00 0xf3432ebc Yes (*) /home/zeus/Desktop/SteamCMD/HLDS/./cstrike/addons/metamod/metamod.so
0xf312c350 0xf3250340 Yes /home/zeus/Desktop/SteamCMD/HLDS/cstrike/dlls/cs.so
0xf2fe6420 0xf3039ad8 Yes (*) /home/zeus/Desktop/SteamCMD/HLDS/cstrike/addons/amxmodx/dlls/amxmodx_mm_i386.so
0xf2fbb4e0 0xf2fc7318 Yes (*) cstrike/addons/amxmodx/modules/steamtools_amxx_i386.so
0xf2fa4080 0xf2fac428 Yes (*) cstrike/addons/amxmodx/modules/cstrike_amxx_i386.so
0xf2f5d580 0xf2f95da0 Yes (*) cstrike/addons/amxmodx/modules/hamsandwich_amxx_i386.so
0xf2f41df0 0xf2f44928 Yes (*) cstrike/addons/amxmodx/modules/fun_amxx_i386.so
(*): Shared library is missing debugging information.
Stack level 0, frame at 0xffef27d4:
eip = 0xf2fbecd2 in SourceHook::CSourceHookImpl::AddHookNew(int, SourceHook::ISourceHook::AddHookMode, void*, int, int (*)(SourceHook::HookManagerAction, SourceHook::IHookManagerInfo*), SourceHook::ISHDelegate*, bool); saved eip = 0x20
called by frame at 0xffef27d8
Arglist at 0xffef27cc, args:
Locals at 0xffef27cc, Previous frame's sp is 0xffef27d4
Saved registers:
ebx at 0xffef27c8, ebp at 0xffef27cc, esi at 0xffef27c0, edi at 0xffef27c4, eip at 0xffef27d0


All times are GMT -4. The time now is 05:18.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.