Lighting experiments
This commit is contained in:
@@ -3,9 +3,16 @@ package maps
|
||||
import (
|
||||
"image/color"
|
||||
|
||||
"github.com/hajimehoshi/ebiten/v2"
|
||||
"github.com/atridad/LilGuy/internal/portal"
|
||||
"github.com/atridad/LilGuy/internal/world"
|
||||
"github.com/hajimehoshi/ebiten/v2"
|
||||
)
|
||||
|
||||
type TimeOfDay string
|
||||
|
||||
const (
|
||||
Daytime TimeOfDay = "day"
|
||||
Nighttime TimeOfDay = "night"
|
||||
)
|
||||
|
||||
type Map struct {
|
||||
@@ -17,6 +24,7 @@ type Map struct {
|
||||
World *world.World
|
||||
Portals []*portal.Portal
|
||||
BackgroundColor color.NRGBA
|
||||
TimeOfDay TimeOfDay // Day or Night tag
|
||||
|
||||
bakedImage *ebiten.Image
|
||||
}
|
||||
@@ -31,6 +39,7 @@ func NewMap(id string, number int, displayName string, width, height float64) *M
|
||||
World: world.NewWorld(),
|
||||
Portals: make([]*portal.Portal, 0),
|
||||
BackgroundColor: color.NRGBA{R: 135, G: 206, B: 235, A: 255},
|
||||
TimeOfDay: Daytime, // Default to daytime
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user