diff options
Diffstat (limited to 'internal/game/game.go')
| -rw-r--r-- | internal/game/game.go | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/internal/game/game.go b/internal/game/game.go index 521c892..1ce89e5 100644 --- a/internal/game/game.go +++ b/internal/game/game.go @@ -21,6 +21,7 @@ import ( "thehouseoficarus/internal/net" "thehouseoficarus/internal/object" "thehouseoficarus/internal/player" + "thehouseoficarus/internal/prediction" "thehouseoficarus/internal/world" ) @@ -60,6 +61,7 @@ type Game struct { Hub *net.Hub GlobalFlags *GlobalFlagStore Combat *combat.Tracker + PredictionClient *prediction.Client Casino *casino.Manager flagIndex *flagTriggerIndex queue *CommandQueue @@ -629,6 +631,13 @@ func (g *Game) handleGameCommand(sess *net.Session, input string) { } cmd := parts[0] + // Counter commands exist only while using the counter, before global prefixes. + if g.predictionInputOwned(sess, cmd) { + g.executeCommand(sess, cmd, parts[1:], input) + g.writePrompt(sess) + return + } + // Seated casino players may shorten any of their game's verbs to an // unambiguous prefix (b 1000 -> bet 1000, sp -> spin at Big 6). Only the // current game's vocabulary is considered, and exact commands still win, so |
