top of page

Tang Dynasty Warriors Mobile

My in-service period: October, 2015 ~ October, 2017

datanglogo.png
app download.png

Overview

This project is a complete mobile adaptation of Tang Dynasty Warriors. It marks my first commercial game development experience, where I contributed to essential components. The game utilizes NeoX, a game engine paired with a toolkit for artists and designers, developed by Netease Games.

Set at the end of the Sui Dynasty in China around 618 AD, this MMO game follows warriors rising against oppressive rule. The Tang group, among these rebels, is the most influential. Players aim to join, lead, and guide this group to overthrow the king's troops and establish a new Tang dynasty.

 

My contributions include the cinematic system, role selection system, scene and character rendering with PBR technology, weather system, day-night cycle, game logic, and performance optimizations. This involved modifying the game engine and tools, writing shaders, and coding and testing logic. Due to a confidentiality agreement with Netease Games, technical details are omitted.

Share

Cinematic System

The cinematic system is a framework that enables real-time production and display of in-game story sequences. It is triggered by new plot developments or when background introductions are necessary.

At the start of development, my task was to allow game designers to create drama scripts using our art resources, displaying them during gameplay. With the NeoX cinema editor, which supports directing character movement and camera paths, and a basic interface for parsing editor outputs, my main goal was to create a dynamic drama management component. This component handles script parsing, resource loading, drama display, resource release, and scene recovery.

 

Additionally, I developed a mechanism for designers to edit display timing and add annotations. Collaborating with designers and artists, we created a system linking drama scripts, art resources, UI elements, and display timings specified by task indices in a readable file. This system, integrated with the drama management component, forms the cinematic framework.

 

Here is a short video edited during gameplay to showcase this system's performance and utility.

 


 

Video 1.  A showcase of the cinematic system

​Role Selection System

The role selection system is where players choose their character in the game. When starting for the first time, available characters from different factions are displayed with unique introductions. Once a character is selected, the player's journey in Tang Dynasty Warriors begins.

To enhance character presentations, we extended the cinematic system for use in the role selection process. A key focus was ensuring seamless transitions between characters and their environments as players switch selections. We revised the cinematic system to preload a comprehensive scene that includes all characters and their settings. This allows for instant transitions and displays each character's performance script within the role selection context.

The system is designed to be highly independent, separate from artist and designer outputs. This means new characters or edits can be added without adjusting the system.

 

Here's a video showcasing this system. The rendering techniques used for the characters will be introduced next.

Video 2.  A showcase of the role selection system

Rendering

The rendering effect in Tang Dynasty Warriors Mobile include non-PBR rendering on devices of low hardware condition and PBR rendering on more advanced devices. Among the production, I mainly  undertook the development of scene rendering with PBR technique, weather system and day-night cycling system, and took part in partial work of character rendering with pbr technique, as can been seen in video 2.

       

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 


 

​* Character and scene rendering

To boost the appearance of partial characters and scenes in game. The PBR(physically-based rendering) technique has been applied in this project. As this technique added on, object in game would exhibit distinctive texture quality using a metallic map. Those bumps, holes, gaps or cracks will be vividly depicted by bump mapping. To further achieve an approximately global illumination effect which exhibits those illumination on object contributed by its nearby surroundings, while consume less computation and space,  static environmental illumination mapping method using a pair of pre-calculated diffusion skybox and speculation skybox are utilized. These two sky boxes varies according to the scene an object resides in. 

To support PBR rendering, adjusting the rendering component of game engine to enable a extendable space for storing and transmitting those extra textures is a prerequisite. Besides, PBR shaders should also expose enough key coefficients for artist's convenient tuning for desirable result. More efficient communication with game artists, therefore, became crucial. This has inherently induced me to appreciate object appearance from artist perspective and try to understand those artistic terms game artist has frequently mentioned in their description for targeting effect. What to do next then is to further translate these artist requests to according rationale in shader codes. For instance, when artists ask for a more volumetric sense, they are actually pursing for a strengthened shading variation on 3D object, the according adjustment in shader code, therefore often implies the strengthening of variations of normal vectors on object and the intensity for strengthening is better exposed to artist for fine tuning.     

Considering the capacity of mobile device, those less noticeable while comparably expensive effect should be removed: ambient occlusion, subsurface scattering, shadow map and etc. Those consuming calculation, like high power computation should be approximated by other cheap substitute.   

