Jump to content
  • Advertisement
Sign in to follow this  
Ahbutfore

2D Spaceship Combat

This topic is 1425 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I'm working on a 2-dimensional space sim which involves combat (think Escape Velocity combat) among numerous squads of spaceships on the order of 5-10 ships per squad. The ships can have a variety of loadouts, big/small, fast/slow, long/short range weapons. Ideally I want the computer controlled squads to be able to beat human-controlled ones. The AI should be sophisticated enough to run from faster / longer range ships so they won't just get kited or fall into similar no-win scenarios.

 

This topic is probably more in depth than forum answers can go so really what I'm looking for is AI books or thorough web resources dedicated to 2D intelligent combat. Are there any good recommendations?

Share this post


Link to post
Share on other sites
Advertisement
Well the obligatory starting point will be Craig Reynolds-style steering behaviors; specific design goals like preventing kiting and avoiding no-win battles should be easy enough to solve either with a simple rule system or with some basic utility-style weighting of what each ship loadout offers in terms of speed, maneuverability, weapons power, etc.

Share this post


Link to post
Share on other sites

I did that not too long ago during my first opus of Grand Strategy: Space War - "Mercenaries"

What specifically do you find challenging with handling this form of AI?

How tighly do you want these squadrons to behave like a pack? 

 

Have a look here: 

 

 

And what Unity is now allowing me to do:

 

 

Edited by Orymus3

Share this post


Link to post
Share on other sites

The AI should be sophisticated enough to run from faster / longer range ships so they won't just get kited or fall into similar no-win scenarios.

 

This topic is probably more in depth than forum answers can go so really what I'm looking for is AI books or thorough web resources dedicated to 2D intelligent combat. Are there any good recommendations?

 

Not at all too in-depth.  We can help you out here.

 

If you have a limited number of dynamics, which it sounds like you do (e.g. ship X is faster than I am, or ship X is longer range than I am) you can test for and execute unique strategies for each of those situations.

 

The first step is to list out all of the likely scenarios where the player can take advantage of your other ships.  Step two is to find a way to test for them.  Step three is to prescribe a new behavior for those cases.

 

Then you rinse and repeat by trying to figure out if any of the new behaviors can be easily taken advantage of.  This will usually require play testing.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!