#gameplay-ai

1 messages ยท Page 35 of 1

finite gyro
#

this is what I mean

#

it's just doing the right side even though everything on the left is passable

dense owl
#

Itโ€™s not just the decorators that can fail

finite gyro
#

how do I make it switch to the left side the moment everything there is passable?

#

nothing is failing

#

because the logic doesn't even get there lol

#

it's not like it's quickly flashing there and going back

dense owl
#

Did you use the pause button?

finite gyro
#

yes but how does that help me

#

when the execution is just on the right side

dense owl
#

Just to make sure itโ€™s not happening faster than you think

finite gyro
#

it's not

#

it's weird

#

sometimes it works, sometimes not

dense owl
#

Ok, then you need to try using the gameplay debugger at runtime (โ€˜) and if that doesnโ€™t give you any clues use the visual logger

finite gyro
#

I can't find a pattern

finite gyro
#

should the wait be cancelled in the middle?

#

because that's kinda what I need

#

I'm not sure if I understand it correctly ๐Ÿ˜„

dense owl
#

You say there are no nodes that could fail but you havenโ€™t tested that

#

Moveto could fail instantly

unborn sphinx
#

on the very left, the branch that we can't see at the bottom, if it passes the selector stops running

dense owl
#

Just because your decorators pass doesnโ€™t mean everything passes

unborn sphinx
#

u could be having a problem with some other tasking passing

dense owl
#

Yeah good point

#

Pausing and stepping through with the arrows should you usually show you that

finite gyro
#

I'm testing it again and sometimes it works, sometimes it just hangs in the right branch for no reason

#

BTs confuse me sometimes ๐Ÿ˜„

unborn sphinx
#

disconnect that farthest left branch

#

it will work then every time I bet

finite gyro
#

the one off-screen?

unborn sphinx
#

yes the left-most child of the target exists and distraught selector

finite gyro
#

that one doesn't change anything because it cannot fire

unborn sphinx
#

well try disconnecting it

finite gyro
#

I tried, nothing changed

unborn sphinx
#

if it can not fire why have it?

finite gyro
#

because it's not being called at all

#

well it CAN fire but not with the current AI i'm testing

#

it's for aggressive behavior

#

the one I'm testing now is scared behavior

#

the aggressive one actually works properly

#

but this AI is not aggressive so the left-most branch never even fires at all

unborn sphinx
#

the way you enter that child might "pass"

#

if any child node succeeds, the selector succeeds

finite gyro
#

it doesn't because the AI would have to be set to aggressive

#

and it's not

unborn sphinx
#

well it is entirely possible that some service somewhere upstream is setting that value to aggressive erroneously for a split second

finite gyro
#

it's really not though :D

unborn sphinx
#

but maybe this is a red herring u r right

finite gyro
#

I'm 100% sure that's not a problem

#

scared type cannot possibly become aggressive in my logic

#

but I'm testing more with pausing and going one by one

dense owl
#

Use gameplay debugger and visual logger, guessing will only take you so far

finite gyro
#

what does the visual logger do? ๐Ÿ˜…

dense owl
#

Pretty much what it says ๐Ÿ˜€

#

Itโ€™s kinda like Insights for AI

#

Youโ€™ll find it in Tools -> Debug

finite gyro
#

I'll check it out

#

thanks

unborn sphinx
#

I wonder if having a selector node with a decorator only will be a success and stop executing children?

#

I have encountered difficulty trying to nest subtrees. is it possible that there needs to be something on the selector other than just the decorator and a child node?

#

if the parent, distraight and target, was a sequence, then either could still fail/abort from the decorator

finite gyro
#

I managed to get it work like once now, I paused and going on by one, it sets all the BB keys to non-passable suddenly, for some reason

#

I'm gonna have to go deeper ๐Ÿ˜„

#

might be an issue in my AI controller

#

working with 3 senses is confusing sometimes

unborn sphinx
#

That node could be a sequence and it would maybe help prevent early exit of the subtree

#

although no

#

because then it would never pass

#

if u need it to pass sometimes, to prevent further selection, than yeah

finite gyro
#

I think something might be wired wrong where I deal with the senses in the AI controller

#

but I'm not quite yet sure how to test it at the same tick when the left tree fails

unborn sphinx
#

I am tending to deal with senses in EQS and services

#

Are you setting keys on your ai controller itself?

finite gyro
#

yeah I'm using the "OnTargetPerceptionUpdated"

#

I actually had it working pretty nicely but I added some stuff since and it kinda broke

unborn sphinx
#

The newly discovered magic that I have found from being here is that using services you can guarantee that a key is set or not when a node activates or deactivates

finite gyro
#

ah, like eliminating the possible "void" between the service updates?

unborn sphinx
#

yeah exactly like when you know a key should NOT be set you can make sure it's not when the node it's needed for exits execution

#

as long as some other service is not also setting it

#

but IMO it is easier to time and track down if everything is done in the BT than the controller and BT unsynced

#

I have even realised you can just pinpoint your inquiries to the senses

finite gyro
#

I'm not sure how I would move it over to the BT though

unborn sphinx
#

like you have a suspect actor, just test for the senses perceived on them only

unborn sphinx
#

then when you leave that subtree you can ensure all those keys are cleared or whatever you need. Leave it in a known state and don't touch it.

finite gyro
#

This is still a bit overwhelming for me ๐Ÿ˜…

finite gyro
#

for a moment it works, then it switched back to the right

#

and then it doesn't switch back at all even for a tick, even though all of them on the left are passable

#

and you can see that even in the moment when the left switched to the right side, none of BB keys changed at all

#

I want the AI to keep repeating that bottom left part

#

if all of them are still passable

#

I think I'm just gonna have to put "Not distraught" decorator on the right side ๐Ÿ˜…

#

okay yeah that makes it better I think..

unborn sphinx
#

the one thing different about that agrressive node is the type. everything else is a bool or checking if something is set while that node is searching for is something equal to another. is it a string? an enum?

harsh storm
#

Is it possible to bind to a delegate from my actor, in a C++ non-instanced task?

tight kindle
#

I dont work with AI so forgive me for not knowing, but is there any requirement for the blueprint type an Ai can control? Can I use a character BP or does it need to be an empty Pawn

dense owl
tight kindle
#

Excellent thank you

vestal gale
#

Any good guides on setting up an EQS generator in BP?

#

Planning on using it to query for valid cover spots, but I'm struggling to get it to return any points at all...

#

Ahh nevermind, looks like I just forgot to set the default generated item type to be an eqs point

vestal gale
#

The custom generator used by the query on my eqs testing pawn seems to only show/generate items when I'm in simulation or play mode... Is this standard behaviour?

vestal gale
#

Makes debugging way easier

vestal gale
#

Yep

dense owl
#

Oh weird, maybe thereโ€™s some flag your custom generator is missing

vestal gale
#

Yeah it's gotta be, just don't see any other settings that could fix it

#

Looks like it's actually generating, just not showing items

wind moat
#

Heya devs, I'll be brief.
Problem: npc follower disappears when follows player far away from a spawn point.
Details: made large world, deep underground dungeon with long elevator down. After taking elevator from the surface and moving a little into the dungeon, there appears to be a line that npc can't cross and simply disappears.
If I move npc, so does the line moves. If I return after disappeared NPC it it appears again. But trying to move further repeatedly makes it disappear another time.
(its not kill zone, I lowered it way lower)

#

Any setting I can check to adjust actor's distance from spawn parameters or something? (couldn't find solution on google)

unborn sphinx
#

how far away from the world origin are you, do you have large coordinates enabled, and do you have any other weird issues in those areas?

wind moat
#

Spawn point location

#

Approximate disappear location.

#

Haven't ever tried enabling large coordinates before. Might give it a go. (Think it will help?)

unborn sphinx
#

it is possible it is related but not for certain.

#

are you familiar with floating point number precision?

wind moat
#

No, I'm sorry. Im not. Less than 1 year xp.

crystal hatch
#

Care to ask a question that doesn't require me reading my UDN answers from years ago? ๐Ÿ˜‰

pine steeple
#

@crystal hatch Sure lol, basically i want to produce navlinks for placeable building building pieces automatically, in this post you said something about "Edge" links

#

thing is i dont want designers to manually place links and have to determine the link positions, etc

unborn sphinx
# wind moat No, I'm sorry. Im not. Less than 1 year xp.

Ok well in computer science in general, floating point numbers can only really accurately represent like 6 digits for single precision, 15 digits for doubles. afaik, if you do not use large coordinates, most stuff uses a single float in UE. I could be wrong. But your numbers are withing the order of magnitude where maybe you will see problemts but not certainly.

If you are using doubles (large coordinates) then you should see no problems, unless there is a bug in the implementation and they missed a few floats somewhere lmao

crystal hatch
# pine steeple <@333981651245727755> Sure lol, basically i want to produce navlinks for placeab...

Right. The thing I mention is an extension of ANavLinkProxy that makes it easier to set up navlinks along some line. There's still manual setup required, but just makes it way easier to place lots of consistent links. It will eventually make it to the engine (it's in Fortnite sources right now and I can't seem to find time to move it out). In the mean time here's something that still worked sometime this year when I tested it. Jus put it in the right places in AIModule ๐Ÿ™‚

floral compass
#

Does anyone else have issues with state trees and property binding in 5.3.1?
I have an evaluator that gets the movement component of my pawn. But when I try to bind some transition condition to the velocity of that component, I get the error:

StateTreeCompiler: Error: Root Condition 'Distance Compare': Input property 'Source' on Condition 'Distance Compare' is expected to have a binding.
StateTreeCompiler: Error: Root Failed to create condition for transition to 'Test'.

pine steeple
pine steeple
#

@crystal hatch seems its missing EdgeLinkRenderingcomponent

#

nvm

#

๐Ÿ˜›

unborn sphinx
#

If I have a composite/node with two decorators on it: one that is set to abort everything if value changes (for example), and the other is just an entry condition.

What happens if the aborting condition becomes true, but the second decorator is never true. Will the first decorator abort the lower priority nodes, but then fail to enter the subtree?

#

Or will it never abort anything because not all decorators evaluate as true?

unborn sphinx
#

I can refactor what I wanna do anyway. On the watched value, where it is set, only set it if that other condition is met too.

pine steeple
#

@crystal hatch I saw also in that post, that you said there was a way that static meshes can generate navlinks, only thing i can see kinda useful is NavLinkDefinition, but i am not sure how it is used

crystal hatch
pine steeple
#

yeah i am currently doing that :P, btw is there a way for Partial Path to ignore certain modifiers and not allow pathing through it? (its a high cost not null)

crystal hatch
#

Man Person, you're milking it! ๐Ÿ˜‰ I don't remember anymore, I haven't worked with nav code in years (when did Fortnite BR add AI? That long ago). You should be able to achieve something like that with virtual filters.

pine steeple
#

haha, sorry ๐Ÿ˜›

tough tulip
#

I am currently looking into creating a GOAP (Goal Oriented Action Planning) system for the AI in my RTS game, purely as practice. Looking online there aren't many games that have (publicly) shared they are using GOAP for their own games. Is there a specific reason for this, or is it just a matter of GOAP being so common in games nowadays that no one really finds it worth mentioning anymore?

keen island
#

Hello everyone. If known, can someone point me to some good resources regarding connecting UE game/sim to an AI Chat engine?

Is this even possible? Let's say as an indie project, there were 10k users all using the code at the same time. Would this dictate using a local system vs. something online? How would you do it? The goal, imagine an AI compainion in a simulator that assists with operations, alerts to treats, and has general conversation time. Picture the computer in Star Trek, where player could request information, give cammds to do duties, etc. Thank all.

dense owl
keen island
#

Understood. do you know of any like kind AI examples? I will ask around regarding my initial questions. ๐Ÿ™‚

#

Meaning example of what has been done natively.

dense owl
keen island
#

I would think that could lead to trouble if there were a large user base. OK, well, appreciate that input this morning. ๐Ÿ™‚ I am on a crash course as it has been years since I did any coding. I am using Python and learning much quickly. I am mainly using it to create and interact with databases. I have yet to connect UE to those databases and that is the next learning phase. I am one of those Jack of all trades types. ๐Ÿ™‚ I do nearly every aspect of game dev but I am weak on coding although I have the aptitude as I wrote entire applications years back. Thanks again.

desert hare
#

Hello amazing people. Learning UE at the moment from the Lyra sample - I've built my own custom map but the AI just stand still. This seemed like a navmesh issue but the Navmesh volume was repositioned and everything that's supposed to show as green does when viewing the navmesh in editor - HOWEVER, after futher debugging using the " debugging menu, I've isolated the issue to what I believe is the AI using the old navmesh as seen in the picture.

How on earth do I go and fix this? My scene has a NavMeshBoundsVolume and a RecastNavMesh-Default, both presumably there from the original map, again I've updated the navmesh bounds, but have no idea what a recastNavMesh is.

#

The same view, but from non PIE view. Instead using the show>Navmesh view in the viewport.

#

Clearly something is not playing nice here.

unborn sphinx
#

Lyra bots need ability spawners and other players to move. And yeah a working navmesh.

Go to build menu, and click build paths. Then save your level. Then they might work.

desert hare
#

What's confusing me is the discrepancy between the nav mesh shown in the viewport, and the navmesh shown at runtime via the " menu. Surely it should be the same?

#

Notes: Using Dynamic for runtime generation "fixes" my AI, however performance is pretty dog ๐Ÿ˜‚

So issue is definitely navmesh related.

crystal hatch
unborn sphinx
desert hare
#

Yeah no luck :c tried both:

Build > Build Paths > File > Save Current Level
Build > Build Paths > File > Save All

desert hare
unborn sphinx
#

well that is unfortunate

#

how are you spawning the bots into the level?

desert hare
#

default lyra method, they spawn at the player starts. Again, this is 100% looking like a navmesh issue.

#

What's the chance that this is a bug on source?

unborn sphinx
#

yes I believe you this does seem like that

#

I bet it is very unlikely a bug that can't be worked around

#

if there is a bug it's a small one that is causing a hitch that can be worked around

#

ur navmesh should work

#

Ok so the ability spawners need to be REACHABLE on the navmesh. possibly other enemy players, too

#

your navmesh might be too small at points to be reachable

desert hare
#

I have an ability spawner that is reachable - when setting navmesh runtime generation to dynamic the AI works as intended - I've also turned off the part of the behaviour tree that looks for new weapons to prevent it from getting confused.

unborn sphinx
#

you can't just turn off part of the BT, because something has to pass or nothing will happen. It is not a stable BT lmao small changes really mess it up

desert hare
unborn sphinx
#

I am making a level with lyra bots and lots of stairs too. You must be careful or thy won't be able to reach

desert hare
#

And then after building path and saving.

#

BUT, ingame:

crystal hatch
#

Have you messed around with navmesh generation properties of the RecastNavMesh instance in the level?

desert hare
desert hare
unborn sphinx
#

dynamic might have different settings so it makes more mesh/enough for them to move

uneven cloud
unborn sphinx
#

but also, yeah, there is some issue with navmesh building and saving correctly in some scenarios

#

As MieszkoZ pointed out, check the RecastNavMesh actor in your level

harsh storm
unborn sphinx
#

I also had to mess with settings there to get it working on my level things were quite messed for a moment

#

BTW that actor kinda messes with OFPA a bit... source control will try and add one but it's not real then it gets messed up lmao

#

the recastnavmesh should be in the level file itself, even with OFPA (from what I can tell) so when UE started adding it to perforce changelists things got screwy for me. I had to go and delete that OFPA file then everything was fine

desert hare
#

Recast Navmesh Settings

uneven cloud
unborn sphinx
#

Lyra does not give u many options to spawn bots by default. They are likely being brought in by the LyraBotSpawner and they should be working correctly

#

But you might be right that maybe the streaming is affecting something, but lyra uses world partition in their levels by default

crystal hatch
# desert hare Recast Navmesh Settings

I don't know how navmesh is setup in Lyra, but:

  • make sure there's no additional "navigation" sublevel. If so, remove it.
  • delete all the navmesh actor instances in the level
  • manually rebuild navmesh
  • save and reload map.
unborn sphinx
#

even tho there are like 4 cells

#

As far as I can tell there is nothinig special happening with lyra and navmesh it's all basic so do exactly what MieszkoZ says

uneven cloud
tough tulip
desert hare
tough tulip
crystal hatch
uneven cloud
crystal hatch
desert hare
#

Levels tab says "This feature is disabled when World Parition is enabled"

unborn sphinx
desert hare
unborn sphinx
#

you have to generate that texture in the build menu

#

are you using source control?

unborn sphinx
desert hare
desert hare
desert hare
desert hare
#

I finally found the issue. Thanks @unborn sphinx @crystal hatch - the issue seems to be that my RecastNavMesh-Default was not 0'd. Zeroing its location, building and saving fixed the issue. Thanks you legends for pointing me in the right direction โค๏ธ

unborn sphinx
unborn sphinx
#

should we be checking if an actor is valid every time before we set focus to it? Or only when we are "accessing" something on the actor?

wind moat
unborn sphinx
#

In lyra the bots should be setup with a playerstate and everything just like a real player

#

unless you changed it

wind moat
#

These are the only settings i see for "owner" in both blueprint settings of the actor and in world screen settings after it's placed.

unborn sphinx
#

do not place thebots in the world by dragging the BP that will not work

wind moat
#

Im a bit blown away though curious. How do I place them then? Through a spawner bp?

unborn sphinx
#
void ULyraBotCreationComponent::SpawnOneBot()
{
    FActorSpawnParameters SpawnInfo;
    SpawnInfo.SpawnCollisionHandlingOverride = ESpawnActorCollisionHandlingMethod::AlwaysSpawn;
    SpawnInfo.OverrideLevel = GetComponentLevel();
    SpawnInfo.ObjectFlags |= RF_Transient;
    AAIController* NewController = GetWorld()->SpawnActor<AAIController>(BotControllerClass, FVector::ZeroVector, FRotator::ZeroRotator, SpawnInfo);

    if (NewController != nullptr)
    {
        ALyraGameMode* GameMode = GetGameMode<ALyraGameMode>();
        check(GameMode);

        if (NewController->PlayerState != nullptr)
        {
            NewController->PlayerState->SetPlayerName(CreateBotName(NewController->PlayerState->GetPlayerId()));
        }

        GameMode->GenericPlayerInitialization(NewController);
        GameMode->RestartPlayer(NewController);

        if (NewController->GetPawn() != nullptr)
        {
            if (ULyraPawnExtensionComponent* PawnExtComponent = NewController->GetPawn()->FindComponentByClass<ULyraPawnExtensionComponent>())
            {
                PawnExtComponent->CheckDefaultInitialization();
            }
        }

        SpawnedBotList.Add(NewController);
    }
}
#

you can expose that function to BP

#

then spawn them in bp at will as long as it is run on the server

wind moat
#

Newbie brain overload, but I'll try to process it.

#

Thanks

lyric flint
#

I want my NPCs to detect the player if the player stands too close behind the NPC for x seconds. I have two ideas, but I'd love to hear thoughts if anyone has a better way:

  1. Create a custom perception sense that detects when the player is too close for too long
  2. Create a collision sphere around the NPC that starts a timer when the player enters; when the timer fires, the NPC perceives the player
unborn sphinx
#

there is a data bp somewhere for each control point, elimination mode that sets how many bots to spawn

#

or using the cheats system but that does not work on shipping builds

wind moat
#

Still beyond my current comprehension. Im sorry. Looks like this month's version will have a bug that needs fixing later.

unborn sphinx
#

I am not good at explaining things I am sorry lmao

wind moat
#

Yeah that's like a weak part of trying to find answers on this discord. Really wish people were more keen on hoping on voice chat with screenshare together to show/solve problems quicker. I kept asking it here sometimes in DM, even for money, but they never answer. Contacted a guy in hire channel suggested same he ghosted me. Is something wrong with me or what I suggest? (inb4 ghosted again.xD)

unborn sphinx
uneven cloud
unborn sphinx
#

is that last note clear? ๐Ÿ˜›

dense owl
# wind moat Yeah that's like a weak part of trying to find answers on this discord. Really w...

