编辑代码

var GameOver = false
var beginTimestamp : Int = 0
let Gameperiod = 20
var TimeCost = 0