Feat: save room even if llm failed to properly guess; fix prompt
This commit is contained in:
@ -78,7 +78,7 @@ func HandleShowColor(w http.ResponseWriter, r *http.Request) {
|
||||
Actor: fi.State.Username,
|
||||
ActorColor: string(fi.State.Team),
|
||||
WordColor: string(color),
|
||||
Action: "guessed",
|
||||
Action: models.ActionTypeGuess,
|
||||
Word: word,
|
||||
}
|
||||
fi.Room.ActionHistory = append(fi.Room.ActionHistory, action)
|
||||
@ -103,8 +103,8 @@ func HandleShowColor(w http.ResponseWriter, r *http.Request) {
|
||||
action := models.Action{
|
||||
Actor: fi.State.Username,
|
||||
ActorColor: string(fi.State.Team),
|
||||
WordColor: "black",
|
||||
Action: "game over",
|
||||
WordColor: models.WordColorBlack,
|
||||
Action: models.ActionTypeGameOver,
|
||||
}
|
||||
fi.Room.OpenedThisTurn = 0
|
||||
fi.Room.ThisTurnLimit = 0
|
||||
@ -124,8 +124,8 @@ func HandleShowColor(w http.ResponseWriter, r *http.Request) {
|
||||
action := models.Action{
|
||||
Actor: fi.State.Username,
|
||||
ActorColor: string(fi.State.Team),
|
||||
WordColor: "blue",
|
||||
Action: "game over",
|
||||
WordColor: models.WordColorBlue,
|
||||
Action: models.ActionTypeGameOver,
|
||||
}
|
||||
fi.Room.OpenedThisTurn = 0
|
||||
fi.Room.ThisTurnLimit = 0
|
||||
@ -139,8 +139,8 @@ func HandleShowColor(w http.ResponseWriter, r *http.Request) {
|
||||
action := models.Action{
|
||||
Actor: fi.State.Username,
|
||||
ActorColor: string(fi.State.Team),
|
||||
WordColor: "red",
|
||||
Action: "game over",
|
||||
WordColor: models.WordColorRed,
|
||||
Action: models.ActionTypeGameOver,
|
||||
}
|
||||
fi.Room.OpenedThisTurn = 0
|
||||
fi.Room.ThisTurnLimit = 0
|
||||
|
Reference in New Issue
Block a user