<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;

class GameUserScore extends Model
{
    use HasFactory;

    protected  $hidden = [
        'created_at',
        'updated_at',
    ];

    public function changeUser(){
        return $this->belongsTo(User::class, 'change_user_id', 'id');
    }

    public function holeData(){
        return $this->belongsTo(CourseHole::class, 'hole_id', 'id');
    }

    public function gameUser(){
        return $this->belongsTo(GameUser::class, 'game_user_id', 'id');
    }
}
