Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
Tags

my deck runs much slower in browser, chaos reigns

A topic by Nicky Flowers created Mar 03, 2023 Views: 153 Replies: 4
Viewing posts 1 to 3
(+1)

been working on a little zine, having a blast doing so, Decker is the future, etc.  i'm testing it out as a playable thing on my itch page and i'm noticing it's like, wayyy slower than how it runs in native Decker. for example, on one card i have a 'sleep[]' function that lasts about 4 seconds longer than it should.

i have a lot of audio clips among everything else, which has made the size of my deck around 1MB. i'm wondering if that's large for a deck and if it could be part of the sluggishness. i dunno! maybe someone's got some optimization tips for me? anyway have a good one

Developer

A 1mb deck shouldn't be too outrageous.

Web-Decker performance does depend on your browser and computer somewhat. I have a few ideas for improving parity with native-Decker (or at least degrading more gracefully), but it'll take me some time.

My apologies for this snag.

(+1)

no worries! i think i'll just adjust the sleep function. i also have a less-than-perfect laptop so that's probably a factor. thanks for your hard work on this

Developer

One other thought that occurs to me is that if you're specifically sleeping to wait for a sound to finish playing, you can use sleep["play"] instead of specifying a number of frames; The all about sound tutorial includes some examples.

Developer(+1)

Update: in v1.13 I overhauled web-decker's timing loop. Results should be much more consistent with native-decker. I also slipped in a few minor performance enhancements. The downside is that on slow machines, dropped frames will cause some animation to look choppier, and particularly expensive transition animations like the "Heart Wipe" from Public Transit will only render a handful of frames.