diff options
Diffstat (limited to 'internal/models/models.go')
-rw-r--r-- | internal/models/models.go | 24 |
1 files changed, 11 insertions, 13 deletions
diff --git a/internal/models/models.go b/internal/models/models.go index eb90a0d..ee6ae5f 100644 --- a/internal/models/models.go +++ b/internal/models/models.go @@ -2,28 +2,26 @@ package models import "time" -type ( - ScoreChanger interface { - ChangeScore() error - } +type ActionType string + +const ( + ActionTypePlus ActionType = "ActionTypePlus" + ActionTypeMinus ActionType = "ActionTypeMinus" +) +type ( UserScore struct { ID string - Acts []ScoreChanger + Actions []Action BurnTime time.Time Score int8 } // plus 1 - PlusAction struct { + Action struct { Name string + Magnitude uint8 Repeatable bool - } - - // minus x - // always repeatable - MinusAction struct { - Name string - Magnitude uint8 + Type ActionType } ) |