Skocz do zawartości

Nowy szablon forum

mygo.pl

Stworzyliśmy dla Was nowy wygląd forum. Z pewnością znajdziesz rzeczy, które wg Ciebie mogą zostać zmienione - wspomnij o tym w specjalnym wątku.

Czytaj więcej

Jak założyć własną sieć

serwerów CS

Zastanawiasz się nad prowadzeniem własnej sieci serwerów? Przeczytaj podstawowe informacje, na które należy zwrócić uwagę, przy takim projekcie.

Czytaj więcej

Tworzymy spis sieci

dodaj swoją

Dodaj sieć do której należysz, pozwoli to na promocję i budowę ogólnopolskiej bazy sieci CS.

Czytaj więcej

[CSGO] HexRedirect


MYGO.pl
 Udostępnij

Rekomendowane odpowiedzi

  • RSSy
Installation:
Quote:

  1. Download there the plugin.
  2. To install the sourcemod plugin just merge the addons/sourcemod located in GameServer/ folder with yours.
  3. To install the php script, just move it(WebServer/redirect.php) to your webserver.
  4. Configure the php script, editing the redirect.php, following the instructions.
  5. Set your motd.txt to redirect to the php script.

Notes:
Quote:

  • The plugin configuration is located in sourcemod/configs/hextags.cfg
  • The patter is "command" "url"
  • Make sure to include the full url with the scheme as well(https or http).
  • The only cvar is sm_redirect_method that must match the PHP Script value. It can be either steam or ip

Example configuration:
PHP Code:

"HexRedirect"
{
    
"google"    "https://www.google.com/"
    "!plugins" "https://forums.alliedmods.net/forumdisplay.php?f=123"
    "zombie" "steam://connect/127.0.0.1:27015" 
//Your server IP, this will make the player join there


To report see/issue the current TODOs and bugs check the ISSUE Page on github

Source Code


How this works:
Quote:

When the user types that are listed in the cfg his ip/steamid is saved in the database, and when a user opens the motd page, it will check if the given IP/SteamID has any url to be redirected, if not it will just send to the set homepage.

Note that the PHP and the GameServer configurations must match, and if you the steam method is choose he will be required to login in, however his session his stored so he'll need to login once per session.

I know that is could not be the most reliable way (especially if two player have the same IP), but it's the only the I could figure without having the user to copy-paste the url.
Video: https://youtu.be/TW_yxPcodhk

Wyświetl pełny artykuł

Odnośnik do komentarza
Udostępnij na innych stronach

Jeśli chcesz dodać odpowiedź, zaloguj się lub zarejestruj nowe konto

Jedynie zarejestrowani użytkownicy mogą komentować zawartość tej strony.

Zarejestruj nowe konto

Załóż nowe konto. To bardzo proste!

Zarejestruj się

Zaloguj się

Posiadasz już konto? Zaloguj się poniżej.

Zaloguj się
 Udostępnij

  • Ostatnio przeglądający   0 użytkowników

    • Brak zarejestrowanych użytkowników przeglądających tę stronę.
×
×
  • Dodaj nową pozycję...