People are busy, sometimes at work, so they can quickly post a msg here and there, they canโ€™t join a full-on zoom meeting to mentor you, nor should you expect anyone to have any interest in spending their time doing that for you here. Your options are thus:

  1. pay someone a ton of money to mentor you
  2. take your chances and pay a ton of money for some โ€œmasterclassโ€
  3. be patient, bump questions when they get lost, spend some time to try to figure things out when someone gives you a lead, wrack your brain and get to the answer eventually, by asking better questions progressively
harsh storm
#

Most of the time that I'm here, answering questions, I'm at work. Definitely can't jump in voice.

wind moat
wind moat
uneven cloud
uneven cloud
wind moat
harsh storm
#

It's something specific to world partition

wind moat
#

Yeah I have world partition.

harsh storm
#

Like, if you had just a regular ol' classic style level - it'd be fine to do it the way you're doing it (IE - drag n' dropping)

wind moat
#

Makes sence the npc disapears if I go too far away then

harsh storm
#

I don't use WP though, so I don't know any caveats to it.

unborn sphinx
#

In lyra it probably will not work without spawning the playerstate. components, and the ASC itself, need the playerstate in lyra

uneven cloud
#

Always spawn NPCs dynamically.

harsh storm
#

All my AI is dynamically spawned as well

#

I just don't want to tie it to a specific actor.

wind moat
#

How does one spawns an NPC which can follow the player as far away as they go then, provided world partition is used?

uneven cloud
#

It's also a waste of perf having AI doing stuff when the player isn't around.

uneven cloud
wind moat
unborn sphinx
#

It's not that bad

#

just start digging. Do you have visual studio set up?

wind moat
#

I've been in this for just 8 months now. 1 of which I gave up for at the beginning, 1 in a village without pc or internet on holiday and about 2 first ones just poking around building map a little with a gasping mouth.

dense owl
#

Wouldโ€™ve given up if it wasnโ€™t for this server tbh

unborn sphinx
#

if u wanna play with lyra u gotta be comfortable messin around with c++ once in a while

dense owl
unborn sphinx
#

๐Ÿ™

dense owl
#

Jk ๐Ÿ˜€

#

I do admire your willingness to get lost in thatโ€ฆ system

unborn sphinx
#

I will be less mental when I finish this first playable prototype in a few weeks lmao

#

I have not much code or blueprint to release, because they are just modified epic files, but it's gonna be an open source community-driven game so like yeah I will spam the crap outta this place with the link I'm sure lmao

#

I will refactor everything into new classes and stuff so I can release it but rn I am seeing what needs to be done for basic functionality and seeing if the core mechanics are even fun

#

(release the code/bp that is... the game will be released on github regardless lmao)

#

development builds only tho. eventually the game might cost like $5 on epic games for a full copy playing on live servers not test ones (no dedicated serves yet tho just p2p)

#

I feel like any "pain" involved with lyra is short lived and GAS is our lord and saviour bow down

#

๐Ÿคฃ

hasty lake
#

Hey ppl , how do i access the character possesed by an ai on a bt decorator?
i just found this, seems to help OwnerComp.GetAIOwner()->GetPawn();

primal pebble
#

Hey guys so on every task in my BT, the first thing I have to do is cast the owning pawn to the actual actor running the BT, is there a better way to go about this?

#

Basically this is step 1 in every single task because I need values within my base human class, but this feels like it cant be the right approach...

hasty lake
#

im a noob on this, but i get the same feeling. i think the idea is that the bt is as detached to the pawn as possible.

#

if i have several pawns, all running an different instance of the same ai controller, with an instance of the same bt, do they share the same instance of the blackboard or is a new blackboard instance per pawn?

primal pebble
unborn sphinx
#

(but just on-topic rambling spam, no link spam)

uneven cloud
vestal gale
#

Curious about the standard way to find cover points at the ends of walls with EQS? I made a generator that draws a circle of points around the player, casts each one towards the player and then stops when it hits the wall. Then I'm moving along to the left and right of the points at a series of intervals (max of 5 atm 100 units spacing between each) and tracing forward again to find the point the last point that hits the wall to hopefully find a spot close to the end of the wall.

Is this sorta the right approach, or am I way off?

primal pebble
#

Hmm that sounds inefficient, here is my approach

#
  • Generate points around target
  • For each point, line trace 150cm towards the target starting from knee height of the point
  • For every point that hits a wall in the previous step, I do an additional line trace at shoulder height from the point all the way to the target to confirm line of sight.
#

The first trace already confirms that the point is cover AND is close to wall as it has limited range. The second trace confirms that cover spot has line of sight to the target.

vestal gale
#

Ahh sorry yeah that's a good system for "duck" point, but I'm after a system to find the edge of a wall, so the character can lean out of cover to shoot.

#

The screenshot was confusing, my bad

#

This kinda scenario

primal pebble
#

Ahhh I see now why you are doing it like that

#

Personally, I kept a cache of all accesible points active, then I just do shoulder height traces and if one point succeeds but its neighbor fails, I know I've got a "lean" point.

vestal gale
#

Oh interesting

primal pebble
#

Yeah and in larger maps I just move the cached point grid to always keep player in center.

vestal gale
#

How often do you generate the points? Would have to be super expensive

primal pebble
#

Not really. I generate them once and I'm done.

vestal gale
#

Gotcha, and you could share the grid between agents I guess

primal pebble
#

Exactly, I have a "query orchestrator" that caches the grid for sharing across all units.

#

IMO its way more efficient than the EQS system as you have to regenerate locations you can move to for every decision when they likely are not changing often.

vestal gale
#

Ah awesome, love that kinda stuff, I might try something like that then and see how I go

primal pebble
#

But thats off topic haha, my approach could work for you if you do more fine grained inital traces to decide navigable locations but that may be too costly.

vestal gale
#

Gotcha, thanks for the help I'll give that a shot

harsh storm
# uneven cloud The move to task uses an AI task.

What's the benefit of doing it through an AI Task over making it instanced? Seems like extra work (AI Task) over just making it instanced. Going to have a UObject created either way. Does the task interface with a different system better or something?

uneven cloud
harsh storm
#

Ahhh

#

Alright - so there is a chance that it never gets created if that branch is never hit for w/e reason

uneven cloud
primal pebble
#

I exclusively test points that are within a given weapon range.

#

What my system does more efficiently is purely having the nav points pre-set up so I don't have to trace down like the EQS system does to find points to evaluate first

primal pebble
uneven cloud
#

You still have to find all the points within the range of a given weapon.

harsh storm
primal pebble
harsh storm
#

It's spreading the cost across multiple frames

primal pebble
#

My personal testing showed that it was more cost effective than tracing for points each decision.

#

Gotcha thanks I figured as much, I've got something similar for my system!

#

Just a simple "only evaluate X amount of points each frame" so probably much less complex than whatever EQS uses.

uneven cloud
primal pebble
#

I'd bet its fast, but I still think my system cutting down on initial line tracing would be a faster first step (establishing points to query from).

#

From there I doubt I have them beat LOL

harsh storm
#

I still think
Should measure rather than think

primal pebble
#

I did measure! I compared tracing for points each decision vs caching vectors and iterating through them for a distance check.

#

Cache vectors and do dist check for applicable points to evaluate won out over making new line traces to query from each decision.

harsh storm
#

So why are you saying "I think" and "IMO"?

primal pebble
#

Because I am not an expert and who is to say my testing is a true comparison of what EQS is doing. Haven't look at the source code, just saw that their very general docs descriptions 'seemed' inefficent.

#

But they could very well be caching line traces behind the scenes as well and not directly describing that in the docs u know?

celest python
#

Do you have a valid proof what you are doing is expensive right now btw?

harsh storm
#

Doesn't matter if you're not an expert though. Would just need to state your findings and how you tested. Then someone who could be more experienced could point out any flaws in that part. Just a tip.

primal pebble
celest python
#

EQS would break actions into pieces and limit them by X ms per frame, and wont evaluate anything else if budget is reached. Your problem would be latency in action rather than perf

#

if it ever gets expensive

#

like if your thingy would take 1ms it would take 1ms / EQS budget to finish that process, but overhead will merely reach EQS budget

uneven cloud
#

Caching off that much data, especially line traces which are cheap, is actually a memory concern. As well as a waste of dev time to reimplement a system that "seems inefficient".

primal pebble
#

I dont cache line traces, just the outcome of the traces which is vector positions.

So my query system that I work with per-decision is an array of 3000 vectors which I don't believe is a memory concern?

celest python
primal pebble
# primal pebble

So as you can see in the image above, the only vectors I keep are the light blue dots. Thats a debug of my initial personal navmesh/query system setup, and those go into my array of vectors that I use in all position decisions going forward.

uneven cloud
primal pebble
#

Yes, my understanding is that 3000 vectors is absolutely nothing to iterate through performance wise compared to line tracing a good amount to reestablish vectors to query from.

#

And then, each "decision" filters vectors down further. So each subsequent check (cover/LOS/height/whatever) is iterating through less and less vectors.

#

Plus keep in mind that grid is dense as hell

#

I do not normally see people query with that kind of density using EQS.

uneven cloud
#

Have you ever perf tested projecting onto the nav mesh? It's ridiculously cheap.

primal pebble
#

And vector iteration + dist comparison is cheaper.

harsh storm
#

There is someone around here who is doing like 10k linetraces on tick and don't have a perf hit from it.

#

Well, not one that they complain about anyway

uneven cloud
#

Perf certainly is relative.

#

Everything has a specific cost, but whether it's a problem is relative.

celest python
#

if I'd be micro optimizing EQS I'd go for the route parallefor per point in the grid and use traces inside of the parallel since they are not GT bound anyway

#

and wouldnt cache anything as it would make things slower implicitly

#

I am yet to see EQS is slow though

uneven cloud
#

I have yet to see it be a problem. At least not after changing the default time slice amount.

harsh storm
#

When Mieszko??? ๐Ÿคฃ

celest python
#

among other 3 message bus systems burn

vestal gale
#

The ProvideSingleActor override I've implemented doesn't seem to be getting called when I'm tracing to my player context... After some testing, it looks like it's calling the ProvideActorsSet method to find the player. Anyone know why this is happening?

