AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Plugins (https://forums.alliedmods.net/forumdisplay.php?f=108)
-   -   [L4D2] Simple In-Game Player Statistics (https://forums.alliedmods.net/showthread.php?t=316621)

thresh0ld 07-25-2019 08:07

Re: [L4D2] Simple In-Game Player Statistics
 
Quote:

Originally Posted by foquaxticity (Post 2660559)
13:43:13 CREATE FUNCTION IF NOT EXISTS `APPLY_MODIFIER`( `name` VARCHAR(50), `value` INT ) RETURNS double BEGIN DECLARE modifier FLOAT; SELECT s.modifier INTO modifier FROM STATS_SKILLS s WHERE s.name = name; IF modifier IS NULL THEN SELECT 1.0 INTO modifier; END IF; RETURN value * modifier; END Error Code: 1064. You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'IF NOT EXISTS `APPLY_MODIFIER`( `name` VARCHAR(50), `value` INT ) RETURNS doub' at line 1 0.000 sec

(i just copied error row)

Underlines: CREATE FUNCTION IF NOT EXISTS
and
CREATE VIEW IF NOT EXISTS

I've never used mysql in my life, i don't even know whats what. Using tutorials got this far:
https://imgur.com/a/BB0HrB0

Mysql version is 8.0.17

You are using an older version of mysql which does not support some of the special keywords on the create statement. Remove "IF NOT EXISTS" and try running it again.

e.g.

Code:

CREATE FUNCTION IF NOT EXISTS `APPLY_MODIFIER`......
will become

Code:

CREATE FUNCTION `APPLY_MODIFIER`........

BeliyKrol 04-06-2020 16:15

Re: [L4D2] Simple In-Game Player Statistics
 
Hi,

I have problems with dropping .sql file in phpMyAdmin mysql
I have Server version: 5.7.24-27 - Percona Server (GPL), Release 27, Revision bd42700 last one

Maybe your's .sql files are not updated? What I can do




But with the problem like other guy. Please can you write me in discord? I can pay you if you can install me it with PayPal.
#1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'IF NOT EXISTS `APPLY_MODIFIER`(
`name` VARCHAR(50),
`value` INT
) RETURNS d' at line 1





My discord: Белый Кроль#7638

Thank you

Raikage 07-15-2020 01:06

Re: [L4D2] Simple In-Game Player Statistics
 
Can you make for left 4 dead 1?

Quote:

Originally Posted by thresh0ld (Post 2653983)
Features

Note: This is still in alpha, which means anything can be added, changed or removed at a later point in time.
  • Records statistics gathered from human players and saves it to a database. Stats are displayed in-game to the player via a Menu/Panel interface. (No web frontend for stats, yet)


    • Survivors Kils - Number of times an infected has killed a survivor
    • Survivors Incapped - Number of times an infected player has incapped a survivor
    • Infected Kills - Number of times a survivor player has killed a Special Infected (Commons not counted)
    • Infected Headshots - Number of times a survivor killed a Special Infected by Headshot
    • Hunter Skeets (Sniper) - Number of hunters skeeted with sniper by a survivor
    • Hunter Skeets (SG) - Number of hunters skeeted with shotgun by a survivor
    • Hunter Skeets (Melee) - Number of hunters skeeted with melee by a survivor
    • Tank Rock Skeets - Number rocks skeeted by a survivor
    • Witch Crown (Standard) - Number of standard witch crowns by a survivor (up close)
    • Witch Crown (Draw) - Number of witch draw crowns by a survivor (chip from a distance and kill up-close)
    • Boomer Pops - Number of boomer pops by a survivor
    • Charger Levels - Number of chargers leveled by a survivor
    • Smoker Tongue Cuts - Number of smoker tongues cut by a survivor
    • Hunter Deadstops - Number of hunter deadstops by a survivor
    • Quad Booms - Number of times survivors have been quad boomed (all 4 boomed)
    • 25 Hunter Pounces - Number of 25 point hunter pounces
    • Death Charges - Number of times a charger has death charged a survivor
    • Tank Rock Hits - Number of times a tank rocked a survivor
  • A customizable connect announce feature. Allows you to display current ranking/steam id/total points of the player. This feature also supports colour coded messages.

    https://raw.githubusercontent.com/so...t_announce.png
  • A display panel showing the player statistics of a user. This can be triggered by issuing sm_rank on the console or by typing !rank in chat.

    https://raw.githubusercontent.com/so...layer_rank.png
  • A display panel showing additional stats such as skeets, levels, boomer pops etc. (disabled by default)

    https://raw.githubusercontent.com/so...ank_extras.png
  • A display panel showing the top N players sorted by their ranking. This feature also allows the the requesting player to be able to view other player's statistics/ranking on the server.

    https://raw.githubusercontent.com/so...op_players.png
  • A display panel showing the ranks of the players currently present in the server. Each can be selected and preview their details.

    https://raw.githubusercontent.com/so...nks_ingame.png
  • A basic points and rankings system is also implemented and can be further customized by modifying the point multipliers from the plugin configuration file (playerstats.cfg)

Requirements
  • A working database system (Mysql/Mariadb 8.0 above)
  • skill_detect plugin. This is only required if you need the extra statistics enabled
  • SourceMod version 1.7 above

ConVars
  • pstats_enabled - Enable/Disable this plugin
  • pstats_debug_enabled - Enable/Disable debug messages
  • pstats_versus_exclusive - If set, the plugin will only work for versus gamemodes
  • pstats_record_bots - Sets whether we should record bots. By default only human players are recorded.
  • pstats_menu_timeout - The timeout value for the player stats panel
  • pstats_max_top_players - The max top N players to display
  • pstats_extras_enabled - Include extra stats to be recorded
  • pstats_display_type - 1 = Display points, 2 = Display the count, 3 = Both points and count
  • pstats_show_rank_onjoin - If set, player rank will be displayed to the user on the start of each map
  • pstats_cannounce_enabled - If set, connect announce will be displayed to chat when a player joins

Commands
  • sm_rank - Display the current stats & ranking of the requesting player. A panel will be displayed to the player.
    sm_top - Display the top N players. A menu panel will be displayed to the requesting player
    sm_ranks - Display the ranks of the players currently playing in the server. A menu panel will be displayed to the requesting player.
    sm_pstats_reload - Reloads plugin configuration. This is useful if you have modified the playerstats.cfg file. This command also synchronizes the modifier values set from the configuration file to the database (This is done by passing 'sync' as an argument)
    sm_pstats_wipe - Reset a player record (all stats set to 0)
    sm_hidestats - This will hide player's the extra stats from public view (except if the viewing user is an admin)

Change Log
  • 1.0.1-alpha - 6/4/2019

    - Bug Fix: Extra stats item from player rank panel does not execute when selected
    - Bug Fix: Error 'Client index is invalid' thrown during player initialization
    - Verify if steamid is valid for ShowInGamePlayerRanks
    - Bug Fix: Views in the database were hardcoded to query from 'playerstats' database. This will not work for those who use a different database name.
    - Added console command 'sm_hidestats'. Allow players to hide their extra stats from others.
    - Bug Fix: Fixed wrong parameter count for Notify().
  • 1.0.0-alpha - 6/1/2019
    - Initial Release

External Resources

GitHub Page (How to Install) - To get the latest updates and for more detailed information about this plugin.

Any suggestions to improve the plugin are always welcome


ajaixal11 08-17-2020 20:40

Re: [L4D2] Simple In-Game Player Statistics
 
i got this error

[l4d2_simpleplayerstats.smx] [ERROR] TQ_ShowPlayerRankPanel :: Query failed (Reason: Table 'np2_3eab02c93793xxxx.STATS_VW_PLAYER_RANKS' doesn't exist)

how do i fix this?

Iam Already Import that But Still Getting Only STATS_SKILLS and STATS_PLAYERS

Toffo 08-26-2020 23:06

Re: [L4D2] Simple In-Game Player Statistics
 
good morning.

The multiplier does not take into account for the extra stats

"survivor_killed" "8"
"survivor_incapped" "4"
"infected_killed" "1"
"infected_headshot" "2"
"skeet_hunter_sniper" "8"
"skeet_hunter_shotgun" "4"
"skeet_hunter_melee" "5"
"skeet_tank_rock" "2"
"witch_crown_standard" "3"
"witch_crown_draw" "5"
"boomer_pop" "3"
"charger_level" "5"
"smoker_tongue_cut" "3"
"hunter_dead_stop" "1"
"boomer_quad" "3"
"hunter_twenty_five" "10"
"death_charge" "10"
"tank_rock_hits" "4"

Only work with:
"survivor_killed" "8"
"survivor_incapped" "4"
"infected_killed" "1"
"infected_headshot" "2"

Sorry my english.

GoGetSomeSleep 02-12-2021 13:58

Re: [L4D2] Simple In-Game Player Statistics
 
https://i.ibb.co/mFRrgPg/image.png

RDiver 06-13-2021 11:47

Re: [L4D2] Simple In-Game Player Statistics
 
Quote:

Originally Posted by BeliyKrol (Post 2691267)
Hi,

I have problems with dropping .sql file in phpMyAdmin mysql
I have Server version: 5.7.24-27 - Percona Server (GPL), Release 27, Revision bd42700 last one

Maybe your's .sql files are not updated? What I can do




But with the problem like other guy. Please can you write me in discord? I can pay you if you can install me it with PayPal.
#1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'IF NOT EXISTS `APPLY_MODIFIER`(
`name` VARCHAR(50),
`value` INT
) RETURNS d' at line 1





My discord: Белый Кроль#7638

Thank you

Same issue right here. How to fix this so far to make this plugin works?

Denizsunar62 06-27-2021 20:21

Re: [L4D2] Simple In-Game Player Statistics
 
hi, i want to use this on my server. I saved everything in mysql. but when I enter the game and type !rank, the rank information does not appear. I wrote some cvar but it still didn't work. Can you help. Sorry for my bad english

nidzo 07-30-2022 21:06

Re: [L4D2] Simple In-Game Player Statistics
 
Hello.
First of all thank you for developing this addon!

I have installed it to my L4D2 Server, but when I list the addons with "sm plug list" I get the following:
Code:

4d2_srs.smx: Unable to load plugin (unsupported feature set; code is too new)
as well as
Code:

03 <Bad Load> l4d2_srs.smx
I have installed and configured the database according to the instructions on https://github.com/sourcemod-plugins/l4d2-player-stats.

The source mod version is:
Code:

SourceMod Version Information:
    SourceMod Version: 1.10.0.6497
    SourcePawn Engine: 1.10.0.6497, jit-x86 (build 1.10.0.6497)
    SourcePawn API: v1 = 5, v2 = 12
    Compiled on: Sep 24 2020 19:39:13
    Built from: https://github.com/alliedmodders/sourcemod/commit/39c2dc6
    Build ID: 6497:39c2dc6
    http://www.sourcemod.net/

And the metamod version is:
Code:

Metamod:Source Version Information
    Metamod:Source version 1.11.0-dev+1143
    Plugin interface version: 16:14
    SourceHook version: 5:5
    Loaded As: Valve Server Plugin
    Compiled on: Aug 19 2020 14:56:50
    Built from: https://github.com/alliedmodders/metamod-source/commit/b8d1fd4
    Build ID: 1143:b8d1fd4
    http://www.metamodsource.net/

Could someone be kind to help me with this problem as I want to be able to use stats on my server. Thank you in advance.

GoGetSomeSleep 01-11-2023 11:55

Re: [L4D2] Simple In-Game Player Statistics
 
can anybody add
if player away for 3 months purge his data?

and
plugins using too much mysql / mariadb so cpu %100


All times are GMT -4. The time now is 11:26.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.