My journey becoming a Unity game developer: Coin Distraction-Use AI to make the guards find the coin dropped

Guards stop to look at the coin when dropped.
Guard1 Tags added to each Security Guard object.
Guards will be sent to the coin position when dropped.
Send AI to Coin Spot method takes the hit point parameter of where the coin will be positioned.
Guards moving to the coin’s position.
Send the coin position to the GuardAI script to use, and set the guards to walk to the coin.
Use the coinPos variable to measure the distance between the guards and the coin. Set guards to Idle animation when near the coin.
Guards Idle animation activated when near the coin.
Distance and stopping distance adjusted for the guards.
Guards stopping 5 meters away from the coin.

--

--

--

Learning to become a Unity game developer.

Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

Can We Still Invent Sort Algorithms?

Cloud Models and Platforms

BLOOM FILTER: System Design

Gossip Data Dissemination Protocol

Implementing Cassandra’s Gossip Protocol : Part 2

It’s just not about the code

A photo showing a floor with three wrinkled yellow paper. There is a trashcan on the right, with one of the papers inside.

Buffer Overflow Abusing EIP Control

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Rhett Haynes

Rhett Haynes

Learning to become a Unity game developer.

More from Medium

My journey becoming a Unity game developer: 2.5D Infinite Runner-Ledge Grab System-Pt4

Enabling Unity Ads

2.5D Cert Req: Upgrading to URP

Building A Stealth Game — Creating Security Cameras