Showing posts with label web. Show all posts
Showing posts with label web. Show all posts

Sunday, January 1, 2023

Unity WebGL tips / advice in 2023

I recently released a Unity WebGL game and the process was a bit painful. Here's what I learned...

In summary: 

  • I was using built-in pipeline and didn't try URP. (HDRP is definitely out of the question btw)
  • Unity WebGL support isn't bad, and WebGL performance is even OK, as long as you treat it like a ~2015 mobile device in terms of capability and performance. Don't throw a lot at it, especially because iOS browsers can't do a lot...
  • ... because it's 2023 and iOS WebGL performance is still pretty shitty even with Apple's promised ANGLE WebGL 2.0 support. You should expect to do a lot of mitigations and workarounds just so iPhones and iPads don't explode. Meanwhile, Windows and Android browsers are generally solid and reasonable. (In case you can't tell, I'm pretty annoyed with Apple.)
  • Here's what'll happen to you: your WebGL build tests on your desktop browser will work fine and you'll be pleasantly surprised... and then you'll try it on an iPhone and it'll be a mild disaster where you spend a week or two fixing all the various ways it explodes.

(Note: this is current as of Unity 2021.3.11 LTS + iOS 15.)

Monday, December 12, 2022

That Lonesome Valley as cowboy coin crusher

SPOILER WARNING: This post spoils what happens in my new game That Lonesome Valley. If you care about spoilers, play it first. It'll take about 30 minutes.

CONTENT WARNING: This post contains discussion of gay sex acts and some screenshots with obscured pixel art nudity. It's mostly "safe for work" even if the actual game is not.

That Lonesome Valley is a short gay cowboy romance game about walking, sheepherding, and kissing. 

Back in 2019 I made an unfinished prototype for a Gay Western game jam to contemplate the anniversary of influential gay cowboy film Brokeback Mountain (2005). Three years later, I've finally finished it. This final release now has gay sex, smoochin', and other important new features. 

I'm still not quite happy with how it turned out, but at this point I guess I'm just gonna have to live with it. As usual, I've written about what happens in the game, and I detail some of my creative process, intent, inspirations, and what I hope to contribute to gay cowboy discourse...

Friday, April 9, 2021

Getting started with HaxeFlixel in 2021

Warning: this is a fairly technical game developer-y post. If you came here for gay sex, I'm sorry.

For an upcoming project commission, I'm making a 2D game with crowd simulation and simple controls that works well on mobile browsers. (Reminder: for iOS, that means WebGL 1.0 and no WASM.) The engine should be able to render and simulate 200+ lightweight game objects -- frame-animated sprites with simple collision, no fancy physics or shaders.

Which game engine should I use to maximize ease of learning and compatibility, and manage hundreds of simple objects on-screen? Here was my thought process:

  • Unity WebGL: way too heavy and slow for mobile browsers, and maybe overkill for a no-physics 2D game anyway. (Although the Lil Nas X 3D twerking game runs surprisingly well on iOS's WebGL 1.0, I wonder how much they had to optimize?)
  • Unity Project Tiny: as far as I can tell, Project Tiny and its DOTS dependency is still in early development. The random caveats and various in-dev inconsistencies with regular Unity would also be frustrating. And as with many other Unity side projects, its long term future feels really hazy.
  • Construct: seems ok, and I think I could've gotten used to the visual block scripting, but overall the pricing and licensing feels weirdly restrictive. I have to pay to use more than 2 JS files? I have to pay to use more than 1 font, or make an animation more than 5 seconds long? These are some really bizarre artificial resource limits.
  • Phaser: seems popular enough with decent TypeScript support, but I want the option of building out to a native executable without a weird Electron wrapper or something. Their monetization model (free open source base but you pay for "premium plugins" and tools) is one of the more generous ways to go about this, I get it, but it still feels weird to me and reminds me of Construct.
  • Godot: I've wanted to try Godot for ages, but in the end I felt like I didn't have a good sense of what its HTML5 Web export could do + learning enough of the "Godot way" and GDScript would've taken a while. It's also in the middle of a big break between v3.0 and v4.0, and ideally I'd like to wait until like v4.2 to commit to learning it.
  • Heaps: promising and some people get great results with it, but maybe still too early in public lifecycle for a total newbie like me, with not enough samples / docs / robust official tutorials to learn from yet. If or when I do try out Heaps, I'll probably try using Deepnight's gameBase project template.

In the end, I chose to build this particular project with HaxeFlixel. This post details my early impressions, thoughts, confusion, advice, etc. with learning it.