top of page

Assignment 6

1. Show a screenshot of your game running.

2. Discuss the advantages of having human-readable asset files.​

1. The designer of the game can easily edit asset files and develop games without understanding codes.

2. It's also easier to understand what's happening in the game and therefore helps debugging.

3. All asset files are at the same location (Content folder) and easy to find.

​

3. Show one of your mesh files. Describe why you made the design choices that you did. In particular, help your readers to understand what you did to make the file readable and understandable for a human.

I used json for the mesh files.

Screenshot 2024-10-04 043806.png

The file consists of 4 parts:
1. triangle count: an integer;

2. vertex count per triangle: an integer;

3. vertex data: an array of objects;

   Each object represents a vertex, including:
   a) vertex position: a float array of size 3, each float representing x, y, z in order;

   b) vertex color: a float array size 3, each float representing R,G,B value in order. 

4. indice data: an array of integers

​

I make the file readable because I have a clear structure, detailed argument names, and difference between value types (integer and float, with float having one decimal place). I make vertex data an array of objects; in other words, a single vertex is an object. The reason is that one vertex may contaim much information besides the position, such as the color and normal vector. This structure is easy to understand, edit, and add more arguments to the vertex data.

One thing I hesitate is to have the position x,y,z and the color R,G,B as float arrays without more explanation. However, I feel it's a universal representation for such data. If I have R,G,B represents like "vertex_color" :{ "R" = 0.0, "G" = 0.0, "B" = 0.0 }, it may seem unnecessary and the structure will become more complex (3rd layer objects).

​

4. Show a screenshot of you debugging your MeshBuilder program.

Screenshot 2024-10-04 045911.png

©2024 by Junxuan Hu, a gameplay programmer and technical designer.

Proudly created with Wix.com

bottom of page