Category: Unity

Trivo.. 2?

It has been quite some time since my last post. Since then lots of work has happened on Trivo in Unity. I had ported most of the old systems outside of all the old user interface code since that was mostly specific to Godot.

The last thing I worked on was, after getting the A.I behaviour trees working in Unity properly, was messing with Unity’s inverse kinematics with the purpose of moving the character’s palm towards a location to make it look as if they were casting a spell without a dedicated animation for it.

Here is a video below of me experimenting with that:

I was quite happy with the result. I also managed to get tower floors generated out of random rooms with all their doors aligned properly.

But as I continued working in Unity on this project, I felt like I was still so far from my goal and decided to take a step back and go back to Godot 3.5 and create a simpler 2D game. The idea being that I could finish a 2D game in Godot in a short amount of time before going back and continuing work on my 3D game in Unity.

I’ll be posting more about that in the future, but here’s a little spoiler: It’s a top down game where you control a ship!

Until next time!

Porting to Unity … continued!

Work continues on the porting over to the Unity engine. It’s practically almost all ported over. Most of the stuff that hasn’t been ported over yet includes things such as certain UI elements which I am planning to revamp, some usable skills I still need to port over, and some combat animations. I have actually implemented a couple things that did not exist in the previous version, such as synchronizing character equipment to multiple clients.

Getting quite close to strictly working on new features, which is very exciting. Hope to show off some more soon!

Porting to Unity

As you can tell from the title, porting still continues from Godot.

I’ve gotten all the networking and steam integration code ported over, and just recently got zone management working inside Unity. The porting is going well so far and Unity has been quite easy to work with.

In my last post I mentioned how Unity has no notion of separate worlds with their own objects like Godot does. Porting my code that dealt with separate zone scenes had to be re-worked.

What I ended up doing was sectioning up the Unity game world into chunks of 2000 unit length squares, and associated each one with a 3D index. Each time I wanted to instantiate a zone I would grab one of these chunks that wasn’t being used and load all that zone’s data into it. When a player is teleported to a zone I grab the world zone index of that zone and get the world offset and translate their destination location by that amount and everything works out. It took a while to get asynchronous loading of the zones in Unity down but I have a good feel for how scene management works in Unity now.

Next, I’m finishing up porting the work on the floor generation for tower floors. It also similar to the zones needed a complete rework because in Godot I took advantage of the separate worlds to make each room in a floor it’s own Godot World and teleported players between them.

Now I’m actually placing the rooms next to each other and the player can physically walk between rooms in a floor instead of teleporting. I’ll be posting about that solution in the future.

Trivo…

I haven’t posted recently, and there is a good reason for doing so.

I ran into issues with the Godot engine, I believe I was running into some very odd stack corruption issues where the game would crash with no crash / debug information at all. I tried for about a week to debug it and eventually found that upgrading to Godot 4.0 fixed it. Unfourtunately Godot 4.0 is quite buggy which was really slowing down my progress. I decided to start porting things over to Unity mostly because I was worried of another such bug occurring in Godot 4.0.

So currently, I’m porting things over to the Unity game engine. Which I’m kind of upset to do, since I really do enjoy Godot’s node tree and work flow much more than the Unity equivalents. We’ll see how the next week or so goes as I continue to port over my code, thankfully they both offer C# as a scripting language most of my issues will changing specific Godot specific solutions to Unity.

One example is Unity has no concept of separate worlds which Godot did, so I have to re-work my zone management code to instead instantiate zones in floating sections of space to separate them instead of just being able to create an empty new world for each zone in Godot.

Anyway, I hope to give a update soon about the progress of the port.