great! thanks for doing that :)
I'll be sure to open a PR if i have others :)
Search found 52 matches
- Sun Apr 01, 2018 4:47 am
- Forum: Plugin Development Support
- Topic: TF2 - Player class id / name?
- Replies: 2
- Views: 3323
- Sat Mar 31, 2018 5:27 pm
- Forum: Plugin Development Support
- Topic: TF2 - Player class id / name?
- Replies: 2
- Views: 3323
TF2 - Player class id / name?
Theres a few things id like to be able to do with players that requires me to know what class they're playing. As far as i can tell, Player does not have a tf2 class property or any way to find that? Edit: I found this: https://github.com/alliedmodders/sourcemod/blob/8f6f8819373fe70ac6965f96cd43e2b0...
- Wed Mar 28, 2018 4:40 am
- Forum: Plugin Development Support
- Topic: Stateful SRCDS firewall
- Replies: 2
- Views: 2680
Re: Stateful SRCDS firewall
So i did some testing, it looks like the connection is a direct UDP connect and does not actually do any port knocking. $ tcpdump -n -i ens3 "host x.x.x.x and port 27015" tcpdump: verbose output suppressed, use -v or -vv for full protocol decode listening on ens3, link-type EN10MB (Etherne...
- Tue Mar 27, 2018 4:13 am
- Forum: Plugin Development Support
- Topic: Stateful SRCDS firewall
- Replies: 2
- Views: 2680
Stateful SRCDS firewall
Hello! I'd like to make a stateful firewall for my srcds server (Team Fortress 2 specfically). Along side some other things i'm doing with my server's firewall to prevent DoS, one of things I'm unable to do is totally prevent UDP flooding unless I could do some kind of port knocking. To my knowledge...
- Sun Mar 25, 2018 5:35 pm
- Forum: General Discussion
- Topic: SourceMod interop
- Replies: 16
- Views: 14484
Re: SourceMod interop
In SM, simply implement the function (with forward on the function stub) and it'll be called when the original plugin makes the forwarding call. https://wiki.alliedmods.net/Introduction_to_sourcepawn https://wiki.alliedmods.net/Function_Calling_API_(SourceMod_Scripting)#Global_Forwards In my case; t...
- Sun Mar 25, 2018 4:38 pm
- Forum: General Discussion
- Topic: SourceMod interop
- Replies: 16
- Views: 14484
Re: SourceMod interop
theres a plugin for TF2 that uploads game logs to a website; in it, it registers 2 forwards: // Make it possible for other plugins to get notified when a log has been uploaded g_hLogUploaded = CreateGlobalForward("LogUploaded", ET_Ignore, Param_Cell, Param_String, Param_String); // Let oth...
- Sun Mar 25, 2018 3:34 pm
- Forum: General Discussion
- Topic: SourceMod interop
- Replies: 16
- Views: 14484
Re: SourceMod interop
The example above creates a native with Source.Python and makes it available in Sourcemod, so SM plugins can call an SP function. I'm pretty sure we can also make it work vice-versa (call SM natives from SP) or even receive forwards. Oh, i'd be very interested in that; theres a few plugins i'd like...
- Sun Mar 25, 2018 4:38 am
- Forum: General Discussion
- Topic: SourceMod interop
- Replies: 16
- Views: 14484
Re: SourceMod interop
I'm a bit confused; does this mean we can receive forwards from sourcemod plugins?
- Sun Mar 25, 2018 4:25 am
- Forum: General Discussion
- Topic: SP Threads?
- Replies: 8
- Views: 7207
Re: SP Threads?
I went ahead and made a decorator so i can just tag up things that will block in my plugins def threaded(fn): def wrapper(*args, **kwargs): thread = GameThread(target=fn, args=args, kwargs=kwargs) thread.daemon = True thread.start() return wrapper @Event('player_say') @threaded def on_player_say(eve...
- Sun Mar 25, 2018 2:24 am
- Forum: Code examples / Cookbook
- Topic: Installing standard python packages (pypi)
- Replies: 1
- Views: 21817
Installing standard python packages (pypi)
On Linux, you can do this with pip $ pip install -t <srcds_base_path>/addons/source-python/packages/custom/ <package> For example: $ apt-get install python-pip $ pip install -t /usr/games/steam/tf2/tf/addons/source-python/packages/custom/ requests $ pip install -t /usr/games/steam/tf2/tf/addons/sour...
- Sun Mar 25, 2018 12:34 am
- Forum: General Discussion
- Topic: SP Threads?
- Replies: 8
- Views: 7207
Re: SP Threads?
Awesome!
This project has so many cool features, but the documentation is a bit lacking. Is there a place I can contribute to that?
This project has so many cool features, but the documentation is a bit lacking. Is there a place I can contribute to that?
- Sat Mar 24, 2018 9:49 pm
- Forum: General Discussion
- Topic: SP Threads?
- Replies: 8
- Views: 7207
SP Threads?
First off, this project is amazing, really awesome work so far! My question may be a bit in depth; but how does SourcePython work in terms of the running srcds process. From my toying around, I've noticed that SourcePython seems to work in a single thread, which is on a game thread. Is it possible t...