Bulletpattern Game design, Flash and Unity development

25May/160

Scripting MOBA AI

I have recently gone back to our MOBA, Adventure Time Battle Party and it reminded me about how I wanted to write up a post about the AI. There were a number of important lessons we learned and I wanted to share them.

 

Ground Rules

We didn't have much time to pursue, what I would consider, strong AI on this project. However, I love working with AI so I made time on weekends to work on this. So to be economical, our explicit goal for AI in Battle Party was "don't be dumb", which is very different from "be smart". Also, my approach to AI is rooted in "make it fun" more than an academic approach to AI, where you might be trying to emulate an algorithm or advanced behavior.

Also, AI was an aspect a number of our team wanted to learn. To keep things simple, I set up and simple state-based AI system and wrote a number of tools for newbie AI scripters to use.

One thing that's important to me is: don't cheat. I try as much as possible to not leverage any data a real player would not have. I don't want to rely on letting the computer know every last detail of a player's state or inputs and make decisions based on that knowledge. There are times when the CPU overhead of certain checks are just too expensive, and in that case, I allow myself to cheat.

 

The "Danger" Measurement

The backbone of the system was a collection of systems that produced a "danger" value. This produced a simple integer that allowed the scripters to make decisions. This system took into account:

  • The number of alive players
  • The number of nearby ("nearby" being 1.5 screens IIRC) enemy players
  • The number of unaccounted players on the mini-map
  • The number of nearby enemy minions
  • How far ally/enemy minions are pushed. This was a +/- value depending on where the minions were pushed relative to the mid-point of the map.
  • A queue of when the AI sees a player use powers. This is a good example of not cheating. Instead of looking at the player cooldowns, when the AI sees an onscreen player use a power, it lowers the danger value by a specific value for a certain time. Higher value powers lower the danger value more.
  • The powers currently available to the AI
  • Player/AI health values
  • Player/AI buffs
  • Being close to an ally/enemy tower
  • Some other items as well.

 

Basic States

The basics were patrol, attack, and flee. Since the more danger there was, the more an AI champ would flee, the back and forth between and attack and flee states created some good dive in/dive out behaviors and some pretty good kiting. If the danger value got too high, the AI would flee to allies, health pick-ups, towers, or the base. If the AI had a power that created movement, it would use this power to run away if pursued (i.e. in a flee state and a champion was close).

If the AI didn't have a champ to attack, it would push minions, help allies, capture altars, patrol, or do special actions. more on social actions later.

 

Listen for Events

Loads of events can trigger a decision to change the state – taking damage, a tower being attacked, the base being attacked, an ally champion being attacked, the danger value changing significantly, altars being open or captured, etc. Many events. Lots.

 

Special Actions

In my experience, I have found you can throw in 95% of random behaviors and 5% of really smart decisions and player's will think your AI is a genius. With this in mind, I did a couple of one-off, hard-scripted behaviors to use occasionally.

  • Tower Dive – Very rarely, when the danger rating was very low and a player was hiding under a tower, the AI would tower dive. During this brief time, it would just go HAM and ignore the danger rating and try to kill the player.
  • Ambush – If the Ai had nothing better to do, it would hide in the brush for a time and wait for players.
  • Dodge – If the player used an aimed power and the AI had a power that could be used to dodge, it would do so.

 

Other Tools

I wrote a number of tools to facilitate other scripters. Things such as "do I have a clear shot to my target?" This mean you could fire a projectile without being blocked by minions. There was a similar check that informed the danger rating on the AI, "does the player have a clear shot to me?

There were quite a few utilities like "find closest safe point", "are targets in range of my powers", etc.

 

Leading the Target

