Big Game Project – Week 3&4

I didn’t write a blog post last week cause it was holiday and I forgot about it after travelling home during the weekend, but I’ll make a double one now.

I feel like development slowed down somewhat after the first two weeks, but I believe this is mainly because of the earlier programming being such huge features in the game and every small task meant progress and impact in the current build of the game. For example every couple of hours I had completed a new tower or their targeting, or maybe I made the enemy spawner more dynamic. Now that most of the basic mechanics features of the game are actually done, it feels like we’re making less progress programming-wise. Either way, we’ve definitely gotten further since the last post.

Week 3 – A Use For While Loops

This week I worked on a variety of things, although overall I worked on bug fixes and many other smaller additions to the game.

I fixed so that if you sell a block tower if will make that path available again. This is interesting because it was the first time I actually used a while loop except for the game loop in games. The while loop is interesting because it continues until you tell it not to, compared to the for loop which is used frequently to check through lists or the like. I actually used the while loop inside a double for loop, which blew my mind somewhat if I’m to be honest. Last week I described the structure I made for waypoints, so you might see where I’m going with this.

When the player sells a block the waypoint manager loops until it finds a waypoint that has a blockedFrom list with an element in it. Once it finds one it casts a linecast through it’s blockFrom list with another loop to the blocked waypoints backwards and repeats this until it finds the block, this is before the block is removed. Then it loops through the paths with a while loop and removes the blocks one by one, using an int to jump through the list from block to block.

I also added animations to the enemies, which was something I had somewhat feared from earlier since we had so many problems trying to get it to work with the matching field (we ended up scrapping it and moving/animating them through code completely). Unity’s Animator is somewhat tricky to get a basic understanding of, but once I knew how it worked it was quite easy to use. For every object you want to animate you use an animator, and that itself is used to call the different animation clips that you need to have added to the animator.

Last but definitely not the least, we decided to change perspective of the game. From complete top-down 2D we’re changing to an isometric view of the game, meaning that all enemies and towers have to be re-made from scratch. I think this will hit our two artists hard in workload, but we all decided it would be for the best. Not only is it easier to understand and see all the different things on the screen, but it looks better and is also easier to draw. It’s harder to make a top-down enemy look good (and even look like an enemy) than it is to make one from the side.

Week 4 – Player Abilities And Why We Have To Re-Design, Or Maybe We Don’t

This section will be more about the design choices of the abilities and how they compare to each other, rather than how I implemented them in code. I intended to make this section a rant about how overpowered Freeze was, but I believe that there are ways to change that without reworking them.

Image

What you’re looking at is the current version of Level 4 in our game, with the player having activated the Freeze ability. It freezes all enemies on screen and stops anything from spawning for ten seconds. This sounds sweet and all, and there’s fancy effects for it already, but the problem is that the other abilities aren’t quite up to par.

I’ve been working with the abilities concerning the Tower Defense part this week, and I realized that there aren’t many reasons not to choose Freeze. Once we finish the menu system with a world map that I’ve started working on the player will be able to choose one ability to use in the game.

At the moment, there are the following ones:

Tower Defense:

  • Freeze – Stops enemies and enemy spawning for ten seconds.
  • Slow – Slows all enemies on screen for ten seconds, spawned enemies after activation are not affected.
  • Killer – Kills the first five enemies on the screen.

Match Three:

  • Clear One Resource – Removes all pieces of the clicked resource’s type on the screen.
  • Explosive – Clears two lines vertically and horizontally on the board, like a cross.
  • Chance of an Extra Resource – Gives a chance to reward the player with additional resources on matching for 20 seconds.

If you look at the list of abilities you can probably agree that Freeze is the best one. I will start by comparing the other Tower Defense ones and giving my thoughts on each one.

  • Killer is currently inferior to the other ones but can be improved by increasing the amount of enemies killed. If Killer for example killed every enemy on the screen there would be no point in taking Freeze, so that one works once balanced. I believe that people won’t take Killer in most cases, unless they like the playstyle of gathering up for a strong tower immediately. Killer is designed to kill off a bunch of enemies at once without having towers, and if the player chooses to keep matching until they get a strong tower instead of playing a couple of weaker ones, it might be viable.
  • Slow is a worse version of Freeze and I would prefer to change it to something else. Right now it at least needs a change. The only reason you would ever choose Slow over Freeze would be if you want the 10 seconds added to your time score after the battle, since it doesn’t stop the spawning. I do believe, however, that if they were slowed until they die it might be more of a contender, especially for people trying to max out score on the levels.

Comparing the Matching abilities is a bit trickier, since they don’t directly affect how well you do in killing enemies. They do however affect the task the player spends the most time on, which is important to keep in mind.

  • Clear One Resource is the same effect you get if you match five in a row and use that “special” you get. It immediately clears a chosen resource from the game and almost always it will give you enough to build a new tower (as the costs are balanced now). This is useful because it gives you extra defense on the field against the enemies. Even if you have enough fire power on the field, you might be able to clear all the coins and give you the ability to upgrade a couple of them. Definitely the strongest Matching ability and also the strongest ability to currently contend with Freeze.
  • Explosive is currently lackluster. It clears a cross of two lines of resources, but just isn’t good enough to be used instead of Clear One Resource or Freeze. I believe that adding another line so that there would be three horizontal and three vertical lines to clear might solve this. Explosive is about granting a bunch of random resources in a way that looks cool to the player, it’s not about being able to choose which one you want, and it’s not about stopping the enemies directly.
  • Chance of an Extra Resource was originally intended to be a passive ability that sometimes granted the player additional resources when matching, but we re-designed it into what it currently is because it would feel weird if the player could only choose between one passive ability. It also didn’t feel very interactive and could prove to be overpowered easily. Currently I believe it can work, depending on how you tweak it, but I think that there’s something very important that we need to keep in mind if we decide to go with this one, otherwise people will probably not use it after trying the other powerful ones I’ve mentioned. If we don’t make the duration of this effect feel good, people would never use it. If we don’t make the players notice the difference of the active, they will never choose it again. Not necessarily by making every match grant double resources or the like, but I think that if we improve the visuals and maybe even play an audio theme working with it (example: star in the Mario games) it might feel rewarding enough to use even though it’s not always the best.

This concludes my thoughts on the abilities for now, and I believe we should have a look at them the coming week and decide if we want to keep them or if we want to swap some of them out for better ones. Freeze being too strong is not necessarily a reason to make it worse, but rather to make the other ones feel better.

 

Until next time!