shobhit-pathak / MatchZy

MatchZy is a plugin for CS2 (Counter Strike 2) for running and managing practice/pugs/scrims/matches with easy configuration and Get5 (G5API/G5V) support as well!
https://shobhit-pathak.github.io/MatchZy/
MIT License
262 stars 75 forks source link

Activate / Deactivate Option #34

Closed Dying-Ducks closed 11 months ago

Dying-Ducks commented 11 months ago

As I understand it the plugin is always active for now and we have the options to be in "match mode" or in "practice mode".

It would be nice to have the option to choose neither. So that neither is active on startup, and we can use the server for retake or whatever and then to have the ability to activate the "match mode" if we want to scrim, activate the "practice mode" if we want to practice. And then again send the plugin in “sleep mode” to use the server otherwise.

shobhit-pathak commented 11 months ago

Hey!

I will check this whether we can fully de-activate the functionalities of MatchZy using some command, thanks for the suggestion!

Dying-Ducks commented 11 months ago

I think it don’t need to be "fully de-activate", if this is not possible or hard to implement. Features like the “.rcon” command could be useful in general.

It would be enough if the plugin just "sleeps" and doesn’t do anything actively, like checking for ready up or execute the practice cvars. So next to the “match mode” and “practice mode” a “I do nothing mode” would be highly appreciated.

ChocOranger commented 11 months ago

As a workaround.: Put the server in .prac mode Then use rcon to set a cfg file with mp_warmup_end and whatever settings you like eg retakes, kz. If you want to return to warmup use .exitprac

shobhit-pathak commented 11 months ago

You can load/unload or stop/start MatchZy plugin using css_plugins command. Usage: css_plugins stop/start/restart/load/unload/reload <pluginname>

So you can have css_plugins stop "MatchZy" command in your cfg where you'll start retake mode to deactivate MatchZy And when you want to enter match mode, you can use css_plugins start "MatchZy", that will re-activate MatchZy

If start/stop doesn't work, you can try load/unload as well. Note: This will disable the plugin completely, we cannot disable it partially.

ChocOranger commented 11 months ago

@shobhit-pathak I think @Dying-Ducks is asking for a way to disable the .ready commands rather than disabling the plugin so that the plugin is in a 'neutral state'. Not in match mode or prac mode. It's simply in a permanent warmup state. Then it can be changed to whatever he wants.

Basically what I asked for in https://github.com/shobhit-pathak/MatchZy/issues/29

Match zy should compliment other plugins. Disabling it in this case isn't the way to go IMO. Most plugins won't add an rcon command which your plugin supports and it has good admin support.

Currently, if you switch to a different config or plugin eg retake the messages will keep appearing to ready up. I realise you have a workaround but I think @Dying-Ducks is asking to stop the ready up messages.

shobhit-pathak commented 11 months ago

Hey @ChocOranger, thanks for the explanation. I'll explore disabling ready messages based on a config variable, but I think this can be picked up a bit later. Till then, the temporary solutions can be:

  1. Disabling the plugin through cfgs
  2. Set matchzy_minimum_ready_required to the maximum number and matchzy_chat_messages_timer_delay to a large number.
Dying-Ducks commented 11 months ago

What @ChocOranger said "rather than disabling the plugin so that the plugin is in a 'neutral state'" is pretty much what I want.

@shobhit-pathak I created my own solution to this issue I use actively on my server and made a Pull Request out of it.

shobhit-pathak commented 11 months ago

Hey @Dying-Ducks!

Thanks for your PR, I've included it in the v0.5.1-alpha release of MatchZy (https://github.com/shobhit-pathak/MatchZy/releases/)

Thanks!