+ 2

Changing color at a certain number in JS

I want the lives to turn red when you have three lives left. https://code.sololearn.com/W8EfN5uwIozD/?ref=app

15th May 2020, 5:21 PM
ANONYMOUS
ANONYMOUS - avatar
2 Antworten
+ 1
line 77
15th May 2020, 6:05 PM
ANONYMOUS
ANONYMOUS - avatar
0
Which credit to owner you are talking about ? And I really don't have any clue on why would someone search this big code to find out what this program is doing and then check what you asked for You could simply do if lives<=3 element.style.color="red" If that isn't working maybe you could point out what part or line in that code where you are changing Colors for the lives is mentioned so someone don't need to go through the whole code
15th May 2020, 5:27 PM
Abhay
Abhay - avatar