mirror of
https://github.com/Team254/cheesy-arena-lite.git
synced 2026-03-10 06:06:47 -04:00
30 lines
978 B
Go
30 lines
978 B
Go
// Copyright 2019 Team 254. All Rights Reserved.
|
|
// Author: pat@patfairbank.com (Patrick Fairbank)
|
|
//
|
|
// Game-specific audience sound timings.
|
|
|
|
package game
|
|
|
|
type MatchSound struct {
|
|
Name string
|
|
FileExtension string
|
|
MatchTimeSec float64
|
|
}
|
|
|
|
// List of sounds and how many seconds into the match they are played. A negative time indicates that the sound can only
|
|
// be triggered explicitly.
|
|
var MatchSounds []*MatchSound
|
|
|
|
func UpdateMatchSounds() {
|
|
MatchSounds = []*MatchSound{
|
|
{"start", "wav", 0},
|
|
{"end", "wav", float64(MatchTiming.AutoDurationSec)},
|
|
{"resume", "wav", float64(MatchTiming.AutoDurationSec + MatchTiming.PauseDurationSec)},
|
|
{"warning", "wav", float64(MatchTiming.AutoDurationSec + MatchTiming.PauseDurationSec +
|
|
MatchTiming.TeleopDurationSec - MatchTiming.WarningRemainingDurationSec)},
|
|
{"end", "wav", float64(MatchTiming.AutoDurationSec + MatchTiming.PauseDurationSec +
|
|
MatchTiming.TeleopDurationSec)},
|
|
{"abort", "wav", -1},
|
|
}
|
|
}
|