Also playing Warframe and want this juicy Arkanas from the Eidolon’s, but always missing when its getting night? Not anymore! Get your lights dimmer when the night is coming with a state trigger!
Thanks to the guys from Warframe Hub we can use the fanbased worlsdsatus API. Much appriciated btw!
In my opinion it is’nt that prittey. But it works ¯_(ツ)_/¯
sensor:
- platform: rest
name: cetus_string
json_attributes:
- cetusCycle
value_template: '{{ value_json.cetusCycle.shortString }}'
resource: https://ws.warframestat.us/pc
- platform: template
sensors:
cetus_is_day:
value_template: '{{ states.sensor.cetus_string.attributes.cetusCycle.isDay }}'
- platform: template
sensors:
cetus_time_left:
value_template: "{{ states.sensor.cetus_string.attributes.cetusCycle.timeLeft.split(' ')[0].split('m')[0]|int }}"
- platform: template
sensors:
cetus_state:
friendly_name: "Cetus State"
value_template: >-
{% if is_state("sensor.cetus_is_day", "False") and ((states("sensor.cetus_time_left")|int) < 10) and ((states("sensor.cetus_time_left")|int) != 0) %}
getting morning
{% elif is_state("sensor.cetus_is_day", "True") and ((states("sensor.cetus_time_left")|int) < 10) and ((states("sensor.cetus_time_left")|int) != 0) %}
getting night
{% elif is_state("sensor.cetus_is_day", "False") %}
night
{% elif is_state("sensor.cetus_is_day", "True") %}
day
{% endif %}
I had my troubles with cetus_time_left due to my split but with ((states("sensor.cetus_time_left")|int) != 0)
I’m getting somewhere.
and also a fast and dirty loflace card for the eye
type: picture-elements
image: /local/jpg/warframe/wf.png
elements:
- type: image
entity: sensor.cetus_state
tap_action:
action: null
image: /local/jpg/warframe/cetus_tag.png
state_image:
day: /local/jpg/warframe/cetus_tag.png
getting morning: /local/jpg/warframe/cetus_morgen.png
getting night: /local/jpg/warframe/cetus_abend.png
night: /local/jpg/warframe/cetus_nacht.png
style:
top: 50%
left: 50%
width: 102%
- type: state-label
entity: sensor.cetus_string
style:
top: 94%
left: 85%
text-align: right
font-size: 16px
color: white
font-family: Helvetica
Some screenshots for the lovelace card:
Would love to make a real sensor out of it… But I cant code, so wont. But would