Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 12 Next capture
2021 2022 2023
1 capture
12 Jun 22 - 12 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
1
Question by DallonF · May 27, 2011 at 11:26 PM · movementpathfindingrtssteeringgroup

RTS Movement - I'm doing it wrong

I'm working on an RTS where units move in groups. If you've ever played Age of Empires III, Battle for Middle Earth II or Star Wars: Empire at War, it's basically like that, except groups can get pretty big (>15 units).

It makes sense to me to calculate pathfinding once for the whole group, then have all the units follow that path. I've been having nothing but problems: Units furthest from the group center will get stuck on walls and corners, units bump into each other, the front-most units are actually pushed ahead by the others and get twitchy, and when/if they reach the destination, the entire group degenerates into a mosh pit of tanks trying to get to the center.

I'm sure I'm doing something fundamentally wrong here. Any ideas what the best approach would be for this?

Also, I really don't want to use stuff from the Asset Store here. My budget is zero and since this project is just a prototype, I need to be able to port my eventual solution to other platforms and languages outside of Unity.

Comment
Add comment
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

2 Replies

· Add your reply
  • Sort: 
avatar image
0
Best Answer

Answer by DallonF · Jun 25, 2011 at 08:04 PM

Well, I wound up just using the cohesion part of Boids, while adding a more intelligent pathfinding system that actually follows the path instead of going from waypoint to waypoint :) Combined, they create an issue where large groups slow down, but I'll figure that out eventually.

Comment
Add comment · Show 1 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image lordmonkey · Nov 07, 2012 at 02:54 PM 0
Share

Hi DallonF, can you describe how did you solve that problem?

avatar image
1

Answer by Chris D · Jun 02, 2011 at 11:23 PM

Check out Boids stuff - there's even a couple of implementations in unity. It's a flocking algorithm and sounds like it might be what you're in need of (mass of units all moving to a common point).

Also, could be relevant: http://answers.unity3d.com/questions/21618/colliders-slow-for-crowds.html

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

3 People are following this question.

avatar image avatar image avatar image

Related Questions

Group Movement (RTS style) using Unity Pro NavMesh 0 Answers

Better Point to Point Movement 2 Answers

Physics based click to move 1 Answer

Racing Ai? long read 1 Answer

Pathfinding and AI for an RTS game 3 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges