#blueprint
1 messages · Page 354 of 1
Do you have a use reverse as brake ?
And this print string shows 1.0 and 0.0 ?
How to attach actor to a component but with some offset ?
I mean I want to attach an actor to my Character's Socket but a little bit forward
Why not just move the socket or make a new one
Because I want to change this offset according to the actor but with the same socket
Can I Set Actor Location after attaching Actor to Component ?
Set Actor Relative Location I guess?
It acts weird
I take Actor Forward Vector and set it to "Actor Relative Location"
uh
what
If you wanna set it in front of a socket you have to get the socket location, add the offset you want on the axis that's forwward, and then put that into the set actor relative rotation
How to know the axis that's forward ?
Use the viewport, generally it's the x axis
It did not work
Ok it did work but not what I want exactly
I guess I have a problem with my animation the socket is moving during
Well yeah sockets are attached to bones so they move with the bones
was looking for local co-op
Hey I'm making an anomaly game like " Spot the difference" game and am having a little trouble, I have two actors, one is an item master bp, and has exposed variables like transform, audio, animation etc, and inside that are a couple functions, one of them basically uses an enumeration filled with anaomly types like change size, change animation, etc, and then uses a switch tomake those happen like setting size, or setting animation, then I have a variable set called anomaly active. I have a second Actor that is a trigger, and what this trigger should do, is check for all the actors that are child classes of the master object bp, and select a certain amount of them to activate them as anomalies, with in the trigger system, I can manually check an anomaly actor as the anomaly being active and the print strings I've set up in the trigger/loop manager will detect them as anomalies, but I can't get it to pick an amount of actors, and activate them through the trigger/loop as I need them to. Does anyone have experience making a system like this that could offer some guidance?
It's just how ALS works. I ended up vibe coding "spawn system on held object" to fix the issue
I see two issues. Or three actually.
First - the only place you set the AnomalyActive bool is at the end of the MakeAnomaly function. But you use it at the beginning of the same function to block it's execution? Meaning it will never run, unless you set it to true somewhere outside of the provided screenshots?
Seecond - double Foreach on the same Array AnomalyObjects? What is this for? I would understand one foreach, to cycle through and decide what to do with the anomalies, but I don't see why you have two of them nested, iterating on the same array? And the check for contains seems unnecessary since you are iterating on it
Third - shuffle changes the order of elements in place. But you have it inside a loop that iterates on the same array. Which means the elements will change during execution because the ForEach loop cares about indexes only. If you change what is under the indexes, it can mean some elements won't be looped over and some will be looped over more than once.
Dang man, Yep as soon as I addressed those issues, Anomalies starting activating, you're a legend
I was curious, if you could give some advice on something else, basically I have some code that should make the first pass through the trigger make nothing happens so the player can do a full loop around the level and memorize things, then when they pass through the trigger again that's when anomalies start spawning. It happens in the anomaly object master and basically sets all the variables to their defaults, and is called on begin play, then it's called near the front of the start room trigger, but the first time I go through the trigger it spawns anomalies.
Simple: In the manager add a variable int starting at 0, increment it after the cast to character, then do a branch and proceed to foreach only when the variable is bigger than 1 (meaning, the overlap with the player happened at least twice)
Better: Place another trigger at a place the player is supposed to reach before anomalies are allowed to spawn (like near the exit) - and when this trigger overlaps with the player, call an event on the loop manager to allow creating anomalies - either by setting some bool variable that you will use after the cast to character, or by opening a gate that you can place after the cast
I do have two triggers currently, the start trigger in one doorway and the end trigger in another after walking the whole loop, when they pass through the end trigger it's meant to reset everything to the default values, (using the record original state function) basically clearing all the anomalies and increments the loop count
You could reuse it then. if(AnomaliesExist) Reset; else LoopManager.EnableAnomalySpawning;
If there are no anomalies, it will assume it is the start of the game and enable creating them on the loop manager instead
Oh wait, you probably want states where no anomalies were generated at all. Then you will need a separate variable to track it instead
Yeah I want to have loops where no anomalies happen
So should I still make that variable and code in the start trigger?
Something like this, it is a rough sketch.
But I don't know if this will be enough, you may need some more edge case guards - like disabling the exit trigger until the LoopManager is triggered again, so the player hitting the exit trigger twice doesn't break anything.
Ok I think I got that figured now, the first loop through doesn't spawn any anomalies, then on the next loop it does, I think I only have a couple things I need some advice on if you're willing to help
play your own game and investigate the anomalies in your BP code 
Yeah coding isn't really my strong point, I'm more of an environment, simple code, and sound design guy.
I'm at work already so can't help now. And yeah, it is fine to ask about problems or suggestions but in general you should design your system by yourself first
Show your code and state your problem
i took apk vr and im getting this big rectangle box around the circular teleport indicator
how do i disable it
What site is this? I want to use it too.
To be fair, you can just create an BP object and do some notes in it. (Or even in the intended BP)
In a lot of cases, i'll create functions and place them where i think they'll need to be called before settings up the function.
Sometimes I forget where things are. I also find it really hard to remember what things are used for unless I use them. That's why I use a note system. Right now, I'm using Miro.com. I'm quite happy with it, but there might be something better out there.
What I actually want to do is;
Create an easily accessible library containing all blueprints.
It is Obsidian - it is not strictly for making graphs, but a general use Notes app. It has canvases like the one on my screenshot though. And some other features. I often use it like a semi-design document. And it has plenty of plugins to expand on features you want
It seems more complicated than I thought. Continuing with Miro.
Thanks anyway
I would say Miro looks way more complicated. Obsidian is just a text editor in comparison
I guess we don't see eye to eye on this
Yeah, yours has project management tools. Obsidian is literally a fancy text editor with some visualization components
I love obsidian. I have a few that organize my basic programming bp that I could forget easily and another for just project creation cvara and visual dev.
Miro is great, mine just crashes from time to time because how much stuff I put t here 😄
Struggling a bit with UMG: I have a checkbox and a textblock inside of a horizontal container. Simple enough. When I hover the text or the checkbox, I want the the checkbox to switch to the hovered style and the text to light up. So I wrap them in an invisible button and set the tint of the text on hovered.
But I can't set the hovered state directly on the checkbox. So I replace it with an image and set the brush manually, keeping track of all the states. But now controller support doesn't respect the hovered state. So I connect the onhovered delegate to 'focused' and put my logic there...
This seems like a hellish way to do a seemingly very simple thing. None of this is reusable or modular. What am I doing wrong here?
Unfortunately, controller support throws lots of spanners in the works. However, I would create a specific widget for that behavior.
You'd then setup event dispathers for things like 'OnStateToggled' for other widgets using it to do stuff. The visual aspect would all be handled inside the custom widget.
Anyone have any clue as to why this isnt adding anything to my "actors removed" array ? this is for when an item is deleted -- and 2nd screenshot is the saving in my game mode
Adding self when self is being destroyed sounds pretty dodgy...
are you destroying the actor ?
yeah; it's for when an item is picked up from the world; trying to save the level's added / removed items
What is this conversion ?
Like what datatype
making a soft ref
ah stupid me
Yo guys, help. I'm making a squid game's glass fall. I already made it has a chance to fall when hit. but now I need to make it that only 1 per row has the chance to fall. and not both. Please help me identify which part am I missing or what to add
I'm kinda beginner so I would really aprpeciate if u help me
If you destroy a actor the actor becomes marked as pending kill
So references to it will no longer work
@last peak can u assist me too!!
As soon as the garbage collector eats it it becomes null
https://www.youtube.com/watch?v=97YiDYbbld0&t=1s
5:53
Thats what i was following to get to this point; so it would always come back as [0] basicaly ?
Ye it shouldnt work anymore
You can just store an identifier to the actor like the name in an array then on load instead of using soft references loop trough that array and destroy all actors
Thats how ive been adding/deleting (following the same Tut) it origionaly worked but not sure what ive done to make it null/0
Hey, I got a weird bug, when pressing the Equip Input the first time, the stance and the socket to the hand are not activated, but the animation montage plays, after pressing it again it works every time after the first try, help please 😄 .
Not sure how expandable you want it to be, but if this is simple "one of the three falls" - add 2 more cubes to the actor and treat 3 of them as one actor. Then the actor chooses randomly which cube falls
im like 99% sure it will never work in a packaged game, maybe´if you play in editor sometimes because the actors are not destroyed yet and the soft ref doesnt return null yet
@crimson briar Do you have a idea for his problem ?
I find it odd that laley would post a broken system like this usually his tutorials work pretty well
basicaly was all working when i had seperate save files character/account/level ; i then moved my saves to a "master save" which has the 3 save structs inside it and the system went caput
I didn't want to butt in to not create chaos but I second it - I was taught to not rely on anything from an actor that had Destroy called on it
But... In theory it could work, depending what the array is later used for
Just add a id to your items
A string is enough
Set it for each item
Create a string array in your save game call it destroyed actors
When you pick up a item you get its id and then you add that to the array
On load you loop trough that array for each id you check all actors in your level if id == you destroy the actor
And thats really all you have to do
I have a question, how can we make 1-2 cube as one actor?
will give that a shot; laley has confused me xD Thanks for the back n' forth! would that only work for an individual item though ? What if i had dropped 5 "apples" in different locations ?
Each apple will have a different id
you place apple 1 set its id to 1
Apple 2 with id 2 .......
correct me if im wrong; that would be for set items in the level, not if i were to go into an inventory and "drop" something form there ? unless i set an id on drop ?
If you want to drop a item from your inventory ou have to set its id on drop
I think you need an introduction tutorial into blueprints if you don't know how to add more static mesh components to the actor.
In short - when having the BP opened, on the left you have components. You can copy paste your current cube or click the plus button above it to add other componnets, like a cube or a static mesh in general.
Then you ned to position them in the viewport however you want
For item ID's use a GUID. Easier to work with than having to generate you're own unique strings.
I need to set blueprint logic that will trigger some animation under 2 scenarios
- in editor via keypress (so animation is triggered in Construction script)
- during sequencer playback for a cinematic.
How would you set up yout blueprint logic to accommodate both scenarios?
Hi! complete nooby here! I'm following a tutorial that says to add a node called "get sm_cube" within the firstpersonplayerbp, with sm_cube being a mesh I created earlier. But when i search for the node I can't find it, even though it's there in the video. Anyone any idea? https://youtu.be/v3JXpF4wl_o?t=485
In this tutorial, you'll learn how to create a push and pull objects system in Unreal Engine 5 using Blueprints. Perfect for beginners, we'll cover setting up character blueprints, animation blueprints, trigger boxes, and other necessary calculations to create a functional and responsive push and pull mechanic.
📚 You'll Learn How To:
- Setup...
Player Character BP has variable called BP_Cube as reference to that cube mesh it looks like. Is it that?
Bit of an open ended question for you guys. Im making a spinning fan hazard for my project. Ive got the mesh and everything. Right now im trying to figure out the best way to do the timing and rotation, because I want to spin for a while and then stop to allow the player through and then start again you know
right now ive got it hooked up to a series of timelines and timmers, so it starts, spins for a while and then stops. The issue is it doesnt really blend as well as id like it.
I was thinking about doing it on tick with a timeline controlling the speed instead which might be more consistent.
Or should I say screw it and just give it a single bone and make a couple animations for it
mainly just looking for pointers
Could be? but then why would I need two of them
Hm... Maybe look for another tutorial. I think this one is a bit "outdated". Normally, you should not be storing BP_Cube variable onto your player.
Are you just learning or do you want to do something more with push and pull?
To answer your question, let me ship through that video a bit more.
Its using physics to move cube yes? I think I see that.
I was thinking on having a mechanic where you can push and pull the cubes
I would go in more detail on what the plan for them is but it aint really nessecary
<@&213101288538374145> 👆 spam
https://www.youtube.com/watch?v=7yIbZWElJU4
Check this tutorial also.
Learn how to create push-able objects such as blocks for your game.
In Part 1 we go through the design considerations for a system such as this and get our character pushing and moving the block around.
SUPPORT ME
Patreon I https://www.patreon.com/ryanlaley
Buy Me a Coffee I buymeacoffee.com/RyanLaley
Donations I paypal.me/ryanlaley
PRIVATE 1...
I will, thank you! I'll save the link and watch it tomorrow, it's getting kinda late rn
thank you
Why are you spamming this everywhere?
Prolly a hack/bot
Like what do you think will happen if you do that ? You really think ppl will watch your videos then
Ye could be
But even if its a bot why ? XD
No one will watch the vids
Thats the worst kind of ad you can do
Yo can anyone help me make a killbrick? just a simple if the user touch it, it will stop the whole play?
Mate you need learn some blueprint baics
I would, but can u help me learn this one for now? @last peak
Ppl in here cant teach you the entire engine
I understand, but please enlighten meo n this one rq
on component begin overlap - if other actor == get player character - destroy actor
or just make the cube's collision profile only match the player, there's a "pawn" collision response in there (click box->look for the "collision" category)
u just destroyed.. the actor... What I mean is legit just "STOP"
just this part
(do both actually, it saves on performance & if you have multiple players it'll work fine)
Do you mean "stop playing in PIE" or "alt f4" ?
PIE
basically, I will manually click the play
But if I fell, I touch the kill brick, it will automatically click the red square function
quit game
FINALLY
IT WORKS
I did that earlier
it didn't
thanks man!
@last peak thanks king
your welcome
@last peak did you just know the console cmd by heart or did you find it somewhere ? I actually can't easily find it online, even in https://digilander.libero.it/ZioYuri78/ it's not there
its a node too, i just remembered it but for commands chat gpt is really good
ok, good to know thanks
https://dev.epicgames.com/documentation/en-us/unreal-engine/unreal-engine-console-commands-reference
Is a really good source
lastly, Idk if this is normal but my third person can't move when I pressed W or A but moves well on S and D, if I turn the game override to none, it moves W,A,S,D works properly tho?
quit game isn't even there @.@ I guess it's a special one smh
Any chance it smh works with Z and Q ? Like an AZERTY keyboard ?
Thats almost impossible to tell whats going on without seeing your code
if your using the default character i have no idea it should work out of the box
actually by any chance @last peak do you know if there's an easy way to make the keyboard layout smh detect & change the bindings based on the hardware ? aka if you keyboard is azerty it automatically maps A to be Q and W to be Z ?
Nah no idea sry
Hey I'm back trouble shooting my game haha, I'm having a problem where, I have my end loop trigger for my anomaly game, basically when the player overlaps it, it should reset all the anomaly objects to their recorded defaults, transform, static mesh, animation, things like that. inside my anomaly master object I have a function to do this, I also have a boolean variable called anomaly active, this boolean is true when the game is running, and false by default, on my end loop trigger, I'm calling the function, containing the false boolean after the character overlaps it, but when I F8 to pilot around the scene and go to a bp that was an active anomaly, the Anomaly active boolean is still true and the effect is still active on the object, meaning when I pass the trigger, it's not actually clearing things.
i dont get this
All the setters are 100% useless
Why is that?
you are setting original value to original value
Thats like saying 1 = 1
So should the new values be plugged and not the original ones?
bascially it should be taking whatever the new value is, and re setting it to the original
Would that effect the anomaly active boolean not being set to false again?
When you start you have to save your original values
Location = 1.1.1
now later on if you want to restore your original location you have to do set actor location = original value
Hmm ok, I'll change all that, would that be causing the anomaly active boolean not to tick back to false when overlapping the trigger?
consider reviewing your entire blueprint again
That's currently what I'm doing, trying to fix the problems
it would be better for you to proceed step by step
Right click a node, preferably the first node you execute so your cast here then add a breakpoint
now run your game and you can go step by step trough your code
Ok, it shows a big red chevron over the node when i run the game, I don't really know what to do with that information though, what is this supposed to do exactly?
you can go trough your code with the buttons ontop of your blueprint
so you see whats going on slowly
Hello, I am new to game development. I am attempting to create a spawning system like the one used in Conquerors Blade (ex. interact with building, unit spawns, player has control of unit squad). I got as far as the spawner spawning a desired amount of units from an AI class, although I want to make it correct the first time so that it is modular when adding other units in later and still need to figure out how to assign ownership to the player, and provide data to unit types (found some resources on that part). Any help or pointing me in the right direction to something to learn from would be greatly appreciated!! Here is what my function looks like at the moment.
I'm building a quest HUD. I have a quest panel with a list view, and each entry also has its own list view for the objectives.
When I create a quest entry and add it to the panel's list view, it works fine. But when I try to reference the objective list view, it returns null every time, even though it's part of the widget graph.
I can't seem to figure out why the objective list is null, is this an inherent limitation of nested list views?
Anyone know how to change the mass of a skeletal mesh physics capsule, box, etc. at run time without have to reinitialize physics/velocity?
Edit: nvm figured it out.
can you share more code ?
It fails on the last node, when it has to reference Objective List View.
Note that the widget this graph is part of, is also an element in another list view. I figured it wasn't fully initialized yet or something, but delays don't appear to affect it.
uh just a small question does the brush object ref need to be connected for it to work?
I need some help with 2dScene Capture components. Here i have a mask which i am capturing with a 2dScenecapture and the pink wall is a material with the render target and that render target is occluding a holw which is the same shape as the mask. The issue is that if my mask moves back and forth then the hole either shrinks or grows in size, and this also happens if my player moves closer or further away from the wall. I don't understand why this is happening and it's not perspective, it's really annoying because i am so close to finishing this!! please help i will greatly appreciate it.
Generally you can use that “V” down arrow to select the brush you need. So you technically plug it in that way.
Does someone know if there is an intermediate format for blueprints before bytecode? E.g., a description of the graph / interfaces for the different nodes that are descriptive?
I'm guessing it's via UEdGraph / UedGraphNode. Is there a way of seeing the code for a blueprint represented by these?
copy and paste nodes into a text editor
There is a good article about this on someone's GitHub Pages blog. They took down the blog, but you can still find the article in a Google search and look it up on the Wayback Machine.
Which sounds insane but the article is good. I think you're right though.
Got suggestions of keywords for starting the search?
https://olssondev.github.io/2023-02-13-K2Nodes/
I guess the blog is back up. This is it.
Table of Contents Introduction K2Node and what are they? Make a custom K2Node Populate the node with pins Adding the node’s logic Improving the UX Final touches Wrapping up for now Introduction Note: If you want to expose functions from C++ to Blueprint, this post is way too overkill. You...
This actually shows some declarative serialization of all the selected nodes
Thanks you both
Daaaamn, amazing resource, I've always wondered how k2nodes worked 😮 thanks
saving those 2 as well, thanks ! I don't want to go down the hole now, but I feel like it'll be super useful to know those
They can be.
If running these; one after the other; i seem to be only saving whatever is run last; am i overwriting the whole "character save data / temp char details" for that map ?
Thanks in advance
Looks like it. You always make the final struct from scratch, you never use the data that is already in the variable.
Yes, you are re-creating the variable completely in each
instead of doing "make..." you have to use the existing one and modify the data inside of it
Or change the TempChairDetails to an Array and add to it instead of setting it - but it depends what you do with the data
Hm but from the look of things - it seems like you want to save everything in one struct. So it is weird to have it separated in completely separate functions.
so something similar / on the lines of this:
yeah, probably a FindOrAdd node instead but yeah
(you're also doing Add at the end, it should probably also be a FindOrAdd)
Thanks both ❤️
is there a way to to copy paste a simple sine wave onto a timeline, or do I need to make it myself?
I believe there is a sine node in blueprint, you could use that with only time on the timeline
is there a way to define what occurs between each value in a sine node? for instance I want a sine wave that occurs between 4500 and 6000 etc
sry i haven't used sine waves in BP's yet 😅
how to make this be correctly offset so it wont go to the corner of the mouse cursor?
Hi everyone, I’m creating a Blueprint that combines PCG and BP. I tried turning PCG nodes into variables so that they can be adjusted externally in the BP variables, and everything worked fine so far. However, I found that when I duplicate and use a second BP with the same setup, the variable becomes synchronized between both BPs as if it were instance-shared. How can I make it so that each BP has its own variable parameters that can be adjusted individually instead of being linked together?
can anyone help me with landscape issues in UE 4.26 please, it seems I have landscape the isn't update it's material to match the one on the landscape actor
I'd say you could make a float curve. You can try to copy/paste the timeline node from the graph elsewhere, idk whether that works
out of interest lets say I make an actor where I select and enum and then I spawn static meshs in a vertical arrangement. bassically like a building generator but for say high rise type buildings. Should I use a specific static mesh like instanced static mesh or just static mesh when I do the construction script ??
I have a macro that's spawning a character and then applying a new scale after a delay. How can I have the new scale replicated to client?
@rose anvil Really sorry to ping again; but; thought this would work; but its not :/ There stats going in; but not being added:
been doing this to "test" after they've been added
Instead of setting the scale, set a variable containing the scale. Make it repnotify variable. And in OnRepnotify apply the scale from the variable
I'm not sure, your design is too alien looking, I don't know how to help. I would need to test it myself but it looks like a bunch of work to replicate a nested structure like this.
If you are asking if you should use ISM instead of individual StaticMesh components - ISM is way better for performance. It is always good to use it for static elements like buildings.
so essentially i'd just use static meshes but I thought there is a better way and thought of ISM just weren't sure if it was right for my purpose. bassically generating buildings where each flow is a contained mesh and i generate the right amount vertically and stuff without manually placing each one etc
I spose I could even make a data table for it where each row is a type of building and within the row there is a struct of the static mesh, the amount it should add etc. could be quite interesting in terms of flexibitly I could make it
Hi guys, I'm trying to move my AI enemy towards a random point with a minimum distance. However I don't understand what I'm wrong but it remains stuck. Somebody could help me please?
bit of a wild guess because I haven't used this node before, but does the Nav Data perhaps need to be connected?
good point
seems plausible, yes
there are probably better ways to get the navigation mesh, maybe by assigning it to the character you're trying to move
Have a look at get random location in navigable radius. Here I created a custom event that is fired when my npc character is spawned or on begin play, which kicks off the roaming process. I enhanced it a little bit by having separate point of interest actors scattered around the map, so the npcs just wander about going from one POI to another random one, pausing for a random bit of time and then repeating the process
comparing to an older project that used AI navigation, it seems like hooking up "nav data" is not needed
the code that they showed used a random distance between 6000 and 8000 units, random location in navigable radius would only give you 0-8000
ah ok sorry I misunderstood - so you want to move a minimum distance but somewhere random - for running away or similar.
why not choose a unit vector, rotate it by a random amount in Z, multiply it by a number between the min and max and use that point as the origin for the get random location in navigable range function. EDIT : sorry I see you were pretty much trying to do that in your prev post.
I guess you could do a few other things to debug this: check what the "Return Value" of that node gives you and/or print the vector that it found to make sure it's finding a usable position to move to
if that looks all good, maybe try to see if the navigation failed or succeeded by printing the movement result for "On Success" and "On Fail"
the node should pick the default navmesh if "nav data" is not connected
https://blueprintue.com/blueprint/wxx5od6r/ hey not sure if im doing something wrong, prolly am, but i have this logic for an npc to display dialogue. but when i run the stop speaking function, the remove from parent never fires only the rest of the execution line nodes fire.
ive checked n it dosnt seem to be creating more than one widget, it just never removes the widget from parent
guys, what is the best method for that green arrow indicator under his feet?
I assume it is mesh, just want to confirm this
Probably emissive decal
My math is too rusty to say if your code is okay but I used a different method for this. I generate a vector, where either X or Y is a random number from a range (6000 -8000 in your case) and the rest is 0. Then I rotate this vector around Z axis by a random angle 0-360.
And yeah, as someone else mentioned, definitely debug first which part is not working - calculations, finding navigation point or moveto. Did you try increasing the query extent a little?
Hey there folks
Im in need of a gravity gun blueprint. I have tried to do it myself but can't seem to get my head around blueprinting. Is there anyone that can help? I would be highly appreciative 😀
When you project to the nav mesh you need to specify the Query Extent. This is how far it can look from the supplied point for the nav mesh. At 0,0,0 it'll fail the project (unless it's already on the nav mesh) and return 0,0,0 instead.
You can try 100, 100, 100 to start and adjust accordingly. What value works best would depend on the map/terrain.
I created this function called RunAway which does what you want..works ok in my testing. I have a large crowd of people roaming about and when I trigger this function, the npcs all run away in random directions. https://blueprintue.com/blueprint/y3uxo3b4/
does it print "hello" or "invalid" ?
you also remove from parent, but afterwards try to use it ?
can you avoid a cast to check for a type to avoid loading another BP ?
does a "is a" (class) would work ?
Starting from UE 5.5 there is a "is a softclass" node I believe
it prints hello
that was just there from me trying to see if i could get it to go away w set visibility bc remove from parent wasnt working, it was late lol i was tired😭
oh ok
wdym it not remove from parent ? the widget stays ? can you access it ?
yea it stays on screen but the dialogue has ended, so it shouldve removed the widget from parent, but it stays on screen but empty where the text for dialogue goes, then on player interacting again the loop should restart
wdym "but empty" ?
theres a text box in the widget that displays the dialogue, when the talk index int variable reaches the end of the dialogue array, it stops showing text and should be removing the widget from parent bc its the end of the dialogue but instead the widget stays on screen with no text
are you removing the text ? or the whole widget ?
not removing the text the text’s like “text” field in the details panel is being set by the dialogue array, once it reaches the end the text stops displaying, the only thing im calling to remove is remove from parent
the rest of the nodes in the stop speaking event run (not the set visibility one), but the ui never leaves the screen
I have a strange issue where a box collider that that blocks and should react to hit events stops doing so the moment I change it from the root component to the child of a scene component root. Any ideas?
no errors ?
Yes!! Now I've understood, increasing the Query Extent it works! thanks also for the explaination, I've searched info about Query but I didn't find anything
@kindred harness @crimson briar@gloomy hound
Thx :3
Does anyone know if "on overlap" nodes are checked every frame? Like if I have 1000 actors with overlap triggers would that mean the engine is checking 1000 overlaps every frame?
If im not wrong, its not every frame its only if the actors in question move
Or change collision settings
i see, thanks.
Yea what blackhand said. There's probably other optimizations as well. On overlap doesn't get called if two things are already overlapping in the level (when you begin play), just something to be aware of.
hello guys
i'm trying to make an outline pp material following some youtube tut, but anyone i try , they are all noisy when moving ,since i have a first person character, take an idle animation for ex playing, it will look noisy. does anyone have a clue how to make them not noisy?
also i tried the overlay material but i cant change the color of it and it look weird on some shapes.
<@&213101288538374145>
Hi!
Is it possible to add these two constant values to the project settings? Maybe as a custom field.
Thank you!
Greetings. I've been racking my brain for days trying to figure out how to remap the controls in the game, via Blueprints, but every tutorial or documentation I find online is either obsolete or incomplete. Could anyone point me towards some material suitable for the latest versions of Unreal? Thans for every possible reply
Hey complete newbie here. I'm trying to set up a blueprint to get an AI character to run away from the player. I have code for them chasing the player under certain scenarios but I can't figure out how to get them to run away.
Here's what I have so far
In run away you have a location as a 0,0,0 vector - are you sure it is a reachable point on the navmesh? If not, the moveto won't do anything. Check if the move to returns failed by connecting the fail pin to a print of some kind.
Also you need some condition for the BT, because like this the run away will only happen when the chasing succeeds
I have it at 0,0,0 because I wasn't sure what to connect to it so it was mainly a place holder. I'm not sure what nodes I should use to get them to run away from the player, but I'll try to make a condition
You could do something like GetDirection from the player to the AI, multiply it by some distance (for example 500), then add it to current AI location. This will give you a location 500 units away from the player.
Use that inside a node called ProjectPointToNavigation, and remember to put something in an extent - I recommend at least 200.200.200. Then use the ProjectedLocation for the MoveTo
It is a basic setup, it will probably require some tweaking
I'll try it out👍
Is one of these the correct get direction?
I think this looks a bit better for the sequence
I've got this sewer actor BP which is made up of 2 meshes, ones the manhole cover, the other is the rest of the sewer, I wanna 'cut' a hole in it so the player can see down into the sewer when the cover is open but I need to do it through the BP itself, I don't want a separate mesh for the floor with an actual hole cut in it if i can avoid it because there are multiple sewer actors around the map placed on different floor meshes, ideally I can do something in the BP to make the section of floor covering the sewer disappear, what should I look for so I can do that?
is there any way to add an input as this to a blueprint function library function? I mean including the self reference without having to get reference to self inside the actor i'm calling the function?
"DefaultToSelf" is the meta UFUNCTION specifier for C++ that allows that. I don't know if you can do that with purely blueprint function libraries
🎓 Want to master Unreal VFX like this?
Learn step-by-step with full project files and real production workflows.
Get the complete course now on Techloria:
👉 Start now → https://techloria.com
✨ MARKETPLACE:
Our Projects: https://www.unrealengine.com/marketplace/en-US/profile/Coreb+Games?count=20&sortBy=effectiveDate&sortDir=DESC&sta...
may not be exactly what you're looking for but render targets might be your answer
this acts as more of a "screen" rather than actual hole tho so idk if it solves your problem exactly
Hey guys, in today's video, I'm going to be showing you how to rebind key events for action mappings and axis mappings. This way the player can choose which buttons to press to use that key binding. This works with movement, interact, sprinting and anything you like.
Original Unreal Forum Post: https://forums.unrealengine.com/development-discus...
mmmhhh, not so updated. Thanks but no thanks
Why does the upload date matter to you?
The only thing would be if it's different for when you use Enhanced Input System which I actually can't answer
Had to go for a bit but this is where I'm at with trying to get the AI player to run away from the human player
I might have something wrong with the behavior tree, the Ai only runs to chase players
you have a destination and a target actor plugged in ? whats that all about ?
not a clue, thats what I'm trying to find out lol
since I sent that I did disconnect the target but I'm still struggling to get it to work
you not setting the aihaslight
but you are setting has seen player
so it should be chasing player
toggle you flashlight value
do you see that the bottom set value isn't connected ?
in the behavior tree?
at the end of pawn sensing
I'm on 5.5.4-and my navmesh has started saying it needs to be rebuilt. I've obviously tried to rebuild it, but it still says it needs to rebuilt. No sublevels, just a persistent level with a navmesh in. I've tried removing it and readding it, same issue. Any ideas?
I'll test some stuff out and get back to ya👍
Changing Project Settings > Navigation Mesh > Runtime Generation to "Dynamic" from Static fixed it.
If you are looking for Enhanced Input Keybind Remapping there are a few tutorials about it on YT with that search query
Hello, good evening
I'm new to Unreal Engine and need some help with Blueprints.
I'm trying to create a blueprint to turn the TV on and off, but it's not working. Can you tell me if the interactive virtual tour interaction can affect this blueprint?
I'm having a hard time grasping the fundementals of calling things from one blueprint in another.
I have a widget blueprint for a menu that pops up when you click an icon in-game with 2 different options.
I simply want to make clicking one of those options run a chain of functions (disable visibility, collision, etc) on an actor blueprint.
(Also as an unlreated note, I am taking this approach because it seems trying to script changing water waves objects on a custom water body is still completely broken in 5.6. That would have been the ideal way to do what I want)
Go the pinned videos
Ie; "Weak Waves" and "Medium Waves". You would think you could just reference each but when I get to that step the dropdown is empty
2nd link, watch that start to finish and rewatch the parts you didn’t quite get until it sinks in
It’s prly the best video out there for bp comms
@lunar sleet Ah, gotcha. Thanks. Bookmarked
Any thoughts on the water waves swap bug? Has that been fixed in the newest version?
Trying to find a proper reference..
Not sure, the UE water plugin has always been kinda crappy, but the better options out there are generally pretty expensive financially
Yeah right here in random AI guide..
"Drag off the Water Body reference and search for Get Water Waves. This node gets the wave simulation component."
That always returns empty.
Yeah, seems that way! Sucks my game idea revolves around water haha
Thanks again
Be mindful of AI with UE. Most LLMs out there just hallucinate stuff
AI might be wrong with the more obscure elements of UE, or it may assume weird things, or it may refer to older versions of Unreal. So depending on the question it jumps between giving you the perfect solution and completely making shit up.
As long as it can find some mention of what you are asking on the internet, it will assume it found the answer and compile it to fit your question
Yeah, apparently it's a feature that "should work" but doesn't after like 3 tests
Exactly, yeah! It's just hard to find answeres specific to my problems because.. well, water haha
Watch the communication video and if you still have problems with it after that, come back with a screenshot of your blueprint
Could be that the plugin can’t even handle changing water wave types at runtime the way it’s setup out of the box
That really feels like the case here.
Cool, I'll take a step back and watch the video.
For the longest time changing a geometry rest collection at runtime just crashed the engine and the game, prly still is the case
And that was an engine code bug, so fixing was not worth it for me, I had to find a way around it
Well in my case I basically had to spawn a diff actor that had the new rest collection already compiled. Idk about spawning a new water body at runtime tho
ahh that kinda sounds like what I'm trying to do
Basically I've got a 2+ custom water bodies, each with their own water waves
And I have a UI in a main game menu that has a button for "steady" and "medium"
Trying to get it so clicking either button toggles the visibility, physics, and tick per water body actor
(I still need to watch the video heh)
Are you talking about the standard Water plugin, or some other plugin/addon
Standard
Why are you jumping straight from "How do you make one object talk to another" to "I want physics tied into the barely working water plugin"?
I was about to say, it being marked as an "Experimental" forever doesn't bode well
Ha. Nice.
The typical pattern for something like that is to make the "API" of the thing (probably an event that can be passed a bool), get it to work no matter who or what makes the call, then just have the UI make the call.
I mean.. lots of things still have that flag but the water plugin is definitely untouched in a long time lol
It shouldn't be that the UI directly sets all that stuff, it just says "Hey water, be steady"
IDK bout the water but the buoyancy plugin looked so overengineered and nebulous it was scary to look at.
It's almost simpler to just roll your own for very project-specific mechanics like that
Are you doing this because you can’t change the setting for just one of them at runtime or did you start off with 2
Well I have logic at least for switching all that stuff
Does it work when hooked up to a key input? Or even off a delay on begin play?
For now I just test it with "begin" and break the link to test not working (within the actor blueprint)
But I can't seem to figure out how to make a button click from a different widget trigger that
So again, I need more time to watch the video. Also, thanks for confirming water sys is jank
Have you made a button click on a widget just print a string?
Do that first
Yeah man
OK so somehow give the widget the references to the water actors it cares about, and voila, you're in business.
either it just gets actors of class, gets fed the refs from whatever spawns itself, pulls them from some WaterBodyManager, however you want.
Yeah I think that's all I'm missing. My brain is a bit wore out
I'd rather avoid getting all actors of class when possible
Does anything know about these water bodies and which is which?
Hrm nothing but the level itself at this point I suppose
get all actors of class is fine if what you need is all actors of that class. You'd still need to differentiate them, thats where you could use tags or something else.
Yeah tags
the information as to which is which has to exist somewhere
what are they, an ocean and lake or lake and river or what
and do you care to apply settings to them seperately or are both calm and both medium, not a mix?
OK cool yeah watching more of this vid and listening to you all I think I'm starting to get it
Right it's always a custom body
A pool with different wave behavior
Had no idea getting into this simply toggling wave behavior would be so hard haha
That's why I tried to just use a blueprint to directly talk to the water body about switching water wave systems but it just wasn't happening
Have you got the wave system to change at runtime at all yet?
even with something like:
WaterBody:
Begin Play -> delay -> chage the waves up
Hm interesting test. No, I have not yet.
Out of curiosity I tried to mess around with the Water waves thing, but huh, it is weird. Like they didn't expose most of it to BPs? You can create the Waves asset and connect it manually. But the SetWaterWaves expects WaterWavesBase and the BP made WaterWaves are not compatible with that. And you can't cast to the base.
So it is either impossible to set on runtime for some reason or it is not exposed to BPs.
Yep, UE tends to do that
You would need to look into C++ implementation if there is a valid reason for it not being exposed
Part of the frustration too is like OK I can't just swap water waves so can I maybe just trigger a change to a water wave in the level? No.
I gotta pass out soon but I'll be active on this next few days at least.
But it is possible to hide water body. Not sure if it wouldn't be inefficient or anything, but it is possible. So you could have two of them and switch between
That is EXACTLY what I was trying to do as a last resort, hense my original question of the night heh-heh.
Thanks
So I have all of that going on
In my water body actor
I mean, don't use this code though, I used level blueprint because it is fast to experiment with
But I can't figure out how to "trigger" that from a seperate main game sub menu button
(Again, that goes back to the video)
Yup
Event button pressed -> get actors of class -> figure out which is which however you want -> call event on them
And when getting all of class WITH tag I'm not spamming up the cpu so to speak?
Like I tag each button operation
And the query finds that instead of "first in index"
Nope
Ah! Really?
It doesn’t go get all actors on the planet and then narrow it down
It just goes for that class, so with 2 actors it’s nothing
Only in the active level yes
No actor exists while the level it’s on is not open
Ah ha ok
Sorry. Old Unreal and modern Unity guy here
Yeah this is very helpful, NeoExo thanks
Hey champs,
For years I'm having headaches figuring out how to get ridd of child actor components as they are buggy and bad practice, but didn't find a way so far. I have a tank as a pawn class. Inside I want to use many different types of wheels with both geometry (static mesh, collision spheres, arrows etc) and logic (variables like current spring lenghts, logic to compute forces etc). The only way to have them show in editor to position all the wheels and set up their default values so far was by adding child actors into my tank bp and place+setup them in the right places. From what I read Actor components would be the solution. But they cannot contain any geometry/collision spheres etc so not really an option for me. Scene components neither. If I spawn the wheels as actors I can only do so in begin play, not in the construction script so there is no way to set up their placement in editior. And copy pasting all of them into every tank blueprint is no option either as I want them to reuse the logic and changes throughout vehicles. Anyone got an idea how I'd best deal with it?
Couldn't you use an actor component for it but link the appropriate wheel StaticMesh to it?
So the wheels themselves will be mesh components - you add a Wheel Actor Component for each wheel, passing it the associated mesh component and possibly some other variables.
The wheels could even be a part of the tanks Skeletal Mesh and passed to the component as Bones that the component can operate on - depending on your use case ofc
If it's just the wheel mesh yeah I could split them apart and have each seperate and link them together. But I also need the spheres, theres a BP_TrailComponent in them and the Arrows are handy for debugging, so I'd like to keep them all together somehow
Make a second component called WheelDebugger that adds all of that when attached 
But being serious, you will either have a mess in the tank blueprint or you will have child actors if you really need so many components per wheel
That's where I arrived so far 😆 so there really isn't an easy way around it I guess
Well you could try fitting everything inside the WheelActorComponent but you would need to experiment if it could work with what you have. Hard to tell
Does that one allow for meshes etc or just logic?
I mean, Actor Component doesn't have physical presence. But you can use it to spawn things (like components) and attach them to the owner.
Yes I could add them through an actor reference with "add component by class", but since the actor component doesn't have a construction script it will still only show ingame, not in editor. So results to the same as attaching the wheels as actors ingame
I would have a custom staticmesh component of 1 wheel that has a setup function that adds the necessary collision and other components it needs, and the setup function you can call either on begin play or the tank can call the setup function on its own begin play or construction. but at least since its a custom staticmesh component you already have the wheel visuals that will help you place them correctly on your tank in the viewport
I see, thats better than just an actor component without any visuals. Not sure why it doesn't let me set the colors for the collision spheres, I can get but not set them. For the arrows it works. It's a bit tedious but I'll try with that approach thanks
Depending how much time to you want to invest, you could look at creating an actor component that handles the creation of all the various parts.
You could then create a custom uobject that can contain specific logic for placing things like wheels, collision etc... The actor component would have an array of desired items that need to be placed, creates the relevant uobject from the specified class and runs its logic.
On the actor, you should be able to have it run some sort of initialize function on the actor component for it to do its thing.
Still it would only be visible ingame and not in editor right?
I'm pretty sure it would work at editor time.
You can do a few quick tests by making an actor component that has a function that adds new component to its owner and call it on the main actors construction script.
Alternatively, you could have the actor component look for a specific instance static mesh on its owner. (A tag maybe) In the editor you can add instances you can see and then on begin play, it spawns an wheel actor were each instance is and clears the ISM when done. (this method works well with door bp's when asembling structures)
Thanks, sadly during construction scripts I can only add a static mesh component, but no derived class from it or anything custom. And putting it in a function to add the derived class and calling that function into the construction script doesn't work either xD I'll try spawning them ingame
nope no errors
if i put a delay on the start speaking event and add a remove from parent node after it removes the widget, but the stop speaking event dosnt do the same
https://blueprintue.com/blueprint/2eowkzud/ https://blueprintue.com/blueprint/etenn4v2/ ive jumped ship to follow a tutorial i found (https://youtu.be/zYYNTBOR8AI) and its working now, but i wanna add a check that if theres more lines of dialogue in the array from the component, to not have the box go back to hidden, to instead wait for another press of the interaction input to set the text to the next line in the array and then once the end of all lines of dialogue have been reached then set it to hidden again
I always really liked how the text boxes would fill in the zelda games, and it always seemed to help me retain information a little bit easier. so let's make our own! we'll set up a dialogue component that can be applied to any object, item, or mesh in our worlds and then used to communicate information to the player. we'll even add in a custom ...
Do you remove Dialogues from the array after it's 'Spoken'?
if not then you should do check if Current Index > Last Index then dialogue is 'over'.
like before you set visibility hidden you ahve to check if there is more texts, so if the Current Index <= Last index of Dialogues array is true set visible, if not hidden
i dont remove them from the array rn they are set instance editable on whatever actor i give the dialogue component but i dont rly want to keep it that way bc the npc actor bps i have setup i have given their own arrays of dialogue that id like to use instead of having to set on each instance
you probably should use data assets for dialogues
i have a struct setup w three arrays bc theres only three types of dialogue for the npc. and they are supposed to repeat themselves depending on the state,
for example, the npc can give a quest. theres then,
pre quest array (telling the player about a quest and opening up the options to accept or reject their offered quest)
mid quest array (if player comes back and interacts w the npc mid quest and dosnt have the requested item)
and post quest array (random lines of dialogue)
w them all having like three-fourish lines each
how would i do that if the array is in the actor component and setting the visibility is in the widget itself
isn't the component creating the widget?
no
why?
the widget is created on begin play inside the player
ok so how do you interact with the npc? does npc have component?
yea the npc has the dialogue component
player has any way to get ref to that component?
well you have to come up with some idea how to architecture it and it's more how you like it
but one way is to have component create widget and pass reference to itself to it so you can access it variables
and then also component calls to hud and adds it to your main_ui widget to some panel or something
the other way is to when you call Speaking, also call Widget that you created and pass it current Dialogue Component
i could move the widget into the component if that simplifies things, only reason i moved into the player to start is bc of issues w creating the widget in another bp previously and the tutorial had me start this way lol
so it can read it
start with the easier way to not change your whole game now but think about it later how you want to add widgets to the UI
so id add another input to speaking thats looking for the ui ref inside my player?
so right now you need to :
-
create Dialogue Component variable inside Widget
1.1 create function inside Widget that sets Dialogue Component called Set Dialogue Component -
when you create Widget in Player promote it to variable
-
the same moment you call speaking (or before it) get Widget ref, call Set Dialogue Component and put the dialogue component you got from FindComponentByClass
-
add logic that you wanted, as long as dialogue component will be set then it will be 'working',
-
have a way to reset dialogue component to null when you finish interaction or something
i myself would do it Component creates Widget, passes it whatever it needs.
when you interact you Get Component -> Get Widget -> Get HUD -> AddWidgetToDialoguePanel -> Game UI get DialoguePanel (box/border/verticalbox) Add Child (widget)
so in the component something like this
which way are you doing it right now?
i was making the component make the widget like you said
i gave you easier for now version to make it work and see what you need before you change your whole game 😄
shit, i completely misread that
with this way you need Panel/Broder in UI, you need to know where is your UI widget (is it in HUD?) etc.
and also the component should create widget once at begin play or something, no need to create it everytime you call speaking
like this?
shh they arent as bad as they were
but 😭 i am also lost for the 4 and 5th step, so id now take the last index of the array from the component and check it based on the curent index right
for the way i have the three arrays of dialogue, would it be easier to add the struct that holds them to the component and get them that way? or should that be inside my npc
from true you ahve to set it visible, and from false invisible
here?
yes
forogt to check the looping to true on thr true branch
i think im confused again, lemm jus get a clip of how its acting,
now when it reaches the end of the line of text, the text box becomes hidden, another interaction brings the next line of dialogue up, then it also is idden after the delay. then when interacting again it resets back to the first line in the array
so what do you want? you want it to dissapear completly only when it's finished?
so you have to check then if current is > than index (without =) and if true then set hidden, if false dont do anything
so it will be only hidden if you actually clicked the last one and is currently 11 > 10
i want, if theres another line of text, to have it hold on the curent line until the player presses the input again, then once they do, switch the text to the next line in the array, once the text is at the end, then hide the textbox until the player interacts w the actor again to resatrt the loop
mostly bc im also planning to add clickable button options for the player depending on what text is being said, like is an npc asks if they will go find an object for them, a yes btn and no btn show up and clicking will change the array the npc pools its dialogue from to the mid quest one, closes the text box until player interacts again, when player interacts again the yes or no is still an option to tell the npc if player found the item, if they did, load a congrats dialogue spawn reward and then set the array for dialogue to post quest so they cant give the player another quest to do and the dialogue reflects that
Lyrics:
Lumalee! Lumabop!
Oh luma (x4) bop!
(LUMA LUMA LUMA LUMA)
Feed me the luma, oh the lumapops!
Feed me the luma, luma luma luma pops!
Feed me the luma, luma luma luma luma luma bops
(LUMA LUMA LUMA LUMA)
Starbits fill me up, everyday
Lumabops are alright, okay
I don't know any words to say,
But lumabops aerererervry [every] day
We are;
J...
visual reference
that didnt work
one way of doing something like this is keeping the index (which i see you have) but doing like a choose your own adventure type of thing, where yes takes you to index 10, no takes you to index 7
etc...
might be an easy way to think about it
you can think of indexes in an array as pages
that makes sense, would that be better than seperate arrays based on the npc state? and im also just kinda stuck w keeping the ui on screen to wait til the letters all load in for the line of text then wait for another input press to advance to the next one
idk what would help it's just an idea
so whats the issue you it's not looping ?
well i look at it as anything is better than me not knowing lol😭 bc theres alot of unknown w how i am trying to set it up rn
rn its closing at the end of the line of text, and then a second input press opens the ui back up to show the next entry in thr array, instead of staying on screen w the filled text box, until player presses the input again to advance to the next entry in the array.
another way i could word it ig is, the text boxes rn are like making statements at the player when id rather have it look like they are having a full conversation w the player
You need to make your code able to use an existing textbox.
it is using an existing text box
It'd look a bit like:
Event SaySomething -> do we have a text box? -> yes -> push text to it
-> no -> make one -> push text to it
Then why is it closing and reopening
bc it sets visibility
then don't do that
but if its at the end of the dialogue, i want it to
or if the player cancels/hits no for the option buttons. to do the same
The computer is doing exactly what you are telling it to do. Right now, when does the visibility get set to false?
What's the rule here
https://blueprintue.com/blueprint/xtqh6-4t/ https://blueprintue.com/blueprint/r1hsf_11/ https://blueprintue.com/blueprint/2ne-9_a7/
this is what i have
that's a mess lol
ok in plain english, what behavior do you want?
What are the rules for when you want the box to close
ive already sent this😭😭 when the player reaches the end of the dialogue array(ie the npc is out of messages), close it.
when the player has accepted the quest and the buttons for yes or no have popped up, if player hits no. close it.
when player checks w npc to make sure they have enough coins to get a reward. if they do. close it
post quest, if player interacts. random line of dialogue is set on each interaction. at the end of each line. close it
the only time it should stay sitting open is when waiting for the player to hit “e” to advance to the next line of text until reaching the end of the array. or when the player is presented w buttons for yes or no and the npc is “waiting” for them to pick an answer
you don't want to close it when they reach the end, you want to close it when they try advance BEYOND the end
yea
Break it up, make these events:
ShowText(index) -> unhide box, show the text
Exit -> index = -1 -> hide box
TryAdvance -> index++ -> if index > last index in array -> true -> Exit
-> false -> ShowText(index)
Get that working first, then expand to include the replies.
Note that it's super simple, and the control of what text is being shown is handled outisde of the actual showing of the text
The only entry to this whole thing should be Advance
although you can also directly call Exit
so rewrite all what i have?
That's what I'd do but you do you. What you have right now has the control over the state machine that is a dialogue, all mixed in with the display of that dialogue, with delays thrown into the mix.
yea to control the speed of the text being displayed
yeah so you'd put that bit in ShowText
but ShowText should just do what it says, show the text with all the flavor
it shouldn't be modifying any actual state
if you make the thing work with you spamming buttons as fast as you can, then you can easily add all the flavor bits to it.
Subject: Help Needed – AI Character Still Not Moving / Patrol Setup
Hello everyone,
I’ve been running into a persistent issue with my AI setup, and I’m hoping to get some help or ideas from the Group. My AI character is not moving at all during runtime. I’ve followed the course instructions carefully — setting up the detection radius, AI controller, and behavior logic — but the AI refuses to respond once placed in the world.
When I test a simple AI with a “Move To” node, it works as expected. But as soon as I implement the same logic in my master AI character (which holds all of my detection/aggro logic), the movement stops completely. Now that we’re at the point of adding patrols, it’s even more obvious because the character just stands still instead of moving between points.
I’m currently getting the following error in the logs:
Blueprint Runtime Error: "Accessed None trying to read (real) property CallFunc_Array_Get_Item_1 in not an UClass"
I’ve tried the fixes mentioned in the forums, such as adding a short delay on BeginPlay and checking variable setups, but so far nothing has worked. I’ve also confirmed that my NavMesh is built and visible, so pathing should not be the issue.
Has anyone else dealt with this problem? I’d really appreciate any suggestions or examples that worked for you. I’d love to finally get my AI moving and responding properly so I can finish the patrol and aggro setup.
Thanks in advance for any help you can share!
Best regards,
im lost. bc starting just from this makes no sense. i already have something working restarting just sounds like im gonna be stuck w more shit not working
This will take you like 2 minutes. It really is that simple.
its not😭 bc im completely confused. esp bc i have shit in three different places already
idk what im putting where, i have the actor component, the ui widget and the interaction input in the player
Hi, Owner No See is not working on Static Mesh in my project. It works with Skeletal Mesh, but I tried it in another project and it works there
Click on the error and show where it takes you
😭🤔 I’m definitely working on it. I’m thinking about implementing a blackboard and a behavior Tree. I really appreciate it. Good motivational thank you!!!
Ok
Does anyone know a good way to apply continuous wind force to a character in one direction ? I tried add force and velocity override but it only really works while in midair and doesn't push on the ground
Do you know why it doesn't push on ground?
It's still pushing
but the friction with the ground is much stronger
I know, so how can apply a constant push force that has the same intensity on the ground as in the air ?
Im trying to figure out a simple way to take a floor tile, and have walls automatically be spawned at the edges where there isn't an adjacent floor tile, as well as have the collision boxes be able to detect if there is already a floor tile occupying the space. I've got 4 collision sockets with their own floor trace channels as well as 4 wall sockets in place. Pretty new, any advice?
could you explain what i need to put where, am i putting this in my actor component? or the ui. i get that its simple im just having issue fully understanding what im doing
You'd have to use math to account for the friction.
Start by just detecting if the target is on ground or not and feeding it a different force.
Editor time or runtime?
Runtime
anyone able to help me figure this out?
I cant access blueprintUE because im from the UK. 😅 Can you share some screenshots?
Its not the easiest to follow but to make sure I understand, it closes the UI after every line of dialogue? Meaning the player needs to interact again to get the next line?
yea thats what its doing rn, but i need it to wait for the next interaction before progressing to the next line, then close at the end of the array
n ik its messy. im just focusing on getting it working before i clean the code up
in the 'IncSpeech' function you set its visibility to hidden once all the characters have been shown. I would probably unhook this and just have an event dispatcher to notify it's finished. Then you can have the dialogue component bind to it and when its called, set the 'IsSpeaking' to false. This should allow the input to trigger the dialogue again.
On the initial 'Speaking' function where you set the current dialogue to 0. (to reset) I would have the UI close at this point instead.
hm, ok that kinda makes sense ill try that out here in a few
Hello, has anyone ever used this node? First time seeing it. It doesn't work with arrays, so it doesn't work for cases when you need to iterate through an array and modify it inside the foreach loop. I don't know what else it might be useful for
I've not used it but I think its for converting a pass by ref variable to a copy. (diamond to circle)
Yeah, but any actual use cases? I get what it does, but bps rarely deal with references when it comes to non-uobjects
If im not mistaken it turns it from a pointer to that object and creates an identical one locally. Changing a reference changes the data within that reference. A copy will not affect the original reference
Oh, so it deals with uobjects?
Bad phrasing sorry. I meant it not in the programming sense of uobject. But say you're referencing a variable from another actor. If you have it as a reference you can manipulate that actors variable.
If it's a copy, you now have an identical version of that variable, but you can not change the original version of the reference and it wont have a pointer to that actor/variable.
Same applies if you're referencing say another actor, and create a copy.
I guess its just an alternative to creating a local var in a function when you want to make a copy of a passed in var so it would change.
Not sure how many cases this would be useful though.
Hmm, I see, with node-local variables like this it makes sense. btw, how do you get them in a function? You can easily get them in a macro, but usually they're not listed in a function/event graph
Just search copy to find the wildcard version. Then you can connect it to something.
If this is in a function I'm not sure this is doing anything. You're turning a reference into a copy, then turning the copy back into a reference.
In the input you can manually change it to being a pass by reference or a copy. When expanding that variables details.
Aside from that, in a use case as this, it would probably be better keeping the pass by reference.
hmm, I don't get the Local Wildcard when I try to drag off of Copy
Possibly something like this. The macro takes in by ref, modifies the value but then returns a copy to help prevent further changes down the line.
Again, not sure when you'd need something like this.
Yea i think you're right. Probally more for macros.
Hello, I am trying to recreate this camera dead zone when you reach the border of a map but without success (video example of Hades2).. difficulty being the 3D isometric camera..
I tried to kill the axis or the camera boom on tick, which works but only on X or Y values thus not fitting the isometric camera.
I tried to place a camera blocking volume but that doesn't work either as the camera is "pushed" down when colliding with the volume...
Your best bet is likely going to be putting this in the CameraManager. It has an update event that decides where the view really gets placed. It passes in what view it wants which is usually your camera location and such. But then you could clamp it's location to the map bounds. This would lead to you not needing to do special stuff in the camera or spring arm and would work with any camera view you have in game to avoid it ever clipping out of level.
Good idea but it's not working great when combined with the player's movement input. Even with a low pushing force added every frame via AddForce walking against it doesn't negate the push in the slightest and walking in its direction doesn't make me walk any faster like expected
Surely having wind as a pushing force that blends as expected with movement input isn't niche right ? You see it in games all the time
So do you have it working for something, like leaves etc, but not for the player?
If you are just manualy doing AddForce, and try big numbers, and it still does nothing, then something is certainly wrong... ( I haven't done this sort of thing, just pondering the situation )
No that's not the issue. My numbers are pushing the character when not moving, but then trying to input movement in the direction of the wind should still allow me to walk forward just at reduced speed which currently isn't the case it doesn't move forward at all and still gets pushed by the wind at the same rate. Then the opposite happens when walking with the wind, it should be making me walk faster but instead I still move at normal speed
AddForce is certainly additive, hmm. What is used for movement : if there's something like SetForce, it might override your other stuff?
AddMovementInput node
Now I am not familiar with it, but it sounds like that might be something that doesn't care about forces
CharacterMovement component is not made to work well with physics. It is made to work out of the box in a standard game like an fps or action game. Adding force to a character will usually interfere with the inputs.
You could try to implement wind as a modifier to the movement input or by changing the allowed speed of the character. I don't think you will get far by using add force - at best it will be very wonky
Or you implement/buy your own movement
isnt this one of the reasons they made the mover plugin. CharacterMovement basically only acts on the simple capsule stuff
Hello guys, i have a quick question. ive been working on a project and wanted to go and try it as a standalone game. in the editor the game is actually really perfect and everything works fine. but i feel like the standalone game is completly diffrent. Some players dont get loaded or recognized. Some gamemodes dont even get activated on swapping maps and in generall its a totall mess. is there a way to test standalone game without having to wait like 10 mins until it starts? Or is there just a solution to this in generall? what am i dooing wrong?
hey can anyone tell me how find component by tag is used for and how it works in unreal engine or for making games?
using bp with bp link to levelsequence to make it easier to move objects as needed- so I have one trigger that removes cube collision so player can walk in, and another sq shape trigger that adds collision which all work fine, but on U, elevator lift, elev goes up, player stays on terrain, what might I be missing here ? I tried messing with cube in mesh editor and bp and leverlseq , nothing works ??
Not really sure how to answer that. It finds a component that has that Tag in it's Tags array on that actor. And you use it when making games to find a component with a specific tag to.. do whatever you need to do with said component you needed with a tag?
Each component has an array of FName variables called Tags.
You can manually add different “tags” to this array.
FindComponent will take in a tag (EX: MyCustomTagName) loop through every component on an actor, and return a reference to the first component it finds with the matching tag.
This can be used for many things, an example from my project:
I have an interaction system. While the player is in “interaction mode”there is an interaction cursor particle effect that will hover over the actor the player is looking at. This is so the player can tell which actor they will interact with.
Each actor will have a different location where the interaction cursor effect should hover at. For a NPC, the interaction cursor should hover over its head. For a door, the interaction cursor should hover over the doors handle. To determine the exact spot the cursor will hover at, each intractable actor has a scene component with the “interactionpoint” tag on it.
Now when the player looks towards an intractable actor, I use GetComponentByTag to find the “interactionpoint” component on that actor, then I place the interaction cursor at that components location.
You are using it
That'd be a nice hack. Basically no forces, "wind" is just basically stick drift
I’m still struggling with simple inventory systems
You would think they would have a simple inventory in and out but it’s always just hey here you go another inventory system you have to create
They’re simple to make so always end up making a project specific one.
Easier than having some more complicated generic version
But bruh it’s the same thing each time with just changes to the data it’s storing
It’s doesn’t feel simple maybe I’m missing the point of something’s
Idk unless you explain your confusion
It’s just an array wrapper
And then a widget to interact with it
Like I always get stuck remove add item in the component. Then idk what else to do I never even finish the code , I cannot
Tbh I usually just make add item, remove item, find item, and remove all items.
Start there then eventually I might add a few others
But that’s the core of it.
Can start making the game with just those few functions
yea inventory is really just array (or arrays if you split it to categories) with bunch of dispatchers (OnAdded, On Removed) so then UI can bind to it and display current state, and then each item is literally widget when you click on it / hover it does something (you can equip or use) and then there might be specific things for the project
I’m trying to understand concept and theory
create a struct for base items, create an array of that struct on your character, and add those structs to your variable when you "pick up" items and load/show them on your inventory widget
if you are working alone, you can dump everything in that single struct, it'll be a chaos, but it'll be your own chaos that only you understand 😄
Ryan laley tutorials are super complicated
I just now am in tutorial 4
I'm working on inventory system right now too
Is there a simpler way to understand this I know the ui is a wrapper but my brain can’t understand arrays. As well and also my client side is broken feels like I learned nothing
But you ask me to create an orbit around gravity physics and I get the concept but Array and ui add to remove it add more it’s so damn complicated find slots empty slot too many moving parts
This is the part where I give up and start over
I'm not the expert, so I'm not sure how much I can help, but I'd suggest not use ui to add remove to/from array, create functions on your character for your widget to call to manage the item array, like if an item is selected to be equipped, call a function on your character blueprint to handle item swapping, changing the asset/mesh etc and updating the inventory array
Well I’ve followed the tutorial I haven’t made a widget yet
I followed it to a T and still I’m getting client issues I just don’t get it
I just want a simple 4 hotbar slot inventory for now
I'm a bit confused by how to use Impulses. I just want to "hit" a ball by adding velocity and a direction, or something like that. But the Add Impulse node is unintuitive. It says "Magnitude and Direction," which honestly is what I'd love to do, separately, but it just has XYZ values. So I assume Magnitude and Velocity are blended. But that doesn't help me if I want to set the Magnitude by other factors and have the direction opposite the Player.
Anyways, I'd appreciate any tips on this. I'm not married to using Impulse, either. Thanks!
You calculate a unit vector (direction) and then multiply it by a float (magnitude)
is disabling foliage material wind/animation worth while for optimizing for lower end machines? or would it be best to just move away from foliage altogether and use static models
that depends on your target hardware and project, ultimatively you have to test and figure out what is necessary for your project
generally speaking, is it noticeably lighter to remove foliage animations?
like, even worth considering
in this particular case, one of my level's has a garden filled with hedge
there's probably ways to get an idea of how much impact it has
maybe a console command to disable WPO
then compare frame time
frame time didn't change at all lol
but my PC is high end, so might not be a good example
the lowest spec'd windows system I have around to test on has a ryzen 5700G
which tanks pretty hard in dense foliage areas
changing LOD bias sounds more promising to increase performance on paper
What is the best solution for moving an actor to different locations during gameplay? Level Sequencer has the problem of only supporting fixed locations, and Timeline becomes complicated if you have many movements
hi, im trying to trigger a level sequencer cinematic once i press E on my box collision Door, i dont know exactly why is not working can anybody help me to figure out what am i doing wrong
im providing images- also is there an option to Apply all trasform to a skeleton mesh? I noticed is possible to restore pivot and all trasform for meshes but not for rigged meshes?
Hello, is there any way to pass a 2d vector reference in a macro? You can do that in collapsed graphs and functions, but not macros?
Default debug steps for problems like this:
- Add print nodes to any loose pins - like the cast failed, so you can see if there is a problem with hitting, or with interacting
- If 1 doesn't tell you anything, add a print with GetObjectName from the hit actor, to see what was hit.
Also the end location for line trace looks fishy, usually you calculate it from the current player location. Otherwise it will always point to one spot, and this spot can be behind the player
yea i know it sucks that i've set -12000 on axes, indeed i was wondering if theres a way to apply all trasform back to 1 1 1 0 - 0 - 0 on a skeleton mesh rigged but seems like is not possible?
i cant use the current player location in my case because i changed trasform on my BP character the arrow forward to me is the Y not X
I'm not sure I understand - what is this line trace supposed to check and in which direction related to the player? Also is this 2d or 3d, I could understand doing it like this in 2d maybe
the line trace is forward to the door and the logic is working till the end but i dont know how to blend to the sequencer once i finish the logic
my chracter supposed to press E on the box colision door, play the sound and start the sequencer
Well you asked "what is not working", you didn't specify the sequence is not working
Is anybody else having trouble launching the 5.7 engine from the launcher? The only way I can launch it without crashing as soon as the editor is supposed to pop up is by launching a project from the launcher's projects library.
At that point the editor works perfectly fine and I do my stuff, but then it does crash again any time I try to open a different project or to create a new one. The issue seems related to the Unreal Project Browser which never shows up and leading to crash instead. It becomes kinda annoying specially if trying to start a template variant from there.
Besides... only the C++ version of them are actually working but exclusively from the templates directory... are they meant to not be used yet perhaps!?? Any hint about a solution, if there is any!? I've googled for it but none of the solutions I've found there {clearing the editor's cache and so on} has worked. Thanks in advance, as always.
PS: The image is from 5.6, I only used that as a reference to what I was talking about}
I've not had any issues. What error do you get when it crashes? And it only happens with BP only projects?
I get always this one. It happens with any project and when only starting the engine with the launcher's buttons. it doesn't seem related to projects' issues.
Have you verified the engine version your using?
I did
Ain't solving the issue.
I feared it was some incompatibility with my rig but aside that issue the editor works as smooth as a charm so shouldn't be the case, luckily!
I forgot to mention... the engine version is the 5.7 Preview of course.
In the settings for the launcher, there's a troubleshoot option. It should tell you if there's any requirements that aren't met.
Also does it happen when launching a 5.6 or earlier project?
guys how do i increase the distance of shadows ?
they fade out if i move the camera away in like 15 meters
I have only 5.6 and 5.7P installed and the issue happens equally... both 5.6 converted projects and the 5.7P templates
Sounds like shadow scalability settings
appereantly its on high
but yeah increasing that to cinematic keeps them for way longer, thanks
There's also a 'Max Draw Distance' on light sources. This is normally 0 by default (usually meaning no limit). It might be worth checking if this has been altered on your main light sources.
Other than reinstalling the launcher, not sure what else you can try.
Troubleshooting gives no issue, all requirements are there.
These two. There's no description on them but I assume it relates to how far things can be to be affected by the light.
Doesn't seem a Launcher issue but rather the editor itself, unless the Unreal Projects Browser is related to the launcher and not the editor, but I think it's unlikely that
What happens if you try launch a project using the desktop shortcut? (the .uproject file)
I don't use desktop shortcuts but I open them from their own folder
when not from the launcher
When I do launch them from there it does work.
I wonder though can i increase it further?
cinematic still cuts them off at a distance
Oh yes i can
I would try reinstalling the launcher then. Most likely something to do with the hand off the editor does to the launcher when it's finishes launching.
I'll try that as well, I have no other option left at this point.
Hi everyone,
I’m working on a project in UE 5.4. My character doesn’t have many abilities yet — just jump, pick up, attack, and keeping track of how many items were collected. We started from an MLBS package and built on top of that.
All the features I added work through interaction, and they don’t cause any problems. But the issue is that right when the game starts — even before any interactions happen — the character movement already has stuttering/lag.
I haven’t used any casts.
I don’t use any Tick functions.
The whole setup is Blueprint only.
We’re also using Advanced Session System.
I tried tweaking some network settings, and for a while it seemed to improve, but recently the stuttering has gotten noticeably worse and I still can’t figure out why.
Does anyone know what might be causing this or where I should start looking?
@forest seal #multiplayer message
Resisting the urge to jump on that cast point like it's a lime cheesecake.
always the black sheep =(.
and it's just sad that people actually AVOID cast and tick just because they are misrepresented incorrectly.
I still have horror stories in my head from Reddit. I still absolutely love that one post about the dude who joined a project and was the only programmer left, and "fixed all the memory issues" by turning everything into interfaces. And literally framed the post as "DO NOT CAST" 😂 Like.. you were SO CLOSE... one more brain cell and you'd have gotten to the linker issue. You didn't need to redo the whole project with interfaces, just move your function calls up from badly linked subclasses.
Hey, I have been searching for this very dumb thing for like 5 hours.....
I have a game already on steam...
I have a button....
When I press the button, i want it to open up from steam's own web browser...
Not from an external web browser...
How.... do I do this dumb thing?
Please @loud vessel tag me if you know....
I.. Used to know that. Sec
Are you using advanced steam sessions or anything? I recall it being a C++ only function but they might have exposed.
Yes
Online subsystem is also on.
Which file would I find it in?
Can you search for a node like ShowFriendsUI?
Yes
Nothing is exposed in default Unreal in BP for that, But Advanced Steam Sessions seems to have a library with that stuff.
There may be a generic Overlay function too, not sure, but the ShowFriendsUI will at least open it up to the friend section.
Well there is this.
But I don't see anything useful...
That'll be what you're after.
I assume the SteamID will open it to their profile page. I'm not sure how you get a UniqueNetID for the local player. There's probably a converter from PlayerController or PlayerState to that.
Right but, what I can't comprehend...
how can I just open a specific url page?
(In steam Overlay)
Ahhh. Like opening a DLC page?
uh... maybe?
I just want to press a button, and a webpage inside of steam **overlay **appears with the specific url.
like ths:
Curious if this console command works...
// activates game overlay web browser directly to the specified URL
// full address with protocol type is required, e.g. http://www.steamgames.com/
virtual void ActivateGameOverlayToWebPage( const char *pchURL, EActivateGameOverlayToWebPageMode eMode = k_EActivateGameOverlayToWebPageMode_Default ) = 0;
steam://store/SomeAppIDHere
steam://url/URLLikeItWouldBeInSteamBrowser
I don't have ASS(lol what an acronym), but I can test those.
@maiden wadi Thanks for the help with U.I. I'm almost done with the cheap cloning.
Nooiiice.
I'm very confused
Where do I put this?
feels weird in full screen though =(.
What do I do with this? 😮
Nothing. :/ Unless ASS implements it. It doesn't work by default without it.
I don't see anything in their docs that help. So I don't know how to get at that without C++.
So, I have the project converted to C++
So, I can access files I think...
Does.. that help?
(I'm using visual studio community 2022
But.. 98% of the time just to Build the project
the .sln file)
Whiich one?
where do I find it?
ctrl + shift + f , look for the method you want to call. Which is what's pasted above.
Thanks.
I'm checking this now.
Is that hard to start a sequencer on an input key and switch from our follow camera to the sequencer cinematic one? Its 2 days im trying and i Cantt
Yeah, I just made a function to test but I don't even know if my project package atm and steam overlay requires non editor build.
Someone please can guide me and helo me?
.h
UFUNCTION(BlueprintCallable)
static void OpenWebThroughSteamOverlay(FString& Url);
.cpp
void UAdvancedSteamFriendsLibrary::OpenWebThroughSteamOverlay(FString& Url)
{
SteamFriends()->ActivateGameOverlayToWebPage(TCHAR_TO_UTF8(*Url));
}
you can try that
Didn't work either. Still crashing. I really have no idea of what I can do, aside trying to install the engine from the source. Problem is... I've never done that before.
whats the best way to fetch an inventory array from the player state?
Anyone know why I cant parent to Actor?
most probably because they're not the same class type. what are you trying to parent?
I see, old parent got corrupted but it was an Actor
Can anyone tell me how do I leave session as host and kick everyone to the main menu? I get an error about failing to package because the clients are still on the level that the host ended the session in.
Thank you.
pretty sure by default the client will get booted to main menu when the host left the game.
you are just testing it in editor, so it doesn't mean anything.
in package, if the host leave, everyone will get disconnected (booted to main menu)
do I need to have ?listen to transport people to the main menu? Because wouldn't this only get called on the host?
you don't need to do anything.
the moment the host dc, client will get booted.
Unreal model is that of a server to client.
alright, thanks I will try that
Also, you are destroying session after open level. You should assumed that after open level, the nodes afterward not gonna get executed.
because the object that calls Open Level would be destroyed on travel.
no but this is on the Game Instance which doesn't get destroyed
the most simple way to approach this is just to destroy session on main menu.
but this code should kick the client to the menu anyway right? It doesn't work in PIE but hopefully it works in a build
from my experience, host leaving will boot clients to main menu.
unless you override the behavior? I guess.
idk, I don't think that would happen with a standard open by level node without ?listen. Because I would assume that gets called on only one person
not sure what you mean by that. Why wouldn't the host open the level without ?listen argument anyway? Without that param, you probably can't get the multiplayer working.
well that's there to initially load the level after starting to host. But I am not sure if it's required when leaving the session. I swear I can't find any information on this online
host disconnecting will make the client booted to the default map.
this is default behavior
no implementation on your end needed.
hi, I wonder why my launching pad animation only trigger once ? I supposed to do it multiple time when I running back and forward. As you can see the sound trigger every time I run accoss the launching pad
like why does it only play one time. It suppose to play every time I enter the colision trigger
Is the animation a state or a montage?
Change from Play to Play From Start
i didn't even notice it play the first time ?
yes, it only play for once, like it supposed to go up and down every time
like you can still hear the sound everytime I run accoss the object so which mean the code work
but not the animation
ive gotten to this part w calling the event dispatcher once all characters are on screen, but im a little lost on binding it in the actor component,
it's a montage
It just play when component overlap as you can see in the code
you need to reset it back to what it was either by reversing or just hard setting it
it's not a montage, it's a timeline ?
and your setting the location so after the first run it's set to the top value
oh yes, you are correct
okay
Use play from start instead of play. Play will leave it at the end
I'm implementing wall climbing and want to make it so there is a slight delay before the character starts moving from an idle state (to prevent janky, spammy movement). Is it just a matter of checking how long input has been held down for or is there another way to do it?
Wall climbing is done in a separate actor component so I don't have direct access to the enhanced input event nodes
Hi folks I have just a pawn to act as a top down camera for a city-builder type game. Problem is when I use Add Movement Input to control the zoom (mouse wheel) it works but incredibly slowly. Multiplying the action value by a constant doesn't seem to increase it. Mouse wheel just seems to add 1 or -1 no matter what. Any ideas?
https://blueprintue.com/blueprint/8m5zsxgb/ https://blueprintue.com/blueprint/xf932d_o/ https://blueprintue.com/blueprint/ud8kcnfw/ ive gotten it working but now i am stuck at the point of checking if a line of the array is a question, if it is i want the player to not be able to advance to the next line w the input like it would otherwise, to instead have the yes or no buttons in the ui set the next line and continue the incrementing logic after setting the next line
for example, player is asked a question on line 3 of the array, a yes or no button pops up, if player hits no, it sets the next line of text to a specific line, if yes it sets it to a specific line in the "current dialogue" int variable. that way once the player has picked an answer the speech logic continues, just from a later point in the array
if that makes sense
also, how can i prevent spamming of the input 😭 bc rn if you spam the e key it breaks the npc (pressing it and spamming the key makes the text loop back around to the first line in the array, same if you press the input again while its blending from the npc camera to the player camera )
Hey, gang. I've got a BP actor that's appearing just fine in PIE, Simulate, and Standalone Game. But when I package the project and launch the level, they're just gone. Any idea why this might be?
You can switch a boolean false/true, then run a branch on key press
i have one already tho
“canbeinteractedwith”
its in the npc itself lemme grab it
Have you got it to work? I got it to work.
Just do this
void UAdvancedSteamFriendsLibrary::OpenWebThroughSteamOverlay(FString Url)
{
if (SteamAPI_Init())
{
SteamFriends()->ActivateGameOverlayToWebPage(TCHAR_TO_ANSI(*Url));
}
}
Hello! I got problem with fov. If fov is small(60) staic mesh that attached to camera barley visible and if change fov to normal(90) its visible. How to make it visible the same way on any fov? For example in game here 60, 90 fov hands looks the same, how to get same result?
You can try looking at First Person Rendering in UE (5.5+ afaik).
I Just Updated Project From 5.4 to 5.6 can some one tell me how to fix
thanks, i was looking for solution and found panini porjection and First Person Rendering is the same but buid in. Unfortunaly im on older version and dont want to switch. Found the solution
How does one raise a custom error from a Blueprint?
You don't
That suggests it's something I shouldn't be doing.
In that case, how SHOULD I have a program yell at the user for failing to do something?
Data Validators, you can really go nuts with them, e.g. yell at people for using BlockingLoad nodes in blueprints.
Haven't created them in blueprints myself, but stuff like UEditorValidatorBase has blueprint hooks, so you can make them there as well to some degree.
E: Assuming its for editor users, not for packaged application users.
I am having a weird issue.
I have a custom actor component on my character and in animation blueprint I am using the node "Get Component by Class" and storing a reference but when I play the game the reference is null. If I print the display name in the anim blueprint, it prints fine.
He's my workaround this issue if anyone ever has the same problem:
I created a short timeline and used it to sort of buffer the very intermittent mouse wheel input. I thought it would feel floaty but it actually looks intentional as the speed comes to a more subtle stop.
(always) show code.
I remember you want to control camera speed with MovementInput, but why?
MovementInput is for movement. It's pretty much just a directional value. The actual Character speed is determined by MaxWalkSpeed in CharacterMovementComponent.
I just created an interface and returned the required variable from the component instead.
This is what I was doing earlier
The first screenshot is from the animation blueprint
Uh kind of, its like a top down camera but I'm using the movement to strafe around at a given height and then mouse wheel to change the height
is it better to add "custom collision object channels" or let 100 flying bullets to check what collision they're hitting?
add the custom channel
Still not enough info, get component should do it. Interface is soo unnecessary unless different owner store their component in separate object.
judging by everything i've read online it doesn't really sound feasible but i'll ask here anyway -- are there any work-arounds to allowing specific enemies to roam an entire map while nav mesh modifier blocking others?
I’m working on a throw/spawn mechanic in a UE5.6 multiplayer project. The setup is shown in the image: the spawned items have Replicate and Replicate Movement enabled.
The issue I’m encountering is that after throwing, only the server sees the item flying correctly. On all clients, the item appears at the spawn location and immediately falls down, regardless of which player threw it.
Additionally, small items, like flashlights, sometimes clip through geometry and end up below the floor.
Has anyone experienced this before? How can I ensure that clients see the same thrown trajectory as the server and avoid these clipping issues?
Translated from GPT
For projectile you may want to use ProjectileMovementComponent
What problems can it solve?
Depends on what sort of projectile you are making.
That component already handle features like gravity, bounces (e.g grenade), etc.
It's quiet common to use in multiplayer setting but it doesn't solve every networking problem.
For smoothing, you most likely will have to implement your own. It all depends on what sort of scenario you decide for your game.
also there's more chance to get help in #multiplayer
any more thoughts on this?
Hi im having a very small issue where i am trying to access my enemy AI Blueprint by casting to it. How can i reference it so i can connect the widget to it?
casting is just a type check. The widget should know the owner of the widget and it's job is to simply read the state.
To start with, you can create a custom function to initialize your widget.
E.g A.I Pawn BeginPlay -> Create 3D Widget -> Pass self (object reference) to the widget it create.
Now that specific widget have reference to your enemy A.I. It simply just have to read the Attribute.
So Get percent -> Get Owner -> Get Health.
Thank you. i am just thinking why is there not a function that can just check - "Owner of this widget" then you can get the ref like you said
but in a simpler manner
As explained above, there is - but you need to tell it who is the owner when spawning it
not exactly what you are asking for, but I'd recommend the UI not doing any calculations by itself, make the enemy bp do the calculations and tell the UI what to display, it might get really confusing to debug in the future if you need to
Calculating percent is U.I job, the component shouldn't need to convert the raw attribute value to percentage.
but that is my point, why should i need to tell it who the owner is - when i have a widget component and i specifically use the Widget blueprint. in the widget i should be able to jjust get owner.. and that should be it. i shouldnt need to go into the Char bp and tell it who the owner is
You do have to initialize it, how else would it know who the owner is?
The owner is something you define. It could be a player controller, it could be a player state, it could be a character, it could be an object. It could be anything.
current hp/max hp is not that hard for the bp to make, but I was mostly saying it for more advanced stuff, the blueprint does not need to have the values, you can just pass the calculation
or just pass the hp.
let the percentage visual calculation done in the widget.
why do you want the character bp to keep calculating percentage? The widget may not even be necessarily shown or nothing needs it.
It's important to keep one way depedency but in the case of displaying Text from a result of conversion, that's the widget job.
E.g Percent = Current Hp / Max Hp.
the blueprint itself? it should now that the owner is the bp itself?
you need to inform the ui to update itself anyways, unless you want to brute force it and check every tick, so just get rid of all the work and tell the ui what to update to by passing the percentage anyways, that way you wont need to keep a variable to track the owner etc
No, you should never ever ever NEED to tell the UI to update.
U.I job is to stricly READ the owner state.
there shouldn't even be an instance where something needs to tell the U.I to update.
e.g Character -> Get Widget -> Set Health/Text. <--- this is shit tier coding.
The normal workflow is to have delegate in the Owner.
anything else can listen to it.
that includes the U.I
This way you create one way dependency.
The Mediator Pattern:
Software Design Patterns are like a guide on how to write good code, whether you're using Blueprints or C++, knowing good software practices is a MUST!
This video goes over the mediator pattern to build a "Combat manager" to coordinate actions between multiple enemies and the player.
We will also be combining the mediator ...
^ formative video imo. Help stop people shooting their own foot.
I would re-iterate that the owner is something that you need to define your self. Are you assuming that the widget owner should always point to the instance that create the widget?
because that's not necessarily always the case.
With widget components it is slightly different, since technically the owner of the widget is the widget component. But there is some weirdness to how GetOwner works in this case, I don't remember precisely
I create my widget in my HUD object but the owner is my player character / controller, not the HUD.
would a switch on int work after setting the curent dialogue int variable? like have it switch to question logic if the entry of the array is a question? or can i maybe check if the current line of the array contains a question mark and if it does, run question logic?
im trying to switch camera and start a sequence level once i step on a trigger box. the problem is that when I trigger the camera and sequencer the sequence its self not move the camera. and when i close the sequencer on my layout the position even change
Where does one view Watches on Blueprint nodes?
Having a widget problem.
I have an item system where you select the item user, select the item and then select the target for the item.
The select item user and select item target both use the same horizontal box with buttons in them.
This works fine with gamepad and keyboard for the most part...
The issue is, you cannot select the target for the item with the gamepad if the target is the 2nd or 3rd party memeber.
The first party member works fine and keyboard input works fine.
So when the horizontal box with the buttons appears the second time, something is wrong with the focus/ visibility that prevents on click from firing with a gamepad.
If I swap the order of buttons in the horizontal box, like making the 2nd player button the first to the left, that one will work with the gamepad and the rest will fail on click events.
the first picture is how I set up visibilty again and focus for when you are selecting your item target.
So it has to something to do on where the buttons are positioned on the horizontal box... moving the buttons over like this fixes it?
event driven design is better for performance, if you have 10 different widgets checking a delegate every tick is unnecessarily costly, you can obviously do however you want to build it, but why waste resources on doing unnecessary checks if nothing changed on the UI.
Obviously the manager systems have their use cases, but for simple UI, I'd suggest not wasting resources, there's no upside of doing tick based design for ui.
Sure there is, if the UI is changing all the time anyway, it doesn't hurt and simplifies things.
It is unnecessary. Let me set up a blueprint pastebin
:
you mean how to watch a value ?
"watches" ?
when you run it select the debug bp
Could you elaborate on this please.
you want to watch a value ?
Yes. I can see that I can set watches by right-clicking on nodes. I do not know how to get something useful out of doing that.
so what bp are you trying to watch ?
is it place in world ? or spawned ?
A menu blueprint. Does that change something?
you want to watch the value in a widget ?
Yeah.
while the game is running, goto the bp where you want to watch
and at the top you'll see it says no debug selected
drop that down and does that have options you can choose from ?
you should be able select the one to "debug" and the watch values will show up
It does not.
and your doing this while the game is running ?
goto the bp
hit play
and then drop down the list
when the thing is on the screen
if it's running and the drop down has nothing then you didn't create the widget ?
I need to run the game and then go into the dropdown menu?
the game has to be running to "watch" a value
I was expecting something like a "Run in debug mode," my bad.
basically for the bp you want to watch, you have to select the one to "debug"
this way it knows so say you ahve mulitple what one to watch
There is a pinned link with the explanation how to use the bp debugger. Did you check it out already?
I did not, that sounds helpful. Thank you.
loop in reverse ?, but also are you checking for 2 spaces and 3 spaces in a character array ?
idk if that will work but you should atleast see one space
but you can't just remove from an array that your looping over
without side effects
unless you do it in reverse
there is a foreach in reverse
I added that in just in case
New Widget question: Is there a good way to shrink this?
All these iterations are pretty much of exactly this form and that feels intolerably WET, but I can't think of a good way to condense it because even if I macro it out, I still need to set all those Target input nodes so it wouldn't really condense all that much. I have very little experience with Widgets so I'm hoping there's something I'm unaware of.
So i kinda see the problem. Wrapping the horizontal box in a size box.
Ifany button is outside of the size box it wont be triggered a second time unless its with the keybord. How to i fix this while keeping the positioning of the buttons?
Doing a width override on the size box dosent workl
not bad, now you can just add a bunch of === to the or ?
thats one way to do it
i like the idea of having a chars string
seems a bit easier to work with
or perhaps even i think a more usable version would have a map of chars to replacements
Hello! I have a character and I want to give them an equippable Gauntlet. What's the best way to have the gauntlet match no only the arm position, but the wrist and finger movements too?
wdym "match the finger movements" ?
i think the basics is to just use a socket
The gauntlet would have finger joints.
So if the character's fingers move, the gauntlet's fingers would move too.
if u rigged it to the same skeleton then yes
return nickname string not the array joined
how does that code find empty spaces?
It needs the === I think
( === space )
it doesn't because you didn't copy what i was doing correctly
you need the second input
and loop over that instead
is anyone able to help me figure this out?
^.^
it works already btw
thats all that matters ig
this is the code i have for it, my issue rn is trying to tell the ui when a string in the array has a question, could i do something like add a check to see if the currently selected string in the array contains a “?” in the string and if so run question logic instead of normal dialogue logic?
yes for sure
substring
so inside my inc speech before i increment the int “current dialogue” check to see if the string contains a “?” and if so run a branch to decide if the player can proceed to the next line or if they have to click a button inside the ui?
or where should i put the check at
i mean think about it logically i didn't look at the code
logically where would you check ?
if your doing a dialog system
ive been trying to think ab it😭 thats why i been asking ab it for a day n a halfish😭😭
id assume id check before increasing the line of current dialogue
yes
so do you have some buttons when the text is shown ?
to proceed ?
do it when you click the next button or whatever your using
i have buttons in the ui to answer the question when it pops up, other than that the player only has one input that runs a trace (for the dialogue atleast)
so the buttons change with the question ?
like how i do it is for different stages they say different things
same button different text depending on the state
thats what i was planning on doing, just not quite sure how yet
have a state
or a variable that represents the state
even an enum
might work for that
and for the question logic. id assume. id make it once the question is on screen. have each button set the next line of dialogue int to the answer for the question like if the player hits yes sets dialogue line to 6 or whatever, if player hits no sets next line to 8 or whatever
for if buttons are active or not? or for the actual options of the buttons
basically what state your in
like is it a question is it not
no just do the check
bc if the check is already telling the ui its a question, cant i have it run off a branch to say if contains a “?” make the buttons visible
yes for sure
would this work. or would it end up being too clunky. i dont mind hard coding the dialogue option responses in this instance bc theres only a specific amount of npcs in my game that can ask questions, just wasnt shre the best way to go about it. just in my head i thought. if i set the current dialogue int after player clicks the button. then the increment speech function can continue from the newly set current dialogue int bc the check to see if its a question will fail and should run like normal
yes this would work by setting the indexes like a choose your own adventure
but thats seperate from the check
not off the true or false for it?
yes you can use the true or false from the response to do whatever you want
you may be able to use your already code
because if i recall your already doing every letter like an animation type of thing ?
ok ill have to try it out. the npc dialogue in my game has been such a hassle past few days😭 hopefully it is almost done
so you can just say if a ? pops up while doing this animation
yea like they load in character by character controlled by a float delay for speed
set the variable to true
right you can use this time to check for a ? as well
to make things a bit more efficient then searching after youve already looped
Help I'm trying import a vehicle to replace the default vehicle and when it lands on the ground, it's an angle. Any idea why? Using 5.5
idk how to check this, but my guess is the wheels are at the center of the vehicle for some reason
thanks!
Ok, so I have a basic almost barebones game project started. I have a cube blueprint that I can spawn and destroy at will. I have enabled physics on the cube so that I can push it around the level, but I'm noticing that when I push the cube around, its transform remains the same regardless. As you can see in the video, I push it and print the transfrom on hit and I keep getting the same transform printed out on the left. Can anyone explain what I'm missing here?
The cube actor remains in the same place, what's been moved is the cube primitive component only.
You turned on physic on the cube, I think that will detach the component from the actor.
