Search found 569 matches

by iPlayer
Wed Apr 12, 2017 2:45 pm
Forum: Plugin Development Support
Topic: [Help] Way to see cause of crash ?
Replies: 21
Views: 15486

Re: [Help] Way to see cause of crash ?

sometimes when a player disconect the server crash It's good that you have this info already, but the more info you have, the easier it will be to debug. The point here is that you are unlikely to get any Python traceback in the crash case. You'll only get memory dumps which are useless. So to debu...
by iPlayer
Mon Apr 10, 2017 11:04 pm
Forum: Custom Packages
Topic: MOTDPlayer v2
Replies: 5
Views: 41190

Re: MOTDPlayer v2

Quoting a question from another thread , Edit: is it possible to use this with say, JS server-side or PHP instead of Flask? MOTDPlayer consists of three parts: SP custom package, Flask application and JS library. If you drop Flask application and tend to use PHP/NodeJS, you'll have to supply your ow...
by iPlayer
Mon Apr 10, 2017 10:53 pm
Forum: Custom Packages
Topic: MOTDPlayer v2
Replies: 5
Views: 41190

Re: MOTDPlayer v2

I did it. Sensibly. In a VMWare Workstation Player :) Well, besides immitating uWSGI on Windows, there're other options: ⋅ If you don't need WebSocket support, you can use any Windows web-server or even run Flask development server (just run application.py ) ⋅ If you don't need M...
by iPlayer
Mon Apr 10, 2017 6:30 pm
Forum: General Discussion
Topic: MOTDPlayer v2 Coming Soon!
Replies: 2
Views: 4344

Re: MOTDPlayer v2 Coming Soon!

MOTDPlayer v2 release page

Edit: is it possible to use this with say, JS server-side or PHP instead of Flask?

Answered here
by iPlayer
Mon Apr 10, 2017 6:23 pm
Forum: Custom Packages
Topic: MOTDPlayer v2
Replies: 5
Views: 41190

MOTDPlayer v2

MOTDPlayer v2 Package by Kirill "iPlayer" Mysnik GitHub: KirillMysnik/SP-MOTDPlayer2 What's this? MOTDPlayer is a software for Source-powered games that allows plugin creators to send interactive Message of The Day screens to their players. MOTDPlayer consists of: ⋅ Source.Pytho...
by iPlayer
Mon Apr 10, 2017 6:13 pm
Forum: General Discussion
Topic: MOTDPlayer Full Installation Tutorial (Debian + uWSGI/Flask/MOTDPlayer)
Replies: 0
Views: 4983

MOTDPlayer Full Installation Tutorial (Debian + uWSGI/Flask/MOTDPlayer)

In the light of MOTDPlayer v2 completion, I've made a video tutorial on how to : ⋅ Install Debian into a VMWare Workstation Player ⋅ Prepare your Linux setup to run a web-server with MOTDPlayer ⋅ Install and configure CCP+MOTDPlayer SRCDS parts into your Source Dedicate...
by iPlayer
Sun Apr 09, 2017 6:42 pm
Forum: General Discussion
Topic: MOTDPlayer v2 Coming Soon!
Replies: 2
Views: 4344

MOTDPlayer v2 Coming Soon!

... with simplified API and more powerful features. I'm working on the docs right now.



https://github.com/KirillMysnik/SP-MOTDPlayer2
by iPlayer
Wed Apr 05, 2017 11:47 am
Forum: Whatever
Topic: Grove Street is back, CS:GO! "Da Hood" custom map
Replies: 2
Views: 13495

Grove Street is back, CS:GO! "Da Hood" custom map

In case somebody doesn't know, in 2016 I've been working on a custom map that puts Grove Street, the legendary dead-end from GTA San Andreas, in CS:GO. Here're some screenies. http://i.imgur.com/KFPJ411.jpg http://i.imgur.com/atMI1TY.jpg http://i.imgur.com/76dWVKO.jpg http://i.imgur.com/BJ0jh50.jpg ...
by iPlayer
Wed Apr 05, 2017 11:35 am
Forum: Whatever
Topic: Best way to distribute Python program?
Replies: 4
Views: 13353

Re: Best way to distribute Python program?

Late reply, but I highly recommend using pynsist package. It puts your application in a Nullsoft Installer. It's much better than packing everything in a single .exe. Your application will install like any other program, it will be accessible in Windows Control Panel etc. Also supports neat stuff li...
by iPlayer
Fri Dec 02, 2016 9:28 pm
Forum: Plugin Development Support
Topic: Restart the round
Replies: 30
Views: 18819

