RSSy MYGO.pl Opublikowano Listopad 12, 2022 o 19:09 RSSy Udostępnij Opublikowano Listopad 12, 2022 o 19:09 Description Create the vouchers/codes/keys that allow players to get vip, credits, various bonuses and privileges by using them. After using a voucher, the server executes the commands listed in the voucher. FeaturesCreate a random or specific vouchers/codes Vouchers can send multiple server commands Variables can be used for commands (steamid32, steamid64, userid, username) Ability to create vouchers with a specified lifetime, after which the voucher will be deleted Ability to create vouchers with a given number of uses of one voucher (there is protection against reuse of the voucher by one player) If the player writes the voucher/code wrong several times (vouchers_attempts), he will be blocked for specific time (vouchers_block_time) Logging block/unblock/deletion/voucher usage in sourcemod/logs/vouchers_core.txt Screenshots Spoiler Video preview Commands Code: sm_voucher (alias: vouchers;code;codes) - Opens menu with selections sm_voucher <code> - Voucher usage sm_voucher_gen "<translation_message>" <voucher_use_count> <voucher_lifetime> - Generate random voucher with parameters sm_voucher_add <code> "<translation_message>" <voucher_use_count> <voucher_lifetime> - Create specific voucher with parameters sm_voucher_cmds <code> "<commands>" - Add commands to voucher usage sm_voucher_del <code> - Delete voucher sm_voucher_unblock "<steamid>" - Unblocking the player from using the voucher command Creating vouchers tutorials Parameterscode - voucher/code translation_message - message from translation file (vouchers_messages.phrases.txt), this message will be sent after player uses the voucher (none - disable) voucher_use_count - number of voucher uses (0 - unlimited) voucher_lifetime - voucher lifetime (in minutes | 0 - forever) commands - commands that the server sends after player uses the voucher (commands must be separated with ; Example: sm_slap userid;sm_blind @t;sm_beacon @ct) steamid - player's steamid Available variables After player uses the voucher so server send specific commands, commands can contain these variables:steamid32 steamid64 userid username Example usage: sm_voucher_cmds TESTVOUCHER "sm_beacon username" and if player with name "Nocky" uses the voucher: TESTVOUCHER so server send command: sm_beacon Nocky Convars cfg/sourcemod/Vouchers.cfg Code: vouchers_attempts - Number of attempts to enter a voucher before obtaining a block (0 - Disabled) vouchers_block_time - How many minutes will the player be blocked if they enter incorrect vouchers InstallationDownload files Upload Vouchers.smx, vouchers.phrases.txt and vouchers_messages.phrases.txt Add and configure custom messages in vouchers_messages.phrases.txt To addons/sourcemod/configs/databases.cfg you need to add: PHP Code: "Vouchers" { "driver" "mysql" "host" "host" "database" "db" "user" "user" "pass" "pass" } Restart server or change map Configure cvars generated in the new file at cfg/sourcemod/vouchers.cfg Download Main repository Direct download Wyświetl pełny artykuł Odnośnik do komentarza Udostępnij na innych stronach Więcej opcji udostępniania...
Rekomendowane odpowiedzi