Skip to main content

Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines
(2 edits)

Actually, optimization has nothing to do with the issue. I already fixed the issue with the text not showing up - had something to do with TextMeshPro materials. It just isn't fixed yet because I can't update the game until after the voting period. Also, I haven't yet gotten any feedback about optimization being bad, although I'm not at all surprised, since I had to do a bunch of my own raycasting and algorithms to detect if stuff is in shadow.

I never saw that self-harm and suicide was against the rules. Could you maybe provide a link to show that? These are the only rules for the jam I could find, and unless "Don't be a dumbass" is the rule you're referring to, there is nothing here that suggests what I did was against the rules.


Anyway, I'm glad you enjoyed the game besides optimization. I'll definitely see if I can further optimize the game in the future, although I did quite a bit of profiling and found that my own custom raycasting stuff never lowered my performance significantly, so maybe it's just an issue with your browser/computer? Unity's URP 2D lighting system isn't exactly perfectly optimized for WebGL on its own, so it could just be that, and that's not really my fault. Regardless, thanks for the feedback. :)

So I can say that Unity's URP lighting is optimized for Webgl as my 10+ games are made using Unity for Webgl it's just a balancing act and trying this and that here and there would improve the fps a lot and the code for how you do it also has a dramatic effect especially if you use a private void Update function on your Raycasting which would 100% make the fps drop a bit. 

It wouldn't be a hardware issue as long as your device can run DX9 then any game on Webgl should work. Its not a desktop game that is very much hardware dependent. It's like why doesn't a ps5 game run on the ps2 ? Its about what it can use and optimizing your game to work with what it can do. 

https://docs.unity.cn/560/Documentation/Manual/webgl-gettingstarted.html

Some resource for you for Unity with Webgl. 

Also I had thought I saw not Violence in the rules. That is my bad.

(2 edits) (+1)

Well, I've actually personally found issues with Unity's 2D URP shadow-casting system where it would unnecessarily be handling shadows outside of the lighting range depending on the scale of the object - I had to add custom code to the 2d shadow caster in order to make my previous 2D URP game w/shadows performant for that very reason, so it might be in general performant, but in particular the 2D shadow casting is definitely not perfectly optimized.

Also, I know for a fact that my raycasting is not the issue, as doing some quick profiling shows that the raycasts I'm doing are using a total of 0.4% of the CPU the game is using, which is an insignificant amount in the scheme of things. Believe me, I did try to bring that number down, but it was about sacrificing performance for the accuracy of visibility detection with my objects, and I wanted to be as accurate as possible so objects wouldn't pop in and out of existence while you could still see them.

I was merely suggesting hardware could explain the game being laggy for you but not other people (like myself), not that it would cause the game not to run. As I mentioned, I know for a fact that the text not showing up (which was the "browser issue" I was referring to) is due to an issue with TextMeshPro materials, not due to any lack of optimization.

Regardless I appreciate the advice. Sorry if I'm being defensive - I'm trying not to be but I know that I am to some extent. I definitely am not an expert on optimization (it is definitely one of my weak points), so I'll still definitely consider your advice for the future.