1<?php
2
3// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the GNU Affero General Public License v3.0.
4// See the LICENCE file in the repository root for full licence text.
5
6namespace App\Models\UserStatistics\Spotlight;
7
8use App\Libraries\HasDynamicTable;
9use App\Models\UserStatistics\Model as BaseModel;
10
11abstract class Model extends BaseModel implements HasDynamicTable
12{
13 protected $connection = 'mysql-charts';
14
15 public function __construct($attributes = [], $zeroInsteadOfNull = true)
16 {
17 if ($zeroInsteadOfNull) {
18 $this->level = 1;
19
20 $this->ranked_score = 0;
21
22 $this->playcount = 0;
23 $this->total_score = 0;
24 $this->max_combo = 0;
25
26 $this->count300 = 0;
27 $this->count100 = 0;
28 $this->count50 = 0;
29
30 $this->replay_popularity = 0;
31
32 $this->x_rank_count = 0;
33 $this->s_rank_count = 0;
34 $this->a_rank_count = 0;
35 }
36
37 parent::__construct($attributes, false);
38 }
39}