​* Weather system

Weather system in this game shows dynamic exhibition of vivid rainy and snowy effect in game environment. Rainy effect, entail a gradual transition of objects in environment from dry to wet and further to pounding state. What's more indispensable is the depiction of those teeming raindrops coupled with corresponding rippling effect. These rainy effects vary from different textures: wood, metal, mud and etc. Snowy effect, on the other hand, exhibits the formation of snow cover, snowdrift and snow gap besides the blowing  snowflakes. 

Conceding to the capacity of mobile devices, weather rendering has been revised to omit those physical while less noticeable details. Rippling locations upon object surface, for example, are fixed rather than physically random. Snow effect rendering, is reached in comparatively cheap way. Moreover, snow distribution varies from surfaces of different tilting degree: horizontal surface with more snow whereas vertical surface with little.

To facilitate game artist to overview and finely tune weather effect in different scene, I replicated weather system in our scene editor tool with friendly interfaces for artist to invoke and adjust. To enable game designer to set weather state over periods of time in game. A weather management component was developed and incorporated into the game logic truck. This component periodically switchs weather state according to designer's setting in XML table.  

​* Day-night cycling system

This system was built to simulate a real-world day-night cycling nature. The transition of shading in scene from dawn, morning, noon, dusk to night is exhibited based on time-scale in game. Similar to weather system, this system was developed both in the game-play side and scene-editor side. Artists set up and overview their desirable shading effect in day-night transition of a game scene in scene-editor. The setting result is further read during game-play, adjusting the shading appearance of corresponding scene through a day in game.  

The following video epitomized an overall rendering effect including PBR rendering, weather system and day-night cycling system in Tang  Dynasty Warriors Mobile.

Video 3.  A showcase of the rendering effect in game

Game Logics

In this project, I took part in writing the logic code for several game chapters, functionality components and user interfaces by Python.

 

For those game chapters, relevant logic codes set up the state of player when the character enter the level scene. Story logic in the chapter will be moved forward by logic codes guiding player to take a sequence of targeting tasks. In this process, player may find interactive objects or NPCs. With their help or information, player further accomplish tasks. The behaviors of these interactive objects are written in logic codes. These chapter logic codes I had undertaken include: the chapter of memory(a chapter reviewing a piece of history of the character you play with), the chapter of prison-break(player control the character to rescue several imprisoned brothers in arms and defeat the prison guard), the chapter of rescuing a village under attack.  

Logic codes for some game functionality components normally requires writing corresponding function codes in client side and synchronizing the result in server side. One functionality component I wrote, for instance, is the garment changing system. As player changes character's armour, relevant client logic take off character's current garment, put them into the property bag, and take on the new garment. The server code accordingly synchronized the changed appearance of this character to all other clients in scene. 

UI logic codes, read UI resources created by game artist through Cocos Studio or Flash, and react corresponding functionality according to player's operation. For this parts, I took part in finishing the scene changing pannel, server section selection pannel and etc. 

The following video is a showcase of the chapter of memory which is mentioned above. 

Video 4.  A showcase of a game chapter 

Game Performance Optimization

For optimization work of this project, I undertook the trade-off of rendering effects that fits the capacities of various devices. The trade-off results are classified into there modes: ultra mode that reaches an utmost appearance performance by keeping all rendering effects, balance mode that balances the performance and cost by abandoning those expensive while optional effects, and fast mode that reaches the highest frame rates by only keeping those most crucial, noticeable while cheap rendering effects. By examining the device capacity, a rendering mode is recommended when player enter the game for the first time. This feature is showed in the following screen shot. 

 

 

 

 

 

 

 

 

 

 

To conserve device battery and decrease device heat, I developed the battery saving mode that turns down device screen brightness and lessen rendering costs by hiding those less-noticeable objects in scene whenever player hang on the game for a period of time. This feature is showed in the following screen shot.

 

      

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

To increase the overall frame rate, I inspected all draw calls during each rendering frame through NSight. Those trivial while consuming draw calls were removed and some successive draw calls were merged into one batching call.

classification.png

Fig 1. Selection of game performance

battery.jpg

Fig 2. Tick off the battery saving mode

battery saving mode
bottom of page