TP-Docs
HTML5 Icon HTML5 Icon HTML5 Icon
TP on Social Media

Recent

Welcome to TinyPortal. Please login or sign up.

May 01, 2024, 01:30:45 PM

Login with username, password and session length
Members
  • Total Members: 3,885
  • Latest: Growner
Stats
  • Total Posts: 195,174
  • Total Topics: 21,220
  • Online today: 167
  • Online ever: 3,540 (September 03, 2022, 01:38:54 AM)
Users Online
  • Users: 0
  • Guests: 131
  • Total: 131

Need some braniac input here!

Started by TimUSA, March 28, 2008, 04:30:00 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

TimUSA

I run a gaming site for a yacht racing simulator. http://vsk-ayc.totalh.com We use a unique scoring system we call a Bonus High Point System to generate the base points for our individual races and series results. it looks something like this:

Base Points = [BS]
1st = 50pts
2nd = 47pts
3rd = 44.3pts
4th = 42pts
5th = 40pts
6th = 38pts
7th = (50 - finish position - 6) or 37
*each position after is calculated the same way.

These base points are then used to calculate ladder points which I accomplish by using a factor for each race type.

Ad Hoc Race
Ladder Points = [BS]*1

Match Race
Ladder Points = [BS]*2

Club Fleet Race
Ladder Points = [BS]*6

Championship Race
Ladder Points = [BS]*8

The problem with this system is that it does not reward the best sailor, it rewards the most active player. I need to be able to reward a combination of both! I have tried just averaging the points, but this allows someone who say has only raced 3 races to be ranked higher then someone who has raced 200.

So my question is this. Given the know factors that i have [BS], the race type multiplier, ladder points, and number of races, what are your thoughts on how I could best achieve my goal of rewarding the best sailor. btw here is the code i use to generate the ladder results:


global $settings;

$query = "SELECT pts_table.skipperName, sum(pts_table.fleetPoints) as SumfleetPoints, smf_members.ID_MEMBER, thm.value AS country
FROM pts_table
LEFT JOIN smf_members ON pts_table.skipperName = smf_members.realName
LEFT JOIN smf_themes AS thm ON (thm.ID_MEMBER = smf_members.ID_MEMBER AND thm.ID_THEME = 1 AND thm.variable = 'country')
WHERE pts_table.fleetPoints> 0
GROUP BY pts_table.skipperName
ORDER BY SumfleetPoints DESC;";
$result = mysql_query($query);
if(mysql_num_rows($result))
{
echo'
  <table class = "bordercolor" cellSpacing="1" cellPadding="1" width="100%" border="0">
    <tr class ="catbg">
      <td width = "100%">Fleet Race Ladder:</td>
    <tr>
  </table><br>
  <table class = "bordercolor" cellSpacing="1" cellPadding="1" width="100%" border="0">
    <tr class ="catbg4">
    <td width = "5%"></td>
      <td width = "70%">Skipper Name:</td>
      <td width = "25%">Ladder Points:</td>
    </tr>
  </table>';
$x = 1;
  while($row = mysql_fetch_row($result))
  {
  echo'
  <table class = "bordercolor" cellSpacing="1" cellPadding="1" width="100%" border="0">
    <tr>
    <td width = "5%" class = "catbg2"><img src="' . $settings['default_images_url'] . '/flags/' . $row[3] . '.png" /></td>
      <td width = "70%" class = "titlebg">' . $x++ . ': ' . $row[0] . '</td><br>
      <td width = "25%" class = "catbg2">' . $row[1] . '</td><br>
    </tr>
  </table>';
  }
}