harsh storm
#

There really isn't much on the interwebs about UE's AI systems. Wild.

wind moat
#

I want to use detection by affiliation without using C++ atm, unless I might be shown how to easily set a bp as friend/foe in c++ (which would be my first text programming) but it says here I can tag npcs for such system. Anybody tried it? Shame they didn't elaborate better. Does it involves array blueprints or?

mint terrace
#

less a "it has this capability" and more a "here's a workaround if you don't want to do c++"

wind moat
#

Absolutely, and I tried it. With it set to neutral npcs attack every other actor, but how does one does this "tag" thing to an NPC with friend/foe team. It cannot be as simple as just giving a tag in the other npc settings, is it? I tried it, just in case, nope.

crystal hatch
harsh storm
dense owl
#

So actor tags but specifically, Gameplay Tags

harsh storm
#

I've typically seen Tags just mean actor tags in the docs and they specifically say Gameplay Tags when they're talking about...well GT

#

Not to mention, all actors have a slot for actor tags, where as all actors do not have a slot for GT

dense owl
#

When you expose the GT Interface they come with a GT container, or rather you implement one in the process

harsh storm
#

Sure, you obviously subclass from Actor or w/e and then add a thing for GT

dense owl
#

Yeah

harsh storm
#

But what if you're using just a raw actor?

#

Like, say you want to make a wall a "hostile"?

#

(I have no idea why on Earth you would, but w/e)

dense owl
#

Well the docs and the Epic video basically tell you to go in your .ini and bypass it altogether

harsh storm
#

Yeah

#

It's a rough setup either way

plush cargo
#

has state tree gotten any epic examples yet?

harsh storm
#

I'd favor GT over actor tags anyway.

harsh storm
#

ยฏ_(ใƒ„)_/ยฏ

plush cargo
#

i havent looked at that but its mostly the crowd parts right?

#

im doing a browse for it anyway

dense owl
plush cargo
#

iirc crowd stuff and statetree overlaps?

#

i wouldnt know. but im searching now.

#

just a quick ask ๐Ÿ˜„

dense owl
#

@harsh storm you were right, I checked the docs again and it specifically says Tags. I was thinking of the wrong interface, itโ€™s GenericTeamAgentInterface. I did find a vid here: https://youtu.be/HwBdnviT2vs that shows how to implement it but then he goes on to say he doesnโ€™t know how to change the teamID at runtime so, usual tutorial caliber. Still, least he shows what needs to be #included

azure ferry
#

Does anyone have any idea why an AI controller would use the Minimum analog speed when walking?

brisk tinsel
#

im doing an rts AI. so i have buildings and recruiting of units. its mind blogging for me to understand when its the appropriate time to build or to recruit.
At first i thought i should check the prices, or if i have enemies around, and that would decide if i should Boom (build buildings and economy), or should rush (build lots of units to attack)...
At the current time im merely going by random? is this okay?
So basically it will build 50% of the times, and recruit 50% of the times.
When it has enough units it will simply attack the most vunerable and closest city?

#

is this okay?

dense owl
brisk tinsel
#

the truth is that a degree of randomization will make it more human

#

humans do random stuff

#

so its like, ai should in general boom then attack. but sometimes it rushes, or should do stuff unpredictably

#

like humans do

misty wharf
#

Has anyone tried running StateTrees dynamically? Eg. deciding which state tree needs to run at runtime? It seems this isn't supported because of course a "general purpose state tree" is as un-generalpurpose as possible... :P

#

I thought about using state trees to process some basic conversation options I have in my game which is currently done via very clunky behavior tree stuff for it but seems that idea goes out of the window immediately because of not being able to choose which state tree needs to run except in edit-time

lyric flint
#

Announce Post: https://forums.unrealengine.com/showthread.php?88199

In this multi-part series, Ian Shadden and Alexander Paschall show you how to use all of the relevant systems and features (Behavior Trees, EQS, Navigation Meshes, AnimBlueprints, AnimMontages, and more) to design, create, and optimize AI for use in a game environment with all ...

โ–ถ Play video
#

Is worth it to watch this fucking +10h playlist from Epic?

misty wharf
#

I wish Epic would actually do other documentation for these than these several hour long livestreams that are impossible to skim

#

I wonder if you could just have ChatGPT watch it and produce a summary? :P

dense owl
dense owl
misty wharf
#

Yeah but they could just write these out in textual form for people who don't feel like spending hours and hours watching the videos, especially when you already are fairly familiar with UE

dense owl
#

โ€ฆyou can prly extract captions from the vids, idk, first world problems

misty wharf
#

It's also made worse by the fact they are this type of livestream in their video format, so the pace and everything is just all over the place. If it was edited into just the good bits it would make it a bit better even in video format

#

lol yeah it might be possible

#

I just have better things to do than figure that out :D

dense owl
#

Granted, thereโ€™s one really cringy one and yet you can still glean good info from it ๐Ÿ˜…

lyric flint
#

The thing that I hate from UE live streams is that is common to be explained by people who didn't work too much with the system (As in the tour of 3 hours of GAS, KaosSpectrum is correcting some things about the system)

dense owl
#

MieszkoZ made the system so anything he says in those you can take at face value

unborn sphinx
#

It is not valid to have a composoite(selector/sequence) with simply a service and decorator on it, and no child nodes, right? Or can you just put a service that ticks on entry and have it work?? no right?

dense owl
unborn sphinx
#

I guess the use case I had in mind was when I had a service that did what I wanted and no other tasks to do

#

it does seem stupid but just wondering if it is technically possible or not even an option whatsoever

misty wharf
#

It's sorta yes but sorta no

#

The selector/sequence will just immediately finish

unborn sphinx
#

Ok yeah so even if the service is doing something it will just leave immediately

dense owl
#

Tick or timer

unborn sphinx
dense owl
#

You can always delete your posts like a ninja ๐Ÿ˜€

unborn sphinx
#

Are you talking to urself? sweeney_activate

#

Listen, I'll be done this prototype AI soon and be outta your hair dw ๐Ÿ˜›

unborn sphinx
#

Are Run Behavior and the dynamic version used often? Does the run tree only execute once, when the run node is activated?

#

It is basically like grafting the tree in as a subtree, with the limitations of the dynamic one being the root decorator, etc.? It doesn't hand off execution to the new BT?

#

Would be a good way to make modular behaviour trees right?

haughty coral
molten sable
#

Is there a way to show distance that will be traveled and visually show the path for navigation before movement

celest python
#

I tend to avoid nesting things like that whether in BT or ST because this is a problem HFSM solves without limiting you much, it makes me feel like I'm using the wrong tool and making things more difficult to maintain

celest python
#

UPathFollowingComponent API

#

GetPath() function has tons of helpers

molten sable
#

Cool

primal pebble
mint terrace
#

epic? clear and complete reference docs? I don't think they have it in them

#

bad documentation practices, a Hallmark of a developer tools company

celest python
#

Epic at least "tries" to have documentation to market things but I wonder if they really have code reviews or not ๐Ÿ˜„

mint terrace
#

but that's where the work is needed -- if UE docs were half as awesome as the videos and articles epic's marketing docs were to put out, they could save a lot of time and effort for themselves and for us

#

but the docs you get in UE docs are basically worthless. No better than your IDE can give you. If there's literally zero descriptive text on a class, that page is useless

celest python
#

I dont want docs for everything, i just dont want to get confused

mint terrace
celest python
#

especially AIModule

unborn sphinx
#

Is this equivalent to checking if the BBKey is set or not?

slim egret
#

Hi, in this node, when is OnSucceeded called? does it getting called when "EndBehavior" inside the gameplay behavior is called, or maybe at the moment that it is available to use and the agent started the behavior?
In my behavior I play a montage, and after it call the end behavior, so on succeded will be called after the montage finished playing or it could be called even before?

misty wharf
#

I recall it gets called after the behavior has finished succesfully

#

Easy way to find out for sure either test it or look at the C++ code for it

slim egret
#

yes, I've put logs in various places, and as i see it for now, after calling EndBehavior (inside the behavior instance), it gives back the control to this node and the OnSucceeded flow continues, and only then it returns back to what after the EndBehavior..
But i'm not sure if it is maybe async or something, but after repeating this several times the logs' order is consistent

deft mural
#

Which should I use, the AIPerceptionComponent or the PawnSensing component?

cyan cairn
#

Hi guys i have a question does making an AI with pawn or character have any difference i wanted to make ai that will move to the player on the Pawn it doesnt work but when i will implement AIController on my Character it is working

slim egret
misty wharf
misty wharf
deft mural
misty wharf
#

Yes

#

It does work on pawns too, but it's intended to be used on controllers and you will get a warning if you put it on a non-aicontroller

deft mural
cyan cairn
#

Guys why i cant put PlayerObject into Move to ?

fleet coral
#

Hey all!
I'm building a prototype that includes a village simulation.
Using utility AI as the method of choice, but wondering about some best practices to get things working.

I already have something functional, but feeling like it's quite convoluted and like walking in mud when I try to iterate on it.

Is there any good reading material on this that u'd recommend?
I'd also be happy to do a consultation with anyone who's got experience with that.

oblique basin
slim egret
#

what do you mean by reading material?
If it is theory, I would suggest http://www.gameaipro.com/GameAIPro/GameAIPro_Chapter09_An_Introduction_to_Utility_Theory.pdf
if it is implementation, you could look at this for general software design https://github.com/rdeioris/UnrealUtilityAI

GitHub

Simple Utility AI implementation for Unreal Engine 4 - GitHub - rdeioris/UnrealUtilityAI: Simple Utility AI implementation for Unreal Engine 4

fleet coral
rapid tiger
#

why is my AI Debugger not showing? I've rebinded it to "comma" and even tried to manually turn it on but it just wont show me anything

slim egret
rapid tiger
fleet coral
dense owl
misty wharf
#

It's pretty hard to find AI info for very specific things like that

#

Check the Game AI Pro books' website, there are a lot of different topics covered in those and you can get them for free

#

Probably not that specific thing though, but maybe there is some topic which is at least a bit related and can give you some ideas

#

In general, I would suggest trying to keep your AI systems as straightforward as possible if you're unsure. If you keep them like that, it won't be a big problem if you need to change them to work in a different way later

