Friday, May 9, 2014

Update 34: The AI is playing itself and the beginnings of a campaign.

Accomplishments this week:


AI: One of my next tasks was to apply the AI to both teams of the tactical game. While I wait for Unity 4.6's new UI to be released, using AI on both sides allows me to ignore the UI and refine the AI code. This also has the positive side-effect of preparing the AI to work better in multi-player games. This also includes selecting, targeting and dead (smoldering) tank animations. You can see these below.



Campaign: Moving next to the campaign, my goal was to create a very simple UI where:

  • Time would pass
  • Enemy encounters would be spawned
  • The game would load the tactical level with the right players and enemies
  • Auto resolve the battle with the AI
  • Return back to the campaign, where the players would receive experience and abilities as they level up.


I had to fix a lot of bugs with the AI and camera to make this all work, including creating a new static game object, but it all works great.

What is next:


  • Game Balance: The tactical game isn't currently very fair 
  • Refining the character sheet: I need to add some new properties to the characters that I am now using
  • Adding in the Campaign Diorama
  • Adding objects to the tactical game
  • Leveling up the tanks: Character progression is very important to this game

Friday, May 2, 2014

Update 33: More Refined Destruction

After refining the decay code, I went to work combining it with the destruction code. As I mentioned before, the idea was to dynamically explode my object and then use the decay to clean up the exploded blocks. This would double as a garbage collector and visually clean up the screen after the object had been destroyed. I also spent a lot of extra time making sure it would work with objects of different sizes and objects rotated. Subtle, but challenging to get right in all places. Below is a series of screenshots showing the current explosions and results. The biggest trouble I had was creating an object in the middle of my explosion with the right force. I'm very happy with the results here. You'll also notice in the during screenshots that 30% of my cubes are applied the same explosion texture as the center of the explosion. I found that this helped with performance and the explosion animation.

Square before:

Square during:

Square after:

Tank before:

Tank during:

Tank after: