3D ENEMY AI in UNITY - (E03): TAKE DAMAGE & DEATH

Поділитися
Вставка
  • Опубліковано 29 сер 2024
  • Let's Finish Implementing the enemy AI behavior in Unity!
    ● 3D ENEMY AI (Part 01): • 3D ENEMY AI in UNITY -...
    ● 3D ENEMY AI (Part 02): • 3D ENEMY AI in UNITY -...
    ● Third Person Controller: • Create a Third Person ...
    ● Scripts Link: bit.ly/3zmQ8VB
    ♥ Don't Click This! : bit.ly/2Zi3vu9
    ♥ My Second Channel: bit.ly/3jvI8g6
    --------------------------------------------------------------------
    ✅ My current Productivity Setup 👇:
    ● Gaming Headset: amzn.to/3HyXgp2
    ● Gaming Mouse: amzn.to/3ni4Ygp
    ● Best Webcam: amzn.to/44pVUqw
    ● Keyboard: amzn.to/3ALXB3M
    ● GPU: amzn.to/42mylNt
    ● CPU: amzn.to/44lOBjs
    --------------------------------------------------------------------
    FOLLOW ME:
    ● Facebook: / developer3.5pro
    ● Sketchfab: sketchfab.com/...
    --------------------------------------------------------------------
    ► All content by GDTitans is 100% free. I believe that education should be freely available to everyone.