#

You can also take steps to insulate your other non-AI systems from being affected by changes in the AI systems themselves, eg. via information hiding, delegates, etc., again to limit the impact of changing the AI systems later

fleet coral
#

Yeah, it's quite a journey =\

timber pecan
#

What would be the best way for an AI to detect a body of water? I'm working with an ecosystem system where the AI can already feed itself when it feels hungry, but I'm a bit confused about how to deal with the part of the AI going to a pond to drink, unlike plants, the AI should only go to the edge of the water to drink, and not enter it, since it should only enter to swim, I wanted to make a way for the AI to detect where the edge of the body of water is on the terrain and then start drinking.

unborn sphinx
#

Should BTservices (BP) strive to use only BB Keys for caching values, etc, or can a variable on the service be used to cache values reliably?

#

as in, can a cached value set to a variable on the BTS bp survive to the next tick?

uneven cloud
uneven cloud
timber pecan
#

Considerind this i don't really know how good a smart object coudl work for this

#

since the border of the water body will vary with the terrain

uneven cloud
#

You can use smart objects with procedural generation. The smart object is spawned with the generation to give a general location and then while walking to the water, do a few ray casts to find the water's edge.

unborn sphinx
uneven cloud
timber pecan
unborn sphinx
uneven cloud
timber pecan
#

So in summary, raycating down in front of the AI to detect it as soon as it's in front of the water

uneven cloud
#

Yes

misty wharf
#

fwiw, you could also generate some kind of markers along the edge of the water and you choose one of them to walk to

#

But I think the raycasting method is going to be entirely fine and likely simpler to implement

unborn sphinx
#

Is this the correcy way to get results from an EQSQuery?

#

I don't know why I'm binding to the event someone said it had to be done...

#

That is on a BTService

uneven cloud
unborn sphinx
#

I don't know. I'm making this as a service that randomly injects a different movegoal and also randomly sets focus on random actors, on tick. I suppose I could run the EQS separately, but it only happens if a probability is achieved in a random bool...

#

I don't want to constantly run the eqs on tick unless the bool triggers true, which could be a ten percent or less chance each tick

#

stupid? yes. ugh

fathom ridge
#

Hey I'm trying to have 2 nav meshes in the same scene for actors of different sizes. Also because I have an fish and birds that steer into the correct direction, and so need some extra space to keep them from slipping off the nav mesh.

Does anyone have any good tutorials that go in depth on how to do this?

Also if I click this button the whole engine crashes. It doesnt matter which version of unreal or project.

#

I'm at a loss on how to get these nav meshes working right.

lyric flint
#

I am trying to make my ai vehicle slow down when turning.

Turning is a float from -1 to 1, when the turning value is nearly equal to 0 I would like to increase throttle input value by a relevant amount, and when closer to -1 or 1 I would like to reduce throttle value by relevant amount.

Using floats in blueprints how could I do that?

uneven cloud
fathom ridge
#

ok this is weird went into a backup of my project and its all suddenly working

inner zephyr
#

How would you implement SmartObjects considering optimization?
In my example there are 2 floors, when I am on the 1. floor the 2. one is , with it's SmartObjects, not loaded (LevelStreaming).

#

My idea is now to keep the BPs with the SmartObject inside the persistant level and maybe use the significance manager to turn most things off in order for the AI to still be able to interact with it. Not sure if that's the way to go though

celest python
#

I didnt use it but I'd go with however citysample went with

#

in the end its used on scale there in a huge city

primal pebble
forest tundra
#

ue5 ai debug does not open

#

despite trying all the necessary key combinations

misty wharf
#

by "ai debug" what exactly are you referring to?

#

if you mean the gameplay debugger, eg. the one which overlays a bunch of text on top of the viewport - for it to work, you need to be in PIE and you must be possessing something, so if you detach from the player pawn, it won't work

#

you can also change the shortcut key to enable it from somewhere in options which might be worth a try because on non-US keyboard layouts the shortcut might be a bit weird iirc

sacred kiln
#

we've had issues with the EQS debugger not opening on a non US keyboard in 5.2.1

plush cargo
#

I need to demystify AI somewhat.
This relates to StateTree but perhaps UE AI in general.

When i am designing an action as an instruction by name
For example Attack. Relative to StateTree, where would this instruction be designed? With the ST or with the character or AI controller?

plush cargo
#

I can also ask it like this.
However the instruction Attack is componsed.
For each sub instruction (walk to target, charge weapon swing, release weapon swing)
Would these be hierarchies in the state tree? Or would attack simply be one leaf state and there be stepping through sub actions of attack?

lyric flint
#

Anyone knows why the node Get Current Acceleration (AnimBP) don't works on AI?

plush cargo
#

not animbp

fathom ridge
# plush cargo I need to demystify AI somewhat. This relates to StateTree but perhaps UE AI in...

https://www.youtube.com/watch?v=iY1jnFvHgbE
This video was really helpful for me on my first ai

In this presentation, Epic's Paulo Souza uses Unreal Engine's built-in AI features to build smart enemy behaviors for a game with stealth-like mechanics.

By relying on the Gameplay Framework in Unreal, we're able to quickly create convincing AI using Behavior Trees. Behavior Trees are great for creating complex AI that can be presented in a way...

โ–ถ Play video
plush cargo
#

i have previously looked at this and most AI solutions appear as if every action is broken down to their states.
state: running
state: running+attacking

fathom ridge
#

Theres a node in the behavior tree to run actions in paralell. That attack node should run based on the condition of how close it is to its target

plush cargo
#

what is the driver

#

the collection of instructions or the action by name.

ocean plover
#

Hi..

I'm using the Easy AI Utility Plugin.. And it works really well and fits my Flow..

Now i strugfle with a small thing, that seems to be a Problem of the "AI MoveTo" Node of Unreal..

On my Screenshot is the Task i created to make the NPC move to the last Known Location of the Player.

What i struggle with is the Thing, that "Aborted", is printed out many times.. And in the same time, the Last Location Value gets set to 0,0,0.. Which only should happen on Success.. (And yes.. The FinishThis is the absolutely only place, the LastLocation Value gets set to 0,0,0 in the whole Project)

And this makes the AI move to the World Center instead..

I'm a bit confused about that.. And maybe someone here knows, why this happens...

misty wharf
#

Woah since when does this exist

#

I had some kludge for this which converted the tag into FName and back again because it didn't use to exist :P

#

Although confusingly enough, it uses a Gameplay Tag Container as the Value instead of a Gameplay Tag...

celest python
misty wharf
#

Huh? lol

celest python
#

tech debt over tech debt

#

solves one problem introduces another UX issue

misty wharf
#

No idea tbh. A container can contain multiple tags so I have no idea what their thinking was with this :D

#
BlackboardComp->SetValue<UBlackboardKeyType_GameplayTag>(KeyID, GameplayTagValue);
#

GameplayTagValue is of type FGameplayTagContainer... I wonder what this actually does...

#

Hm, it does actually somehow keep a gameplay tag container in there?... okay...

#

So it seems the "gameplay tag" BB type is infact... a gameplay tag container

fathom ridge
#

Is it possible to have this node use a seperate navi mesh to the main pawn? I'm trying to have it path so that it gives itself some leeway

misty wharf
#

If you make the context object your AI controller, I think it should use its navigation settings such as agent settings etc.

#

So if it uses an agent which uses diffferent navmesh settings that oughta do it

#

But beyond that no - if you need to have more control over it, you would probably need to drop to C++ where you have more control over how the navigation query is done

dense owl
ocean plover
dense owl
#

So you know youโ€™re not telling your AI to move to an invalid location

ocean plover
#

Itยดs just strange that the Stimulus Location, that sets the Last Location on Prediction.. is not reachable..

ocean plover
fathom ridge
#

Ok so since having a lot of control over what aspects of a pawn access which nav mesh is a pain without c++

Whats the easiest way to make a pawn try and keep distance from obstacles when pathfinding? In other words how do I keep a pawn from walking right along the edge of its nav mesh?

lyric flint
#

There is some way to see when is executed each service?

#

Because I can see the graph in action but I want to see how much gets to update...

dense owl
#

The point is to test with something other than 0,0,0

ocean plover
dense owl
ocean plover
#

The Location gets set in the Prediction sense Function of the AI Controller

#

and read back when the Investigation Tasks fires..

dense owl
#

I see

ocean plover
#

the Locatio is correct.. until the AIMoveTogets aborted...

#

but on Aborted, i donยดt reset the location to 0,0,0

so.. there is something strange..

dense owl
#

Pawn Sensing was replaced by AI Perception btw. Iโ€™m not sure why youโ€™re using these keys instead of just normal values but who am I to judge?

#

Try using the Visual Logger next

#

It should shed some light as to why your move is aborting

ocean plover
dense owl
#

You donโ€™t need a blackboard but yeah I havenโ€™t used that plugin

#

Debug using Tools -> Debug -> Visual Logger

timber pecan
#

How do I make an AI move to a place that the navmesh hasn't loaded yet? I'm using a dynamic navmesh generated by the AI's actor to save loading time for generating the navmesh of the whole world, but I'm having trouble because this makes it restrict itself to objects that are within that area

uneven cloud
ocean plover
dense owl
#

I didnโ€™t say anything about prediction

ocean plover
dense owl
#

I know, thatโ€™s why I said that ๐Ÿ™‚

uneven cloud
plush cargo
uneven cloud
plush cargo
ocean plover
#

i really canยดt figure out what the logger is printing to me here >_<

plush cargo
#

I have a hard time working with both ST and BT by constructing executive decisions

#

i mean reaching the level of state vs action controll

uneven cloud
plush cargo
#

gotta read theabout GAS quick

uneven cloud
#

GAS = gameplay ability system

plush cargo
#

i have some shallow knowledge about it.

#

never had relevance until now ๐Ÿ™‚

#

a quick look tells me that GAS might be what im asking for in terms of executive functions by name

uneven cloud
#

I use GAS, because it handles animation replication. We also use it for the player, because of the prediction functionality.

#

Also because we don't want to write our own ability system when there is already one available.

plush cargo
#

i see

#

im not so versed in all that UE offers so i usually design from a blank actor

