So I'm trying to make a idle game and im using a timer that resets to 0 every 30 cycles to make a 1 second timer, my goal is to make the total number increase by 0.2 every second but after a wile it increases by 0.1999 instead and I have no idea why
heres my code:
function _init()
timer=0
counter=0
end
function _update()
if timer==30 then timer=0 end
if timer==0 then counter+=0.2 end
timer+=1
end
function _draw()
cls()
print("timer:",0,0)
print(timer,24,0)
print("counter:",0,7)
print(counter,32,7)
end




Pico-View January
Hello Pico-View reader, this January Issue marks the beginning of the monthly "Pico-View" Web-Zine. Formerly Pico-View was a small interview series. From here on out, it will be a montly Web-Zine featuring several exclusive articles, perfect for anyone wanting a "view" into pico-8. Without further ado... We hope you have fun adventuring through the pixels and paragraphs of this brand new Pico-View web-zine.
-Achie, Nerdy Teachers, Celesmeh, AlexWolfe, SmellyFishSticks, Louie Chapman, and Marina
Contents:
-Growing and learning in Pico-8
-Little Eidolons - Achie Reviewed
-Yasuhito (Quantattack Dev) Interview (ft. Marina)
-Random Reviews
-Creating Better Sound in Pico-8 - Louie Chapman Article
-Secret of The ̶O̶o̶z̶e̶ Flip... In Pico-8 - AlexWolfe Pixel Article
-Goodbye (Epilogue)
Growing and Learning With Pico-8 - Celesmeh
Odds are if you are reading this, you know what Pico-8 is. You've seen videos, looked at the forums, Reddit, watched gifsor seen tweetcarts. Pico-8 is an amazing fantasy console that opens the world of game development and programming up to many, But what makes it such a good starting point? Why is Pico 8 generally seen as one of the best tools to enter the world of programming and the world of game development?


I downloaded Pico8 in 2021 and catching up again now...and started to see the potential and love the simple language from a non-programmer perspective. I'm more of an artist but recently found out about Lazy Devs youtube videos and patiently follow each shmup vid, I can see hope in creating my own shmup. I love shmup since the late 80s growing up visiting local arcade often. Now I have to really focus on making my own 1st shmup game..
Thank you too to Nerd teacher, Lazy Dev, and others for all your time and energy in making the software and tutorial vids
<3

