krampus19/soko/entity.go
Sander Schobers 7634e632fb Moved level state to soko package.
Renamed entity type character and egg to player and target respectively.
2019-01-15 21:25:32 +01:00

20 lines
260 B
Go

package soko
import "opslag.de/schobers/geom"
type Entity struct {
ID int
Pos geom.Point
Typ EntityType
}
type Entities map[int]Entity
func (e Entities) Clone() Entities {
clone := Entities{}
for id, e := range e {
clone[id] = e
}
return clone
}