#

@uneven cloud is GAS the system that was only in c++ ?

#

it looks to me that isnt the case now. still reading

ocean plover
plush cargo
#

thanks

#

great info

uneven cloud
plush cargo
#

rihgt

#

with BT and ST i never got past the point of doing move to and attack outside their basic introduction.

#

moving to target and attacking always felt a bit flimsy

dense owl
ocean plover
#

I think before that.. i start this all over and try to be more precise in the States and their Tasks.. maybe i need to doublecheck the locations and void overwriting of older ones... maybe.. many maybes..

#

Since my head is melting.. I think i'll go to bed now and start a new try tomorrow ๐Ÿ˜…

plush cargo
uneven cloud
uneven cloud
plush cargo
#

the one i would guess! but thanks for confirming

#

"Blueprint Friendly, no need to dive into the cpp side, you can implement Abilities right away"

timber pecan
dense owl
#

Youโ€™re invoking nav mesh generation on your actual AI ? @timber pecan

uneven cloud
# timber pecan Just bringing it up again because it's too high

You can't make it navigate if there is no nav mesh. You can make it move there, but it won't be able to avoid obstacles without some kind of a navigation solution.

I do not recommend putting invokers on moving actors. Invokers are incredibly expensive, specifically the most expensive navigation option, and it's made a lot worse to have them move.

lyric flint
uneven cloud
plush cargo
#

@uneven cloud
since you are on the topic. Would you recommend invokers for proc gen maps?

lyric flint
#

Because this object is not updating the perception, and as I see the sphere is on the chest of character

uneven cloud
plush cargo
uneven cloud
lyric flint
timber pecan
uneven cloud
timber pecan
timber pecan
#

My biggest problem is that I have to rely on the classics of base building survival, the navmesh needs to be dynamic and not take too long to update as the world is constantly changing.

dense owl
upper terrace
uneven cloud
timber pecan
#

I don't know if this is a common occurrence in projects made in 4 after being moved to 5

fathom ridge
fathom ridge
uneven cloud
fathom ridge
uneven cloud
fathom ridge
#

Well I increased the agent radius and it was constantly getting stuck.

uneven cloud
#

You don't have it avoid edges. You make the edges valid. If it's still getting stuck then you need to adjust it more.

fathom ridge
#

