PhlexPlexico / G5V

A front-end for G5API to manage matches/seasons/tournaments for CS:GO
MIT License
56 stars 29 forks source link

[REQUEST] User can create a match without create teams #98

Closed hoan111 closed 2 years ago

hoan111 commented 2 years ago

Hello! Sometimes I want to create a quick scrim match with G5V but I have to create teams first to create a match. I think it is cool to make create a new match form with options a user can manually enter team name or use existing teams on the database. If you can help me now, I need the instruction to modify G5V and G5API (if required) to have this feature. I really appreciate all the help you gave me. Thank!

PhlexPlexico commented 2 years ago

Heya,

Sorry, but that isn't within the scope of this project. The API itself can let users launch games without teams (just make sure you send the cvar get5_check_auths 0 in your additional cvars), but this panel was intended for the purpose of season/tournament management, not to just allow random scrims to be created. I would suggest using something like (this)[https://github.com/thboss/G5-PUGs-Bot] if you have a discord server to setup matches instead, as it would create the teams on the fly as well. If you really wish to have a workaround, you should be able to create two teams with no team members, then have additional cvars include get5_check_auths 0, and that should also do what you're trying to achieve I think. Just note that some stats may not be tracked as the front-end does rely on users being a part of a team.

Thanks!

hoan111 commented 2 years ago

Yeah thanks for your response. I'll close this issue.

aronmgv commented 6 months ago

Hey, trying to achieve same thing. Configured 2 empty teams, but setting get5_check_auths 0 in cvar section when starting match is not working.. I am still being kicked upon connect

image

PhlexPlexico commented 6 months ago

Hi,

Considering get5 is not supported in CS2, there may be other cvars you would have to use depending on what plugin is being used. You'd need to check the server logs and see what they say.

Thanks

aronmgv commented 6 months ago

Hey, thanks for ultrafast response! I am using only MatchZy plugin.

Here are the logs from today: https://pbin.aronmgv.com/rcRIhHX3V5axamzyS6Xat

[MatchZy] [LoadMatchDataCommand] Match setup request received with URL: https://cs.pcwzone.com/api/matches/5/config headerName: Authorization and headerValue: ZIDISQIBW8PMMOH1KIINF3VE
[MatchZy] [LoadMatchFromURL] Received following data: {"matchid":"5","match_title":"Map {MAPNUMBER} of {MAXMAPS}","side_type":"standard","veto_first":"team1","skip_veto":false,"min_players_to_ready":5,"players_per_team":5,"team1":{"id":"4","name":"RANDOM A","tag":"RANDOM-A","flag":"","matchtext":"RANDOM A","players":{}},"team2":{"id":"5","name":"RANDOM B","tag":"RANDOM-B","flag":"","matchtext":"RANDOM B","players":{}},"cvars":{"get5_check_auths":"0","get5_remote_log_url":"https://cs.pcwzone.com/api/v2","get5_remote_log_header_key":"Authorization","get5_remote_log_header_value":"ZIDISQIBW8PMMOH1KIINF3VE","get5_remote_backup_url":"https://cs.pcwzone.com/api/v2/backup","get5_remote_backup_header_key":"Authorization","get5_remote_backup_header_value":"ZIDISQIBW8PMMOH1KIINF3VE","get5_demo_upload_url":"https://cs.pcwzone.com/api/v2/demo","get5_demo_upload_header_key":"Authorization","get5_demo_upload_header_value":"ZIDISQIBW8PMMOH1KIINF3VE"},"spectators":{"players":[]},"maplist":["de_vertigo"],"min_spectators_to_ready":0,"wingman":false,"num_maps":1}
[MatchZy] [LOADMATCH] MinPlayersToReady: 5 SeriesClinch: True
[MatchZy] [LOADMATCH] MapsPool: de_vertigo MapsLeftInVetoPool: de_vertigo
[MatchZy] [ExecuteChangedConvars] Execing: get5_check_auths "0"
[MatchZy] [ExecuteChangedConvars] Execing: get5_remote_log_url "https://cs.pcwzone.com/api/v2"
[MatchZy] [ExecuteChangedConvars] Execing: get5_remote_log_header_key "Authorization"
[MatchZy] [ExecuteChangedConvars] Execing: get5_remote_log_header_value "ZIDISQIBW8PMMOH1KIINF3VE"
[MatchZy] [ExecuteChangedConvars] Execing: get5_remote_backup_url "https://cs.pcwzone.com/api/v2/backup"
[MatchZy] [ExecuteChangedConvars] Execing: get5_remote_backup_header_key "Authorization"
[MatchZy] [ExecuteChangedConvars] Execing: get5_remote_backup_header_value "ZIDISQIBW8PMMOH1KIINF3VE"
[MatchZy] [ExecuteChangedConvars] Execing: get5_demo_upload_url "https://cs.pcwzone.com/api/v2/demo"
[MatchZy] [ExecuteChangedConvars] Execing: get5_demo_upload_header_key "Authorization"
[MatchZy] [ExecuteChangedConvars] Execing: get5_demo_upload_header_value "ZIDISQIBW8PMMOH1KIINF3VE"
[MatchZy] [StartWarmup] Starting warmup! Executing Warmup CFG from MatchZy/warmup.cfg
[MatchZy] [UpdatePlayersMap] CCSPlayerController count: 1 matchModeOnly: False
[MatchZy] [UpdatePlayersMap] CCSPlayerController count: 1, RealPlayersCount: 0
[MatchZy] [LoadMatchFromJSON] Success with matchid: 5!

Seems like the command is being sent to the server but has no effect.. Do you have any suggestion what might be not working?

Really would appreciate. Thanks

PhlexPlexico commented 6 months ago

As I said, get5_check_auths was a cvar directly associated with get5. I've never used MatchZy so I don't know if it allows 5v5 without teams being predefined or not. You will have to ask on their support channels to see what values are needed to allow for an authless match.

Thanks!

aronmgv commented 6 months ago

Appreciate for explaining! Thanks