КОМЕНТАРІ • 76

  • @nicolaimasur6358
    @nicolaimasur6358 2 роки тому +5

    Thanks for this great tutorial!
    It would be interesting if the dragon could damage the character and after 5 hits, for example, a message comes up: you died!

    • @GDTitans
      @GDTitans  2 роки тому +3

      Thanks 😊
      That's the topic of the next videos

    • @nicolaimasur6358
      @nicolaimasur6358 2 роки тому +1

      @@GDTitans oh okay, i'm looking forward to it :)

    • @laserkillerofthedeath8024
      @laserkillerofthedeath8024 19 днів тому

      @@GDTitans hello Sir, did yo ever do a video for the dragon damage the player? ive looked and can't find it.

  • @tigerjustice
    @tigerjustice Рік тому +1

    You have created a very useful course. Thank you very much

  • @markovetska
    @markovetska Рік тому +1

    Thanks for this great tutorial!

    • @GDTitans
      @GDTitans  Рік тому +2

      Glad it was helpful!

  • @glimpsygames2734
    @glimpsygames2734 Рік тому +2

    OnTriggerEnter needs a rigidbody component in 3D on the caller (Arrow)

  • @dreamland3855
    @dreamland3855 2 роки тому +1

    Keep it going

  • @AytonNijboer
    @AytonNijboer Рік тому +4

    Hey, just a heads up, the dragon sounds are not on the google drive anymore

  • @user-lb4oi4sr2o
    @user-lb4oi4sr2o 2 роки тому +1

    Very good videos. Good Format explaining of content. like

    • @GDTitans
      @GDTitans  2 роки тому +2

      Glad you enjoyed it

  • @Sven7VR
    @Sven7VR 7 місяців тому

    These courses are GREAT! TY so much. Question - Is there any way to make the arrows stay stuck in the enemy instead of floating? Or even disappear?

    • @KhanKhan-mo4de
      @KhanKhan-mo4de 7 місяців тому

      Destroy (this.gameObject)
      After the arrows hit the dragon

  • @wesleye9062
    @wesleye9062 2 роки тому +2

    does this work for raycasting?

  • @zackwilder1856
    @zackwilder1856 Рік тому +2

    My enemy is floating in the air when plays the death animation. I've disabled the Nav Mesh Agent and it plays well. Any ideias what went wrong?

  • @SteveTheExploiter
    @SteveTheExploiter 2 роки тому +1

    With the HP variable in the class dragon set to public, calling TakeDamage is unnecessary, I can just set the HP variable directly. If you want a variable to show up in inspector, keep it private to the class and make it a [serializefield], otherwise ANY class can change the HP variable.

    • @GDTitans
      @GDTitans  2 роки тому +2

      Thanks for the advice.
      It's a good practice in coding.

  • @malikthetalentmaker6001
    @malikthetalentmaker6001 2 роки тому +2

    And there's another problem
    I did everything you did and no sound is playing

  • @Zaidiio_o
    @Zaidiio_o 2 місяці тому +1

    where you downloaded these sounds

  • @fredqq2003
    @fredqq2003 Рік тому +1

    May I ask, can we use StateMaching to call a particleSystem?

  • @tobiasnilssenopedal6660
    @tobiasnilssenopedal6660 Рік тому +1

    why do you have Destroy(gameObject, 10); at the start function in your arrow script? what does this mean

    • @GDTitans
      @GDTitans  Рік тому +2

      Once the arrow is instantiated, this function will destroy it after 10 seconds.

  • @kevingervais3900
    @kevingervais3900 2 роки тому +3

    Audio files aren't good

  • @phamthanhbinhfgwhcm9000
    @phamthanhbinhfgwhcm9000 Рік тому +1

    Where can I find sound effect for free please help

  • @CYCY-gi8us
    @CYCY-gi8us Рік тому

    You did a great tutorial! but just a little help, when I shoot a bullet that I created on my own (I'm trying to make a fps game) the dragon is like having a force field and all my bullets just fly away when I shot at the dragon. Why is this happening? Thanks!

  • @letsplayfuxico6509
    @letsplayfuxico6509 8 місяців тому

    why doesn't the mesh collider work. I can only make it work with the box and capsule collider, for some reason the mesh collider doesn't recognise the shape of the dragon. How can I make it work?

  • @danebutler4575
    @danebutler4575 Рік тому +2

    For some reason my projectile does not trigger any reaction from the enemy. It just bounces off.

    • @CYCY-gi8us
      @CYCY-gi8us Рік тому

      same

    • @CYCY-gi8us
      @CYCY-gi8us Рік тому +1

      hey I just found out you need to tick is trigger on your whatever collider like a box collider to work

  • @cmfunkwito
    @cmfunkwito 2 місяці тому

    collider change collision if you want hit Dragon and use box collider

  • @afnirestianaputrid6091
    @afnirestianaputrid6091 2 роки тому +1

    Hi, i did everything, but with bullet, theres no effect, no animation, just pass through it, any solution?

    • @GDTitans
      @GDTitans  2 роки тому +1

      Make sure that the enemy and the bullets have a collider in order to work

  • @MoTivE-pw9hb
    @MoTivE-pw9hb Рік тому +1

    Amazing tutorial so far, but iv hit a problem as I have tried this with a character who has a sword and when I hit the enemy nothing happened no animations are being trigger ? I have added Collison box to my sword on my player character but it seems to not be detected on the enemy 🤨 any idea what's going on here pls ??

    • @loicrohan5017
      @loicrohan5017 8 місяців тому

      I'm having the same problem

    • @emretasdemiir
      @emretasdemiir 8 місяців тому

      any update?@@loicrohan5017

    • @melted__
      @melted__ 7 місяців тому

      did u fix this I am having the same problem

    • @emretasdemiir
      @emretasdemiir 7 місяців тому

      @@melted__ i think you need to add rigidbody both to the colliders, try it, i fixed it a long time ago but i couldnt remember

  • @malikthetalentmaker6001
    @malikthetalentmaker6001 2 роки тому +2

    Do you have a solution for me
    Mr.chaker?

  • @KineticProduction
    @KineticProduction Рік тому +1

    Please atleast make Player Health script also...The series is not complete

  • @torokami1109
    @torokami1109 7 місяців тому

    My projectiles somehow can only hit the enemy in the attack state, what could be the problem?

  • @turgaykirikkale3224
    @turgaykirikkale3224 11 місяців тому

    Thanks for video how can we reach sound effects?

  • @malikthetalentmaker6001
    @malikthetalentmaker6001 2 роки тому +2

    Mr.chaker I got a problem in unity endless runner 3d
    Whatever I do in animation transitions it goes wrong
    Run->slide works but
    Slide->run never works
    You have an idea of how to fix this?

  • @nabilahzairi867
    @nabilahzairi867 Рік тому +1

    Hi, may i know if this works for VR fighting?

    • @powermax6391
      @powermax6391 Рік тому

      Works as well, you just have to set up your Input system. Code remains the same.

  • @gmangman123
    @gmangman123 Рік тому

    Thx my friend but we need; when the player shot the enemy, enemy start to attack player. just like when player get enter enemy attack circle. Thx.

  • @juliaalder2007
    @juliaalder2007 Рік тому +1

    I get the wrong audios, when I click the link. The audios from the 2D series (Checkpoint, Click, Coins, First Jump,...). :(

  • @indiestudio23
    @indiestudio23 2 роки тому

    Bro A small problem with my arrow when I Add A Box Collider To my Arrow And Enable Trigger Then Arrow Moving just front of my character and Floating In air Solution Please.

  • @charlocabural9973
    @charlocabural9973 Рік тому

    I having a Issue in Take damage I dont know if the collider is not trrigged or what
    the enemy is not taking damage
    My weapon is a Sword I add the weapondamage on it like the arrow in this video and collider and attributes in the enemy

    • @melted__
      @melted__ 7 місяців тому

      did u fix this i am having the same problem

    • @charlocabural9973
      @charlocabural9973 7 місяців тому

      @@melted__
      Yeah, I forgot to add Rigid body Component

    • @kyb4182
      @kyb4182 6 місяців тому

      Do I have to add RigidBody to Weapon or Enmy?@@charlocabural9973

    • @jhovanesparago8701
      @jhovanesparago8701 5 місяців тому

      ​@@charlocabural9973rigidbody of what the dragon or the sword?

    • @charlocabural9973
      @charlocabural9973 5 місяців тому

      @@jhovanesparago8701 both because the dragon also has an attack and the player has a sword

  • @PlayOurGamesHorrorGames
    @PlayOurGamesHorrorGames Рік тому

    My First Game Will Be "Horror Dinospaital"

  • @EydouTouchFr
    @EydouTouchFr 2 роки тому +1

    hello where is the audio manager script?

    • @GDTitans
      @GDTitans  2 роки тому +1

      Hi, I forgot to add it.
      Thanks, for reminder

    • @GDTitans
      @GDTitans  2 роки тому +1

      bit.ly/3zmQ8VB

    • @user-yd4yq6qu3x
      @user-yd4yq6qu3x 9 місяців тому

      Excuse me where is dragon sounds ?

  • @HD_TOON
    @HD_TOON 2 роки тому

    Please uploade how to fix games crash on android device

  • @muhammmadluckylazuardisant3046

    can you tell me how to enemy attack damage player?

    • @GDTitans
      @GDTitans  Рік тому +1

      I will cover that in the next video 📹

    • @remmer9964
      @remmer9964 Рік тому

      @@GDTitans will you ever finish this and add attacking the player? You have another video series like this but it's with shooting the player instead of a melee attack. It would be suuper useful to see how it's done with the dragon's melee.

  • @zeroerror2338
    @zeroerror2338 Рік тому +2

    my dragon is dying in air help

    • @zackwilder1856
      @zackwilder1856 Рік тому

      I have a zombie and is dying in the air too. Did you find the solution?...

    • @dootieb
      @dootieb Рік тому +1

      @@zackwilder1856 I had the same issue but found the answer in the Unity forums. Back in the animator controller if you open up the "Death" animation and on animation tab change the Root Transform Position (Y), Based Upon value to "Feet" instead of "Original".

    • @zackwilder1856
      @zackwilder1856 Рік тому

      @@dootieb Nice!!! Thank you very much!!!