Raised This Month: $12 Target: $400
 3% 

[TF2 Stats] With Web Ranking and Item Logger [v9.1.0]


Post New Thread Reply   
 
Thread Tools Display Modes
Sillium
AlliedModders Donor
Join Date: Sep 2008
Location: Germany
Old 07-22-2011 , 12:44   Re: [TF2 Stats] With Web Ranking and Item Logger [v8.1.4/v7.1.5]
Reply With Quote #1701

Thanks Obsidian
__________________
brb, dishes have developed their own language and are talking to the garbage about overthrowing me... i must correct this

www.unterwasserpyromanen.de
Sillium is offline
DarthNinja
SourceMod Plugin Approver
Join Date: Mar 2009
Location: PreThinkHook()
Old 07-22-2011 , 19:50   Re: [TF2 Stats] With Web Ranking and Item Logger [v8.1.4/v7.1.5]
Reply With Quote #1702

Quote:
Originally Posted by Sillium View Post
Why do react angry like this?
I never said it was your fault or that it definitely has to be this plugin. I was only trying to find out what happens.
You told me that the event was never fired I accepted this and was going to try removing other plugins.

Anyway if you have the feeling I was accusing you: I'm sorry
Sorry, I didn't mean that to be quite so snappish (I was tired).

Quote:
Originally Posted by Obsidian View Post
Found the problem.

http://wiki.teamfortress.com/wiki/July_20,_2011_Patch

So, the "Found items" feature of this plugin is now completely useless as Valve's taken away the event that was previously fired when it happened. :\
The wiki lists that as a "bug" so presumably it will be fixed at some point.
If not there are other ways of tracking item drops.

__________________
DarthNinja is offline
aRcTiC
SourceMod Donor
Join Date: Apr 2010
Old 07-22-2011 , 21:13   Re: [TF2 Stats] With Web Ranking and Item Logger [v8.1.4/v7.1.5]
Reply With Quote #1703

Trying not to go to offtopic but lets say asherkin's backpack hook was updated and did work, could that be a solution if this bug goes unfix for a while?
aRcTiC is offline
DarthNinja
SourceMod Plugin Approver
Join Date: Mar 2009
Location: PreThinkHook()
Old 07-22-2011 , 22:01   Re: [TF2 Stats] With Web Ranking and Item Logger [v8.1.4/v7.1.5]
Reply With Quote #1704

Quote:
Originally Posted by aRcTiC View Post
Trying not to go to offtopic but lets say asherkin's backpack hook was updated and did work, could that be a solution if this bug goes unfix for a while?
That was what I was thinking of actually, but I'm not sure if asherkin wants to update it. Maybe Valve breaking the item found event will give him reason to update it.

Eraserhead:
I just finished looking into the extinguish code, and it appears that the event doesn't even fire.
I'll look into other ways to detect this for a future update.
__________________
DarthNinja is offline
DarthNinja
SourceMod Plugin Approver
Join Date: Mar 2009
Location: PreThinkHook()
Old 07-23-2011 , 03:35   Re: [TF2 Stats] With Web Ranking and Item Logger [v8.1.4/v7.1.5]
Reply With Quote #1705

Welp, I just need to do some testing, then I'll be able to release.
Unfortunately my hosting company has picked tonight to relocate the entire datacenter where my webserver is hosted to a new facility.

I'm told that the move will take 2-3 hours so I'm going to wait up and see what happens.


__________________
DarthNinja is offline
DarthNinja
SourceMod Plugin Approver
Join Date: Mar 2009
Location: PreThinkHook()
Old 07-24-2011 , 10:05   Re: [TF2 Stats] With Web Ranking and Item Logger [v8.3.1/v7.1.5]
Reply With Quote #1706

~ Update Released ~

