Documentation ¶
Index ¶
Constants ¶
View Source
const ( Name = "sun" EntitySun = common.EntityType("sun") )
View Source
const ( StateAboveHorizon = "aboveHorizon" StateBelowHorizon = "belowHorizon" )
View Source
const ( AttrHorizonState = "horizonState" // aboveHorizon|belowHorizon AttrPhase = "phase" AttrAzimuth = "azimuth" AttrElevation = "elevation" AttrSunrise = "sunrise" // sunrise (top edge of the sun appears on the horizon) AttrSunset = "sunset" // sunset (sun disappears below the horizon, evening civil twilight starts) AttrSunriseEnd = "sunriseEnd" // sunrise ends (bottom edge of the sun touches the horizon) AttrSunsetStart = "sunsetStart" // sunset starts (bottom edge of the sun touches the horizon) AttrDawn = "dawn" // dawn (morning nautical twilight ends, morning civil twilight starts) AttrDusk = "dusk" // dusk (evening nautical twilight starts) AttrNauticalDawn = "nauticalDawn" // nautical dawn (morning nautical twilight starts) AttrNauticalDusk = "nauticalDusk" // nautical dusk (evening astronomical twilight starts) AttrNightEnd = "nightEnd" // night ends (morning astronomical twilight starts) AttrNight = "night" // night starts (dark enough for astronomical observations) AttrGoldenHourEnd = "goldenHourEnd" // morning golden hour (soft light, best DayTime for photography) ends AttrGoldenHour = "goldenHour" // evening golden hour starts AttrSolarNoon = "solarNoon" // solar noon (sun is in the highest position) AttrNadir = "nadir" // nadir (darkest moment of the night, sun is in the lowest position) AttrLat = "lat" AttrLon = "lon" )
View Source
const ( Sunrise = "sunrise" // sunrise (top edge of the sun appears on the horizon) Sunset = "sunset" // sunset (sun disappears below the horizon, evening civil twilight starts) SunriseEnd = "sunriseEnd" // sunrise ends (bottom edge of the sun touches the horizon) SunsetStart = "sunsetStart" // sunset starts (bottom edge of the sun touches the horizon) Dawn = "dawn" // dawn (morning nautical twilight ends, morning civil twilight starts) Dusk = "dusk" // dusk (evening nautical twilight starts) NauticalDawn = "nauticalDawn" // nautical dawn (morning nautical twilight starts) NauticalDusk = "nauticalDusk" // nautical dusk (evening astronomical twilight starts) NightEnd = "nightEnd" // night ends (morning astronomical twilight starts) Night = "night" // night starts (dark enough for astronomical observations) GoldenHourEnd = "goldenHourEnd" // morning golden hour (soft light, best DayTime for photography) ends GoldenHour = "goldenHour" // evening golden hour starts SolarNoon = "solarNoon" // solar noon (sun is in the highest position) Nadir = "nadir" // nadir (darkest moment of the night, sun is in the lowest position) )
Variables ¶
This section is empty.
Functions ¶
func NewAttr ¶
func NewAttr() m.Attributes
func NewSettings ¶
func NewSettings() m.Attributes
func NewStates ¶
func NewStates() (states map[string]entity_manager.ActorState)
Types ¶
type Actor ¶
type Actor struct { entity_manager.BaseActor // contains filtered or unexported fields }
func NewActor ¶
func NewActor(entity *m.Entity, entityManager entity_manager.EntityManager, eventBus event_bus.EventBus) *Actor
func (*Actor) Spawn ¶
func (e *Actor) Spawn() entity_manager.PluginActor
func (*Actor) UpdateSunPosition ¶
Click to show internal directories.
Click to hide internal directories.