Kaizen's Origami

Overview

Kaizen’s Origami is an interactive slice-of-life roleplay game developed by Fate Forge, earning over 27.5 million visits. The game is set in a fictional Japanese town called Kaizen, where players can create characters, customize their homes, and use provided facilities to socialize and develop their characters. The game was developed on Roblox using their Luau language.

Originally freelancing for this project, I was able to satisfy my client and took on a part-time role in maintaining the game. My role as the Lead Game & Tools Programmer involved programming gameplay, UI/UX, datastores, networking & replication optimization, and tools to improve the proficiency of our builders & designers.

Screenshot_74.png

Screenshot_73.png

Replication Challenges

An issue that developers often struggle with on Roblox is synced tweens across all connected clients. Naturally, a developer would decide to let the server handle the syncing. However, many developers will tween game objects (instances) through the server. This results in terrible animation frame skips as clients generally have varying ping. Additionally, network and CPU usage drastically increases, resulting in lower performance on some low-end clients like our mobile player base. It is important to note that server updates tend to have more latency than render updates, which results in the animation frame skipping. Animations should never be handled on the server and games should instead rely on the client to perform the animation.

Unfortunately, this problem was present on Kaizen’s Origami. Aiming to improve the programming quality of the game, I did my best to update and improve all legacy code. As a solution, I created a ReplicatedTweening module to handle tween replication between the server and the client. Instead of the server handling the animation then transmitting each animation frame to the client, the server only send the tween information to each client and expects the clients to perform the animations themselves. After the tween ends, the server would simply apply the final value of the tween to the game objects. This way, the client handles animations and the server can still use up-to-date values for the game objects that it manages.

In the event that the tween is canceled through manual assertion of a new value, the server would simply cancel the thread which handles applying the final value of the tween. The client also reacts this way due to the way the engine works. ReplicatedTweening also allows for callbacks upon completion and the ability to only tween an object for specific players. ReplicatedTweening resulted in a significant decrease in CPU and network usage, with most of the network usage being the initialization call.

The module can be found in the GitHub repository below.

https://github.com/yousefalshaikh17/roblox-replicated-tweening

ReplicatedTweening in action

Connected Projects

These are all projects that are used in Kaizen’s Origami.

Character Customization

Character Customization Systems (2023)

This is a core component of the player experience. Allowing players to customize their characters has extended the lifespan of the game by a great amount.

Test-Driven Development

Lua/Luau Unit Testing Library (2023)