One of the biggest lessons we learned was about the value of trying to lead the target when aiming powers. Every scripture's first instinct was to try to predict player movement and fire where the player would be in the future. This might be good for a game where player velocity cannot be changed instantly, like FPS or racing game, but in a MOBA a player can "juke" (i.e. dodge) in any direction instantly, so the value of prediction is greatly decreased. Experienced players will nearly always dodge. We found that it's statistically more likely to hit player just aiming randomly in a radius around the player than trying to lead their current movement.

 

Conclusion

The AI turned out pretty good considered the limited resources we had. Quite a few people got to try their hand at scripting AI and they only needed to worry about strategies around the character's power set, instead of learning about managing behaviors states & calculating distances.

Filed under: Uncategorized No Comments
24May/160

Multiplayer Ranking Systems vs. Declining Population

The Problem

A solid ranking system is required for a healthy, competitive online game. You want same-skill players to be facing each other – you want your newbies playing and your veterans playing veterans.

A good skill system will allow high-skilled players to quickly rise in the ranks and only face like-skilled opponents. You want these good players away from the lower-skilled players as quickly as possible.

The more granular the system you have, the better matched players will be. Having numerous ranks gives players goals to work towards and the more goals the better.

But what happens a couple years after release and your game's population dwindles? You may still have a small, but dedicated, set of players who can no longer find matches due to your ranking system. What was previously a great feature of your game has become a detriment that will kill your game's community all the faster.

This unfortunately affects the players at the top ranks the most. These are your most passionate players and they are already in the smallest population pool. They will be punished the most with the longest matchmaking times.

 

A Solution(?)

A system that adjusted the number of searchable tiers separately from actual ranks would be better to offset population reduction. These searchable ranks would  shrink and grow depending on average concurrent users.

In our previous game, we had 4 ranks and 14 sub-ranks. We did matchmaking between ranks, and then allowed to expand to more ranks after a set time. Five minutes per rank, if I recall correctly. This means a high-rank player might have to wait for 15 minutes to search the entire player base for a match.

What would be better is something along the lines of:

  • Player population high = Matchmake as 4 ranks
  • Player population low = Matchmake as 1 rank

And some couple gray areas in between. This would mean when the game is healthy there are loads of ranks and similar skill matches, but as population dwindles you sacrifice skill-matching for getting games started at all. I think this is a sound trade-off.

Filed under: Uncategorized No Comments
3Nov/152

On copying games (re: Battle Party)

"Why did you copy that other game? Don't you want to make something new and original?"

Of course (nearly) all game developers want to make something new and original but there are a great many factors that inform a team's decision on what game to make. I want to give my perspective on the decisions that may go into making an "in-genre" game. I hope I can change a few minds that think when a game is influenced by another game, that the developers are not just creatively bankrupt or making a "cash grab".

We are fans

This might be a surprise, but most game developers are game players too. We are fans of all the same games every one else is playing. You know when you sit around with your friends playing a game and say, "I like Game XYZ, but I would LOVE this game if it had this and that"? Well, game developers have those same conversations and we (sometimes) get to do something about it! We can make the game we would love to play.

For Battle Party, the team liked LoL, DOTA, and other MOBAs. However, we are filthy casuals and find the standard MOBA formula too complicated, too toxic, and find the games take way too long to play. We wanted to make a MOBA for people like us.

 

Existing Team & Tech

OK, so maybe you want to make a FPS with a grappling hook or, in our case, a super streamlined "Arcade MOBA". What existing game engines or code base do you have already? What does the current team have experience or expertise making? Do all of these things line up?

Our team had a lot of experience with 1) multiplayer competitive games and 2) Diablo-style isometric games – a perfect fit for making a MOBA.

 

Business Goals

Now you have the game you want to make and the team to make it, but does it align with your parent company's goals? Is anyone going to give you time and funds to make it?

In our case, CN needed a competitive online game with global appeal. A game where we could roll out new character-specific content over a long period of time.

We had been wanting to make our take on MOBAs for a long time and the opportunity finally presented itself. We had the right design for the business goals, we had the team and tech, it was a perfect fit!

 

Deadlines

