Extremely SIMPLE but POWERFUL platformer 'bloodhound' enemy AI

Поделиться
HTML-код
  • Опубликовано: 12 ноя 2024

Комментарии • 51

  • @andrewsolesbury115
    @andrewsolesbury115 Год назад +22

    If you wanted to have the AI 'lose' the player you could simply limit the number of waypoints it can create after it's lost sight of the player and then when it reaches the end, just have it move left and right in a sentry style until the next time the player is in sight. It might also be nice if the AI could only 'see' the player if it is facing the correct direction. This would allow the player to out manoeuvre the AI and then attack it from behind. With a combination of the 2 and a short time for tracking the player you could create the illusion that they will follow you around a corner, but no further until the player is back in sight.

    • @TheKarishi
      @TheKarishi Год назад

      This was the first thing I thought of as well; that in a game like this I didn't like the idea - either for performance or gameplay reasons - of having drones that absolutely never give up the chase. But limiting waypoints and then dropping back into a holding pattern if the last waypoint was reached seems great.

  • @windwalkerrangerdm
    @windwalkerrangerdm Год назад +11

    That is such a beautiful, elegant idea. LOVE it. I value problem solving skills very highly.

  • @TrentSterling
    @TrentSterling Год назад +4

    Also called Breadcrumb pathfinding! You can also look ahead and set the agents goal to the "highest indexed waypoint it can see and omit some" and set up a linked list with indexed waypoints for a few optimizations.
    Whether each agent gets its own list of waypoints is another gameplay / optimization direction to explore.
    You can set up paths that don't recreate the player motion so exactly. Ive seen this method work in a number of configurations and I love to see it!

  • @oldshamen
    @oldshamen Год назад +2

    This works perfectly for simple AI and provides enough challenge to make it fun. I have used a similar approach in previous dungeon crawler games with success. Also opens up for interesting mechanics like a "decoy" type of grenade that you can throw to lead the drones away from your character's trail. Would be really easy to implement if you just provide your "scent" points with a priority variable. That would also allow for implementation of "smarter" or "dumber" AI .. so many possibilities!
    Ultranova instantly reminded me of an evolved Turrican II .. which was one of my favorite games on my Amiga 500. So, it is instantly wishlisted :)

    • @Imphenzia
      @Imphenzia  Год назад +3

      Awesome, thanks for the input and great idea with the decoy - I really like that idea. I already have a hologram clone that can be deployed as one example of what the drones should lock on to.
      You could not have made me more happy than a Turrican II reference - that game has been a huge influence on my life but oddly enough mainly from a music and graphics experience, because I didn't play it much - I just put the menu music on, and I had an Amiga 500 that being one of the big reasons, haha. But I love retro, I love low poly (it's like modern pixel art to me), I love music style, I love the setting and epoch of Turrican so that will be in the back of my mind through the development process :) Thanks for the Wishlist!

  • @WaterShowsProd
    @WaterShowsProd Год назад +1

    Very interesting method. It's a lot more real-world than the enemy simply knowing the player's position and navigating toward it. Unless that's part of the story of the game, of course. For things like drones, penguins, and rampaging floor-cleaners, this method is perfect.

  • @sapientunderground
    @sapientunderground Год назад

    Very nifty, I can see myself making use of this in the near future, thankyou for sharing! Particularly, I expect it to be handy for procedural levels. Wishlisted Ultranova, looking forward to seeing what comes next!

  • @GuilhermeFArantesSouza
    @GuilhermeFArantesSouza Год назад +3

    IDEA: You could incorporate these waypoints into gameplay by making them visible to the user (maybe in a specific mode, a "electromagnetic-interference vision" kinda thing being left behind by Nova-s suit), and adding a life time to the waypoints so that they dissipate with time. This way the player can try to outrun a particularly difficult drone or group of drones, while activating the mode to see their trails to check if it's even possible to run away.

  • @samhenry97
    @samhenry97 Год назад +1

    You'll probably want to change the data structure for waypoints from List to Queue. With a list, RemoveAt(0) is O(n), which could be quite slow if the waypoint list is long or lots of drones are tracking. Since we only care about the start/end of the list, a queue would be O(1) instead 🏃‍♂

  • @jacobbradshaw995
    @jacobbradshaw995 Год назад +1

    Cool feature! Very clever!
    I have an improvement you could make.
    I noticed that the camera has some interpolation, which makes it smoother, but it also means that the player has less visibility in the direction he/she is running. Maybe you could make the camera interpolate to a location in front of the player or in the direction of his/her velocity instead.
    I love how this game is coming! I look forward to playing it when it releases!

  • @skik210
    @skik210 Год назад

    This is an amazing code breakdown. I would love to see more tutorials like this.

  • @alec_almartson
    @alec_almartson Год назад +2

    The results you are getting are Amazing 😮👏🏻
    And I also like a lot the Visuals of the game 🖼🎨 🎮💯

  • @MrTomateSalat
    @MrTomateSalat Год назад

    Cool idea - thank you very much for sharring :)

  • @davidnoyb755
    @davidnoyb755 Год назад

    Awesome game, awesome video, and awesome lesson, so well explained!. Thank you Imphenzia

  • @alexleonardkrea
    @alexleonardkrea Год назад

    That's a super cool idea! Thanks for sharing!

  • @mikedolan03
    @mikedolan03 Год назад +1

    Ive seen this called Breadcrumb AI. Dilmer who does the XR youtube tutorial channel had a breadcrumb asset in the early days i used a few times. Great explaination.

    • @Imphenzia
      @Imphenzia  Год назад

      Thanks, I figured it would already be a known/used method, thanks for letting me know the name :)

    • @mikedolan03
      @mikedolan03 Год назад

      @@Imphenzia realized it was Mike Mood from the Bendy series that created the Breadcrumbs AI asset. all those early devs in the Unity 4 space bouncing around in my head

  • @davestomper3428
    @davestomper3428 11 месяцев назад

    Your game is cool looking can't wait to play it... You need to get this on WII and other consoles it will explode

  • @eGregiousGames
    @eGregiousGames Год назад

    Keeping it real, love your content.

  • @midniteoilsoftware
    @midniteoilsoftware Год назад

    That looks amazing!

  • @haim96
    @haim96 Год назад

    very useful! thanks!

  • @DJOrangeJoe
    @DJOrangeJoe Год назад

    Amazing.

  • @letsplaybbracing9827
    @letsplaybbracing9827 Год назад +1

    Hi ! I'm going to see your game ! In your description! I see your videos and I think you are strong in you domain 🙂! And I learn with you video! Thank you for this! But it difficult to me to do like you! I asked myself: where you found inspiration?🤔😅! And you do this game with low poly modeling? Thank for your answer!

  • @StigDesign
    @StigDesign Год назад

    Really Nice to see you back :D
    btw: how hard was it to learn blender from 3dsmax? am still stuck at 3dsmax, oldeer stabel version tho hehe :D

  • @fv4202x
    @fv4202x Год назад

    I really liked this solution but this is not going to work for well for maps that include dynamic platforms right..?

    • @Imphenzia
      @Imphenzia  Год назад

      I can imagine that moving platforms will need to be compensated for. I think if the platforms are small, it would work without much of an issue. But if doors are closing etc, they could not find another path to you.

  • @juleswombat5309
    @juleswombat5309 Год назад

    Awesome thought process. Thanks for all these insights.
    Your game level is really beautiful, complex and large. Did you model this explicitly in blender or unity ? (A lot of detailed work for a level) or is it procedurally generated ?
    Then I guess you used mesh colliders on the whole level. Maybe its not actually a 3D world, just a 2D world ?

  • @andreagrumpeenlate5813
    @andreagrumpeenlate5813 Год назад

    Nice 👍 👏

  • @DenisGricuk
    @DenisGricuk Год назад

    Thanks for this video! Can you make video with approaches explained making level like this. It's one big mesh or prefabs, or random generator maze e.t.c thanks!

    • @Imphenzia
      @Imphenzia  Год назад +1

      You're welcome. Yes, that is on my list! I am learning level design in parallel to making the game and I'm trying to get it right with progression, helping the player navigate, gradually upping difficulty and challenges. I will also show the prefabs and modules, how I modeled and assembled them in Unity. I decided to go for a manual assembly rather than generated to get better control over how it looks to tie it in with story and the progression.

    • @tnrfiles
      @tnrfiles Год назад

      @@Imphenzia will be a tutorial video for creating platform in the game? it looks fantastic. the platform itself is really charming.

  • @myk3l9675
    @myk3l9675 Год назад

    Man this is cool. How did you even come up with this idea?

    • @Imphenzia
      @Imphenzia  Год назад +2

      I don't know, it sort of just clicked. But I've found in the comments that the technique is called breadcrum AI and it's been used before. I'm not surprised at that since it's such a simple technique - but I am still happy that I just stumbled across it :)

  • @annugamer24
    @annugamer24 5 месяцев назад

    hey can you help to create an enemy ai system like this but in 3d . I want it for my dinosaurs to when found or seeing the player they will follow the player and when loosed sights they will start patrolling all around the map Randomly [if possible can i add an animation in which when the dinosaurs will saw the player they will sream at player first before chasing ]. please help i am an newbie and i want to complete my game before my age hits 14 🤗🤗🥺🥺

  • @DylanODonnell
    @DylanODonnell Год назад

    Hey how are you going in Brissie? Fam settled in ok? Come down to Byron for a beer.

    • @Imphenzia
      @Imphenzia  Год назад

      Hey, yes, getting there slowly, mostly some headaches that remain from Sweden to deal with but once those are out of the way we can focus better. I should plan a road trip at some point :)

  • @markedforstrike
    @markedforstrike Год назад

    I feel that it should delete a node if new one has LoS to previous one, since on straight paths nodes between start and finish arent really used

  • @funguy398
    @funguy398 Год назад

    5:40 code about Line of sight

  • @pirateskeleton7828
    @pirateskeleton7828 5 месяцев назад

    I just finished adding an A* to my game. Had to homebrew it all because all the locations are procedurally generated, therefore no baking.

    • @Imphenzia
      @Imphenzia  Месяц назад +1

      Nice work creating your own implementation!

    • @pirateskeleton7828
      @pirateskeleton7828 Месяц назад

      @@Imphenzia thank you. My game is used dictionaries to store what type of terrain features or structural features exist at a coordinate. Instead of relying on colliders. Since everything is in a grid, it works out.

  • @scorpioncoreuniverse8981
    @scorpioncoreuniverse8981 Год назад

    What is the game storyline? Almost looks like he is going through a downed warship looking for scrap.

    • @Imphenzia
      @Imphenzia  Год назад +1

      Collecting scrap from destroyed enemies is likely part of it. I am working on the story in parallel with development so I will reveal more later - but it's a cyborg getting of a planet and there will likely be 8 land areas of the planet (this is the first wrecked ship area) and the two final areas/levels will be in orbit.

    • @scorpioncoreuniverse8981
      @scorpioncoreuniverse8981 Год назад

      @@Imphenzia sounds awesome

  • @MilesMiracle2.0
    @MilesMiracle2.0 Год назад

    What's the AI name

  • @tykobrising5339
    @tykobrising5339 Год назад

    Blodhundar har inte korta ben, det är Basset 😅

  • @letsplaybbracing9827
    @letsplaybbracing9827 Год назад

    Second!🙂

  • @Aye_Sid
    @Aye_Sid Год назад

    First 😀