Browse Source

minor tweaks, including go fmt

master
Stephen McQuay 7 years ago
parent
commit
bc2d1cdd52
2 changed files with 5 additions and 5 deletions
  1. +1
    -1
      robot.go
  2. +4
    -4
      splosion.go

+ 1
- 1
robot.go View File

@ -283,7 +283,7 @@ func (r *Robot) Tick(g *game) {
}
}
// We only self repair when we're stopped
// We are only allowed to scan when we're stopped
if math.Abs(float64(r.Speed)) < v.Epsilon && r.ActiveScan {
r.ScanCounter += delta * float32(r.Stats.ScannerRadius) * 0.1
} else if r.ScanCounter > 0 {

+ 4
- 4
splosion.go View File

@ -5,10 +5,10 @@ import (
)
type Splosion struct {
Id string `json:"id"`
Position v.Point2d `json:"position"`
Radius int `json:"radius"`
Lifespan int `json:"-"`
Id string `json:"id"`
Position v.Point2d `json:"position"`
Radius int `json:"radius"`
Lifespan int `json:"-"`
}
func (s *Splosion) Tick() {

Loading…
Cancel
Save