Game deadlines almost always slip. However when making games for a television company, there is a lot on the line. There are episodes of shows being produced, commercials being made, worldwide marketing plans being created – the game has to go out on time. The is no wiggle room, not a single day.

Here is where the risk of something new is a huge gamble. We have to ask ourselves, "Can we make a game that's new & innovative, in a year, with this team, that's good, on time and in budget? Can you 100% guarantee that?" There is absolutely no way you can guarantee that.

I have worked directly on 50+ games and consulted on 100+ more and I have seen how many times something truly unique, something that sounds really exciting on paper, ends up either a) taking way longer to "find the fun" than you imagined or b) turned out being bad in development, no matter how much work you put into it.

 

Conclusion

The next time you see a "copy" of game, consider that it might be the game the team was really excited about making. Maybe they had the right skills and tech already in place so they could worry about the fun part of development – making the game fun and not having to worry about making it just work. Maybe their parent company's needs aligned perfectly with something they were passionate about. And maybe they had 6 months to make it.

 

30Oct/150

Better Game UI

I work on quite a few games a year and over time this has added up to hundreds of games. During this time I have seen the same UI mistakes over and over again. I want to share a simple improvement we make to improve game UI. I will be using fake examples as to not call anyone out.

Main screen

First, let's look at an example main game screen.

main

This is functional but it could be much better. I get why developers do this – it's easy & flexible. A developer can create a single button asset with a dynamic textbox and dynamically place the buttons. The number of buttons can easily grow and updating copy for changes and localization is easy.

It can be more than just ease of development too. Sometimes UI designers come from web or app design backgrounds or a game studio leans on their website designers for UI design. However, the rules for good game UI are very different than web/app UI. The core concept that differs is that web/app interface does not seek to suggest what users should do, game UI should do this blatantly.

To make better UI, ask the question, "What do you want players to do?"

Do you want players to hit HIGH SCORES just as much as you want them to hit PLAY? No, of course not. Once you have your answer, you have an idea of what element should have dominance. The best thing to change is the size of the desired action input. This will work regardless of language, icons clarity, or color blindness. The larger size also draws players' attention best. You could also change the color or shape.

main1

There are numerous ways other to improve this. You can add icons for people who cannot read (i.e. kids) or non-english speakers to clearly delineate the "neutral" buttons.

This isn't too much more work. Instead of one dynamic text button, you make two – a neutral button and a call-to-action button. On screens with no clear call to action, using all neutral buttons is acceptable. You can expand this concepts with a call-to-action button, a neutral button, and a "back" button, when you have numerous screens that flow back and forth.

Now let's look at UI issues on the "Level End" and "Pause" screens. I am lumping these together because they usually have the same issues.

 

Level End or Pause screens

Here is what I see too often. Again, this is a fake example.

end

Again, a call-to-action is needed – what do want players to do?

end1

If you are too pressed for time to make two buttons instead of one, at least arrange buttons "in order of call-to-action", in this case, home, level menu, restart, play/continue.

 

Conclusion

Find what you want your players to do and make that the dominant interactive element! Making 2 buttons is not that much harder than making one and the clarity it provides players is worth it.

Filed under: Uncategorized No Comments
5Jul/143

Adventure Time Battle Party is out

adventure-time-battle-party

http://www.cartoonnetwork.com/games/adventuretime/adventure-time-battle-party/

 

Filed under: Uncategorized 3 Comments
23Apr/1413

Adventure Time Battle Party beta!

2014_03_03_BattlePartyLogo_B-2

Oh my Glob, you guys! The Adventure Time Battle Party MOBA is in closed beta. You can get in on that sweet gaming action!

Join the party now!

http://www.cartoonnetwork.com/games/adventuretime/adventure-time-battle-party/index.html

You can play all day Thursdays, or throw down with the devs during our scheduled play tests, Thursday nights from 8-10 EST!

