diff options
| -rw-r--r-- | main.go | 4 | ||||
| -rw-r--r-- | person.go | 10 |
2 files changed, 7 insertions, 7 deletions
@@ -20,7 +20,7 @@ func NewTile(size Point, position Point, color color.Color) Tile { } var soilColor = color.RGBA{0x60, 0x40, 0x20, 0xff} -var soil = NewTile(Point{280, 200}, Point{20, 20}, soilColor) +var soil = NewTile(Point{2800, 2000}, Point{200, 200}, soilColor) type Game struct { Persons []*Person @@ -71,7 +71,7 @@ func (g *Game) Draw(screen *ebiten.Image) { } func (g *Game) Layout(outsideWidth, outsideHeight int) (screenWidth, screenHeight int) { - return 320, 240 + return 3200, 2400 } func main() { @@ -16,14 +16,14 @@ type Person struct { } func NewPerson(position Point) Person { - image := ebiten.NewImage(10, 10) + image := ebiten.NewImage(100, 100) image.Fill(color.RGBA{0xff, 0xff, 0xff, 0xff}) - selectedImage := ebiten.NewImage(12, 12) + selectedImage := ebiten.NewImage(120, 120) op := &ebiten.DrawImageOptions{} - op.GeoM.Translate(1, 1) + op.GeoM.Translate(10, 10) selectedImage.Fill(color.RGBA{0xff, 0x00, 0x00, 0xff}) selectedImage.DrawImage(image, op) - return Person{Position: position, size: Point{10, 10}, image: image, selectedImage: selectedImage} + return Person{Position: position, size: Point{100, 100}, image: image, selectedImage: selectedImage} } func (p Person) Image() *ebiten.Image { @@ -45,5 +45,5 @@ func (p *Person) MoveTo(destination Point) { } func (p *Person) Update() { - p.Position = p.move.Update(p.Position, 3) + p.Position = p.move.Update(p.Position, 30) } |
