110yards / fantasy

MIT License
2 stars 0 forks source link

Scoring for plays not included in the CFL game boxscore (eg: Defensive Touchdowns) #117

Open mdryden opened 2 years ago

mdryden commented 2 years ago

From @SteveTaskersSon (https://github.com/mdryden/110yards/discussions/80#discussioncomment-1641631):

  • allowing points for defensive touchdowns
  • awarding different point values for different field goals lengths. For example, field goals of 50+ could be worth 5 points, 35-49 yards 4 points, 0-34 yards 3 points...or something along those lines.

Notes

There are a few other scoring items I'd like to add, if I can figure out an efficient way to do this, including negative points for fumbles lost, and points for tackles which result in a safety.

The best way I've come up with this is a post-game cron job which fetches player stats for each player in each game that week. It could happen maybe once per night, to reduce the load (it definitely can't happen in real time). The downside here is that they won't show up until much later, and it will result in a lot of HTTP requests to the CFL's API that result in no actual changes to player stats.

Another option might be to reach out to the CFL and see if they can start including this data. That likely wouldn't happen quickly, but it would be the best option.

kamikazecanuck commented 2 years ago

Defensive TDs are the big one. The rest is just gravy stuff.