Details:
Quote:
  • V8.3.1 - "Star Wars" Update
    • Added tracking for the Victory Pack (aka "Star Wars") weapons:
      • The Cow Mangler
      • The Righteous Bison
    • Fixed points not being printed if the points were 0, but a bonus was added
    • Added a time offset cvar to the plugin to allow tweaking "last seen" times at the server level.
    • IPAddress database field has been bumped from 17 to 50 characters in length to support IPv6
    • Updated descriptions for CP/CTF cvars
    • CTF Tracking Changes:
      • Plugin can now give points to the capping player instead of/in addition to the whole team (cvar added).
      • Plugin now counts intel captures only for the capping player, not the entire team.
      • Added admin command to reset all "number of times capped" records (rank_debug_resetallctfcaps)
    • CP Tracking Changes:
      • Plugin can now give points to the capping player(s) instead of/in addition to the entire team (cvar added).
      • Plugin now counts captures only for the capping player(s), not the entire team.
      • Added an admin command to reset all "number of points capped" records (rank_debug_resetallcpcaps)
      • Added pl_ and plr_ maps to the list of game types that have control points.
      • Fixed a bug preventing the correct tracking of blocked CP captures.
    • Minor grammatical fixes for ctf/cp cap notices
    • Added a cvar to disable the round start/end messages
I would recommend running the two new database reset commands in order to get rid of the old incorrect capture counts.

As I said in a previous post, the player_extinguish event does not fire, but I'll see about looking into other options for tracking it.
You may want to email Valve and ask them to fix the event.

Item drop tracking is currently broken, the item found event is no longer sent to the server and can't be tracked.
You may want to email Valve and request they fix this as well.


__________________
DarthNinja is offline
-=eternal=-
Junior Member
Join Date: Jan 2005
Old 07-24-2011 , 15:50   Re: [TF2 Stats] With Web Ranking and Item Logger [v8.3.1/v7.1.5]
Reply With Quote #1707

First I want to say thank you for your work.

Can we just update the plugin (smx) or are there other changes that we would need to upload the other files?

On the web interface I am not seeing the Tomislav but I am positive it is counting the kills.
-=eternal=- is offline
DarthNinja
SourceMod Plugin Approver
Join Date: Mar 2009
Location: PreThinkHook()
Old 07-24-2011 , 21:03   Re: [TF2 Stats] With Web Ranking and Item Logger [v8.3.1/v7.1.5]
Reply With Quote #1708

Quote:
Originally Posted by -=eternal=- View Post
First I want to say thank you for your work.

Can we just update the plugin (smx) or are there other changes that we would need to upload the other files?

On the web interface I am not seeing the Tomislav but I am positive it is counting the kills.
https://forums.alliedmods.net/showpo...97&postcount=2
__________________
DarthNinja is offline
Obsidian
Senior Member
Join Date: Jun 2011
Old 07-24-2011 , 23:58   Re: [TF2 Stats] With Web Ranking and Item Logger [v8.3.1/v7.1.5]
Reply With Quote #1709

DarthNinja, there's something I want to bounce off of you for a possible future schema change.

Have you thought about splitting weapon kills off into their own table, and using a non-associative design?

