tilde-os
5 months ago
hiya! Javascript has a function named setInterval (https://developer.mozilla.org/en-US/docs/Web/API/Window/setInterval) which lets you set a function to be called at some arbitrary regular time increment! I then used that to make a tick loop to move things around every couple milliseconds!
devhank
5 months ago
oh yea Ik you'd use setInterval to write JS timer function, I mean how did you write for the dropping food anywhere on the page so one of your fishes flips itself and goes eat it part?
tilde-os
5 months ago
hiii sorry i missed your reply! So the way i handled it was like this: fish idle by randomly picking a point on the screen, and a duration to get there, then lerping to reach it. When you click on the screen, it registers the location that you clicked on (like the screen x and y), and constructs a Food object which is then put into an array
tilde-os
5 months ago
When a fish goes to pick its new random point, if there is food in the array, then it pops the food off of the array, and sets *that* as its next point instead! Once it reaches the position, it deletes the food and goes back to idling!
devhank
5 months ago
recently I joined tons of vsynth discord communities and dropped links of underrated and underappreciated vocaloid originals and my previous UTAU/OpenUTAU covers. I also read jojo part 7 (still peak fiction) consistently
devhank
6 months ago
just moved all of my wallpapers to my resource github page and decorated my utau page. I made hanoi plum (and pineapple) juice and passionfruit juice to deal with this summer
devhank
6 months ago
having multiple interests sucks, I put my Ravelry and Ribblr pattern collection links on blinkies. Recently I joined tons of crochet discord communities, the most important thing for me right now is how to save more storage space in my phone
devhank
6 months ago
put official and fanmade Vocaloid and Kpop game links on images, is anyone interested in my simple Vocaloid/UTAU visual novel? I'll release the itch.io game for playing in browser later, Vsynth Tuning contest is held again so I'm working on my UTAU cover first...
devhank
6 months ago
RoyalRoad's Writathon is gonna end soon and I just realized I wrote more drafts about human interrelationships for chapters from nth arc omg
Thank you so much, glad you like it. Its an HTML canvas element that tracks your mouse position. Every time the mouse moves on it I draw a line between the last and current mouse position.
oh ty, I get what you mean, will try it oneday