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
0
Question by DayyanSisson · Aug 02, 2011 at 10:19 PM · aitutorialslearning

How to Learn AI Scripting

I'm currently learning how to script. I've got most of the basics down. My team is developing a game pretty fast, so is there any tutorials in which to get me started on scripting AI. Thanks in advance.

Update

I have some more experience with scripting, so are their any tutorials specifically for scripting AI. I don't need anything specific about AI, just some tutorials on basic concepts to get down. If you don't have any resources, tips would be nice too.

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

3 Replies

· Add your reply
  • Sort: 
avatar image
3

Answer by save · Aug 03, 2011 at 07:57 PM

Lovely comments in here. :-) Well.. for the task you describe it's no biggie (book a couple of hours of testing and a couple of days of developing though into your calendar). So here's some thoughts that might help on the way:

You create checkpoints (as a simple example) for a computer driven character. You make sure that it follows these checkpoints in a correct order of sequence. The movement of how it progresses is merely up to what your game looks like. I would make the character physic driven where script control the aiming of the rigidbody towards each checkpoint, to do this you make great use of raycasts and SweepTests. The rays will act as the very eyes (or tentacles if you will) of the character.

When the character is aiming towards its goal you can go full speed - When the character is oversteering you can simply decrease the speed of the moving rigidbody so it gets time to aim towards its goal. Randomize the target area of a single checkpoint to not get exactly the same movement every time. Small adjustments like this will make it seem very much alive.

For different behavior logic you can make use of enums, they'll make the logic seem even more logical for you as a developer (if that makes sense). With this method you can trigger different events on given situations, for instance if no target is in sight and everything seems clear towards next checkpoint you make a switch for "lonesomeFlyMode", when danger occurs you switch to "barrelrollMyAssOutOfHere" / "bringOutTheBigGuns" - and so on.

Its all a matter of how complex things has to be, many events might even be able to be animated, a question you should always ask yourself before entering the realm of artificial intelligence.

Comment
Add comment · Show 3 · 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 DayyanSisson · Aug 03, 2011 at 08:18 PM 0
Share

Wow... That has been the best answer I've heard in forever! Thanks.

avatar image Meltdown · Aug 03, 2011 at 08:33 PM 1
Share

If you want a complete script on how to do something like that.. take a look how the cars follow a path in this car tutorial, step 5 : AI gotow.net/andrew/blog

This is an extremely simple AI script and shouldn't be too tough to implement. Good luck :)

avatar image save · Aug 04, 2011 at 06:10 AM 0
Share

I forgot about that once again @$$anonymous$$eltdown, great add. :-)

avatar image
2

Answer by BerggreenDK · Aug 02, 2011 at 10:29 PM

Funny, the Related Questions box in the lower right corner of this page, showed me this link:

http://answers.unity3d.com/questions/8876/ai-programing-resources.html

Comment
Add comment · Show 9 · 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 DayyanSisson · Aug 02, 2011 at 10:48 PM 0
Share

Yeah. I already looked at that. I need tutorials to help me script my OWN.

avatar image BerggreenDK · Aug 02, 2011 at 10:52 PM 0
Share

okay, tell me. WHAT kinda AI. AI is just "artificial intelligence". what sort of AI do you want to learn?

avatar image BerggreenDK · Aug 02, 2011 at 10:53 PM 0
Share

in other words: what should it perform, once its working? re$$anonymous$$der, AI's often arent that clever, they just act by patterns that you think is clever.

avatar image Chris D · Aug 02, 2011 at 11:06 PM 0
Share

From that link you'll find a run-down, from Intel, on AI design. There are a number of articles in that series and I suggest you read them.

avatar image DayyanSisson · Aug 02, 2011 at 11:14 PM 0
Share

Well, I want the AI to appear like it's fighting other AI, but doesn't have to actually do that (Space Battle)

Show more comments
avatar image
0

Answer by SisterKy · Aug 02, 2011 at 10:27 PM

http://unity3d.com/support/resources/tutorials/fpstutorial.html

Greetz, Ky.

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

6 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

How to get AI ( Boots ) 1 Answer

Machine Learning with AMD Radeon? 0 Answers

Why Does this Barracuda error suddenly pops and stops training - unity ml agents 1 Answer

Tutorials Don't work. 1 Answer

Creating Particle Systems? 0 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