I was playing with the idea myself, and came up with this as a schema:
Code:
CREATE TABLE `weaponkills` (
  `STEAMID` varchar(25) NOT NULL,
  `WeaponName` varchar(64) NOT NULL,
  `WeaponKills` int(11) NOT NULL,
  `WeaponHeadshots` int(11) NOT NULL,
  KEY `STEAMID` (`STEAMID`),
  KEY `WeaponName` (`WeaponName`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
As it's impossible to have a primary key here, it is a little worse for performance, but that is partially negated by having indexes on the steamid and weaponname (DBMSs are designed with these kinds of situations in mind after all).

It won't be hard to grab weapon kills from the database for the web interface itself either since a multi-table select is easy as pie.

This also comes with the benefit of not having to assign unique column names for each weapon, leaving it so that you can just use a single prepared query in the plugin and just pass in the weapon's name that was received in the player killed event, and the web interface can handle the translation itself. After all, Valve must their weapon names unique already, so there's no real need to change them ourselves.

It may or may not be worth it to also track headshots per-weapon this way, that's something you need to determine if it's possible plugin-side or not.


Also, updating the data that would be stored for a table like this would have to be done in a unique way, which a friend of mine calls an "upsert". Initially, you try an update query, where it's something like "UPDATE Players SET WeaponKills = WeaponKills + 1 WHERE (STEAMID = 'STEAM_0:0:123456' AND WeaponName = 'bat')". Afterwards, you check the number of rows affected; if it is less than one, you need to run an insert query so that the row exists for future queries, and from there it's just a plain INSERT INTO with WeaponKills being set to 1 (and if it's one or more rows affected btw, you're done and don't need to do anything else).

The huge benefit of doing the database structure this way, though, is that it reduces the amount of code in the plugin (I see a lot of redundant code in there just for queries) and it removes the need for the plugin to be updated with new TF2 updates that add weapons. Only the web interface would need updated to display the new weapon data (since it has to localize the weapon name and add in a kill icon).

E: Also, thanks for the changes that I asked for.

Last edited by Obsidian; 07-25-2011 at 00:11.
Obsidian is offline
Obsidian
Senior Member
Join Date: Jun 2011
Old 07-25-2011 , 01:11   Re: [TF2 Stats] With Web Ranking and Item Logger [v8.3.1/v7.1.5]
Reply With Quote #1710

The 1.0.2 update for my tf2stats web ui is now available!

The interface also leverages the new features of HTML5, CSS3, and also makes use of PHP 5.3 OOP to organize the codebase into something very close to an MVC pattern (it doesn't use models, that'd be overkill).
The interface also makes use of the Steam Web API to provide a few different unique features, and to also build it around an already existing community and foster its growth.

Changes in 1.0.2 include:
  • [Bug] Wrong asset file referenced in asset config (only was noticeable if not using gz compressed assets)
  • [Bug] Exception handler wasn't handling exceptions very well
  • [Bug] Properly calculate playtime in the player listing - leftover from the previous version's update, forgot to apply the change to that page as well.
  • [Improvement] Display a notice to the end-user when they are trying to install/run the application without having PHP 5.3+ available
  • [Improvement] Now displays data for the Cow Mangler and Righteous Bison (requires 8.3.1 of the stats plugin)

Full set of changes (files, lines changed) are available on github:
https://github.com/damianb/tf2stats/....1...rel-1.0.2

Update instructions:
  1. Download 1.0.2, extract all files locally
  2. Upload (overwrite) the following files in your installation
    • data/config/assets.json
    • data/config/weapondata.json
    • includes/Scrii/TF2Stats/Bootstrap.php
    • includes/Scrii/TF2Stats/Page/Instance/ListPlayers.php
    • style/image/killicon/Killicon_cow_mangler_5000.png
    • style/image/killicon/Killicon_righteous_bison.png
    • index.php
  3. Pat self on back, play some music, and go frag some F2P'ers

Demo: http://tf.scrii.com/
I am not responsible for any raptor attacks that occur on the demo site.
(running a slightly customized version of 1.0.2)


License: Original code licensed under GNU GPL v3 - dependency licenses are listed in the README, available here: https://github.com/damianb/tf2stats/...EADME.markdown

Download 1.0.2 @ github: https://github.com/damianb/tf2stats/downloads
It should be fine this time.

Should be.

...If it isn't, I swear I will go tsuntsun on github's download system. >.>
__________________
TF2 Stats plugin alternative web interface - profile @ Github
(tf2stats-webui latest release: 1.1.1)


"If you're not willing to do it right, don't get involved with security or Explosive Ordinance Disposal."

Last edited by Obsidian; 07-28-2011 at 02:11.
Obsidian is offline
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 09:31.


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