Join our discussion on Reddit - http://www.reddit.com/r/battleparty/

 

Filed under: Uncategorized 13 Comments
28Nov/1318

FusionFall Heroes – Marceline sketches

While going through some old files, I found some sketches I did for Marceline in FusionFall Heroes. These were attack animation concepts. Some of them made into the game, some didn't.

20131128-130436.jpg

20131128-130427.jpg

Filed under: Uncategorized 18 Comments
1Jul/132

First boss last

I am currently working on an iOS game in my "free time" (haha, I don't really have any), mostly to learn what it takes to make a mobile game. My day job is making PC games but I feel it's my duty as a developer to stay informed of the current trends, and mobile games are surely the trend right now.

My goal was to learn the ins and out of the iOS platform, and what sort of unseen challenges mobile development can bring. In my experience I have discovered developing certain types of games, or developing certain platforms, can have large unseen challenges which must be taken into account when designing or managing a project. While I certainly learned many things about iOS development, I also have learned a very important design & development lesson. A lesson I am hoping I don't forget about when I start my next project.

That lesson is this, when you first start on your game, you are at your weakest. You don't have the hang of the development pipeline quite yet, maybe your art style or technique is 100% refined or maybe you don't have a full roadmap for the game. However, when developing a game, you often start at the beginning. You start at level 1, and then develop to the end. This means your later game content will be of greater quality than your early game content.

The problem is,of course,  more people interact with your early game content than your late game content. If you early game content isn't the best it can be, players won't ever make it to your late game content!

In my current project I have definitely fallen into this trap. My first boss fight is pretty terrible. It's confusing and doesn't build properly on the skills players have built up to that point. The other boss fights are pretty nice! Especially the last boss but who is ever going to get there when the first real payoff moment for players is so weak?

So my new rule is – do your first boss last. This is when you will be at your best and you can give your best to players.

Filed under: Uncategorized 2 Comments
20Mar/1328

FusionFall Heroes – details

What is FusionFall Heroes?

FusionFall Heroes is online multiplayer 4-player co-op beat 'em up featuring heroes from the Cartoon Network universe. Players can choose their favorite hero, run missions with their friends, beat up baddies and earn coins. Players can use their cash to buy "blind boxes" which will reward them with new heroes or rank up their existing collection.

Check out the announcement of FusionFall Heroes!

You can play Finn, Dexter, Four Arms, Mordecai and Gumball. Not only that, but we have tons of hero variations. What about Dexter with the Null Void Projector, that can send enemies to the Null Void? Finn with Generator Rex's sword? What about Mordecai taking down enemies with his guitar?

Loads more heroes coming soon 😉

 

Why Co-op Multiplayer?

Cartoon Network Games Studio focuses on multiplayer, multi-property games. While we love to make competitive games (e.g. TKO and Exonaut), we heard a lot of feedback that many players don't want to compete. So we wanted to make a cooperative games for player who wanted to play together, not against each other. We also included solo modes for players who want to get the hang of the game by themselves before teaming up with other CN fans.

 

Why in the FusionFall Universe?

FusionFall is an awesome game and a great brand. It's still popular and has a very loyal following. We wanted to give fans of FusionFall, and new players who are unfamiliar with the brand, way to have a quick, bite-sized play sessions of FusionFall. FusionFall

One major goal was to make sure everyone could experience FusionFall Heroes. That means no login or registration is required to play. Another things we are responding to, players wishes to play as the Cartoon Network heroes.

We are all super excited about FusionFall Heroes. I hope to see you all in the game!

 

Filed under: Uncategorized 28 Comments
19Mar/130

New game announced – FusionFall Heroes

Cartoon Network Games Studio's new game, FusionFall Heroes has been announced! Watch the teaser here: http://blog.cartoonnetwork.com/2013/03/19/coming-soon-fusionfall-heroes/

Stay tuned for loads more info about our new game.

Filed under: Uncategorized No Comments