Beispiel #1
0
// Draw the given list of Drawables on the surface.  Items should be a list of Drawables
func draw(screen *sdl.Surface, items *list.List) {
	screen.FillRect(nil, uint32(0x00202020))
	for cur := items.Front(); cur != nil; cur = cur.Next() {
		if d, ok := cur.Value.(Drawable); ok {
			d.Draw(screen)
		}
	}
}
Beispiel #2
0
// draw the marker
func (m Marker) Draw(screen *sdl.Surface) {
	screen.FillRect(m.Rect(), m.Color)
}