[Mechanics] - Sound, Performance, and death


Fair amount of bug fixes and enhancements last few days:

Slow Loading

This turned out to be due to TSCNs, Godot's native scene format, being woefully inefficient at loading anything remotely large. As such, embedding my models into the TSCNs caused scenes to load heinously slowly. Changing scenes to instead reference the GLTF versions of models dramatically improved scene loading times, this just makes accessing the mesh directly a bit more of a headache.

Mad Frame Rate Drop after linking enemy to main scene

This turned out to be due to collision shapes being woefully inefficient at collision detection, so as soon as move_and_slide was called it would cause the whole scene to grind from ~115fps to ~5fps. I knew TriMesh would do this, but I did not think the simple generate shapes would be such an issue as well, so annoyingly this means I will be manually creating all collision shapes from basic shapes. Not THAT big a deal, just more extra steps that I would have hoped the engine could do for you.

Spatial Audio

I wrote a script that fires a raycast into the ground from the player's position to detect what ground type they are walking on, then used this to randomly select one of 30 sounds relative to that surface, e.g. Wood_Barefoot, Wood_Shoes, Concrete_shoes and so on. This is working as a basic concept at the moment, though carpet is basically silent atm, but  also am thinking I might have a 'bump' mechanic such that if you knock a chair it will cause a sound. Also added some howling wind in the kitchen as the intent is for the windows to all be broken, hence the ivy. Can see this in the video below.

Demon Included

Finally got my Demon enemy into the main scene with a basic repertoire of 'charge at the enemy using A*Pathfinding and attack', then animated a screen shader to cause a warping effect along with some eerie sounds I whacked together from freesound.org. As always, sounds/textures/models are essentially placeholders while I prototype the game and subject to change, but as a concept I'm happy with where it's heading


As always, thanks and I welcome any comments.

Bimbam

Get Estate of the Damned

Download NowName your own price

Leave a comment

Log in with itch.io to leave a comment.