Description:
A powerful statistic and Ranking System, which uses sqlite database, that allows you setting/getting score from almost all l4d2 events. figure 1:
figure 2:
figure 3:
figure 4:
figure 5:
figure 6:
Spoiler
Update Log:
Code:
v2.5 (17 March 2022)
-Fixed page bugs.
v2.4 (17 March 2022)
-Using [--] instead of N/A country name tag
v2.3 (15 March 2022)
-Fixed SRS Panel pressing 0 can not close.
v2.2 (8 March 2022)
-Fixed cheat command
v2.1 (23 June 2021)
-Initial project
Features:
Real-time update SRS panel data.
Combo score system
Uses SQLite Database
Records over 100+ records in the game.
Notification(Text/Sound) for player joining the game
Country ([--]) and Rank tag for players in the chat (can be turned off in the config file)
Supports showing rank when clients chat or join the game.
Type !eff in the game to turn on/off combo effect.
Type !sound in the game to turn on/off combo sound.
When will save data?
To avoid making the server lag, I just added two triggers for it.
Round end
Player disconnected
Native functions:
Spoiler
PHP Code:
/**
* Gets the version of rank
* @param buffer string buffer
* @return current version of rank system in form of a float
*/
native float SRS_GetVersion();
/**
* Get 4 clients of a rounds MVP
*
* @param buffer1 buffer to store client index
* @param buffer2 buffer to store client's score
* @return none
*/
native void SRS_GetMvp(int[] buffer1, float[] buffer2);
/**
* Get a client's score
*
* @param client client index
* @param srsType SRS Type
* @return score of the client
*/
native int SRS_GetScore (int client, int srsType);
/**
* Get the server score depends on game settings status
*
* @param buffer buffer to store the string
* @param buffer size of the buffer
* @return none
*/
native void SRS_GetScoreStatus (char[] buffer, int size);
/**
* Get a client's rank and score
*
* @param steamId client steamId
* @param rank rank pointer
* @param score score pointer
* @return rank of the client
*/
native void SRS_GetRankAndScore (const char[] steamId, int& rank, float& score);
/**
* Get a online client's rank and score
*
* @param int client index
* @param rank rank pointer
* @param score score pointer
* @return rank of the client
*/
native void SRS_GetOnlinePlayRankAndScore (const int client, int& rank, float& score);
ConVars:
Spoiler
PHP Code:
// This file was auto-generated by SourceMod (v1.10.0.6494)
// ConVars for plugin "l4d2_srs.smx"
// How many Combo for each level?
// -
// Default: "5"
srs_combo_level "5"
// How many seconds to decrease for each level?
// -
// Default: "0.4"
srs_combo_time_decrease "0.4"
// Minimun combo time after decreasing by combo level
// -
// Default: "2.5"
srs_combo_time_min "2.5"
// Add your server commands that open a menu/panel to here so that the panel will not block menu.
// Use ',' to split commands.
// -
// Default: "sm_top,sm_ji,sm_top10,sm_ivoteblock,sm_menu,sm_ivote,sm_ihud,sm_csm,sm_lightmenu,sm_hat,sm_hats,sm_shop,sm_admin,sm_team,sm_teams,sm_buy,sm_market,sm_item,sm_items,sm_usepoint,sm_usepoints,sm_buy_confirm,sm_kill,sm_suicide"
srs_command_white_list "sm_top,sm_ji,sm_top10,sm_ivoteblock,sm_menu,sm_ivote,sm_ihud,sm_csm,sm_lightmenu,sm_hat,sm_hats,sm_shop,sm_admin,sm_team,sm_teams,sm_buy,sm_market,sm_item,sm_items,sm_usepoint,sm_usepoints,sm_buy_confirm,sm_kill,sm_suicide"
// Add [--] country tag before the name?
// 0=Off, 1=On
// -
// Default: "1"
srs_country_tag "1"
// How many score multiply/divide in easy difficulty?
// 1.0=No Multiply/Divide
// -
// Default: "0.5"
srs_difficulty_easy "0.5"
// How many score multiply/divide in hard difficulty?
// 1.0=No Multiply/Divide
// -
// Default: "1.5"
srs_difficulty_hard "1.5"
// How many score multiply/divide in impossible difficulty?
// 1.0=No Multiply/Divide
// -
// Default: "2.0"
srs_difficulty_impossible "2.0"
// How many score multiply/divide in normal difficulty?
// 1.0=No Multiply/Divide
// -
// Default: "1.0"
srs_difficulty_normal "1.0"
// Extra common intected spawn time.
// -1=OFF,0=Depends on amount of players (60 - (survivors*3), min=30.0)
// -
// Default: "45.0"
srs_extra_ci_spawn_time "60.0"
// How many seconds for frame move once? (Affect all timer)
// -
// Default: "0.1"
srs_frame_move_time "0.1"
// How many score multiply/divide in coop gamemod?
// 1.0=No Multiply/Divide
// -
// Default: "1.0"
srs_gamemode_coop "1.0"
// How many score multiply/divide in realism gamemod?
// 1.0=No Multiply/Divide
// -
// Default: "1.0"
srs_gamemode_realism "1.0"
// How many score multiply/divide in scavenge gamemod?
// 1.0=No Multiply/Divide
// -
// Default: "1.0"
srs_gamemode_scavenge "1.0"
// How many score multiply/divide in survival gamemod?
// 1.0=No Multiply/Divide
// -
// Default: "1.0"
srs_gamemode_survival "1.0"
// How many score multiply/divide in teamscavenge gamemod?
// 1.0=No Multiply/Divide
// -
// Default: "1.0"
srs_gamemode_teamscavenge "1.0"
// How many score multiply/divide in teamversus gamemod?
// 1.0=No Multiply/Divide
// -
// Default: "1.0"
srs_gamemode_teamversus "1.0"
// How many score multiply/divide in versus gamemod?
// 1.0=No Multiply/Divide
// -
// Default: "1.0"
srs_gamemode_versus "1.0"