Ok that works with characters that turn in place like normal but here it takes time to turn. I dont know how to keep it from slipping off those edges than. I tried them at near zero and way higher. (the dot is its goal

obtuse igloo
#

Anyone know if theres a good tutorial out there or have advice on flying AI? I'm trying to make some birds~

uneven cloud
fathom ridge
#

I'll record it with the extra room. The issue is it gets stuck still just farther away from the walls. I'll record another video to show what I mean

fathom ridge
inner zephyr
upper terrace
uneven cloud
fathom ridge
fathom ridge
#

and this is how it chases its target

fathom ridge
upper terrace
#

not working well with ship

fathom ridge
upper terrace
#

Ai move to node only work well with ai characters

fathom ridge
#

Its getting there. Once I have this issue fixed its gonna be awesome.

fathom ridge
upper terrace
#

In first I wanted an ai character to control the ship. But later I realize that is a too complex task

fathom ridge
#

I still think your solution is going to be a combination of 'get look at rotation' combined rinterp to. But I'm really novice

upper terrace
#

I used that in this video logic. When ai ship get 3000 meter away from enemy ship it rotate like this

#

But i want something like when the ai ship and enemy ship is are too far and then ai ship make it rotation towards the enemy ship and then move towards it

lunar niche
#

Quick question: Would I place a bool that stores true/false of a npc attacking in the npc class, ai controller, or blackboard component or it doesn't really matter?

fathom ridge
#

I'd do it in a blackboard struct.

midnight hornet
#

I'm interested in creating a project to emulate pikmins gameplay. I was attempting at first to have some primitive characters follow behind a player character using behavior trees to dictate their behavior, but they all favor moving individually as opposed to a group formation. I did some googling and found some people talking about a crowd simulation. Would this be a good fit for what I'm trying to achieve?

Does anyone have any suggestions (either for the crowd manager or otherwise) for where I can look into creating a system to manage 100 or so pawns individually and/or as a group?

hasty lake
#

hey people i have a very basic issue on eqs. ive been searching but could not solve yet.
i want to find "the closest enemy that i can pathfind to"
the system seems to detect it, but the scoring is bad. im missing something but not sure what.

dusky lodge
#

Is there a Delegate thats exposed for when the NavMesh is rebuilt in editor?

#

I want an Actor to run something when that happens.

hasty lake
dusky lodge
#

Thanks ill take a look

dusky lodge
hasty lake
dusky lodge
#

What Id really prefer is a World delegate or something

celest python
#

there isnt that I know

slow sphinx
#

Say in that course 'Learning Agents - Getting Started' after you start the training, isn't the vehicles only supposed to reset if they go off the track?

Because on mine it is reseting from what seems like the same distance in any given direction even if it's running straight down the track.

#

As far as I can tell so far, I haven't done anything wrong but it's possible I might have misunderstood something in relation to setting up the Spline for them to follow

hasty lake
#

is there a way to chain an eqs node ? eg "get actors of class" and then from the best spawn a grid?

unborn sphinx
#

BTService Event Deactivation: is it called every time the tree re-evaluates? So if it is on a selector, and the first task of the selector keeps firing, passing, and then the tree re-evaluating, is deactivate called every time if there is a service on the selector?

dusky lodge
#

@celest python @hasty lake Ive decided to utilize FEditorBuildUtils::RegisterCustomBuildType

#

Which will trigger after a "Build All" is done.

#

Since I cant find any other reasonable delegate to subscribe to

slow sphinx
#

I'm running it again from where I left off though and it seems to be doing fine

#

They are slowly figuring out how to turn corners

unborn sphinx
#

ok implemented this BT from start to finish now let's see if it works lmao

ashen trail
#

Hey, for VR I'd like to have a player navmesh and an AI navmesh.
Since I can't find any info about this online, I setup two different agent types under Project Settings -> Navigation System.
Should I now somehow create two navmesh area classes and set their supported agent types? Then just put nav mesh modifiers with those classes to demarcate player vs AI areas for navigation? Thanks

dire fable
#

Hi, why, in a BT, at the start, the cooldown is returning "fail" directly ?

#

if I remove the composite node, it works

#

in the first case, i have to wait 10s before the burrow task is executed

#

in the second case, the task executes immediately then waits 10s before executing again

dire fable
#

nobody ?

tough tulip
#

Would anyone happen to know why the nav mesh isn't covering this tiny bit of landscape? It is by no means more steep than other bits of the landscape, nor is it blocked by anything

forest tundra
#
UT_EmptyTargetLocation::UT_EmptyTargetLocation(FObjectInitializer const& ObjectInitializer) : UBTTask_BlackboardBase{ObjectInitializer}
{
    NodeName = "Empty Target Location";
}

EBTNodeResult::Type UT_EmptyTargetLocation::ExecuteTask(UBehaviorTreeComponent& OwnerComp, uint8* NodeMemory)
{
    if (auto* const Cont = Cast<AAIC_PM>(OwnerComp.GetAIOwner()))
    {
        if (auto* const NPC =  Cast<APM_AI>(Cont->GetPawn()))
        {

            TArray<AActor*> Computers;
            UGameplayStatics::GetAllActorsOfClass(GetWorld(),ACS_Computer_1::StaticClass(),Computers);
            for (auto ComputerFinder : Computers)
            {
                ACS_Computer_1* Computer = static_cast<ACS_Computer_1*>(ComputerFinder);
                if (Computer)
                {
                    if(Computer->Status == ACS_1::Empty)
                    {
                        Computer->Status = ACS_Computer_1::Full;
                        GEngine->AddOnScreenDebugMessage(-1, 3, FColor::Red,TEXT("32"));
                        FVector TargetLocation = Computer->Chair_1->GetComponentLocation();
                        OwnerComp.GetBlackboardComponent()->SetValueAsVector(GetSelectedBlackboardKey(),TargetLocation);
                        OwnerComp.GetBlackboardComponent()->SetValueAsBool("SitSearch",false);
                        FinishLatentTask(OwnerComp,EBTNodeResult::Succeeded);
                        return EBTNodeResult::Succeeded;
                    }
                    else 
                    {
                        OwnerComp.GetBlackboardComponent()->SetValueAsBool("SitSearch",true);
                    }
                }
            }

            FinishLatentTask(OwnerComp,EBTNodeResult::Succeeded);
            return EBTNodeResult::Succeeded;
            
        }
    }
    return EBTNodeResult::Failed;
}
#

I wanted to check if there was a seat the player found and fill the empty computers.

#

and I tried to make a system for NPCs to move around randomly if they cannot find a computer, that is, if all the seats are occupied.

#

but

#

"OwnerComp.GetBlackboardComponent()->SetValueAsBool("SitSearch",true);"
this code here enables random location

#

characters only start travelling randomly

#

If I delete that code, they don't browse randomly at all.

#

I only want random navigation if there are no seats occupied

#

Anybody got any ideas?

dense owl
forest tundra
# dense owl You could run a service that checks if any seats are occupied.
for (auto ComputerFinder : Computers)
            {
                ACS_Computer_1* Computer = static_cast<ACS_Computer_1*>(ComputerFinder);
                if (Computer)
                {
                    if(Computer->Status == ACS_1::Empty)
                    {
                        Computer->Status = ACS_Computer_1::Full;
                        GEngine->AddOnScreenDebugMessage(-1, 3, FColor::Red,TEXT("32"));
                        FVector TargetLocation = Computer->Chair_1->GetComponentLocation();
                        OwnerComp.GetBlackboardComponent()->SetValueAsVector(GetSelectedBlackboardKey(),TargetLocation);
                        OwnerComp.GetBlackboardComponent()->SetValueAsBool("SitSearch",false);
                        FinishLatentTask(OwnerComp,EBTNodeResult::Succeeded);
                        return EBTNodeResult::Succeeded;
                    }
                    else 
                    {
                        OwnerComp.GetBlackboardComponent()->SetValueAsBool("SitSearch",true);
                    }
                }
            }```
#

this Shouldn't he be checking it out anyway?

dense owl
#

Idk how often youโ€™re running that

#

And if you debugged to make sure it works

forest tundra
tough tulip
# dense owl Try widening it on the Z axis

Yea I tried that earlier, with no success though. I reckon it has something to do with the nav mesh resolution in the project settings and how it is being mapped onto the landscape. Something to look into at a later time when it becomes a bigger issue ๐Ÿ˜„ Thanks for the help though

#

Different question; The move to location or actor node has an async task reference output. Could I use this reference to, at a later time, cancel this specific move to node?

warped barn
#

Where can I read up, what invalidates a nav mesh tile? I would be fine too if you could point me to some cpp code if the answer is long

misty wharf
#

They're somewhere in the recast related classes

#

FRecastTileGenerator, FRecastNavMeshGenerator and such

unborn sphinx
unborn sphinx
#

I suppose I could search the project/engine for "OnEventDeactivationAI"

#

hmm no that's not it

#

ok si it is OnCeaseRelevant. so I will see what ceases relevant

#

ooorrr

#

u could just tell me ๐Ÿ™‚

#

It just says "service became inactive" as a comment, and it is hard to drill down farther into how or why those specific methods are called

#

is it inactive when it is decided not to execute it anymore? or is it inactive for any brief moment when the BT is cycling and not actively executing the node with the service?

dense owl
#

I havenโ€™t tried this, but can you set breakpoints on the source code?

unborn sphinx
#

Sadly with breakpoints, at least in VS community edition, u can't go backwards lmao

#

I think in the paid ersion you can step backwards :\

#

The thing with UE source is that often, the trail is broken. It is hard to tell where or how a specific function is called lmao because somehow it is not called explicitly by name?

#

or it is just called by some obscure base class we don't know about?

#

like this little guy

#

๐Ÿ˜ญ

#

in my short experience, the ReceiveActivation does not seem to get activated each time the tree cycles... but I could be wrong about that

#

"cycles" lmao wrong term

dense owl
unborn sphinx
#

I am not sure of it though I will have to verify just finishing up some things before I can set up a pure test where I can be sure of what I am seeing

slow sphinx
#

Alright, so I'm following this guide 'Learning Agents - Getting Started' and it's saying it should be trained in 2 hours and it's saying also that the 'Average Reward' and 'Average Return' should increase over time.....but on mine they are decreasing further into the Negative with each iteration and I double checked to make sure I didn't miss anything, going back through the entire guide a second time.....

Anyone have a clue as to what's going on and why my Average Scores would be going further and further into the negative? Is it possible I'm looking at this wrong and a Higher Negative is actually a good thing? LOL

https://dev.epicgames.com/community/learning/courses/M3D/unreal-engine-learning-agents-getting-started/qj2O/unreal-engine-learning-to-drive

#

I swear I followed the guide to the T, I made sure everything was done just like the guide said. This is why I like videos though, it's easier I think to not overlook something when you can watch them do it

#

It may be working this time...idk for sure but I ran it twice last night with really bad results and errors at the end something to do with Training Failed

fathom ridge
tough tulip
unborn sphinx
#

It should work just fine as is. As long as there is a green mesh under those occluded regions.

#

I think deactivation might actually execute every single time the tree evaluates ๐Ÿ˜

#

yeah this tree is MESSED lmao dammnit me and my assumptions

hasty lake
#

how do i add a gameplaytag to a character so that it works with behaviours and EQS? it seems to me that characters don't have a member or attribute to set them

dense owl
polar inlet
#

cant getpawn() in ai controller

#

been having this problem for days... ive tried a lot

ivory rune
#

Because the pawn and the controller is not spawning by sequence, so it will be a problem you try to get a pawn at the beginning of the controller is spawned.

polar inlet
#

onpossesed wont let me access my blackboard though. it says my blackboard key is invalid

#

when in onpossessed that is

ivory rune
polar inlet
#

i think its a timing thing with the blackboard

ivory rune
#

It is the same. Because you need to RunBehaviorTree, maybe just put the whole block of your running behavior tree to onpossesed?

polar inlet
#

ill try that

polar inlet
#

that worked

#

thanks!

tough tulip
#

When determining where to store information, is there a best practice? For example, if I want to keep track of how many resources my worker AI has collected, would it be better to save this in the AIController, or in the pawn itself?

ivory rune
tough tulip
# ivory rune Do you have any idea for more detail of your information?

Not sure if I understand what you mean. But if I want to track how much wood my AI has collected over time. Would it be better to save this in the AIController, or would it be better practice to save this in the AI pawn. Just want to avoid having to refactor the system later down the line ๐Ÿ™‚

ivory rune
tough tulip
patent patrol
#

Hi! I have a question on combat. How do you deal with alerting the AI that the player or other AI is attacking them ? This is so they can dodge or do something else. I'm thinking tracing from the weapon during the animation but not sure

misty wharf
#

It can be done in many different ways depending on how you want it to work

#

If you need it to detect when someone else is attacking and before the actual damage has applied, then yeah you could trace from the weapon and use that to alert the target, or some other method of testing what the target might be

astral sinew
#

Hello. I am currently trying to run an EQSQuery off a component. I have went into simulate and enabled AI Debug Tools->EQS but it says that there are no queries running (and I also can't see any results.) However in the query's profiler window it shows the correct amount of executions. This is my current setup:

#

I have also tried adding tests that only scored results but it changed nothing.

fathom sun
#

Hello, I'm trying to make my AI move properly in the navmesh, however I have some problems. I have many AI character that should get to a point, however since there are many characters the ones that are behind always stay there, even after the characters in front reach the goal. I would like the AI to try to walk around others when they cannot walk any further, because other character are blocking them. Can someone help me with that? What would I need to do to achieve that?

#

On the picture there are 3 character that are always stuck behind others, and are trying to walk towards them with no success

dense owl
#

You can try using either (not both) RVO or the DetourCrowd AI Controller

fathom sun
#

I'm trying to use RVO with 250 consideration radius, but it doesn't seem to work properly ๐Ÿ˜ฆ I've tried to use lower radius values, still no success

#

I'll try to use detour if it's the only option left

dense owl
#

Turn off RVO when you do

fathom sun
#

Sure

unborn sphinx
#

That could possibly be related to the controller/pawn rotation speed. Set your CMC rotation speed on the Z axis to something like 360-720, and ensure on the pawn, the setting to use controller yaw is NOT checked.

#

And instead check the setting on the CMC to use rotation i forget what it is called

fathom sun
#

The thing is that it's already the case. Rotation rate Z is set to 720, and they're using Orient Rotation to Movement only

unborn sphinx
#

u must ensure the pawn setting is unchecked or it doesn't work

fathom sun
unborn sphinx
#

this looks like lyra. I am familiar lmao

fathom sun
unborn sphinx
#

go to the character BP

#

on the pawn there is a setting with the word yaw and controller

#

disable it

fathom sun
unborn sphinx
#

720 is also quite fast I use 360

#

oh right

#

SORRY

#

lmao

fathom sun
fathom sun
unborn sphinx
#

they aren't usually right beside each other I didn't realize u filtered the page lmao

fathom sun
#

Yeap ๐Ÿ˜›

unborn sphinx
#

is there anything else setting focus or anything on it?

fathom sun
unborn sphinx
#

hmm yeah but there does seem to be something weird in the way they are focusing on things

#

I get that when the character goes from focus to clear focus

fathom sun
#

They essentially walk towards the box that is the most distant relatively to them

unborn sphinx
#

they snap back to their movement orientation

fathom sun
#

wdym? Once they finish walking, the don't do anything

unborn sphinx
#

not movement orientation I guess

#

Like when my bots are "SetFocus" on something, they watch them and turn smoothly

fathom sun
#

Oh, I don't have any focus

unborn sphinx
#

but then when the ClearFocus is used, they snap right to the normal controller orientation

#

hmmm ok

#

how are you commanding the move to?

#

is it to an actor?

fathom sun
#

I have a BT that determines the farthest cube, and all it does is move to towards the cube actor

unborn sphinx
#

yeah that causes them to set focus on the actor

#

use the cube location as a vector instead

#

they won't look at it

fathom sun
#

kk

unborn sphinx
#

like maybe use an eqs to find any cube actors and add them as movegoal

#

then it will be a vector

#

if movegoal is a vector, that is...

fathom sun
unborn sphinx
#

LMAO

#

wat happened to that one guy

fathom sun
#

It's funny sad how they fly away

#

Pushed too hard ๐Ÿ˜ฆ

unborn sphinx
#

it looks like you have things fighting over the focus/rotation

#

it might be related to rvo, try disabling it, but I think it is a symptom of another problem that is highlighted by RVO maybe

fathom sun
#

The log btw looks like that

LogCharacterMovement: Foe_Fishman_C_11 is stuck and failed to move! Velocity: X=-29.67 Y=-26.82 Z=0.00 Location: X=1771.20 Y=571.74 Z=120.60 Normal: X=-0.96 Y=-0.08 Z=0.28 PenetrationDepth:5.288 Actor:Foe_Fishman_C_14 Component:CharacterMesh0 BoneName:fishman_index01Left (31 other events since notify)
LogCharacterMovement: Foe_Fishman_C_5 is stuck and failed to move! Velocity: X=39.99 Y=0.63 Z=0.00 Location: X=3356.86 Y=210.14 Z=121.90 Normal: X=0.78 Y=-0.56 Z=0.29 PenetrationDepth:1.552 Actor:Foe_Fishman_C_4 Component:CharacterMesh0 BoneName:fishman_middle01Left (39 other events since notify)
LogCharacterMovement: Foe_Fishman_C_14 is stuck and failed to move! Velocity: X=-57.61 Y=51.47 Z=0.00 Location: X=1903.36 Y=515.99 Z=122.49 Normal: X=0.93 Y=-0.36 Z=0.10 PenetrationDepth:5.707 Actor:Foe_Fishman_C_11 Component:CharacterMesh0 BoneName:fishman_handRight (0 other events since notify)
LogCharacterMovement: Foe_Fishman_C_6 is stuck and failed to move! Velocity: X=38.21 Y=-11.84 Z=0.00 Location: X=3385.01 Y=404.38 Z=120.10 Normal: X=0.66 Y=0.68 Z=-0.31 PenetrationDepth:1.791 Actor:Foe_Fishman_C_4 Component:CharacterMesh0 BoneName:fishman_head (4 other events since notify)
fathom sun
#

With RVO it was worse

unborn sphinx
#

ohhhh

#

I have never used detour but I think it technically uses RVO kinda but yeah

#

I think that is simply highlighting some other issue maybe even something is being triggered in the animation bp

fathom sun
#

wdym? By ABP is essentially one single BS1 with locomotion, like idle, walk and run

#

With no root motion or whatever

unborn sphinx
#

oh ok I don't know in specific, but ABP can take in any value really and do stuff with it. Velocity, acceleration, angle, etc so anything could be messing with that

#

bvut if you have a clean simple one, it won't be the case

fathom sun
#

๐Ÿ˜”

#

I'll try to look for the warning on the forums

#

Perhaps something will come up

#

Sadly, I didn't find anything really. Only a few questions rather than answers ๐Ÿ˜”

tough tulip
#

So the "Move to location or actor" nodes are giving me a headache. Could someone explain to me why this node continues to execute even though a different Move To node has been called? is this because it is being executed on a seperate thread and persists in an order of priority, executing its most recent move to request before finishing the others it had running?

dense owl
tough tulip
dense owl
#

Yes

tough tulip
hard stump
#

after the initial MoveTo completes my AI fully stops before starting the MoveTo node in the simple parallel, what can I do to get around this?

hard stump
#

it seems its intended to be that way, ai stops 100% of the time when move to is finished before starting the next move to seems like i gotta make my own logic for it

unborn sphinx
#

you can change the BB key that the moveto is moving to and it can watch that key for changes in value and update the move

fathom sun
pastel star
#

Hi all, I'm trying to optimize a game to run with 45k pawns at the same time, with 10โ€“20% of them moving at any given time. Is node "AI move to" optimized enough, or do I need to use a BT?

dense owl
#

I donโ€™t think thatโ€™s a consideration

#

The BT MoveTo and the AIMoveTo are virtually the same afaik

wary ivy
#

you need to use mass and forget about pawns

pastel star
dense owl
#

#mass is great but very much still being worked on

#

Theyโ€™ve got the best people on it tho ๐Ÿ˜‰

pastel star
#

Ok, i'll look into it

uneven cloud
unborn sphinx
#

I have previously been using an EQS to find perceived noise locations. I have a need to gather both the actor and the location of the noise (in case of a bullet hit), but I still want to use EQS to choose the best sensed actor based on tests like distance, etc...

How can I set it up so that the EQS selects the most relevant noise location, and also can provide the actor associated with that exact same stimulus?

I can't do it in the custom generator, because I don't know which generated noise location ultimately becomes the chosen one?

#

Is it possible to set the stimulus itself as an object in a BB key? Then just get it when I need it? But wait then that doesn't contain the actor either ugh lmao

#

Should I be making a custom struct to contain both the actor and the location?

ashen trail
#

How to setup different nav meshes for different agents? I want to make some areas traversable by AI and some by player (VR teleport)

  1. Have 2 agent types - 2 nav mesh bounds volumes (each supporting one agent type) - this doesn't seem to work at all and in the editor only one RecastNavMesh is visible, the other won't draw
  2. Have 1 nav mesh with 1 agent type for everything but use filters somehow to divide into "player areas" and "AI areas"?

Thoughts/help please!

unborn sphinx
#

I think I will just immediately abort lower to a HeardActor is set subtree. Then, the first thing I do in that subtree is set the noiselocation from the last sensed noise from the HeardActor. Should catch it in time and be accurate

hasty lake
#

is there a simple way to run an eqs query with a blackboard actor as the origin?
i have an ai, with a blackboard variable for enemy, i want to generate a grid around the enemy, not the ai.

dense owl
#

You need an environment query context

sweet coral
#

may i ask a question here?

hasty lake
hasty lake
sweet coral
#

can i change a key's name in my blackboard after its been created

#

my ai is not detecting my character

dense owl
dense owl
#

Not sure thatโ€™s gonna help you detect the character tho

sweet coral
#

yeah

sweet coral
#

probably not lol

#

my AI isnt chasing but i am not sure why i gotta do some looking around

dense owl
sweet coral
#

im sorry where do i press it

dense owl
#

At runtime

sweet coral
#

at runtime?

dense owl
#

Yeah like when you run the game

sweet coral
#

oh it brings up the consol comd

#

cmd

dense owl
#

Not that key

#

The apostrophe

sweet coral
#

oohhhhh

dense owl
#

Itโ€™ll give you some info like whether or not keys are set properly

#

Ai perception, eqs etc

sweet coral
#

you want to see or something im very new so idk how to say whats wrong yet

#

its not detecting the player with the pawn sensing

dense owl
#

Use AI perception, pawn sensing is ancient stuff

#

Just follow the docs to the letter

#

Especially the affiliation part

#

Also 3rd link pinned here will show you how stuff is done

sweet coral
#

oh boy

#

this is a lot lol

dense owl
#

Take your time with it

#

Once it clicks itโ€™s not that bad

sweet coral
#

so i found out how to crash the game

#

i dont understand how to get the sight setting menue to edit the sight settings

dense owl
sweet coral
dense owl
#

I just said above

sweet coral
#

i only see the basic ones not the ones to change the sight details

#

im sorry im just confused

dense owl
#

Did you add an AIPerceptionComponent to your AI?

sweet coral
#

no

#

wait yes

dense owl
#

Ok, so do that part. And then you want to add a perception stimuli source on the actor you want to detect

#

And you select which kind of source it is

sweet coral
#

im talking about here

dense owl
#

Hit the +

#

By the senses

sweet coral
#

o

dense owl
#

Again the video and the docs go over all of this stuff so you should go through them carefully

sweet coral
#

ty

uneven cloud
sweet coral
#

oh boy

hasty lake
#

is there another way to show the debug ui without a key? my game doesnt capture the mouse and itล› impossible to use a key. ive tried like 5 different hotkeys on the settigs.

frosty pond
#

I'm learning EQS and have a quick question just to validate my approach.

I made a pretty basic AI that runs away from my player and hides, I generate a grid around the AI, do hit tests to the player to pick a point.

I wanted it to be a little better, so that it would get close to the object it's hiding behind. I made a task which takes the winning EQS position, performs another line trace to the player, and updates the new position.

Is it possible to do this entire thing inside EQS, or are we limited by initial generated positions.

tawdry zephyr
#

Question. I've found for most of my AI needs an FSM works really well. What kinds of games would suit BT or FSM and why? My games tend to have AI that is quite simplistic and predictable by design. Do BTs start becoming more useful when AI needs to think a bit more?

ivory rune
tawdry zephyr
#

For my games I often want players to have predictable outcomes
I suppose that's one end of the spectrum, and the other end is fuzzy logic

ivory rune
#

You want to tweaks the combat feelings during developement

celest python
#

BT = Sandbox/fluid environment where you know all posibility on a top-level layer and able to prioritize (half life alyx & stealth games & simulations)
FSM = I want to jump from a node to another arbitrary node (more scripting & more flexibility & DOOM Eternal is a good example - wouldnt want to do that AI in BTs)

#

At 2023 modern game engines combine tools so its never one works and other doesnt

tawdry zephyr
celest python
#

FSM is not feasible btw

#

HFSM is what you need

tawdry zephyr
#

Yeah, that's what I meant, sorry ๐Ÿ˜„

ivory rune
#

There's one plugin for Unreal IIRC

tawdry zephyr
#

I use Logic Driver Pro, its rare to see a marketplace plugin made with such great knowledge/foresight/design

celest python
#

I like doing everything in the graph without carrying things to code classes, so I would like my combat system in LogicDriver

tawdry zephyr
#

The dev is actually amazing

ivory rune
tawdry zephyr
#

Unrelated to AI but I was even able to make a GAS based melee combo system while using it just for designing the combos and link detection

celest python
#

even if its so simple

#

I'd need more flexibility, so either my own C++ system or HFSM

ivory rune
#

That's a typical user case

celest python
#

problem with UE AI is its BT is designed to let you do things in BTTasks, so you dont use tasks as blocks to construct the behavior but encapsulate things inside of it. this cost a lot of flexibility when doing something other than paragon bot AI

#

meanwhile you're suppose to use BT and FSM graphs as scripting layers

ivory rune
celest python
#

If you used Kythera you must have seen tasks are more like functions in the BT graph

#

LogicDriver is also able to provide same design if you build your SMTasks with this mindset

#

but BT graph is designed badly

#

it limits us to blackboard selectors, AIControllers and blackboard component

tawdry zephyr
#

I notice almost all gameplay dev jobs that involve AI are advertised with the need for knowledge of BTs
But I suspect that's because its what UE offers and not because its the best job
As it stands I've yet to make a game that requires BTs and tend to roll my own solutions that are better suited
Maybe I should stop avoiding those roles and just ask what their reason for BT is (or maybe I should just make a game using them already, lol)

ivory rune
celest python
#

not impossible but why would you do it without writing editor customizations

#

solves some of the issues of UX

celest python
#

but I also intentionally dont work with big companies to work short term

ivory rune
celest python
#

so you can edit and bind variables through upper layer

ivory rune
#

Actually, if you are using GAS, it solves a lot of these costs

#

Anyway, I like how the way BTs fallback rather than FSM, since you don't need to assign a specific state for it which sometimes is confusing or very difficult to tell in runtime. (Maybe you need to set a very complicated conditions to tell which state the AI should jump to though)

fathom sun
#

@pine steeple Hey, I remember that you're making a game about zombies, and I'm wondering how you handle their movement (I suppose that there is a lot of them) so that they don't get stuck. Do you mind sharing it? ๐Ÿ˜„

celest python
#

and significance manager to set tick rates

fathom sun
#

Custom checks on CMC? For instance?

#

And what's a significance manager?

celest python
#

tl;dr checking if AI is stuck, which means navwalking is not possible since its not on navmesh

#

then raycast closest edge on navmesh

#

and move AI to there

celest python
#

behavior LODding

fathom sun
#

Oh, I see