2022-06-29 21:26:05 -04:00
|
|
|
package models
|
|
|
|
|
|
|
|
import (
|
|
|
|
"gorm.io/gorm"
|
|
|
|
)
|
|
|
|
|
|
|
|
type Frame struct {
|
|
|
|
gorm.Model
|
2023-02-12 02:49:33 -03:00
|
|
|
ID uint64 `json:"ID,omitempty" gorm:"primaryKey"`
|
|
|
|
GameID uint64 `json:"game_id,omitempty" gorm:"not null"`
|
2022-06-29 21:26:05 -04:00
|
|
|
Game Game `json:"game" gorm:"not null"`
|
|
|
|
Coins uint64 `json:"coins" gorm:";not null"`
|
2023-02-12 02:49:33 -03:00
|
|
|
Points uint64 `json:"points,omitempty" gorm:"not null"`
|
|
|
|
FPS uint8 `json:"fps,omitempty" gorm:"not null"`
|
2022-06-29 21:26:05 -04:00
|
|
|
ElapsedTime uint64 `json:"elapsed_time" gorm:"not null"`
|
2023-02-12 02:49:33 -03:00
|
|
|
Objects []Object `json:"objects,omitempty"`
|
|
|
|
}
|
|
|
|
|
|
|
|
type FramePublic struct {
|
|
|
|
Frame
|
|
|
|
Game bool `json:"game,omitempty"`
|
|
|
|
CreatedAt bool `json:"CreatedAt,omitempty"`
|
|
|
|
UpdatedAt bool `json:"UpdatedAt,omitempty"`
|
|
|
|
DeletedAt bool `json:"DeletedAt,omitempty"`
|
2022-06-29 21:26:05 -04:00
|
|
|
}
|