Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 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
0
Question by Ignition246 · Mar 15, 2011 at 10:21 PM · aienemyrpgbattle-system

Enemy AI/Battle system

I have some rigged models of enemies for my rpg, and after i give the player character some weapons, I want to set up a battle system. I want it to work somewhat similar to Dot Hack (Infection through Quarantine), or even like runescape. How do I make an enemy AI that runs towards the player and avoids obstacles, respawn after death, and regain health? Also, how do I make a battle system where the weapons and armor affect the amount of damage dealed to either side?

Comment
Add comment · Show 1
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 networkZombie · Mar 15, 2011 at 10:52 PM 0
Share

to avoid obstacles use raycast based AI

1 Reply

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

Answer by Uriel_96 · Mar 15, 2011 at 11:10 PM

seems you are looking for an algorithm and this kind of things believe me are very difficult. First one algorithm I recommend you that I usually use is the Greedy's algorithm an to understand it better here is an example of this algorithm: http://www.openprocessing.org/visuals/?visualID=6716 another good example of algorithm there is path finding algorithm here is an example: http://www.policyalmanac.org/games/aStarTutorial.htm, http://en.wikipedia.org/wiki/Pathfinding and if you have weakness to do all of this and you simply want something fast I recommend you the A* pathfinding and there are more examples you can see in this question http://answers.unity3d.com/questions/35421/online-advanced-aiartificial-intelligence-with-js, http://www.youtube.com/watch?v=xogj5Vw1K7E&feature=relmfu and for final there is the Dijkstra algorithm, so again doing this is very difficult but is the best way you have to get what you want


OK I give you some examples of algorithms but maybe you don't want algorithms for what your doing so there is something more simple but you cab get a lot of troubles to do this: http://www.youtube.com/watch?v=9iOfYdaaeB8&feature=relmfu


then for health and amount damage I recommend you to see all the videos but these are the videos of health and all that stuff: http://www.youtube.com/watch?v=MgRIwJrwwhE&feature=related, http://www.youtube.com/watch?v=kx31sZr_RJs, http://www.youtube.com/watch?v=xB8wEDeAQk0&feature=related, and there are more interesting things you can see if you see more videos, so hope it helps :)

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 Ignition246 · Mar 15, 2011 at 11:18 PM 0
Share

Thanks, this is very helpful. I will look into all of these algorithms and see which one(s) look best for my game.

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

1 Person is following this question.

avatar image

Related Questions

Complete AI Tutorial? 1 Answer

2D Random AI 1 Answer

free roaming enemy ai 1 Answer

Top Down Shooter Enemy AI using raycasting 1 Answer

Shooting Damage Help 1 Answer


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