Re: Restart the round

I guess that's a console variable, not a command. So you need to find it and set it to 1.
There must be some Source handler attached to that variable.
by iPlayer
Thu Nov 10, 2016 1:37 pm
Forum: Plugin Development Support
Topic: CVEngineServer::CreateFakeClient
Replies: 12
Views: 8642

Re: CVEngineServer::CreateFakeClient

L'In20Cible wrote:You cannot spawn fake clients as they have no AI bound to them.

How do third-party bots work though? Like Botrix. If I'm not mistaken, they spawn fake clients and then control them.
by iPlayer
Wed Nov 09, 2016 3:47 pm
Forum: Plugin Development Support
Topic: CVEngineServer::CreateFakeClient
Replies: 12
Views: 8642

Re: CVEngineServer::CreateFakeClient

What about selecting class? For TF2 it may occur essential for them to be somebody.

Try this:

Syntax: Select all

self.player.set_property_int('m_iClass', 1)    # Spawn as Scout
by iPlayer
Tue Nov 08, 2016 9:37 am
Forum: Plugin Development Support
Topic: CVEngineServer::CreateFakeClient
Replies: 12
Views: 8642

Re: CVEngineServer::CreateFakeClient

I personally used this code (simplified) from engines.server import execute_server_command from listeners import OnClientActive from players.entity import Player _requested_bots = [] @OnClientActive def listener_on_client_active(index): player = Player(index) if player.steamid != &qu...
by iPlayer
Sun Nov 06, 2016 2:35 pm
Forum: Plugin Requests
Topic: Weapon Cleaner
Replies: 4
Views: 4909

Re: Weapon Cleaner

After a second thought... DropWeapon function actually does some important stuff. It actually removes weapon inthandle from player's properties. To be certain, from m_hMyWeapons array, that is used, for instance, here . If we prevent this function from execution, I suspect that weapon's inthandle wo...
by iPlayer
Sun Nov 06, 2016 9:20 am
Forum: Plugin Requests
Topic: Weapon Cleaner
Replies: 4
Views: 4909

Re: Weapon Cleaner

I've had weird random crashes when removing an entity in a pre-hook without preventing function from further executing. Invincible told me it happened because function may try to continue operating on a removed entity. So I'd

Syntax: Select all

return False
in both hooks after removing it.
by iPlayer
Sat Nov 05, 2016 7:27 pm
Forum: Plugin Development Support
Topic: finding out who used func_button?
Replies: 4
Views: 3728

Re: finding out who used func_button?

targetname -> target_name
by iPlayer
Fri Nov 04, 2016 3:58 pm
Forum: Plugin Development Support
Topic: Admin Chat
Replies: 4
Views: 4397

Re: Admin Chat

You can also add a callback that gets called when an unauthorized player tries to execute the command. from commands.typed import TypedClientCommand ... def on_test_failed(command_info, args): NO_PERMISSION_ERROR.send(command_info.index) @TypedSayCommand(TSAY_COMMANDS, ADMIN_CHA...
by iPlayer
Fri Nov 04, 2016 3:31 pm
Forum: Plugin Development Support
Topic: Admin Chat
Replies: 4
Views: 4397

Re: Admin Chat

I would recommend using TypedSayCommand instead of regular one. It supports permissions out-of-the-box, handles the case with invalid permissions, and has a really convenient way of providing you the arguments. http://wiki.sourcepython.com/developing/module_tutorials/commands.html#using-permissions
by iPlayer
Thu Nov 03, 2016 7:23 pm
Forum: Plugin Development Support
Topic: Removal of print?
Replies: 25
Views: 15471

Re: Removal of print?

Update: just tested

Syntax: Select all

print("Hey there", end='')

and it didn't print anything.

Doing

Syntax: Select all

print("Hey there2")

after that printed
Hey thereHey there2

Maybe their sys.stdout.line_buffering attribute is set to False?
by iPlayer
Thu Nov 03, 2016 7:17 pm
Forum: Plugin Development Support
Topic: Removal of print?
Replies: 25
Views: 15471

Re: Removal of print?

Works for me on CS:S SRCDS and Windows 7. For reference, <_io.TextIOWrapper name='<stdout>' mode='w' encoding='cp866'>_CHUNK_SIZE = 8192 __class__ = <class '_io.TextIOWrapper'> __del__ = <method-wrapper '__del__' of _io.TextIOWrapper object at 0x006195B0> __delattr__ = <method-wrapper '__delattr__' ...

Go to advanced search