This tutorial shows how you how to use the dot product determine whether an enemy is behind, beside, or in front of a player. I then explain the dot product and its use cases, and finally, I apply it to create the following functionality:
Determine enemy position in relation to the player
Perform a critical attack when behind an enemy
Perform a weak attack when beside an enemy
Have an enemy sneak up on a player when the player is looking away
Can only attack the enemy when in range
Basic player controls (move and rotate)
0:00 - 0:55 - Introduction and Showcase
0:56 - 2:30 - Project setup (place enemy and player)
2:31 - 21:20 - Explanation of Dot Product and its application
21:21 - 52:47 - Implementation of everything seen in the intro
Full project can be downloaded from:
https://github.com/nostalgicbear/Unit...
Nesta página do site você pode assistir ao vídeo on-line Unity Basic AI Tutorial - Dot Product duração hora minuto segundo em boa qualidade , que foi baixado pelo usuário Stephen 17 Junho 2018, compartilhe o link com seus amigos e conhecidos, no youtube este vídeo já foi visto 1,769 vezes e gostou 48 espectadores. Boa visualização!