Module: AG0982A - Creative Research

This blog documents my 3rd year research project at Abertay University. The focus of my research is on video game progression, tutorial design, and how to teach the player. My vision statement could be stated as such:

A game often needs to gradually introduce its mechanics and skills to the player. This needs to be done at such a pace that the player is neither anxious nor bored, and needs to be clear without sacrificing challenge. How can this balance be achieved? To investigate this, I've created a simple puzzle game, and released it to a sample of players. I can use data from their feedback to improve my game.

This issue came to my interest when I noticed that many games do a superb job of gradually teaching a player how to master a complicated system (such as Portal), while many other - often more complicated - games are lacking in comfortable and effective tutorship (such as Crusader Kings II), forcing players to resort to online wiki reading, and YouTube guides.

Saturday 27 February 2016

Creating level-building tools in Unity to allow speedy level creation

When I send out my game to gather user data, I intend to be able to quickly create and adjust levels. Faster level creation saves time at the beginning of the project when creating the initial setup, and subsequently, as I start to gather feedback and make adjustments to the design of my puzzle's progression, difficulty curve, and pacing.

To elaborate; when building my circle-rotation puzzle game in Unity, there are two main approaches:

The normal 'messy' way: This would involve me placing puzzle pieces to create my levels, one by one. I'd have to set which pieces are locked, and texture accordingly. This would work out fine eventually, but it would also A) take more time to create each level, and B) Make it difficult to make changes without messing something up, applying the wrong texture, etc.

The custom-editor 'elegant' way: Unity supports a large degree of customization. That is, if you want to make a button in the engine's editor that resets the position of all enemies in the game - rather than selecting each enemy and doing it yourself - you can do that without too much difficulty. And, in my case, say I want to ask the engine to look at all the data for the circle-pieces, which slices they're locked to, etc. and apply the appropriate texture (because it needs to be clear to the player which pieces can and can't rotate), I can do that.

(Left) Screenshot of how editing puzzle pieces would work in Unity with the 'messy' option. Locking slots can be done by ticking the boxes under 'Slots Locked', but the effect on the textures of the slice pieces won't appear until either the game starts, or until I assign it manually. This would be time consuming with complex puzzles.






So, by creating a custom editor class, I can override Unity's (already quite useful) editor features, and automate the process of assigning textures based on data, such as which slots are locked.

This is easier said than done. Creating the control system required a fair amount of debugging, and took two weeks. But the basic control structure is quite simple. Again, keep in mind that my main objective here is to allow textures to be assigned automatically. I want locked puzzle pieces to be easily picked out ...

1. Locked slots are counted up. There can be either 1, 2, 3, or 4 locked positions on a given circle piece.

2. In the case of 1 locked slot, a single-lock texture is applied to the circle piece. For 3 and 4 locked slots, it works the same way. However, if a circle piece has 2 locks, it could be either 'L' shaped, or with the two locks opposing each other.

3. The locked circle piece textures are rotated appropriately.

4. Locked textures are also applied to the slice pieces.

Using placeholder textures where the red arrows indicate locks, and to which direction the piece is being locked, here's the result:

These four circle pieces had their 'lock' indexes assigned with the clock of a button. Then by pressing the 'Update Graphics' button (that's my custom-inspector work), all of these red-arrow textures can be assigned automatically, vastly reducing the workload.

So if I ever wanted to make an adjustment to a level, the changes should be easy to implement. This will allow me to respond quickly to the feedback I gather.

No comments:

Post a Comment