#gameplay-ai

1 messages · Page 50 of 1

uneven cloud
#

What have you got so far?

pure creek
#

ok i will show you

#

alot of guys said i need something that starts the attack but im using ascent combat freamwork so i dont know what start it

uneven cloud
pure creek
uneven cloud
pure creek
#

forget that do you know how to implement thing like this

harsh storm
#

There is a greater chance than zero that Luthage knows how to implement the desired behavior.

uneven cloud
pure creek
harsh storm
#

This kind of thing can be handled with a simple ticket/token system. (As Luthage just mentioned).

Pretty much, AI can only do something if they have a token. So in this case, they want an attack token. You can only have 2 attack tokens in use at a time. So - if they have an attack token, then they would attack, otherwise, move around or something.

#

Then on death, return the attack token so another AI can claim it.

pure creek
uneven cloud
harsh storm
#

This can be very very simply implemented as an array in the gamestate/gamemode (if you're trying to stick to doing BP only). Not saying it's the best place to put it. That array has X number of attack tokens. When AI wants an attack token, they ask the gamestate for one. And it removes it from the array. When you give it back to the gamestate, it adds it back to the array. Array can be like, Available Attack Tokens or something like that.

The reason I'm saying GameState is because it is globally accessible, so it's easy to get and give back the token. Again - I want to stress this is a very very very crude way of doing it.

pure creek
uneven cloud
harsh storm
uneven cloud
harsh storm
#

(Jokes aside, you're right)

#

Was just thrown there as a quick, easy to implement thing.

#

I didn't even think about the actual target part 😭

pure creek
harsh storm
#

Target is the better approach

#

The important part is understanding the concept of tokens

uneven cloud
# pure creek ok ill try that

All you need is 2 ints on the target. The max tokens available and the number of current tokens. A function on the target to request a token and one to release. If Nun tokens is < max tokens, you can give one out and increment the number of tokens.

harsh storm
#

That is the super duper simple and straight forward approach.

pure creek
uneven cloud
pure creek
#

ok what should i set the default value

harsh storm
#

w/e you want the max tokens to be. In this case, sounds like 2

cold surge
#

No I'd rather even not use them!
I have a Single Player Game in the Yosemite Valley, so forest rich environment, and Navmesh is needed for some roaming Wildlife and such.
Mainly ABK powered animals.

I'm building Paths now, but previous run was going for over 3 hours.. I don't understand why it takes so long. I wish I could figure out and find out what's slowing the Nav building down..

uneven cloud
#

Ours is more complicated, but it still tracks them via ints.

pure creek
#

ok i created the functions and than what

harsh storm
#

Reread what Luthage said and work through it.

#

She can't write each line of code for you

uneven cloud
cold surge
rough finch
#

I guess I'll bump my question since I think it got flooded over 😛

uneven cloud
cold surge
uneven cloud
pure creek
#

is this right

rough finch
uneven cloud
# pure creek is this right

You'll want to return true or false depending on if they can get a token. I'd also recommend using the increment node, but the logic is correct.

uneven cloud
pure creek
#

this part You'll want to return true or false depending on if they can get a token

harsh storm
#

Convert those red events to functions. And return true if you grant a token successfully or false if you don't.

harsh storm
#

This kind of communication is beginner tier terminology. You might want to go through a beginner BP course from Epic. Not necessarily the AI one that was referenced earlier. I don't think they teach beginner level topics.

uneven cloud
pure creek
#

is this right

harsh storm
pure creek
uneven cloud
pure creek
harsh storm
#

Do the same thing, but backwards

#

Instead of incrementing, you decrement

pure creek
harsh storm
#

And don't let it go into the negatives

pure creek
#

ok now what

harsh storm
#

Now you go back and reread what was explained to you a few times, in different ways, and try to figure out what you need to do to accomplish the end goal. You really need to do some of this on your own in order to cement the understanding.

#

All for helping, but not paint by numbers.

pure creek
harsh storm
#

Spend more than 3 minutes trying to figure it out

harsh storm
#

This is the very important part in the learning process

#

It's where you use your problem solving skills

#

Which really helps with actually learning

#

And that is the important bit

pure creek
#

you really type fast

#

still : (

subtle birch
#

i have a question am considering to use mass crowd but am not sure if its stable enough and also if its able to do attack commands like zombies does anybody know if its stable to use in a project and if its even posible to use it for say a zombie templet ?

harsh storm
#

It's not marked as production ready - so there is that

#

I wouldn't use it yet myself. But some people are.

mortal bay
#

Hi all. Why doesn't a service continually execute while a child node is executing the "move to" task? Am I thinking about this wrong?

#

(I want the "move to" task to abort if the service changes a certain value)

uneven cloud
subtle birch
#

hmm ok is there maby a other way to have like a manager that instucks the ai to do tasks. instead of telling every ai to do individual tasks

mortal bay
uneven cloud
pure creek
uneven cloud
sudden stag
#

just to double check. this is how a ST should look like where a states should lead to the other? in this instance it should get patrol point then Move to Patrol Point then wait? (i know i can do all these stuff in one task, im just playing around with this thing for now)

harsh storm
#

From what I remember of ST from a year and some change ago, yes.

#

Take that for what its worth

sudden stag
#

sure! btw what do you think of it? to me it seems like a neat way to organise a boss fight maybe but for "regular" enemies i feel like BTs is the way to go. maybe have the ST act as a "enemy team manager" of sorts. what do you think?

harsh storm
#

Editor was too buggy for me when I used it. My boss fights are simple. I just cram everything in the class. (Don't bonk me Luthage)

#

Good ol' simple state machine that is handled via enums

sudden stag
#

lol fair enough

subtle birch
rotund swallow
#

Trying to use "FindPathToLocationSynchronously" with a Nav Query and having issues.

Want AI to path through the "BP_NavArea_Pawn1", but it still avoids it like the query doesn't exist.

Tried playing with "Travel Cost Override" with no luck...

#

What am I doing wrong?

uneven cloud
rotund swallow
uneven cloud
harsh storm
#

@uneven cloud Do you hear it as a "token" system or "ticket" system more frequently?

harsh storm
# uneven cloud Token

I ask, because I've renamed the one I wrote like 4 times, undecided on what to call it that is familiar 😅

rotund swallow
#

Sure! Doing this at BeginPlay in the Character BP and then MoveTo in the Behavior Tree.

(Patrol point expected is the Path End given in the function.)

uneven cloud
harsh storm
#

Back to token I go!

uneven cloud
uneven cloud
rotund swallow
#

Thanks, I didn't set it in the controller. Originally had it in a BTTask, but we were having issues, so were doing some quick tests.

Image shows the latest. Looks to go through, but still puts path points at the edge of the Nav Area, which is strange.

#

Are you able to replicate it in a blank project? Been stumped trying different things.

rotund swallow
#

May just be a function bug. The "MoveToActor" node works as expected.

cyan sigil
#

Hello! When I am using EQS I want the AI to pick a location relative to the player, but prefer the MIDDLE of the available range instead of the minimum or maximum distance. How can I do this? Can I make a custom score curve?

uneven cloud
cyan sigil
#

I'm having a hard time getting a particular behavior. I want this AI to move towards a particular location while shooting. In this tree I am having them move immediately, then after 0.5 seconds I want them to shoot three times, then wait until both the movement is done and the shooting is done. However, in this setup if they reach the target too late they will repeat the shooting branch a second time. How can I ensure branch #11 only fires once?

#

If I make the Shooting the purple parallel then the Loop decorator does not work.

#

Oh! I had an extra loop decorator that was fucking my testing.

nimble smelt
#

How does PlaySound interact with looping sounds? Is there a graceful way to start it and stop it?

deep bramble
#

Does garbage collection clear out all the old unused AI controllers after the pawn has been destroyed? They seem to be accumulating.

uneven cloud
deep bramble
#

Also should I bother calling unpossess before destroying a "dead" AI pawn?

#

I guess that doesn't matter because a new one is possessed but it seems a new AI controller is also created instead of being reused.

vivid drift
#

Calling clear blackboard value appears to be setting my vector value to have all 3 values be the max float value. I'm curious if there's any logic to that?

open swift
#

what is the way you're supposed to handle arrays in a blackboard? You can't set an array key that I can find. For example, if I wanted to update in a service a list of enemies that are close together, and then pass those in to a task to fire an attack at all enemies in that group? Would I just do this outside the blackboard?

celest python
#

I also prefer ticket these days because people confuse tokens with NFTs.. burn

uneven cloud
uneven cloud
cyan sigil
#

The solution to my problem turned out to be using multiple MovetoLocation tasks run back to back.

pure creek
#

ok than ill delete what all what you have said cuz you didnt tell me what to do next done

dense owl
#

Another satisfied customer. Next!

naive sorrel
#

Hello, is there a way to temporary like 5s disable ALL inputs from the AI controller ? so that the pawn doesnt move or rotate or anything ?

#

My problem is it rotates to the player when stunned 😦

#

Like I need to mute the AI controller or something

misty wharf
weary holly
#

has anyone ever used the perception stimuli forgotten event? It never fires off for some reason. Is the system in that part broken too or is it just me?

naive sorrel
#

Yeah I've used it

weary holly
#

ah now i see, need to turn it on in the project settings

lyric flint
#

Hey all!

I want to script a behavior tree to have an AI peek out of cover, fire a few shots, and then duck back down.

I currently have this set up as a BT service:

  • On Activation the service plays the first section of an anim montage (for peeking)
  • This section leads into a looping section of the character standing
  • On Deactivation the service plays the last section of the anim montage (for ducking)

It seems like there are a few problems with my implementation:

  1. It is fighting the animation blueprint (i.e., there is animation state logic living in my BT).
  2. Sometimes, the service ends and the deactivation is called, but the animation doesn't play the last section of the anim montage (probably because of #1).

A few questions:

  1. Should I turn this service into two BT tasks: Peek and Unpeek that require the peek/unpeek behavior to complete before returning?
  2. Should I be running Play Montage in this service/these tasks at all?
  3. If no to #2, is the best way to communicate to the ABP that my AI's state has changed using gameplay tags on the character (e.g., Character.State.IsPeeking)?

Thanks!

nimble smelt
#

This tree is largely working how I want, but the one problem is that if the target is within range and NOT in line of sight, it frantically does line traces every frame. How can I make that decorator only attempt its check every 0.1 second or so?

#

I've got it working now, but this pattern I've developed of using a simple parallel "wait + move" to be "just move around for this amount of time before trying anything else" feels wrong

nimble smelt
#

Wait is there seriously no way to dynamically configure an AIPerception component? If I've got two pawns that have exactly the same brain, the same logic, but one has sight range 1000 and the other has sight range 500, how would you do that?

lyric flint
nimble smelt
#

Orrrrrr I subclass my controller and don't create an entirely new dev environment to change one stupid thing

devout bramble
#

For some reason, my enemy randomly stops chasing the player. I think it might be because I'm using AI perception and the event 'On Target Perception Updated', which apparently only fires an event when the player is moving. But how do I fix this with an alternative?

dense owl
devout bramble
#

Alright, I'll try that and see how it goes. Thanks!

uneven cloud
# lyric flint Hey all! I want to script a behavior tree to have an AI peek out of cover, fire...

You don't want to play an animation with a service, if you want logic to wait for the animation to play. You have to use tasks for that.

I don't recommend using the anim bp for anything that isn't stateful. Attacks, reactions or anything that is one off and triggered by something should be done via montages.

If your anim BP is fighting the montages, then you don't have it set up correctly. Montages should override whatever the anim BP is doing.

uneven cloud
nimble smelt
# uneven cloud Why do you have multiple line of sight decorators for the same branch? Also why...

Why do you have multiple line of sight decorators for the same branch?

The wait. The enemy sees the player and stops, getting ready to pounce, but the player has that moment to break LOS and avoid the attack. But I also want it to be resilient to the player breaking LOS for just a moment, or lingering on the edge of the range, which is why I'm only checking at the "entrance" to this sequence, and right before the attack, but not continuously checking in between.

nimble smelt
# uneven cloud Why do you have multiple line of sight decorators for the same branch? Also why...

As for the wait and move, the basic idea is force the enemy to stay in movement mode and NOT do the attack at certain points, even if that attack move would otherwise be valid.
For example, if the enemy jumps at the player and MISSES, then it's behind the player. It'll still be close, it'll probably still have LOS, so if I don't stop it, it'll immediately jump at the player again but this time from behind, making the attack nearly impossible to avoid. Bad experience. So I force it to roam around for 3 seconds before it can try again.

#

Think of it as "Wait + Idle Animation", just that I have it walk around instead of idling in place

bleak gazelle
#

Are there any guides out there on overriding ANavigationData in C++? Would like to have a concise list of to-dos and interfaces to look into rather than reverse-engineering it myself via code parsing.

misty wharf
bleak gazelle
#

Still really helpful; I'm going into this mostly-blind so any clarity is beyond welcome bcaApprovingNod thanks a million, I'll definitely give these a read

tardy sundial
#

Hello everyone.

I’m currently working on my AIs for my game, and while testing performance I hit a wall… Basically my game is a theme park builder, and I would need to have at least 1000 AI pawns/characters on screen with another 9000 hidden while still executing their logic (state tree).

My issue is that just having a few hundred AIs on screen kills performance, I’m unable to reach beyond 500 without going under 10fps.

Now, I have tested multiple ways to optimize the AIs on screen, I have turned off any overlap, optimized the movement component, collisions and I even have a plugin to handle distanced-based update rate, but it doesn’t help that much.

I also did research based on the profiler results I got, and it seems like the issue comes mainly from the character movement component, unfortunately I haven’t found a good way to replace it.

I also know about MASS, but from my understanding, MASS is still heavily hidden behind C++ and doesn’t work with the nav mesh and I'm unsure it works with my type of AI yet.

So there I am, stuck with this issue, I would really need help with that.

Thanks.

misty wharf
#

If you've found that CMC is the main source of performance trouble (which seems likely), I would suggest trying to first replace it with a much simplified movement system

#

For a game where I would assume the NPC's are primarily going to be walking on paths and not doing anything particularly fancy, you can probably get away with a much simplified movement system where it behaves more like the floating pawn movement component or such

tardy sundial
#

I see, yeah the AI just has goals to reach and animations to play, the movement doesn't need to be super complicated, walking, running... No jumping or anything... I found an Unreal livestream where they talk about alternative Pawn movement but this livestream was of no use since the hosts are just goofing around the whole time

misty wharf
#

There's probably like 5-10 minutes of useful content hidden somewhere in the two hours of goofing

#

Unfortunately that's just how the streams are

tardy sundial
#

I'll try to watch it entirely, and I'll do some more research on "floating pawn movement"

misty wharf
#

If you didn't try it, maybe see if using navwalking instead of regular walking on the CMC would be any better

#

that effectively just makes it stick to the navmesh instead of trying to simulate the movement more

tardy sundial
#

I think it uses that by default, at least from what I read

raw tundra
#

My enemies were not colliding with the player(thus not causing damage), unless the player would walk toward them. Unchecking this fixed that. Just in case someone else is having the same issue.

uneven cloud
tardy sundial
#

I figured that much

uneven cloud
#

You don't have access to the significance manager or the animation budgeter. You can't profile even your own BP, so if you do a simplified BP movement component you can't profile it.

#

I can't say it's impossible, but it probably is.

cyan sigil
#

Hello! In my behavior tree, I have the need to start two different tasks and wait until both are considered complete. I tried using Simple Parallel but that only allows a single task in the main slot, and the other branch will loop when I want it to end. Is there a practical way to do this?

uneven cloud
cyan sigil
#

Move towards a designated location, and also use an ability a certain number of times in a row.

#

I found a workaround by repeating the Move task multiple times in the tree but it seemed unclean.

harsh storm
#

Why wouldn't that just be to move to the location and then a different task to use the ability - with the ability one in a loop?

#

Update the location in a service while the move to is happening

#

Or are you trying to move and shoot at the same time?

devout bramble
#

I'm trying to make an AI enemy that's blind and detects where the player is via hearing. I know how to give the AI hearing, but I don't know how to make the player make noise whenever they walk. How can I get the player to make noise when they walk so that the AI can chase it?

sly saddle
#

I'm trying to write an EQSQuery to find the "nearest container with an item of Class". The query itself isn't too complicated, I've already added my own filter test to check if each actor has the specified item.

However I'd now like to be able to configure the item we're testing for from the BehaviourTree that is calling RunEQS.

I've had a look at the QueryConfig, it looks like it only supports float/int/bool as configurable parameters. Does anyone know of another way I can pass down a UClass or even a UObject?

harsh storm
devout bramble
#

Oh sorry, I forgot to mention as well that it's a first-person game

harsh storm
#

Make a sound event every like, 0.1 second as long as your moving.

#

So first check that the movement component has a velocity length > 0. If true, make the noise event. But only do this check every X seconds

#

Or something like that.

devout bramble
#

Ok, I'll try that. Thanks!

open swift
harsh storm
#

My service doesn't actually tick - is there a way to remove this in the UI?

cobalt kayak
#

I'm not all too familiar with AI, but needing to add to my game. Only issue is I can't use navmesh as the entirey of my game is within a 3d swimming environment. Anyone have anything they could point me to for something like that? I've seen one that uses BOIDS for flying animals, but it's not working for me for some reason, so wondering if theres a better way.

dense owl
sly saddle
# open swift Also very interested in this, it looks like internally they're actually all just...

I spent a couple hours googling + reading documentation source code and the best I can find is that you might be able to pass a UEnvQueryContext that pulls the value from the Blackboard component of the Querier actor. You'd still have a hardcoded BlackboardKey name, but at least you wouldn't need a seperate EQS query for each individual item you were looking for.

https://forums.unrealengine.com/t/right-way-of-passing-parameters-to-eqs-after-running-it-from-run-eqsquery-node/473470/2

Haven't actually tested it, for now I've given up and gone back to a BehaviourTask.

open swift
#

was using EQS outside of a behavior tree, so unfortunately don't really have blackboard keys 😦

sly saddle
sly saddle
# open swift was using EQS outside of a behavior tree, so unfortunately don't really have bla...

Something like this (the UObject just implementing a couple of ExposeOnSpawn properties for the actual Querier, and whatever Class you're trying to filter by).

You'd still then need a context to pull that TargetClass from the wrapped Querier, and probably need to replace the default Engine querier context (since it's now wrapped by another object).

No idea if it would work, but it might be a path to explore.

open swift
#

interesting, i'll have to look into it a bit more lol

strange crystal
#

I have level sequence and am spawning one of my enemies, it runs forward and then is supposed to attack the player. BUT when its done jogging, it just runs in place and cant attack me :/ (yes I have nav mesh an tried turning on run physics without controller. and auto posses AI is place in world or spawned)....
Im stuck. nany ideas? thx yall!

dense owl
strange crystal
#

@dense owl ...
Wierd it didnt log it like I expected

dense owl
#

currently you’re looking at the gameplay debugger thing but you want to observe the PCs

strange crystal
#

Guess its nav mesh related

#

TY

dense owl
strange crystal
#

I pretty have this all in a sequence.
basically it does -spawn particle effect Portal thing. Enemy spawns/isVisible, walks through portal. Then game resumes and he uses the regular AI to come kill the player

dense owl
#

Basically that’s saying your guy is not on the mesh at the end of the anim

strange crystal
#

Yeah so strange. Trying to place it right on there.

#

The AI sees my char just fine

#

Is it stuck bc I have a keyframe in there (the location one)

#

I technically dont need the location/transform after it stops jogging. Wonder if I could disable that channel or something maybe its locking it into the location I set it to run to

dense owl
strange crystal
#

Yeah its stuck in the air

#

snapped to that location keyframe

#

Need to release it somehow. The AI wants to work it locks in on me but the keyframe has it locked to that vector value

dense owl
#

But the animation is ended?

#

Or is it still going

strange crystal
#

the normal running animation is going now, like its supposed to cuz it sees me

#

gonna verify quick tho

dense owl
#

I mean you could increase the project to mesh distance but prly best to just force it down to the ground

strange crystal
#

ah u know what

#

its still playing the animation i set

dim lynx
#

hi, "on smart link reached" doesn't work, it only works when the AI ​​first hears something

#

someone can help me?

#

in behavior tree i use this to chase player:

dense owl
dim lynx
#

@dense owl

#

@dense owl it is all

#

I thought maybe it's because Simle Links has an index in PointLinks, but after deletion it doesn't go to the SmartLink point at all

open swift
#

Is there some way to prevent aborting a specific task in a lower priority subtree? For instance I want a sequence of moving to a position -> using an ability. Higher prio branches can abort while I’m moving but once the ability has started I want to prevent aborting until the ability completes

dense owl
dim lynx
dense owl
#

Where is this bind

dim lynx
#

Begin Play

dense owl
#

Then why is there a cast to nav link proxy before it

#

How are you getting that ref for it, is that cast failing ?

dim lynx
#

this is component

dense owl
#

That’s not what I asked

dim lynx
#

Bind works

#

but i don't why AI can't reach it

#

if i use Report Noise

#

then works

#

but i don't know why :/

dense owl
dense owl
dim lynx
#

ok

dim lynx
#

and doesn't work

#

in VisualLogger I don't see nav link

dim lynx
# dim lynx

someone can help? why my AI don't go to Smart link? only when the AI ​​hears something then I receive a signal from On Smart Link Reached

ivory rune
#

I've a simple question that EQS in 5.3 is still experimental, is it mostly okay to use it in the production? I know it has been experimental for ages. Still wonder why not make it official or at least beta...

dense owl
#

They forgot 🙂

ivory rune
#

In other words, it is safe to use?

#

I've used it for several projects already shipped. Just very interested in why it is still...experimental

harsh storm
#

Yes, safe to use

ivory rune
#

They even changed pretty much after 5

#

Make it much easier to use than 4

glacial harbor
#

Anyone here familiar with HTNs? I've been reading about it and to my understanding (in simple terms) it's basically a hybrid of BTs and GOAP, right? Where it has a world state, goals and, actions like GOAP but the actions (or methods in HTN's case) can only be done in a set number of ways (aka subtasks like in BT).

Is this a correct simplification? The reason I ask is because I think I accidentally made an HTN system instead of GOAP. It works, but now that I look at it there's only a set number of ways for the AI to accomplish certain goals and it makes a plan in a recursive way

celest python
#

GOAP is quite outdated

#

and when HTN exists no need to use it anymore

#

so its good you made HTN instead by accident

glacial harbor
tepid cloud
#

How do you make the agent stick to the ground using floating pawn movement?

tepid cloud
#

im trying to implement AI system of my own

#

thinking between GOAP and HTN

unborn jungle
#

Functions perfectly

harsh storm
misty wharf
#

That looks very comprehensive

harsh storm
#

It very much is.

#

It's one of the most comprehensive plugins I've seen on the marketplace

wind summit
#

Hello! Behavior tree question

#

so this is how I've got an AI's combat phase organized - brain decides which behavior to do, and it passes over to do it, then back to the brain. I've structured this for modularity's sake. The question is I have the attacking handled on a parent service, and that resets every time a subnode is called; is there a way to have this work without re-triggering the service? Or do I need to just consolidate everything and just run all of this on one task with the service node on it?

harsh storm
#

This looks like you tried to apply state machine concepts to the BT honestly. BT's are better used as priority selectors more or less. So set the highest priority behavior to the far left. Next highest priority after that one, so on and so forth. Then you'd gate those behaviors with conditions.

#

What does your revolver service do?

wind summit
#

I came from doing FSM AI for 2D to this, yeah

#

and yeah it's organized like that in general, everything moves left to right

#

the sub tasks handle movement, the service itself handles attacking, because as a generic mob AI I wanted those to operate independently

#

When I organized this I was under the impression the service would keep running without resetting

harsh storm
#

It will every time you reenter the node

wind summit
#

and it's going to reenter the node every time an existing task is finished?

#

Regardless of whether or not the next node it finds is below the service?

harsh storm
#

When an existing task finishes in that branch, it goes back to the root and re-evaluates the tree.

wind summit
#

Yep, that was the part I missed. Thank you

stray bobcat
#

Has anyone moved their AI into C++? If so, what parts did you move to C++ and which parts to leave in BP?

  1. Tasks
  2. Behavior Tree
  3. Blackboard
  4. AI Controller

I'm assuming move everything but the Behavior Tree as that by default is very visual, but interested in what others have done and ultimately the most optimal way for performance.

misty wharf
#

I've mostly moved AI controller stuff into C++, and if there's any BT task or such that runs a lot

#

AIC primarily because it just feels more robust to have that type of "core" logic in C++ for me

#

With regards to perf, you should probably use Unreal Insights to find out if there's something. Otherwise it's kinda hard to say if you'd benefit from moving it to C++ or not

harsh storm
#

Tasks are probably one of the bigger wins to move to C++, so you can avoid the instancing of BP tasks

#

Which can cause perf issues

misty wharf
#

That's what I always figured as well but it actually didn't seem to take that much overall frametime for me when I was testing it in my project

harsh storm
#

Luthage has seen it cause issues in her AAA game/s.

misty wharf
#

Yeah it probably depends on how many run and how often, but seems best to profile even that to find out

stray bobcat
#

Super helpful, thanks guys. Yeah I was thinking tasks could be better in C++ if they're heavy or run often. AIC makes sense, at minimum to have a c++ base AIC. If the BTs are in C++, would I need to put my blackboard in C++ so they can reference it?

misty wharf
#

I don't think you can really build the tree itself in C++ at least it definitely isn't designed for that

#

The BB is just an asset anyway that's configured from the editor, so it wouldn't make any difference I think

wise sluice
#

Hello ! Anyone know if that's possible to paint landscape to specify a specific navmesh area?

stray bobcat
lament hemlock
#

Hello. I have 4 NPC characters that follow my main character in a third person style game.
Using a controller, if I walk into the NPCs they do not move and act like I’m walking into a brick wall.
To try and help with this,when the player collides with them, I make them move out the way a little. This works ok, but it causes pathfinding issues if the NPC gets close to the player while trying to path around him and collides. In case it's important, I have the AI controller set to Detour Crowd.
Is there a way to make the player push the NPCs out of the way so I don’t need to move them on collision?

shadow dawn
#

I'm trying to run an EQS query outside of a behaviour tree but it is returning an empty array

misty wharf
#

Besides you access the BB's via names anyway so it doesn't really make any distinction

lyric flint
uneven cloud
uneven cloud
unborn jungle
#

BTs are essentially just a visual tool to manage behavior at the end of the day but isn't required to make AI at all so if you prefer coding the logic in C++ and managing state yourself, you absolutely can. I like to do it for FPS bots similar to how they do it in Unreal Tournament

uneven cloud
#

Scripted AI, which is anything not using an AI architecture such as FSMs or BTs, are incredibly difficult to debug, have terrible performance, and doesn't scale well with number of agents/complexity of the world state/agent variants.

unborn jungle
#

I'd be interested to measure my FPS bot logic with an idential BT setup just out of curiosity! There's very little actual logic to be run and I can run it quite infrequently in most cases

#

Main thing that I prefer about it is not having my logic fragmented across code and various BPs that each run a line or two of code essentially

uneven cloud
#

You call it fragmented, I call it organized.

unborn jungle
#

If I need to boot up the editor to see a line of code then go back to the code to continue along the flow it feels more fragemented than helpful but that's why everyone can work the way they want 🙂

#

It's like making a separate class for each of your functions instead of... having functions in your class. But that's just my preference

uneven cloud
#

Why would you boot up the editor to see a line of code?

unborn jungle
#

Well you could make a C++ task etc. but then you are ballooning your codebase with lots of single function classes

uneven cloud
#

All of our BT nodes are C++ and I certainly wouldn't say that the codebase has "ballooned" with a lot of single function classes. And it's a AAA game.

unborn jungle
#

And it's a AAA game. which is exactly why it depends 😄

#

AAA is great to have stuff fragmented so the designers can tweak things

#

But for smaller games where less people or just one person is doing the AI logic, it can be nice to manage it in C++ directly. All preference / situational at the end of the day

#

Lyra is basically the epitome of AAA dev with logic for almost everything split up into dozens of sub BPs

uneven cloud
#

I've also worked on games that it was just me doing the AI. If you write your BT nodes well, you really don't need a lot of them.

Lyra is certainly not the epitome of AAA dev.

unborn jungle
#

Alls I'm saying is you can absolutely do everything with BTs and have a great time and also do everything in C++ and it's not necessarily going to be "terrible performance" etc. I've seen it and done it both ways and they are both valid but it does depend on the style of game and type of AI

Have you worked on any FPS style bots that have to do a lot of things constantly to mimick human players? Definitely possible in both BT and C++ but from experience, managing the logic visually in BT was much more cumbersome than just having it in code due to all the chunks of logic being separated out

#

I'm not talking fortnite style bots where you can almost see the clear cut tasks play out 😄

#

But even simple ones that just have to move to a location while attacking player and doing some secondary movement things at the same time are quite fun to set up with just code

tepid cloud
harsh storm
harsh storm
#

(Only commenting on the "very expensive" part!)

tepid cloud
#

Also how do you make navmesh agent out of FloatingPawnMovement? Like it properly sticking it to ground

tepid cloud
unborn jungle
tepid cloud
#

we are just duo in our case. Anyway what would I do if I have to do it from scratch?

harsh storm
#

Well, learn how what an HTN even is for starters

tepid cloud
harsh storm
#

GameAI Pro is a series of books written by industry vets

uneven cloud
unborn jungle
#

Attack is just a single func which could be a single node or a func called in C++, the BT interface doesn't really matter if you have the logic cleanly running in code

#

Point being BT is just a nice visual way to manage AI logic but if you prefer to do it in code you absolutely can if it feels clearer to you that way

harsh storm
#

Give it gravity

tepid cloud
#

I need Unity-like NavmeshAgent

uneven cloud
unborn jungle
#

I'd argue that writing AI logic in C++ results in "terrible performance" is wildly false also 😄

#

Depends entirely on what you are doing

#

I've also had gripes with BT logic when you are dealing with parallel logic

uneven cloud
unborn jungle
#

which is much easier to deal with in code: a movement layer, a combat layer, a "secondary" layer for things like slides, strafes or other small actions as well as any other layers you might need instead of the often very static stateful setup that BTs encourage "I'm doing this".. now I'm doing this!

unborn jungle
#

AI logic is extremely cheap most of the time, infrequent traces to populate data, infrequent queries to decide where to move to next or who to attack next etc. Not sure where the terrible performance is coming from really

#

Moving to code will likely improve on BT performance on similar logic especially if staggering it over multiple frames for different units

#

Since BT is still essentially running the same gameplay code at specific times anyway

tepid cloud
# harsh storm Give it gravity

i am using FLECS(ECS Solution alternative to Mass). So I need to use 2000+ characters. Not sure how Raycast-Gravity gonna help me

#

unless specific solution out there

uneven cloud
unborn jungle
#

Sure! and very valid + encouraged to use BT!

#

Not saying it's not at all

#

Just saying you can manage state + call the funcs yourself in code if you feel like it and you aren't going to magically have bad performance, BT is just calling stuff like MoveTo(MoveReq, &PathInfo); behind the scenes anyway

#

Plus (in my case) making less stateful "I'm moving now, I'm angry now" etc. AI, I found it easier to have multiple layers of logic running in code than with BT which is why I switched over in the first place

uneven cloud
#

The BT is heavily optimized. It being stateful and event driven is also a way to keep the performance very light. "Just calling stuff like move to" is a very naive way of looking at it.

unborn jungle
#

Right well it's not like you can't be stateful in code too! I only query where to move next if my move to completes or fails for example

#

Not like I'm running it on tick

#

I just have either event driven logic or when required, very infrequent timers for secondary logic (similar to a service in BT)

#

Nothing on tick or similar frequency

#

Again nothing that would suddenly cause terrible performance

harsh storm
#

If you want them walking on the ground, they need gravity.

#

Otherwise - navmesh stuff is just XY stuff really

lament atlas
#

Hey ! I'm trying to create an eqs that search a position on the navmesh but where there is not a specific type of actor around. Anyone can help me ?

wind summit
#

If I wanted to have shooting and attacking separated from movement, how would I do that in behavior trees? Like, how would I structure it?

#

is this the best use, where I have all movement in a task and the shooting logic in the service?

#

as discussed earlier, dividing it between multiple tasks resets the service every time a new task is chosen

unborn jungle
#

Stuff like the above is why I moved to code for shooting style bot logic, it quickly becomes more cumbersome than it needs to be. In your case though you can probably look for the parallel node if you just need simple movement and shooting happening at the same time

wind summit
#

yeeeah, was afraid of that lol

unborn jungle
#

Add in submovements on top of all this like strafing, jumping, dashing, sliding, blocking, aim variation etc. and BTs quickly become annoying to work with imo

remote magnet
#

With state trees being more general purpose now, is there a good way to integrate state trees with animation blueprints?

unborn jungle
#

What state tree info would you want in your anim bps?

remote magnet
#

Basically just knowing what state a character is in.

unborn jungle
#

Well since anim bp is driven by char and char is owned by AI controller which houses the BT you can likely query it from the char if needed with getters

wind summit
#

yeah, for animation blueprints I just pull states/booleans/etc from the pawn, and set it on the pawn from tasks/whatever

remote magnet
#

Alright, I'll probably do something like that then.

remote magnet
#

Come to think of it, my state tree tasks are built to apply a set of movement values and also a GameplayEffect. Would it be wise for me to just read from the GamepalyEffect to determine what state the character is in?

tepid cloud
harsh storm
#

As in what?

#

I don't understand your question

tepid cloud
#

like how exactly can I place my agent/actor exactly on top of navmesh?

#

like unity

#

but seems like they dont as much as they should

harsh storm
#

I haven't used Unity in years, so I don't know the reference

tepid cloud
#

like often tends to go out of Navmesh if you use floating pawn movement. CMC cant be used for obvious reasons

harsh storm
#

But all you do is bring out your agent and make sure it has gravity. Which FloatingPawnMovement doesn't by default

tepid cloud
#

not sure if you can do multithreaded raycast

tepid cloud
harsh storm
#

Moves out how though?

#

Like - outside of the bounds via the XY plane?

#

Or the Z?

#

Or what?

tepid cloud
#

how do I put this. Let's say you make plane. Put volume on it. Order your NPC to follow specific character/Actor. Then go out of the plane. It seems it goes all the way out of plane and just floats on air

#

cant go back to the plane or pathing

dense owl
#

So on the Z

#

You can increase the projection distance to the navmesh

sly saddle
#

Is there an idiomatic way to reserve/use a SmartObjectComponent directly if I already have the actor it is attached to, rather than by running another query?

obtuse dome
#

Do NavLinkProxy objects created via child actor component not work? My manually created one (right) works fine and has the black arrow drawn between the two points, but my link proxy created via child actor component (left) does not have the black arrow / is invisible to pathfinding even though I can see the markers

#

Nevermind, I think it has something to do with generated dynamic mesh hackery. If I make a normal blueprint and create the nav link in there, it works, but only in the generated dynamic mesh bp does it fail to work

hot shore
#

What's the best way to go about the Ai getting stuck besides adjusting the navmesh?

#

I've been playing around with a lot of different methods like having it transport if its velocity reaches 0 or change route to another location

#

But curious if there's a better way to like have it reverse and go around the object it's stuck on

#

For reference, I did increase the capsule component size because it's a bigger Ai

#

I'm working on a level with a lot of trees and even with the nav agent radius increase, it still gets stuck every now and then

unborn jungle
#

Usually does the trick if they get caught in walls or off the navmesh

hot shore
unborn jungle
#

So launching upwards and outwards in the direction of the nearest navmesh will often fix stuck characters

#

There are likely more graceful solutions like allowing the game to teleport the AI back to the nearest navmesh point or to a safe navmesh area

#

If that doesn't disrupt gameplay

hot shore
#

Is there a node to locate the nearest nav mesh?

unborn jungle
#

There is a func that gets closest point on navmesh which you can then use to determine launch dir

nimble smelt
#

Is there a way to make FloatingPawnMovement behave like a missile, such that it can only move in the direction it's facing and needs to turn to change direction?

#

Right now it's more like a quadcopter, it can change direction without changing facing at all, and in fact seems to prefer to

harsh storm
#

Why not use projectile comp?

#

Can also subclass it and make sure it only moves it actor forward

nimble smelt
harsh storm
#

Pretty sure projectile comp has the INavAgent interface. I think all movement components that you can use out of the box do. Though I have never confirmed.

But you could just do the same thing I said but with FPMC. Subclass and only move in actor forward.

nimble smelt
harsh storm
#

Idk if it is to be honest.

nimble smelt
#

It's also not suuuuper hard to fake it, I can just get the movement vector and rotate it that direction lol

#

Is there a graceful way to shut a behavior tree off, like an inverse of Run Behavior Tree?

storm sail
#

"stop logic" node

#

inside of the brain component inside of the AIController

#

brain component only exists when you have an active behavior tree I think. I'm not 100% sure though because I despise Behavior Tree's

misty wharf
#

^this or state tree comp

#

BT comp and ST comp extend BrainComponent

tepid cloud
#

where should I do changes to ensure it sticks to navmesh?

uneven cloud
# tepid cloud This is my problem

I see that you aren't using the character movement component. If you want to keep it stuck on the ground, you have to actually add in that functionality. How the character movement component works is to first find the floor and then adjust the movement the capsule does to stick to the floor.

gusty trellis
#

hey guys i have a door with a physic costraint that is simulated and move when u go throught work with the player but the Ai dont consider it cause the nave mesh stop at the collision box used with the physic, any sugestion on how to make the ai go throught ?

tepid cloud
uneven cloud
gusty trellis
proud flume
#

So for a hearing report it seems like MaxRange is the value you want to mess with, and Loudness is just a multiplier on it? Hmmge

#

I'm not sure I understand the point of loudness 🤔

#

If it's just a multiplier why wouldn't I just multiply MaxRange myself

#

hmm but then, the AI perception component also has a specification for hearing range

#

I would expect the AI to specify only that it can hear, and maybe a multiplier.

#

And sounds to just specify range

#

hmm I guess you could also simulate volume loss over distance, but the AI multi would cover that

#

Max range at which the sound can be heard. Multiplied by Loudness. A value of 0 indicates that there is no range limit, though listeners are still limited by their own hearing range.

#

🤔

#

This is oddly unintuitive heh

#

I'm guessing it's for technical optimization reasons hmm the hearing range must cut down on checks

jade ledge
#

So I'm playing around with the StateTree plugin, currently I'm using a behavior tree. Here in my NPC controller, I have these blackboard assignments on BeginPlay. What are the nodes to do this for a StateTree instead?

harsh storm
#

You'd just bind to the variables directly in the ST

jade ledge
harsh storm
#

I don't know all that you've done or haven't done.

#

But these docs should be decent enough to get started

simple stump
#

Whats my best option for managing a horde of between 100-200 if I want easy access to all of them for flocking but still want them all to be actors?

misty wharf
#

Make them actors?

#

I'm not sure what the question really is. 100-200 is entirely doable with actors, that's nothing

#

Character Movement Component may give you some performance grief but it's still doable

simple stump
#

I'm sure it is doable, but I need the CPU headroom elsewhere

#

Is there any consensus as the value of having a singleton manager for doing things like the mass pathing and flocking?

#

and just do it RTS style where they are all dummies to the AI manager, or will the performance gain be negligable to an object oriented approach and trusting the engine to multithread them individually with a traditional behavior distance heirarchy? (Still learning Unreal)

misty wharf
#

The engine won't multithread things for you, actor updates generally need to be performed on the gamethread, but you can certainly perform calculations on another thread but need to sync it to GT

#

The value of managers and such largely depends on the circumstances and how it's implemented. I would do some tests to find out, you can probably throw together some quick prototypes for pathing pretty quickly to find out what the performance for it is like in the kinds of scenarios you envision

hybrid crypt
#

I'm trying to make a character go from the left platform to the right platform using a jump pad. I use AI MoveTo towards the sphere on the right, I was hoping the nav link would make the character go towards the jump pad, which launches the character in the right direction. However the characters gets stuck on the left platform, and stops (On Success is executed)

#

Increasing tile size to the max value (19467 UU) solves it, is there a workaround for distances that require even higher TileSize than allowed? (except using these PRs)

#

Maybe connecting small links in the void will work too

nimble smelt
#

How can this even happen in an AI Controller? This object only exists BECAUSE a pawn is spawned that needs to be possessed.

harsh storm
nimble smelt
#

Weird! Well, weird that I haven't run into this before, I've been doing it this way a LONG time

#

That makes perfect sense though

kind jacinth
#

how AI would handle quadtree LOD terrain that update often ?
do AI paths need to be recalculated every time terrain updates ?

nimble smelt
#

I've got an AI pawn that's supposed to be moving just with FloatingPawnMovement and MoveDirectlyTowards. Except despite the movement goal being set to something valid, it literally doesn't move at all it just sits there.

#

Hm. This USED to work and I've since updated the pawn to have a new parent which may have replaced the based component. The new root component IS set to movable, but is there anything else that needs to happen?

nimble smelt
#

Weird it's working now, I just had to delete some random other collider

mighty imp
#

Is there a way to set a blackboard key as an array? I've been learning with ChatGPT and it's telling me to do that but I cannot find a way

misty wharf
#

Depending on what you're doing, you could also just read the data directly from its source, eg. if it's something on your pawn or somewhere else you can conveniently access

mighty imp
#

ok tyvm

nimble smelt
#

Is there a way to check whether a pawn has AI running currently? I guess I could call GetBlackboard and juse see if it's valid, but that seems a little gross

uneven cloud
uneven cloud
jade ledge
#

What do I need to do to fix this error?

hybrid crypt
#

I have a selector node which a bunch of child nodes, and sometimes all the child nodes fail, but I still want the selector node itself to succeed so that the parent sequence can continue. I can add an empty sequence node as a child to the selector node, but is there a cleaner way?

oblique basin
hybrid crypt
#

oh it's a decorator, thanks!

hybrid crypt
#

when an AI character is mid air, how can I make it stop (like stop movement immediately but smoother)? I've tried adding movement input in the direction opposite to current speed but that doesn't seem to work

misty wharf
#

Isn't there an air braking/friction value on the CMC?

#

Increasing that seems like it would do the trick as long as you're not adding any inputs

misty lion
#

Hey devs! anyone here who could help with EQS?

misty wharf
#

It's best to just ask your question instead of asking to ask :)

misty lion
#

So the thing is in the Behaviour tree the eqs doesn't run!

#

Ill share the screenshot wait

haughty iris
#

Hey Guys, I have an issue using the Gameplay Tag Decorator in the Behavior Tree.
I am working with the Gameplay Ability System (GAS).
At the beginning of my Game I am assigning a Gameplay Tag via an infinite Gameplay Effect to my AI Actor. But If I check for it in the Behavior Tree it is always returning false. So its telling me that he is cannot find the gameplay tag on the Actor.

I checked if the gameplay effect is working and it is. So the Tag should be assigned.

Is there a way to debug and see what gameplay tags an actor has? Or do you have an idea why the decorator is not recognizing it?

haughty iris
#

I checked and printed out all tags that are assigned during the game. The tag I need is actually assigned. So somehow my behavior tree is not recognizing it. Im am using a ability system component which has access to all my tag of the actor. Could it be that the bahavior tree decorator is just searching for the tag at the actual actor and not the ability system component?

hybrid crypt
nova quest
#

Hello, how would i go about making my AI be able to hear player microphone?

misty wharf
nova quest
misty wharf
# misty lion

It's a bit hard to tell but it looks like either the run eqs node or the move to node after it is failing, which is causing the sequence to fail, which is then triggering the next node from the selector

#

You can use the Visual Logger to get more information on whether the nodes are failing and if so why

misty lion
#

Its showing that the points of interest variable is invalid when using visual debugger

#

And even when seen in the Behaviour tree

misty wharf
#

Try to find the execution of the eqs node in the visual logger

#

it's possible that it's actually returning zero results

misty lion
#

Yes that may be possible! but anything that I can try to resolve this issue?

misty wharf
misty wharf
haughty iris
misty wharf
#

If you're using C++ you can implement the interface and have it return the tags from the GAS component

#

But if BP's only, then you can't and adding a new decorator would be the way to go yeah

pine steeple
nimble smelt
#

So I have "Allow Strafe" set to false on this move node, but the pawn does nothing BUT strafe, doesn't even turn at all regardless of what direction it's going. How do I make this work?

#

These are the settings in the controller

#

Interesting, I added an arrow to the pawn and set its rotation to the control rotation every tick, and unlike the pawn the arrow DOES face toward movement, though it's very jumpy

#

Flicking around instead of turning smoothly

uneven cloud
nimble smelt
lyric flint
#

Hey guys, is there a way to retrieve nearest player location to use destination? I added service like pics

uneven cloud
vivid drift
#

What's the most sensible way to interrupt and then restart a BT in response to things like stun effects

dense owl
reef wharf
#

Think I'm experiencing some kind of bug. When I place my AI in front of a trigger, it will not be able to see anything past it. I am using AI sight perception. Is there a way I can filter collisions on the AI perception component?

#

I've made the trigger to overlap all collisions but still nothing

reef wharf
#

Solution: bring the trigger boxes to the ground

#

I guess it will have to do

uneven cloud
reef wharf
#

it is already set to that:

vivid drift
#

@dense owl

 
void UBrainComponent::StopLogic(const FString& Reason)
{

}```
#

am I dumb?

harsh storm
#

BehaviorTreeComponent is a child of BrainComponent

vivid drift
#

got it

dense owl
#

So it’s not GAS related or did you have to change what the acronym stands for because of trademarks? 😀

placid halo
harsh storm
#

(Ignore that it wasn't under the same conditions!)

placid halo
#

But still, I tried both StopLogic and RestartLogic before running the same BT (I kind of want to just "restart it") but it stays stuck at the last branch

#

the first node is a sequence node, I just want to run the branches under that sequence node

#

but I guess that might be precisely my problem? (using a sequence node as root?)

crude harness
#

Hello everyone!
I'm seeking advice on managing multiple AI characters, all using the same Pawn and AI Controller but with different Sight Sense configurations. Is there a more efficient solution than modifying the AI Controller within the BeginPlay function of the Character class?

#

Same question for customizing per-pawn some Blackboard values

misty wharf
#

Modifying it is probably the way to go unless you want to use inheritance to apply the changes

#

Depending on what and how many you're changing, you could potentially use a data asset as the configuration to make it easy to share and/or create new ones

dense owl
nimble smelt
#

So this CanAttackTarget decorator is throwing errors occasionally because TargetActor is none. I could add a check there and I think I will, but what i don't understand is how it can possibly get into that case in the first place, considering that I'm checking in the parent node whether TargetActor is set and it should abort when that's not true

vivid drift
vivid drift
dense owl
vivid drift
#

does abort self abort children?

#

oh hm

#

so it does

nimble smelt
nimble smelt
#

So that's what's doing it.

dense owl
#

In BTs you can even go backwards

nimble smelt
#

Yeah though that's tough because i also have to be the player and escape this thing lol

#

which is not easy because it's VERY fast and real mean. All my AIs are mean

vivid drift
#

make them not fast until they work

dense owl
vivid drift
#

Are they any obvious gotchas regarding nav link proxies? I have a door class that works in one map but not another? Not work meaning the ai doesn't think to use them.

dense owl
vivid drift
#

I'm rendering my units paths, and it seems to route through the nav link even though the navmesh is separated. So I think it's working from the routing perspective. but the pawns aren't interacting with it.

vivid drift
#

@dense owl not really sure how to use this thing. what catgory would it be under? AI NAV? Nav?

dense owl
vivid drift
#

ehhhh I got it to work by just nudging things around but thats super unsatisfying. I could not discern anything meaningfully different about the not working positioning vs the working positioning

uneven cloud
vivid drift
#

@uneven cloud I mean my ground is mostly flat but is there anyway to at a glance confirm that the links have successfully projected? I assumed it would be ok if the capsule was touching the ground. What is it actually projecting to? Because it doesn't seem to be either the ground or the default green colored rendering of the navmesh

uneven cloud
vivid drift
#

the green arrow?

#

that appears to be there regardless for me

#

ohhh shit, no you're right, there's a second black arrow

uneven cloud
#

Yeah it's a second arrow, the default is a really dark green

silent hamlet
#

Hello! I am building the behavior (tree) for a melee fight and I want my agent to determine its next attack based on some conditions (distance from target, other stuff possibly). The only way I can come up with for this is to have one task evaluate the required conditions and commit this decision to the BB and then have another subsequent task execute such decision.
The problem I have with this approach is that the BT is in charge of managing its state (setting and clearing the BB key for the attack decision).
Is there any better way to go about it?

misty wharf
#

You could have the rules defined using decorators instead in order to choose the appropriate attack branch which contains the nodes for a specific kind of attack

#

I have noticed that in some cases it may be simpler to just have the logic for selection + attacking outside of the BT, and you simply have a node that says "attack". I don't know if this is the case for you necessarily, but just putting it out there so you know that's also an entirely fine way to do it :)

silent hamlet
#

hm yes in this case i could have decorators to check "am i far away", "am i mid-range", "am i close".. i like this more indeed but it's a bit less flexible because if i want to decide behavior based on more factors i need to start compositing decorators and have one for each type of behavior

#

but maybe i don't need that much comlexity in my fight

misty wharf
#

Yeah it kinda depends. You can certainly stack several decorators for the choice

silent hamlet
#

ill try this, see how it works out for my case

#

thanks!

dusk kelp
#

Hi guys
Could you please tell me how can I check what NavArea is under the actor?
I want to trace it sometimes to change actor's speed

vivid drift
#

I have some objects that my units can utilize as cover. If they enter the box area, they crouch and gain a benefit.

#

I'm trying to make it so that they prefer to walk near short cover by using a nav area class with a lower cost

#

But it seems like the modification is going much wider than the collision area of the cover objects

#

which causes the units to use it, but prefer walking on the outskirts and not actually benefitting from the cover. Anything I can do here besides just adding another collision boundary for the navmesh?

vivid drift
#

And if I do go that route, how can I stop it from dynamically recreating the navmesh all the time...

#

because these objects should be static and I would think that shouldn't affect anything. I think it's because I'm checking off "dynmaic object" on the collider. But I want to it to be a static nav area thing.

dense owl
vivid drift
dense owl
vivid drift
#

ok yeah. I'm not too bothered by that. It doesn't seem to have gameplay impacts. I'm trying to get the nav area to fall neatly within the collision boxes.

#

I'm thinking maybe the navmesh is built using tiles that are too big to do this cleanly? This is an attempt with smaller colliders to genrate just the nav mesh

#

it's decent but inconsistent

uneven cloud
uneven cloud
harsh storm
#

@uneven cloud Can I get some feedback on this setup, if you don't mind.

Idea is to only request a token if we have a valid target. Then go into the attack branch if it was successful, otherwise do some other thing and after that completes, it should reevaluate the tree, ending up in the position of trying to request the token again. The service is there to release a token only if they have one. It's not actually ticking.

#

Just a prototype setup.

dusk kelp
# uneven cloud BP or C++?

C++, I need it to be fast. But BP will be good too
Ive checked source code and found a way to find a closest polygon, but I havent finished the solution yet cause nav code is pretty hard to understand right away xd

uneven cloud
dusk kelp
uneven cloud
harsh storm
#

Yeah - I just threw that in there just to have something. It won't actually be to wander

#

Thank you!

uneven cloud
uneven cloud
vivid drift
remote magnet
#

I've been told this is a good place to ask about general state trees, seeing as they're derived from behaviour trees.

I've got a state tree that seemingly won't stay compiled. I have to compile it each time I open the editor, or it won't function. Anyone know what might cause this?

uneven cloud
#

Isn't a state tree a data asset like the behavior tree is?

remote magnet
#

Ah, I believe you're right.

silent hamlet
stiff stone
#

Yo folks! I'm working on a queuing system for customers in a bar using smart objects, and unfortunately after packing the project it doesn't detect the target points, in the editor the whole tree goes through without a problem and they queue normally, do you have any idea why this is happening, or maybe what is better to use for such a system instead of smart objets (working on 5.3)

uneven cloud
open swift
# uneven cloud It's very common to set a BB within a BT. Using a service or task. That's a bi...

I agree with all of this but I'm having trouble figuring out how to structure a reusable behavior tree that multiple different enemies can use, when enemies can have any number of abilities that want to be used at different ranges, have different targeting considerations, may or may not prevent moving while they're being used, etc. do you have any examples of projects that you or anyone else have publicly available that you think have a good example of a behavior tree that handles multiple enemies with different abilities and range considerations?

uneven cloud
harsh storm
#

Look up, from Luthage, about determining to use an ability based on EQS stuff

uneven cloud
#

What I didn't explain, is that any ability that does movement is in the ability itself and not in the BT.

open swift
#

does that include movement to make the ability usable in the first place? Like if I don't want my enemy to use an ability unless its within range of a target, I would need to eventually make the enemy move into range to use that ability even if there are other abilities that they could use at their current location instead? would you encapsulate moving into range as its own action in your priority list somehow?

uneven cloud
haughty tide
#

How can I make my service instanced ? Right now I have a service that should update a blackboard key per NPC but it seems to update the blackboard key on all NPCs.

uneven cloud
harsh storm
#

And is the key shared in the BB?

haughty tide
#

from the blackboard component. NPCs have all the same blackboard asset but I assume that its variable will be separatly updates per NPC

open swift
uneven cloud
#

A service doesn't need to be instanced to only set a BB key

uneven cloud
haughty tide
#

yes I am using the selector.

uneven cloud
#

Is the key set to be shared?

haughty tide
#

is this the instance synced ?

harsh storm
#

Yes

haughty tide
#

in the BBKey ?

#

its set to false

harsh storm
#

How are you confirming it's updating it in all of the NPCs?

uneven cloud
#

Have you verified with the visual logger that it's setting the BB for NPCs that are not running the service?

haughty tide
#

not exactly. That might be a good starting point

uneven cloud
uneven cloud
haughty tide
#

but in order to go a bit more high level. When its NPC creates the brain component and loads the BB Asset, a change in the blackboard Key does not get synced to other NPCs using the same blackboard right ? In other words the value of each key belongs to each controller and is not shared right (unless specified) ?

uneven cloud
#

The only thing that instancing a service does is allow that service to save variables within it's own class.

#

The runtime blackboard is an array on the blackboard component, which each AI controller has their own version of.

haughty tide
#

I see. So changing a boolean BBKey on one NPC does not mean it will change on another one.

uneven cloud
#

Unless it's set to be synced.

open swift
#

can you pass EQS contexts into a query dynamically?

uneven cloud
#

No. You can pass in query params with blackboard keys

harsh storm
stray bobcat
#

Hi All - If I just want a branch of my BT to be idle and still (character doesn't move or do anything) is it ok that I just have a branch that when idle it just instantly finish executes with success? The BT is then constantly firing but I'm unsure if that's the intended result or I should have some kind of wait?

worldly remnant
#

I need a little help trying to figure out how to get something to work. I'm working on a small demo for my capstone project. It features two playable characters. Only one character can be possessed at a time. What I'm trying to do is get the unpossessed character to follow the possessed one. I've done that. The problem is that when they follow, they are not facing the direction they are traveling. I also posted this question in my WIP post where I have examples of what I'm doing.

I have tried looking up solutions and tutorials on my own. Unfortunately, I haven't been able to google fu my way out of this.

Any help is much appreciated.
https://discord.com/channels/187217643009212416/1213910377562247179

stray bobcat
worldly remnant
#

I'm working with 2d sprites. They can only face one of 4 directions at any given time.

dense owl
#

oof, 2d in a 3d engine is rough

#

can you get forward vector properly?

dense owl
worldly remnant
#

Here's the current blueprint. It's on the parent class to the two character child classes. I'm aware that I'm probably biting off more than I can chew. However, I'm half way through the class, so it's all in or bust at this point. Thankfully, I'm not making a whole game. Just an alpha demo level.

#

The two bottom functions are what dictate the behavior of the unpossessed character. I found this based on a tutorial.

#

Nearest I can figure is I need something to plug into the direction x and direction y instructions on the AI Move To node.

dense owl
#

I mean, that's a lot of calls to Follow but I won't say you should use BTs, cause I'll prly have the book thrown at me with velocity 5000 shortly after 😀

dense owl
#

that should give you a rotation you can rotate it towards

worldly remnant
#

I'll give that a shot. Thank you!

worldly remnant
#

I've tried a this a few different ways. The closest I got was the unpossessed character spinning while the player character walked circles around it.

#

I still think it's promising, so I'll keep working on it. Thank you again!

stray bobcat
#

My behavior tree doesn't seem to run properly unless I add a small delay before I call 'Run Behavior Tree' on Begin Play. I have an Enum called PassiveBehavior that has both Idle and Patrol. By default it's Idle. In my BT it works fine with a small delay on Begin Play before I run my BT, but if I don't add the delay it runs the Patrol branch even though it shows PassiveBehavior as Idle. Why is this?

harsh storm
#

Use OnPossess

stray bobcat
harsh storm
#

Yes. Controller should be the one doing that.

stray bobcat
#

Thanks. I think my issue is it's starting the behavior tree before my Movement Component has been intialized so it fails when I use AI Move To initially. Looks like I'll need to call my BT once my Movement Component has been initialized.

dense owl
misty gale
#

Should be just like a 3d actor but clamped in angles of 90 degrees

stiff stone
uneven cloud
stiff stone
#

I already fixed it, the problem was in the nav path, i just build path and this work

stiff stone
#

I have one more question, how to release the occupied slots after the action with the first customer, so that the queue will start

nimble perch
#

hey guys, how can I assign the same cost values as area modifiers do but to a proxy link?

#

changing the default enabled class on the proxy link to an area does nto seem to have an effect, AIs still try to use it, but they never fire the Reached event though..

#

it works okay on nav modifier areas btw

#

did this and on modifiers it works, on proxy it doesnt

#

well thats stupid, seems like its used the point link area class rather than the default one even though its a smart link

worldly remnant
#

I spent the morning working on the find look at rotation function. The issue I'm having is that the animation is not reflecting the direction the unpossessed character is traveling. Here's what it looks like in action. I'll paste the blueprint below.

crisp oar
#

I ran into an issue that's causing a headache and can't find any good solutions online. I have an enemy that chases the player using AIMoveTo but they keep getting stuck and confused at doorways (Note I don't have actual doors, just door openings) despite me having nav link proxies. It works just fine when they patrol normally so I'm pretty sure it has to do with the fact that they are constantly calling AIMoveTo while also trying to use the nav link proxy maybe? I tried this bit of code form the only real person I saw talking about this problem and tried folowing their fix which didn't work. I tried binding an event to the navlink proxies that would play whenever a nav link was reached that would use a boolean branch to disable the path that activates AIMoveTo for 1 second before setting the boolean back and resuming the AIMoveTo, but it's not really working. Any ideas on how to fix? I'm planning to move into learning better ways to make AI than just blueprints but this is for a class project I'm working on and I haven't had a chance to learn either Behavior Trees or State Trees.

deep bramble
#

My navmesh and AI are working fine in PIE but when I playtest using a testing packaged build it says the Nav Mesh Needs To Be Rebuilt and the AI wont even move. What am I doing wrong? and how can I fix it?

worldly remnant
#

What are you nav mesh dimensions?

deep bramble
#

Varies from level to level but max is probably like 100x100x100

worldly remnant
#

I found a tutorial that mentioned if a nav mesh is too small, it won't work. I'll find the tutorial and link it.

deep bramble
#
bDrawPolyEdges=False
bDistinctlyDrawTilesBeingBuilt=True
DrawOffset=10.000000
bFixedTilePoolSize=False
TilePoolSize=1024
TileSizeUU=2048.000000
CellSize=64.000000
CellHeight=10.000000
NavMeshResolutionParams[0]=(CellSize=128.000000,CellHeight=10.000000,AgentMaxStepHeight=45.000000)
NavMeshResolutionParams[1]=(CellSize=64.000000,CellHeight=10.000000,AgentMaxStepHeight=45.000000)
NavMeshResolutionParams[2]=(CellSize=20.078432,CellHeight=10.000000,AgentMaxStepHeight=45.000000)
AgentRadius=31.000000
AgentHeight=464.000000
AgentMaxSlope=44.000000
AgentMaxStepHeight=35.000000
MinRegionArea=0.000000
MergeRegionSize=400.000000
MaxSimplificationError=1.300000
MaxSimultaneousTileGenerationJobsCount=1024
TileNumberHardLimit=1048576
DefaultDrawDistance=5000.000000
DefaultMaxSearchNodes=2048.000000
DefaultMaxHierarchicalSearchNodes=2048.000000
RegionPartitioning=Watershed
LayerPartitioning=Watershed
RegionChunkSplits=2
LayerChunkSplits=2
bSortNavigationAreasByCost=True
bIsWorldPartitioned=False
bPerformVoxelFiltering=True
bMarkLowHeightAreas=False
bUseExtraTopCellWhenMarkingAreas=True
bFilterLowSpanSequences=False
bFilterLowSpanFromTileCache=False
bDoFullyAsyncNavDataGathering=False
bUseBetterOffsetsFromCorners=True
bStoreEmptyTileLayers=False
bUseVirtualFilters=True
bUseVirtualGeometryFilteringAndDirtying=False
bAllowNavLinkAsPathEnd=False
TimeSliceFilterLedgeSpansMaxYProcess=13
TimeSliceLongDurationDebug=0.002000
InvokerTilePriorityBumpDistanceThresholdInTileUnits=1
InvokerTilePriorityBumpIncrease=1
bUseVoxelCache=False
TileSetUpdateInterval=1.000000
HeuristicScale=0.999000
VerticalDeviationFromGroundCompensation=0.000000```
worldly remnant
uneven cloud
crisp oar
uneven cloud
#

Constantly calling it, means that it will constantly try to repath. Which is not just very expensive perf wise, but make nav links not work.

crisp oar
#

also the downside is it's a chase thing so if the player runs a different direction and it isn't updating it won't follow them

#

performance wise the game is running fine currently

harsh storm
uneven cloud
crisp oar
#

pawn sensing

#

I mean I'm learning, I'm new

harsh storm
#

May I ask where you found that?

crisp oar
#

sorry for not knowing immediately

harsh storm
#

Because it's long been deprecated, just not with the official deprecation tag

#

AIPerception supercedes it and should be used

crisp oar
#

tutorials online

#

kk

harsh storm
#

Which ones?

crisp oar
#

youtube, I'd have to pull them up

uneven cloud
harsh storm
#

Please do. I'm very interested in knowing. Because this is a recurring thing.

dense owl
crisp oar
#

this is one of them

harsh storm
#

Oh Matt...

dense owl
#

Just gotta bind a macro to auto reply “use AI perception, pawn sensing is deprecated”

uneven cloud
crisp oar
#

his explanations were pretty bad but the thing he showed worked so I figured that would be fine

dense owl
#

Technically get actors of class Actor on Tick also works 😀

harsh storm
dense owl
#

Pin #1: before you begin learning #gameplay-ai , unsubscribe from the following “content creators”

uneven cloud
crisp oar
#

is the perception thing able to be done through blueprints or is it behavior trees?

uneven cloud
#

The perception component is separate

crisp oar
#

ah

harsh storm
#

😈

harsh storm
#

Got it - so make AI video. Join the ranks 🫡

#

JK - I don't wanna be bad

uneven cloud
#

I saw someone post a course on Reddit that said it was a "Pro course". Not only was the teacher not actually a pro, but the AI section included using the pawn sensing.

harsh storm
#

Jeebus

crisp oar
#

I appreciate the heads up

harsh storm
#

Blind leading the blind

uneven cloud
#

It took seconds to find the "teacher" on LinkedIn to find out he'd never worked at a studio or shipped a game.

harsh storm
#

Those who can't do, teach.

#

😈

uneven cloud
#

Unfortunately, most people aren't going to look them up.

dense owl
#

Snake oil vendors 2.0

#

“This may or may not teach you UE”, pro course

harsh storm
#

Well, the algorithm doesn't favor proper learning to be honest. Because it wants short videos. So that's what people make. As well as people not wanting to watch a video for like 40 minutes to actually understand something.

uneven cloud
#

What's worse, is that our designers also use these shit tutorials and break things all the time.

#

Apparently they "fixed desyncs" by using a node that makes the server wait. Caused a bunch of problems.

harsh storm
#

Designers and networking. Scary combo.

#

Unless the designer was also a networking engineer, lol

#

So, Luthage, Decorators and Services both have OnBecomeRelevant and OnCeaseRelevant (or w/e it is called), why prefer using services over decorators for OnCeaseRelevant? And do decorators execute before services?

uneven cloud
#

I haven't needed to know which one would fire first, so I've never dug into it.

harsh storm
uneven cloud
#

We keep decorators as only conditions, so the tree is easy to understand for the entire team.

#

Where as services happen while the branch is executing.

harsh storm
#

Gotcha

harsh storm
#

So the data had to be valid pretty much (which is what the decorator was going to be checking) and the service was going to be doing things with the data.

worldly remnant
harsh storm
worldly remnant
#

I'm noticing that. I'm struggling hard with the thing I'm still trying to fix. Didn't help that part of my class wanted me to hook up to github. Doing that damn near broke things on its own. I managed to get back to where I'm stuck though.

#

I'm not hating the engine by any stretch. Granted, what I'm trying to do with it might be akin to shoving a square peg in a circle hole.

#

Doesn't help that what I'm trying to do is a 2d top down demo, but all of the tutorials are 2d platformer.

#

I just need it to hold together until this class is over. Then I can go back and take my time to do the things.

harsh storm
#

Why is your class doing 2D in unreal? 🤔

#

Is the topic about pain or something?

worldly remnant
#

XD

#

No, it's just me. The class is called Applied Software Practices. Unfortunately I didn't really have time to really research what I wanted to do, so I painted myself into a corner.

#

Basically, everyone got to pick their own project. This one's on me.

#

However, I wouldn't mind looking converting this to HD-2D if I redid after the class.

#

Or going full 3d since I won't be in such a time crunch.

#

If it's not apparent, I'm a dive into the deep end type of person. Thankfully, I'm only endeavoring to make a crude demo at best.

deep bramble
#

So why would a nav mesh work in PIE but require to be rebuilt in a packaged test config build? My AI chars won’t move…

uneven cloud
deep bramble
#

Maybe it got all screwed up since I made changes in the ini config but didn’t go around to each level and let it rebuild…

#

Just went straight into another test build

strange marsh
#

yes when i scale up my ai to 450x y z

#

the wpon does no damage

#

weapon

#

but smaller scale it does

#

is it the sockets?

#

even if it hits me still no damage so im assuming sockets could be the issue?

dense owl
#

did you mean to post in this channel?

strange marsh
#

yes

#

need to send my tree aswell which could be the issue but i doubt it

uneven cloud
dense owl
#

ik little about montages but not sure how that says you actually hit something

uneven cloud
strange marsh
#

yes bu the ai system uses it?to detect collsion

#

but

uneven cloud
#

That tells us nothing. It's an anim notify. Not how the collision is set up.

strange marsh
#

oh ok one sec

#

meant for that to send before the other

uneven cloud
#

Is this a plugin? Because that's probably one of the most ridiculous ways I've seen collision set up.

dense owl
#

and if it's a tutorial, by all means let us know who the creator is so we can build the no-no list lol

uneven cloud
#

I have so many questions. Like why are VFX and SFX being triggered on the server? And do you know that server RPC functions don't work on NPCs? Or why are you making a collision component dynamically? Or why does the character have a component for AI behaviors?

#

The easiest way to debug collision problems is to use debug drawing. I'd use the visual logger and debug out the collision shape that it makes. Maybe turn off hiding that collision component in game.

glacial minnow
#

Hi. I am working on a goal-oriented planning extension, which I want to integrate into UE5. In my program I represent agent state with an array of ints. This is done due to simplicity and it is suitable for 95% of my situations. However, when it comes to a parameter showing agent's current position, I am pretty stuck. As my agent will use Unreal NavMesh for movement, I wonder if there is any bi-mapping int<->position? I only need agent's position to measure how far an object is from the agent, so a little approximation is allowed. Maybe, I can use the id of the closest NavMesh node or something?

turbid escarp
#

Hi, the "Move to" node in one of my behaviour tree is not working, i was able to narrow down the cause to the fact that i had too many AIControllers spawned in a scene but i cant find a fix for it.

pine steeple
#

If your using crowd avoidance you can increase the agent limit

turbid escarp
vivid drift
#

If I have actors A, B, C and I want them to approach an arbitrarily shaped mesh such that they walk towards the nearest edge, how should I do this? I don't need a globally optimal solution or anything but I'd like it to be decent.

  1. I've tried move to actor, but they really want to move towards the center of the object, which in this case may require going around it

  2. I've tried cast a line from the actor to the mesh and going to that point, but this seems to introduce a fair bit of randomness in terms of where they go...

#

I'm contemplating ignoring the nav system entirely and just drawing my trace and then applying root motion towards it until a trace suggests they're right against it.

misty wharf
#

you could try using the bounding sphere I guess and take the closest point on the sphere?

#

if that doesn't put them close enough you could probably do a linetrace from the closest sphere edge which might give a better result

vivid drift
#

I have the point. My issue is that telling the actor to get there seems too finicky

#

Like, when the object is very thin, the ai can't tell if it should go to the left or right side even if I provide a point

#

maybe I could just peel it back a little bit...

misty wharf
#

Try offsetting the point you get towards the AI actor?

#

Yeah

crisp oar
#

I modified the Agent Radius of the recastNavMesh-Default to let the npc move through doorways, and it worked the first time I tested it but after that I started getting an error saying "NavData RegistrationFailed_AgentNotValid" and the npc won't move anymore. I'm not really sure how to fix it, but I'm digging around. Any ideas?

neat hatch
#

is it actually possible to make an ai use the navmesh of a different nav bounds volume?

neat hatch
#

actually, a better question, can you restrict which ai can just walk through a NavArea volume and which cannot?

misty wharf
#

You can by using a nav query filter, you can specify which one to use on MoveTo nodes and such, and I think there might also be some default filter on ai controller

neat hatch
#

hmm

#

this is funny.... my custom navArea blueprint ain't showing up for some reason

#

doesn't work either

#

the default nav areas work fine

#

but the custom one does absolutely nothing

#

idk why

stray widget
#

Hey, devs!! I am trying to rework a problem I asked quite sometime back, and now I am focusing on the pathfinding... so here it goes:
A spiral track for the enemies to move

And I want the enemies to not go out of the path and also the player shouldn't be able to place buildings on the path... I can use splines for the enemies but that doesnt take care of the building placenent... if it was a straight path than I could simply add a navmesh bound and change the collision settings on it... but I cant do it

the image is for the ref

edit: I found this tut to be useful but am not sure if there is any better way to do this:
https://www.youtube.com/watch?v=7CYSoJYpKtU&ab_channel=GamingDev2020

Create custom shaped NavMods, by drawing out a custom brush with the pen tool first and then converting it to a Navigation Modifier Volume. Learn how to do this technique for both Unreal Engine 4 and 5.

Check out how to use NavMods for different Area Classes and Query Filters:
https://youtu.be/vzvOM--Zv0I

Need help optimizing your NavMesh?
htt...

▶ Play video
neat hatch
#

yeah so I'm blocked

#

I can't use my own custom nav areas anymore

#

cause it doesn't work

#

default ones do but mine don't

silent hamlet
stray widget
#

unless there is a way to broaden it for every segment

silent hamlet
#

But what determines the width of the spline? Probably a mesh reference on the spline itself? Or maybe a variable. Either way you can query that value from your spline actor

#

And ensure that nothing is built within those bounds

silent hamlet
stray widget
neat hatch
#

@silent hamlet it has no blueprint setup

#

Just the cost values

#

And a color parameter

silent hamlet
#

It doesn't necessarily have to be a mesh. It could also be metadata of each spline point determining how wide the path is at that location.

silent hamlet
stray widget
silent hamlet
neat hatch
#

Before a crash, the modifier was working just fine after setting the entrance cost to 1

#

After that I was tryna see in the navigation system if I could create a new Navdata blueprint

#

After clicking the + sign, unreal crashed for no reason

#

After reopening the project, the custom nav area stopped working

#

And the ai was also moving right through it no matter the value of the cost

silent hamlet
#

Did you try reproducing the same setup in a new level?

#

And rebuilding navigation data

neat hatch
#

I gotta try it tomorrow

#

The project better not be bugged

nimble smelt
#

Is there a system by which I can force an AI to perceive a given actor?
Normally my AIs just use AI Perception like you're supposed to, but in the case when the AI is spawned in response to the player stepping on a laser wire or something, I want to IMMEDIATELY tell the AI to target the player.

silent hamlet
nimble smelt
#

I don't want to override or invalidate the AI Perception system, just like.... give it a hint.

silent hamlet
#

What you mean by invalidate perception? The two systems can co-exist with no issues

nimble smelt
#

That's true but when they disagree one has to win

#

Normally my BB key is set based on the AI Perception status, so that's the source of truth.

silent hamlet
#

But what you mean disagree? Either perception sees the target first or your trigger. Whoever comes next will just re-set an already set key

uneven cloud
glacial minnow
uneven cloud
glacial minnow
#

For instance? I guess my scope is pretty small...

nimble smelt
silent hamlet
nimble smelt
misty wharf
#

"Bad experiences"?

silent hamlet
nimble smelt
#

I mean, it's not a story, it just wasn't triggering when I thought it should

misty wharf
#

If it isn't triggering when it should trigger then something is misconfigured

#

Manually checking if something is perceived won't make it perceive something that isn't getting perceived by on perception updated

#

Note that I'm not saying that periodic manual check is a bad way of doing it - it certainly could be valid depending on how you want it to work :)

nimble smelt
#

That's the problem, I can set it manually, but it'll just get cleared instantly

nimble smelt
misty wharf
#

oh wait is on perception update the one which gives you an array of stuff?

#

that one's a big newbie trap as far as I can tell :P

#

the one which gives you just one single actor's perception info is much better, maybe that one was on actor perception updated

silent hamlet
#

Independently of what is setting it

nimble smelt
#

That doesn't solve the problem where ConfirmTargetDetection then removes that target when it cant confirm detection

nimble smelt
uneven cloud
silent hamlet
#

Hmm it's a bit of a weird setup...the decorator is on the same level as the service that's setting the key being evaluated. Ideally you should have that service one level above this. But in any case, when target is out of sight, you unset the key. The ai correctly has no target. It will lock it back when it becomes visible or when it enters your hypothetical trigger. I still don't understand where is the problem!

#

Or you want that when insider the trigger the target is visible independently of the perception system not being able to see it maybe?

nimble smelt
nimble smelt
uneven cloud
nimble smelt
#

seems like it is in a way?

uneven cloud
#

But you have to pick a specific sense and go through an array

#

At the end of the day, I still recommend you either make a new sense or send a fake hearing event. Depending if you are using hearing for different functionality

silent hamlet
nimble smelt
nimble smelt
silent hamlet
#

That couples things a bit though. But for what you want to achieve you can't just unset the key if not visible anymore

nimble smelt
#

I don't think I need to actually DO damage to have a damage event

uneven cloud
silent hamlet
#

The problem with the fake sense is that it will be forgotten by the logic you have in place..I think a lot of your problems come from your custom service

nimble smelt
misty wharf
#

@uneven cloud are you aware of any usecase for the on perception updated function that gives an array? I never quite figured out when that would be beneficial to use over the one which gives you a singular actor's stimulus update

silent hamlet
#

So indeed a custom sense could be good for this!

uneven cloud
nimble smelt
#

Actually I have some questions on this node. Like, should the Event Location be the location of the actor that CAUSED the damage or TOOK the damage? Also do I need to call this manually in the case where the actor ACTUALLY receives damage or is it smart enough to link to event ReceiveAnyDamage on some deeper level?

uneven cloud
misty wharf
#

Yeah no worries, it's not really an issue or anything that I'm facing, was just curious because I can't think of any usecase for the func :D

uneven cloud
misty wharf
#

And it seems a lot of beginners end up trying to use that function, and inevitably struggle with it because it doesn't seem to always behave quite as predictably as the one which just gives a single stimulus value

nimble smelt
#

Oh it actually HAS a hit location value if you expand lol

uneven cloud
nimble smelt
#

I guess it's a "bird in the hand/bush" scenario. Should the AI chase a low-priority target it can currently see, or a high-priority target that is merely remembered?

uneven cloud
#

Using known means they can remember the target for the amount set on the config. So momentary breaks of line of sight doesn't make them drop target.

nimble smelt
#

There's also no reason you have to do target ACQUISITION and target UPKEEP with the same function, I have different services for initial detection and for continual pursuit

uneven cloud
harsh storm
#

Luthage's advice to most things 😅

uneven cloud
#

Only for things where it makes sense.

nimble smelt
#

Dumb question, I notice each sense has a "Debug color" how do you like.... see that?

uneven cloud
cyan hemlock
#

Hey all, quick question. How would one go about changing the size of the debugging spheres for EQS results? If it's possible at all 🫠

uneven cloud
cyan hemlock
gentle saddle
#

looking in to state trees, and wondering when evaluators are updated if not run on tick?

neat hatch
#

@silent hamlet it looks like the custom nav area got bugged out cause of that crash
so I made a new nav area and it all works fine now

neat hatch
#

I don't think thats sight....

#

ah wait no, now I see it

#

I expected a cone shape

#

but its actually a flat cone in the debugger

#

anyways, for some reason the sight perception isn't detecting the player

#

here's the setup

#

normally it should fire just fine

#

but it doesn't

neat hatch
#

oh, right

#

target also needs an ai perception stimuli

#

oop, and also forgot Sense by Affiliation

signal island
#

what does it do?

neat hatch
#

I wish it was possible to manipulate the "Use Acceleration Using Paths" through blueprint....

#

this forces me to create a custom blueprint that changes the moving speed depending how close it is to the target

celest python
#

BrainComponent and other AIModule classes listen for AImessages

harsh storm
#

I don't think it's really used all that much anymore either.

signal island
#

is there a way to share EQS results?

celest python
#

but I dont recall where

harsh storm
uneven cloud
celest python
#

i recall one at braincomponent too

#

but if thats changed too then yay

tough ermine
#

hi wondering where i would best start on creating ai enemies for a 2dd platformer

uneven cloud
spice nova
#

This is probably a dumb question, but is AI via Behavior Trees and EQS more resource intensive on a packaged product than something like AI Move To? I'm struggling with the latter, and think that EQS will probably solve my problems, but was hoping I could produce something for mobile and don't know if it's ill-advised

misty wharf
#

I'm not quite sure how to answer that because you're talking about three totally different things

#

Behavior Trees in general are not particularly expensive compared to regular BP graphs if that's what you're asking

spice nova
#

Sorry, I guess what I mean is are the computations done by a behavior tree going to burn up a mobile processor when a Blueprint AI move to would not?

#

So it seems like you've answered my question. I'll start learning more about EQS because the simple move-to isn't working for me