#blueprint
1 messages · Page 81 of 1
yh
Okay, I need to learn that then... haven't tried it
it loops with event tick
It's really useful once you learn it
So for rotating the objects I could have a boolean to check if the object is held, an input event like RotateObject, and switch the input mappings when the object is picked up?
Is that the general idea?
You probably don't need to use input mappings if you only need to add one input but I'm only a beginner so I don't really know the best practices
which nodes could i use to make a thingy that checks for a specific actor in an array and returns a boolean of true or false based on if the actor is in the array
with event tick, the timer doesnt delay the shots just rapid fires, but with beginplay just shoots once
can you show the bp?
you could do a for each loop and check if the actor has a specific tag
Is it a thing in unreal that if you have 2 widgets on the screen, the buttons from the widget on the bottom cannot be clicked?
you need to put the spawnactor logic in the firing event cause that is what is getting repeated
ahh i can use contains node
nice
Can you reply me for this?
makes sense, how do I open the event to add the code in?
drag the arrow white node from the firing event to the spawn actor and remove the link from set timer to spawn actor
then it should work
like this? it doesn't fire anything
put the begin play into the set timer
and remove the white link from spawnactor to timer
thank you for the hand holding, it works nicely now
np
Hello, When i change dynamicly the mesh of a skeletal mesh. Which material is apply by default on the skeletal mesh? do you know?
i have define into the model this
but when i play the last one is blinking
is it possible i have some conflict?
i build my mesh like that
I want to say should be able to click any number of separate widgets at the same time as long as none of the functions/events get rid of your mouse cursor
How to change a ui position at run time? it seems impossible
help would be really apreciated
I haven't tried setting a widgets location at runtime but maybe if there's a way to get the clamp and change its location not sure off the top
Alternatively copy the widget bp, change the location of it then have it swap between the widgets in viewport as conditions are met. But depends on your need case just a temp solution
You want the widget to appear where your mouse is?
yea
I feel your super close one sec you'll want to get your cursors x and Y then attach it to set position but I'm not sure the node yet
hey there i am facing a strange problem my joystic is not comming on screen i enable sho touch input but still i am using activate touch but no touch is comming
the x and y are the mouse location
I'm not sure the use case off the top but this also works kinda it changes icon based in button or if cursor is over select items
Change Mouse Cursor With OR Without Events!!! Compatible for both Unreal Engine 4 & Unreal Engine 5. ue4, ue5.
🕺 Come join the Team Beard Discord 🕺
If you're a game developer and looking to join a friendly game dev community which ranges from expert to professional, be sure to hop into the discord! We're always looking for more awesome peop...
sadly, that's not really it
Gotcha gotcha
solved
What was it?
I will just create a widget and before adding it to the viewport, you set position in viewport to the mouse position
Ohhh that makes sense. Create, then set location very good
I'm tryna add a group of widgets into the grid box inside my editor utility widget so I can set which tile should activate to what direction
but when I click on the button, nothing happens, yet it is firing all the way to the end
what am I missing?
this is how my tile widget looks like
Hello, I'm trying to understand how to cleanly manage my player states in Unreal and set behaviours for each one.
I understand using Enums might be good for this. Anyone have any good resources or examples of how to set this up?
I'm confused how I manage this and block player movement in certain states and things.
hi unreal dev any good tips on
for translate between earth ground to space orbit earth any good blueprint tutorials for this ?
hello guy is there any node that can load player item before spawn
how can i cut a whole in a mesh at runtime ?
I want to use an cube in an actor to cut out spaces in a mesh
hi, can I cut a ui at run time?
Howdy folks, got an annoying little bug here. I have a list view widget that, obviously, displays a list of items. I'm following this example: https://forums.unrealengine.com/t/quick-start-guide-to-list-view-widget/738161. The first screen shot shows my code, and you can see in the second screen shot that the code is correctly obtaining data for the list and dis. I compile everything, save everything and then close my UE5 project completely. Upon reopening and playing my project the data no longer shows in the list widget (Screenshot 3). I can fix this easily by replacing the 'CONSTRUCT' node, as seen in screenshot 4. After replacing the 'CONSTRUCT' node, the widget works as intended again, as seen in screenshot 2, even though it is exactly the same node as the one it is replacing, and i can even just copy paste the same node and it works. Why does closing my project somehow stop this working? This seems like a very commonly used functionality, surely it cant be this buggy? Anyone know how to continue development on a project without constantly refreshing construct nodes eevery time you open a project? its infuriating! any help greatly appreciated
i'm trying to move an actor slightly randomly.. like have it hover on place
ideally without AI.
any tut? or ideas?
Is there something like an Actor GUID for a shipping build?
I was using it as a key to uniquely identify actors placed in levels, but unfortunately, they're all zero in a build.
Hey im trying to create a spectator system i managed to set it up but the problem is that the camera is not the same as the first person character camera that the user is spectating im using set view target with blend
i cannot edit character blueprint when project is created as c++ ?
Is there any way get an array of bones with physics bodies and or constraints?
Has anyone expereinced where you can no longer place a breakpoint in a blueprint, either by right clicking on the node, or by pressing F9? I must of clicked something somehwere to disable it, but I have no idea where 😅 It appears to only occur in a Macro
Bit of odd one this but if I wanted to use these assets in my game, I'm guessing I would need to migrate the assets I want from that project to my project ?
or is there anything way to do it ?
Sometimes i'm getting infinite loop detected, is there anyway do this more efficiently ?
i'm trying to generate some random numbers but i don't want ones that are too close to others
I would generate a random starting number (0-20) add it to an array. Then generate another random number within a range (10 - 30) that gets added to the previous number. Repeat again using the last number. This will save you having to loop through all your previous numbers.
You can create a var of type GUID. You can just create a var on the actors that need one.
so your saying just load it in a pattern ? the first would would be a lower number, and the rest are higher ?
hmm
Yea, you could always shuffle the final array to mix them up afterwards.
well i'm generating a string
and generating random numbers
for that string
idk how to shuffle the array would work
There's a shuffle node. Plug in the array and boom lol. Just do it once you've added all the random numbers to the array.
Yeah, I've ended up with an actor component that handles GUID generation and it gets updated with the construction script (but only generates if it's zero)
Maybe next time I won't ignore that big gear that means "EDITOR ONLY."
I'm only using the array to see if i generate one closer to the other, i'm not actually using it for anything else
Yea thats what I do. Just be careful when you're duplicating actors in the level (editor) though as they'll have the same GUID as the original.
Can you show how you use the numbers to generate the string? I might be able to get a possible solution.
I have a widget inside of a enemy blueprint to show some data above him. Within that widget, how do i get the owning pawn so i can call function from it to get data to update the widget?
i'm really not using the array, i'm using the random number generated
it's how i'm building the level dynamically
but i guess i could generate them in a specific section per index
i was hoping to find some sort of way to keep them seperate but random without this infinite loop problem
@lofty rapids Something like this would do the job. You should be able to slot the stuff you're doing with the strings after it. So you'd generate all the numbers first and then use those numbers for the string part.
It does sometimes go over the max but you can always clamp it or modify the max value it can add. (I've probally made a mistake in it)
I have a enemy class. I added a widget to that blueprint so i could display a UserWidget blueprint over the enemy head. How do i get a reference to that enemy from inside the widget?
I'm not entirely sure of the hierachy of widgets when inside a widget component but this might work. Assuming it's being called from the actual widget type thats selected for the widget component (not any children within the widget) I would guess the outer would be the widget component which you can then get the owner of which would be the character it's placed on. You can then cast if needed.
Anyone have any thoughts on using Click Events vs Line traces?
In what regard?
Well for interacting with objects I always see people using line traces to detect objects being interacted with by player but just discovered how much easier click event on collision box is to set up
Don't seem to need interfaces and things
Ahh, ok. Well normally you want to know what the player is looking at before they actually click on it for showing a pop message or apply an outline effect. It's much easier to handle this using linetraces and what you interact with needs to reflect what you're looking at so using two different systems would cause headaches. Using a linetrace means you can use the same data and have everything run through the same system.
Adding to this, sometimes you might not want pin point accuracy so using a sphere trace can allow you to get the object without looking directly at it as well as handling multiple actors nearby.
Another thing to be aware of is other systems might need to know what you've interacted with which would mean what you've interacted with (using the click events) would need to communicate back with the player which isn't ideal as you want to keep communication one way as much as possible.
If all you need is a simple click event, it's great but more often than not you need an interaction system which can't be done with a click event.
ok that did compile, but now i must be doing something wrong. the progress bar is not updating. I did click "create binding" on the progress bar, and added the enemy health to feed into that return value.
Did you get an access none errors?
when does that binding function it created get called? does not seem to be firing. so i have to manually call it?
no compile errors.
Great answer, thanks Pattym
I mean after you've tested it.
No probs.
i test it and the progress bar is just 0 always
Show how you setup the binding.
Another question, I'm very confused on how to manage my player states cleanly and efficiently with blueprint, is using an Enumerator the right start?
Can you elaborate on what you mean by player states?
i dont even know what i mean. im sorry. gonna scrap this and just follow a different tutorial.
Ok no probs, good luck. 🙂
My player has different states like... digging, walking, conversing, inspecting items, and these have different implications on input, movement speeds, what effect different button presses have (e.g. the back button) and I'm unsure how to manage all that
I know how to set that up independently but when it comes to connecting them and having them work together I get lost
Well from a player input perspective I would use different Input Context Mappings. You can have different control sets for the different states there in with there own input actions. It would just be a case off adding and removing when needed.
An enum can be a good way to handle this and when set could modify the walk speed and the main ICM. The advantage of using an enum as well is you could get it in the animBP to control what the main state tree is being used for things like Crouching, Walking, Swimming, Sitting etc...
Thank you.
I am using let click to set the destination for my character (Top Down template), would it make sense to have a second binding that is using the left click to do a line trace but with the same key or should I just use 1 input for both.
It depends how you want to do it. If you click on something that's interactable, you might want the character would move to it anyway (and then perform the interaction when reached) and if you don't click on an interactable it just moves to where you click. In the case, you would probally only be using one input action anyway.
Thanks again!
simple and quick question
is there a way to influence the cursor speed? using blueprints
The system cursor, i don't think so.
sad.
What are you trying to achieve?
basically, I have a character which is static (he's not moving and the camera too), only the mouse can move
the player should be able to change their mouse sensitivity in game or it's gonna be really boring to change it mannually
You could hide the system cursor and have a cursor widget move to the actual cursors location. You'd be able to control the speed it moves to it. Depending on your end goal, this might not be applicable though as you would need to check what's under the widget instead of the actual cursor when clicking.
I guess, I will need to learn c++ to implement that lol
Hey Brothers,
I managed to get the multiple enemys heatlh and damage works, now i have a little problem, if i spawn 2 of my child class [ AI_HUNTER ]
The Widget HealthBar it's gonna measure the health for both of them.
if the other Enemy [same class] spawns when the first one's at 5% HP, the other will have the same amount of HP [Only visual [widget]]. Any ideea?
is there a way to open very old blueprint files and just see what nodes were in a certain place
i guess i could download the whole repository at that date so it opens but thats going to take forever
as a reference.
Hi all - I am trying to create an Editor Utility Widget which adds the selected blueprint of a specific class to a sequencer. I am stuck on adding the selected actors of class to the sequencer. The drop down would suggest " add actor to sequencer -> add selected actors", but I cannot find the equivalent blueprint triggers. Any help would be much appreciated -Thanks.
I think I worked it out.
why are you using get selected actors, your not using the return value ?
You're right - I should use Get Selected Assets of class - Yeah?
or you can just use get selected actors and loop through those, are you only try to use the selected actors?
idk if that function works but it sounds like what your looking for your not using it correctly, why get all actors of class after, which one do you want to use ?
You are probably correct that I am using this incorrectly - I am looking to only add specific actors of class from my selection.
no output = useless bro
Hi I keep getting this error but I can't change any character movement settings on the child blueprint to add new references or at least I can't figure out how to? any ideas?
Blueprint Runtime Error: "Accessed None trying to read property CharacterMovement". Node: Branch Graph: Handle Enemy State And Calculate Degrees Function: Execute Ubergraph BP Base Enemy Blueprint: BP_BaseEnemy
what happens if an actor is set to no owner?
you can maybe get selected actors loop through them, try to cast to your bp ? i'm still learning might be a better way
Thanks - I had just done this before I read your comment
If i have a enemy blueprint (based off pawn). and i add a widget to that blueprint, then assign a userwidget i made to that widget so it can be placed above the enemy. How do i get a reference to that enemy blueprint from the userwidget blueprint now?
Trying to fade between levels can swtich but failing with the fading, Anyone help on this Im close. just not getting there. Cheers
Is this the correct way to change input mappings?
I'm trying to make an actor component that subclasses scene component, because I need the transform. But I've found it's really hard to use with no visual element. Is there a way to attach an editor-only visual element to a scene component, like that white sphere that the default scene components have, or an arrow like the arrow component?
It's frustrating that I can't just subclass ArrowComponent directly
GetBoneMass Seems to return 1 or 0 (it recognizes the mass scale but that's it.)
Has anyone ever got this node to work properly?
Not exactly looking for help more so a starting point. I’m looking to make a state where when the player presses a spell cast input the camera is disabled, an actor is spawned, and that actor can then be moved around with the right stick, after say 5 seconds it passes its location to another actor who spawns there just after the “aiming actor” is destroyed. If anyone has played dragons dogma, pretty much the spell aim in that game. Just not sure where to even start for being able to control another actor manually with the right stick, I should be able to handle the rest of it, Any ideas would be great thank you
Can I use a skeleton mesh in a static mesh?
What do you mean in one?
It’s ok I just need to convert
i set up all my control functions in the pawn not in the player controller.
the player controller doesnt cannot inherit from AI controller.
so i think this is better so that i dont have to repeat the same function in player controller and the ai controller
am i correct?
How can I apply different colours to different parts of a skeletal mesh
What is the simplest method for delivering a UMG using the Lyra framework to the player? - in BP
Anybody see whats wrong with the function?
what are you looping?
nothing..
speaking of.... how would you set a certain enum in an enumerator to hidden?
thats how a tutorial said to pull out the variable is start. What would be a better way to find the starting piece compared to the other board pieces at the start of every level?
well the if will probably alway be false because there's no value to it, it's just looping nothing and trying to get an information from it, the tutorial is probably wrong
nm, apparently theres a UMETA flag in C++ for that and this just skips whatever ones you hid.
Would I not be able to set the board piece to true on the piece itself?
annoying its not in the editor tho
you are looping through a list of actors and not doing anything, then trying to get info to it at the end of the loop, everything seems wrong
How can I create an ability system like this in Unreal please ? https://youtu.be/6RN57ibqfHY
By that :
- Having a palce to set up a keybind
- Having it linked to a UI, with a progress bar, countdown
- Play an animation when the key is pressed and the ability isn't in cooldown
- etc...
I want to create a system like that to make it modular allowing me to create as many abilities as I want, and applying them or removing them from players when I want. And having different animations or doing different stuff according to my code 🙂
Learn how to create an in-game object that your character can pick up, and make it activate an in-game ability and display in the UI. This video is part of the Core Tutorial Series. Here's what to watch first:
Introduction to the Core Editor - https://youtu.be/pWvFgTh0jp0
For more tutorials and information visit https://docs.coregames.com.
...
Only in cpp with UMETA=(Hidden)
Hi All - I am getting a datatable reference from another actor via a Widget Editor Utility. I can read the datatable fine If I reference it manually from Get Datatable Row, however if I use the cast reference from another Actor (which sets the datatable as a global variable actor), the outrow pin greys out, and I can't get the data from it. What am I missing?
you mean this "grey"? This is because the blueprint couldnt determine which struct you are using based of a variable based DataTable, because the DataTable pointer is nullable and there wouldnt be any struct in this case.
However, from the "grey" node, you can actually break into the struct you would know the data table will have.
Yes - correct, that grey. How would I break the struct?
drag it off, type break <structname>
"grey" node means a wildcard, basically means the type hasnt been determined yet, and it could be anything.
anyone know why this is running an infinite loop? its probably really obvious 😭 but i cant seem to figure it out
how can i change the forward direction of character after switching camera? For eg when i press the W key it should move in -Y direction
how can i change the forward direction of character after switching camera? For eg when i press the W key it should move in -Y direction
You can swap the logic that happens with the input action move forwards axis and the input action move right axis depending on if the camera is third person or swapped to the other position using a bool.
im switching cameras on overlap of box collider
Mabye enabling "Use Controller Rotation Yaw" when you switch your camera to the top camera will do the trick
its being like this
you enabled that option ?
u mean this right?
u mean changing the movement inputs?
Try adding some print statements and see which is looped, I feel it has something to do with Is In Range
The input action bindings for MoveForwards and MoveRight have an axis value float either -1,0, or 1. This is when you hold W, S, A, or D for standard movement. What you can do is have a boolean setup for when the camera switches then have the input action events check first for that boolean before rerouting what happens with the incoming axis value for both MoveForwards and MoveRight. Maybe a value of 1 for W goes into move right instead of MoveForwards that sort of thing. It depends on how you’ve rotated your camera.
i can that try that
Check this, if it helps
You want the movement axis to follow the camera orientation? So in the top down view, W would go "up"?
Should also rotate the character so it’s facing the same way as the camera.
yes!
In that case
1. Get the Camera Forward Vector:
Use the "Get Player Camera Manager" node to access the camera component.
From the camera manager, extract the "Get Forward Vector" node. This gives you the direction the camera is facing.
2. Invert Y-axis for Top-Down:
Since "up" in the top-down view is typically considered -Y, you need to flip the Y-axis component of the forward vector.
Simply multiply the Y-axis of the vector by -1.
3. Move Character based on Adjusted Forward:
Multiply the adjusted forward vector by your desired movement speed.
Use the "Add Actor Local Offset" node to move the character in the direction based on the calculated offset.
This method essentially takes the camera's forward direction, flips the Y-axis to align with up in the top-down view, and then uses it to move the character accordingly. So, pressing W will always make the character move in the direction the camera is facing, regardless of any camera rotations.
Additional Tips:
You can use a "Compare Floats" node to check the camera rotation angle and adjust the movement based on specific thresholds. This allows for fine-tuning how the character behaves at different camera angles.
Consider blending between world-based and camera-based movement for smoother transitions when switching between camera views.
This worked Thanks!!
Np
Only would need to change one thing from the TPS template
thanks! i fixed it before this message, but yeah it was a problem with that, and also something was up with the while loop, so i just moved a validated get in tick and plug it into the attack function
The rotate vector instead from the local camera, get from camera manager instead
ohh nice
yup
✋ If I use "test array", it works well, but if I use "Items",it prints 0 which means no element in the array. Does anyone know why? Is it because it does not support setting array element in another array?
That array is on a pure node (the green node), so every time you're using that array you're calling that node again and getting a new copy of the array from it.
OMG...Thank you a lot😃
Sup everyone
I draw a blue sphere at actor location (Screenshot 1)
For some weird reason at higher speeds actor position is straight up wrong (Screenshot 2, Screenshot 3 - as you can see, the faster is speed, the bigger the offset)
How to fix that?
In regards to AI Execute events, does the success bool on the Finish Execute node actually correspond to some other functionality that I shouldn't just be using it as a check of the task's outcome or is that all it is? I don't want to be tripping up the engine by making it think something went wrong by saying fail if there just was no desirable condition to call a "success" for my personal use
I want to find this node on top, but when I search for 'Rotate Vector', I only get this bottom one with (Quat), how do I get the top one?
I've been learning about the concept of delta time and its uses to prevent linking important functions to framerate. If my movement system is structured so that it always moves the player x units per button press, am I right in assuming that incorporating delta time into the distance calculations is irrelevant?
Now how to change pawn's forward vector such that W should make the pawn go up direction
i didnt add any movement code in the pawn class yet
I don't see why it would be irrelevant? Your code will behave differently if your button press is queried 120 times per second or 60.
You'll move 120 x UNITS or 60 x UNITS per second.
Delta time compensates for that.
I use version 4.26, I don't think that version has it, can I use something else?
why do u use 4.26?
old code assets that don't have newer versions etc that dont work on newer versions
that doesn't work either, idk what else to do
send a screenshot of ur search?
But it's down there
🤦♂️ thank you, idk how I didnt see that
what you're saying makes sense but I'm getting confused as to how it can be applied to a dungeon crawler movement system.
Basically what I'm doing is moving the player 1000 units when the movement button is pressed in the direction they are facing
This movement is Lerped using a Timeline alpha to simulate a smooth transition between the old location and the new location
I have noticed that the Lerp or whatever's update rate seems to be tied to the framerate
but that doesn't seem to have a functional impact

np 
Timelines are based on time and thus don't need correcting for the number of frames if using it with a lerp node. (Using an alpha curve in the timeline)
Yes, that extra context changes things.
If you're using a timeline it already has deltatime correction.
The success bool in the finish execute node is used by the sequence and selector nodes in the behavior tree. These nodes (depending which one your using) will either break it's flow or continue down the chain.
thanks kings
np np!
That's not entirely true. It depends how you use it. The values used in the curves are yes, but the number of times it executes (updates) is dependent on frames.
Yes, but in this case the end result would be the same.
A timeline finishes in the specified time.
But sure, I guess it can be relevant to note that the Update function runs a variable number of times.
I want to create an objective system, but when I look at examples, I only see tutorials triggered by overlap. For instance, after completing a crafting process, I want to complete an objective. Is there any example like this anywhere?
First of all I might recommend this free plugin, which we use for our game with good success:
This system is based on quest/objective/task ID:s, and lets you finish tasks in code (or via Blueprint) arbitrarily by simply calling FinishTask(TASK_ID)
I dont have c++ knowladge may i use still ?
Yes, it's fully BP exposed.
Although the plugin is source code.
So you'd need to have a basic C++ setup.
Then it should be fine!
Regardless of how you approach it you'd probably have some function similar to FinishTask(task_id), which you could then for instance call by subscribing to an event in your crafting system.
So OnCraftingComponentFinished(ITEM_ID) --> FinishTask(TASK_ID).
Read the instructions on the repo.
Creating your own isn't too complicated but you do need to be comfortable with event dispatchers and how to correctly reference things.
They're right there.
I agree, but this I would say is also a place where you might re-invent the wheel in vain.
Although SUQS does have some shortcomings that I'd like to address, it sure was time saved.
may i use this on multiplayer game also ?
I don't think it is replicated out of the box.
(of course creating a quest system is excellent for learning, by the way -- I was thinking mostly from a production standpoint)
The time saving can be questionable but that would be down to experience. A basic quest/objective system can be setup from scratch in an hour or two.
I will try this dispatchers again
but it did not go well last time
Yes, but why have a basic, shoddy version of the same thing that you'd constantly need to extend, when you're probably going to end up with roughly the same end-result?
You'll need a quest manager (actor component) that can be placed on the player controller and then a base quest/objective uobject you use to create the quests. The manager would then have functions to create and initialize the various quest objects and store them. The uobjects when initialize would then bind to the various event dispatchers it needs to know the quest has been completed.
You might need to go through your other systems and add event dispatchers for logic events that the quest system can use. Like picking up an item, interacting with something etc...
The time it can take to implement someone elses system can often overshadow the time it would take to make one from scratch that could better work with existing systems.
You can also run into an issue where big crop up do to features that might not actually get used.
It's swings and round abouts but it's always good to know how it works either way.
Fair enough.
Realistically you won’t understand much when you implement someone else’s code
Gotta get your hands dirty to actually learn
Yes, but I also think it's stupid to impose some stigma against using plugins for very common tasks.
I think the only system I've seen where I've thought 'yea, I'll just use that' is the ultra dynamic sky and weather. It's all self contained and doesn't need anything else but you can have other stuff call functions on it which is nice.
The excellent DLG dialogue system is a key one for me.
Depends on the plugin, good non-Epic ones are few and far between
Definitely.
But they sure do exist.
I just tend to find them on GitHub rather than the epic store.
This uobject does not mean c++ class right ?
You can make UObjects in Blueprint but the workflow proposed by Pattym is probably best suited for C++.
It doesn't make a difference. I use blueprint based uobjects all the time. There the backbone for a lot of my complex systems and not a single bit of C++ is used.
If you say so. How does world context work with BP UObjects?
No, you can create bp uobjects. They don't have any context of world but using a manager that's creates them, you can usually get outer and cast to the manager to get references you might need.
They don't have any world context. 😉 this however is just a mild inconvenience.
I need to see example inside of quest manager and base quest class
If you dont want to share i will find another way
I can share an overview of the system I made shortly.
Thank you
me getting frustrated wondering why a node wasnt working only to realise i hooked it up to the wrong input
>debugging function not working for 1 hour
>realizing I never call the function
Guilty as charged haha
This is the general gyst if you can follow it. The first 4 screenshots are from the quest manager, the next 3 are from the base quest object and the last one is setting up a quest where the player needs to speak to an NPC. Adding a new quest is a simple as getting the quest manager and calling the add quest function and specifying the quest object you want to add. In the quest object you override the 'Quest Started' function and add the logic to start the event dispatchers you need. In the example, i get an NPC dialogue component and bind to the on conversation started. When this happens the quest object knows it has happened. You can then override the 'QuestCompleted' function to define what then happens. The quest manager will automatically remove the quest from the active quest list when the 'OnQuestCompleted' event dispatcher is called inside the quest object.
There's a few other stuff but there not important to the general function of the core quest system.
I am on it thanks again
No problem.
Hi. So I have an actor blueprint that is causing problem. It's not returning as valid on my player character, and yet the component has no compiler errors.
To fix it, I delete the component and replace it. The component now returns as valid, no changes have been made in the component script itself.
However, whenever I reopen the project, the component that just returned valid before closing UE5, is now no longer returning as valid.
Does anyone have any idea on why/how this oddness occurs?
What is this "AC UI manager base" ?
I start questions with first picture ofc 😄
That's just a setup I use for handling UI stuff. You can just create you're quest widget and add to viewport here.
Interesting, the outer of a widget that used in a widget component is the game instance. Hmmm... 🤔
I can see widget in game when i add quest manager component to character but getting this error
This might bee a dumb question, but what us the difference between a set and an array?
You should add the quest manager to the player controller. As for the error, I'm not sure what could be causing it. The only thing I can think of is it's being called more than once but one of those times it fails to create the widget.
A set is an unordered list of unique values. They're great for when you want to just compare lists and the actual order isn't important. They also have different functions to help combine and split sets.
Ohh ok
May i add to viewport in player controller ?
Yea, UI stuff is assigned to a player controller anyway.
Btw could you take an unordered set and turn it into an ordered array?
You can convert a set into an array for when you need to loop through them. The order tends to be the order they were added to the set but this isn't gaurenteed, especially if you've done some manipulation to the set.
Oh true true
I just have a few arrays that can be turned into sets
This dispatchers class also quest base right ?
Which dispatchers?
Here
The reply only points to the whole comment not a specific screenshot.
That's in the quest manager.
Yes i am asking event dispatchers classes
should be basequest right
The event dispatchers shown in the screenshot should be created on the quest manager. The quest object base has it's own event dispatchers.
I understand that but i was asking event dispatchers has any input here
how would i implement a first person directional melee sword system like mount and blade..
i have the animations set up i just need a method of picking directions
Oh, i get you. One min.
I only got to setting up the quest added and quest completed but they have an input that is the quest object. (I had planned to set up something on the quest updated so the UI can be updated, you can always ingore that one for now)
perfect thank you again
Wouldn't the direction just be the players desired movement direction when they click the melee input? If there not moving, it would just be the forward vector of the character.
I have this bp to do DoT damage to the enemy but the event doesn't activate. I can print a string after the do once node but not in the event
Timers with a time of 0 don't get created as it would be the same tick. Instead of having the delay in the Apply DoT event, use that as the time for the timer and remove the delay node.
ok I'll try that thanks
I have an attribute named Mesh which is a path to a static mesh. How can I convert my path into a static mesh object reference so I can read the bounds of the object?
How can I make a editabletextbox that I can interact with through hand tracking? Any one know a guide I can use? I've been looking but haven't found a solution
Aight, why can't my line trace detect my metahuman?
So here im possessing the mirror and trying to rotate that by rotating the platform but as u can see in the video when i rotate the platform and then possess the mirror again it changes its location and rotation. I cant understand whats going on here can anyone help?
try checking collision response for the channel u r doing on line trace
it should be blocked only then it will detect the hit
Hi guys, I have some information. I would like to make it so that if I give values to my character I increase the height and length of his arms. Is there a way or even a video where you explain it to me?
You've not shown how you're possessing/unpossessing the mirror.
im doing that by using the built in function Possess and here it is
Whats the switch player function?
its a event in thirdPersonBP to call the mirrorManager Function
Its normally a good idea to show the flow of functions being called. 😉 The issue might be in that function. 🤷♂️
parent manager is the parent class of the mirror Manager class
the defination of that function is in mirror manager class
Hi guys, i have a problem which i dont fully understand how to solve. i want to make the player win after he has done something. But i dont want to check everyframe if he has achieved it. is there otherways to do this?
I have recently started delving into Unreal Engine 5.3. Is it possible to build a library here for, for example, my materials and objects?
does this look like a object that will move only 200 in Z axis value or am i doing something wrong?
Hey everyone! I was wondering if anyone knew an alternative method than using EventTick to determine whether a boolean is true or false? Trying to not use cost effective methods to performance if there is another easier way to check.
Hello guys im using smart object as explained in a tutorial of Ryan Laley and it work fine but i would like to cast an actor from the class gameplay.Behaviour that is used to use smart object system but i can't get the class any idea ?
try this...on lerp, for A: connect Get current location. For B: Get current location, the connect x and y, for z : z+ 200. And use set actor location instead of add actor local of set
Why would already spawned chars get a value but not the player generated pawn off same bp?
You'll need to cache the get location or it still won't work
what does it to mean cache the location
delete do once, and try this. make a boolian (eg : is hidden?). The after the brach on your code for true: make brach with boolian (is hidden?). on true: connect your set hidden false part and set the boolian is false. On false of your first brach (is dark?) make a brach with boolian(is hidden) on false of the brach connect your hiding part the set boolian value is true
i tried this and it might work, but what i dont understand is, it now only moves up 200 in Z, it just doesnt stop moving. it goes above and beyond. i plugged it into an Action input Event so i dont understand
whats going on here, your looking for an actor with that boolean set ?
Put it into a variable
Otherwise you're trying to lerp between changing values which doesn't work
yes. Its setting the starting board piece as the current piece
Imagine trying to run between point a and point b, but they're constantly moving further apart
So then i have all the pieces connect with next piece and previous piece but it wont work unless the start piece is the current piece at the begining
you could use a break on the forEach to be a bit more efficient, but what is not working about it ?
it will only move a pawn already spawned in the game. but for instance if you have the pawn generated off a player start etc it wont move
and gets a null value
I could do a pawn possession instead of this but wanted it where players could customize their pawn which is why im doing it this way.
so you want to work it for a sing time ? right?
anyone know on how do i transfer data "score" of A_Quiz to "random score" of WB_leaderboard?
yes, i dont want it to constantly move. i want it to move 200 in Z axis once
Are you using enhanced input?
yessir
i tried, it just flies of
look here
So do what I said with the caching and it wont
When using format text, when using an input as a integer, it adds commas to the number. How can i stop that ?
testing{someNumber} becomes testing1,200
i want it to be testing1200
without the comma
Yep
not excatly where i want it to be or how it should move
just teleport there and slowly moves up
Then your current location is incorrect
Yep u were right
thank you for the help
but why is it necessary to store it into a variable?
or like you called it "cache" it
floor:1,200; should be floor:1200;
i can parse with a different character but i would like to just get rid of commas
in the number of the format text
anyone know how to do it?
i figured it out i converted the number to text first and uncheck use grouping
So you want to move between the initial location and the final location.
What you're doing otherwise with getting the location is your point is ever changing.
So one frame you might be moving between 0 and 200, then next frame it might be 1 and 201, then 3 and 203, all the way to infinity
You're constantly moving the endpoint away, so it can never reach it
I see, thank you for clarifying it ☺️
is there only one a_quiz ?
you can probably get actor of class, and get the variable
but it's on tick, i would probably set the reference on load or something
so you don't have to keep get actor of class
on tick
usually i don't like to set the text on tick, but rather call a display function or event when it needs to update
for instance you only need it to update when the value changes, not constantly update
but it's a performance thing and doesn't really change much
it worked!!!!!!
thankyou
i just want it to display as text to player
i choose tick bcs i want it to keep up to date all time
makes sense, probably won't be a lot but i do microperformance stuff all the time
a lot of littles add up to a big
What analytics are you using for your games? I was using flurry but they’re shutting down now. I found out firebase is only for android. I have an app in both App Store and play store. Wondering what analytics service everyone else is using..
anyone can help me with this please?
https://www.reddit.com/r/unrealengine/comments/1adypel/comment/kk4b18v/?context=3
Hello! I'm making an ad system to show an ad whenever the user dies, however it crashes about 1/3 of the times. Heres the code.
heres the crash summary: https://pastebin.com/KqS2i5EU
I dont call show or load ad anywhere else btw and I have set the test ad id
This is a very basic question.
I don't like how I cannot scroll view distance of exponential heightFog more than 10000.
I know I can type in to get more than that.
But I want to smoothly scroll the distance value interactively without typing.
Is it possible to create a blueprint to be able to control the slider more than 10000?
Thank you!
Oofff a ad every time you die. o.O I always give low score reviews when this happens. So annoying.
Anyway, the error tells you the issue, 'The ad unit ID must be set on InterstitialAd before show is called.' looking at the BP, you attempt to show an ad before it's been loaded so I would say this is the issue.
I want it to go beyond 10000without typing it
I will make it like 1 third of the time, and also each level lasts like 4 minutes
won't it work since I have an "is interstitial ad availlable"
or do I need a requested too?
I would you would need to check if one is available, if so then load it.
thats what im doing... check at the left
Yea you check if one is available but try to show it before you've loaded it.
?
im doing that already
oh
What am i doing wrong with this? My character doesnt do its animation after attack
And where do you load the ad before you attempt to show it?
i misread what you said
well I load a new ad at the start and whenever I show an ad or fail to do so
even if one isnt loaded it should return the branch at the left false and not attempt to show an ad
Can someone give me a random game theme?I will try to make a simple game in a few days
Caterpillar survival game
Thx
It sounds like you need a simple inventory system to keep track of the amounts in game.
Fine, I will reveal my secrets. 😉 This is what I do.
Assuming it's just the amounts, you could probally just use a map where the key is the item name and the value is the amount (int). When you pickup or drop something, you just need to find it in the map and update the number. The UI can then use this to show the list.
hey guys what would be the node and the layout to get a pawn/character class and get the children and randomise it to spawn it as ia ? i found this on internet wich is cool but i want to use a specific class of npc and randomise the children of it, also i know its not spawn actor but spawn ia
What is IA in this context?
Is it possible to increase the radius for nav link proxies? I've got a setup for launching an actor from point A to point B, but when they navigate to it in a group it bottlenecks and they all stand still at the proxy location
the pawn class i want to get the children and randomise and spawn it as an ia
Read the question again. Are you talking about AI?
Not sure, may want to ask in #gameplay-ai
I’ve been having trouble with my timeline saying “timeline paused” and I couldn’t find any solution. I have 2 other types of doors with the same code on opening and they work amazingly but this one doesn’t and I don’t know why. Anyone help please. Thanks
i dont understand, i want to spawn an ai wich use this character class wich as children with unique character and i want to randomise from that list im sorry if i dont understand i realy dont get where i need to precise anything
May I ask why you have a Flip Flop with nothing connected to B?
It’s the first time you said “ai” instead of this “ia” lol
oh sorry im french lmao
I was having the reverse go into the B of flip flop but I just decided I don’t want it to close
It works on my 2 other doors with the same exact code so idk why it isn’t here
Guys, sorry for bugging, it is a bit of urgent matter, and I am noob in Blueprint. If I can borrow any brain it is greatly appreciated.
I have just one Exponential Height Fog in a blueprint.
There is a node called Set Start Distance to control its value.
But the one I need is Set Start Distance of Volumetric Fog inside Exponential Height fog.
How can I create a node to control this value??
Thanks a bunch.
Yeah, I thought you might be 😀 np, just wanted to make sure we’re talking about the same thing. There’s a few get children nodes but I’m not sure if either of them gets you child blueprints
Anyone please 😭😭
Read #rules
yes it seem that i can't for what i saw i mean nothing with the context
There should be something let me check
use play at start
thx sir, i doubt there is nothing too
Its still the same
oh then i dont know sry
It’s okay Ty tho
There are 3 start distance in exponential height fog, and the set node only has two of them. I need the 3rd one...
I'm trying to make an actor component that subclasses scene component, because I need the transform. But I've found it's really hard to use with no visual element. Is there a way to attach an editor-only visual element to a scene component, like that white sphere that the default scene components have, or an arrow like the arrow component? Is there a way to include an Arrow or something that looks like it inside a different type of ActorComponent? I wish you could just subclass it.
while looking at it a second time it seem that the flip flop is sus indeed
maybe u can drag the fog actor and get that parameter idk
Let me try to remove it but I don’t think that’s the problem cuz I have 2 other doors with different open scenarios but the same code and it works even tho the flip flop is there
I’ll try tho
One sec
Nope it’s the exact same
Sadly all I could find is people using a function that goes over each class and if it’s got that parent, adds it to an array.
https://forums.unrealengine.com/t/find-all-subclasses-of-a-certain-baseclass/337736/2
and did u tried to debug it and see where the flow stop ?
im new to unreal sorry i have no idea what and how to do that 😭
go check how to debug that will save ur life
Can you get volumetric fog from inside exponential height fog? Dunno much about fog tbh
damn that look usefull but might not be realy performance friendly maybe its ok cause cpp i never used cpp for now ill try it if i dont find a simple way thx
in this Video, I will go over how to build an easy Level Teleporter Blueprint in Unreal 5
https://www.epicgames.com/site/en-US/home
You can’t have components inside components afaik
i searched up debugging on youtube and google and i found this guy talking abt break points
am i on the right track
Even just giving it the same arrow mesh would work but I can't even figure that out
You could attach a component to component dynamically on construct maybe
i mgiht be to much of a nooby and not understand the question, but dont u can just add a scene component to ur actor and use his transform ?
Would that construct fast enough to be useful in editor though? Because that's really the main place I need it
Construct runs at editor time
But actor components dont have a construct function do they?
Yes, and I can set values for all the parameters of volumetric fog section. But I just cannot edit Volumetric Fog Start Distance, there are few parameters missing in blueprint for some reason.
anyone know any youtube tutorial for being able to enter a car in a third person template, i tried a tutorial but it wasn't working, and I made sure the blueprints were perfectly done
OH MY GOSH i just found out the problem was that i forgot to put a get player controler when enabling input 😭 idk if breakpoints is true debugging but it sure did help so thanks
Thx
I have two blueprint actors that completely glitched out and now share the same event graph, anyone know how to fix it
Oh I haven’t checked tbh, might not have
theyre inseperable
what a cute couple
i have no idea
@pulsar vigil how many children are you working with
I re-checked but yeah I've actually run into that issue before. I really wish they DID have constructors
woah there
Children bp classes*
phrase it a little diffrent buddy 
Maybe he’s a child therapist or an educator you don’t know
I'm trying to make an upgrade system for my game. If I have a bunch of custom events, each being an upgrade, is there a way I could choose randomly from a list of them and assign that chosen upgrade to be selected like on a button click?
Actually I found it but I donno how to make it exposed to the editable value of blueprint.
It shows up to the surface of blueprint but I cannot change the value from details panel of viewport
Did you search for start ranges
Oh that’s your var
yeah
Well you’re setting it already so how can you not change it
I donno lol
Ofc it won’t change you’re resetting it with every tick
Construct doesn’t just fire once
It’s editor time “tick”
So if you drag it to 0 but the code says nah change this to 65000 it will always reset
If you want to do it in editor time that’s fine, but you need to do it differently. You’re currently trying to change variable that is constantly being overwritten by another variable
You’re not changing the reference you’re just changing your copy
Maybe you can use Set by Ref on the Start Distances
Or just set the original Start Distance to whatever you want
I did not know it can be complex... All I wanted was a simple blueprint with one slider, to control volumetric fog's start renges
this one is not the value I wanna change... but...
Why this works?
it is in construction script @lunar sleet
When you're adjusting the value, the construction script is getting fired. If you're setting the value on the construction script, it sets the value to what you've set in the construction script, meaning it resets the adjusment you've made.
This new one doesn't appear to be setting any value, it's calling a function that could be adjusting a value that isn't your "Start Ranges" variable.
Yeah I said on tick but Datura is correct, it’s when you make a change
In other words - you can't expect to adjust a variable of a placed actor when that variable is being set within the construction script. The construction script's value will be the one that is used and will override any changes you make.
Is that new function custom made then?
Ok so that function is the one doing some trick
no it is not a custom made, I can just search this one. Not sure how it is doing
There is no "trick". It's a matter of you're not setting the "Start Ranges" variable in the construction script.
Ok good that’s a built-in function
Because you're not doing that, you're able to set the value as you want. Then it's calling into that particular function to do whatever.
ok, then how can I set the value without overwriting it?
Why do you need it set in the construction script?
it does not have to be in the construction script... I was just dumb and too new to blueprint...
You can set the value as you need, you can also make it so it has a default value. You cannot set the value on the construction script and expect to also be able to set the value manually.
basically it is for a virtual production scene, a on set director needs a single slider to control the starting distance of Volumetrig Fog in the Exponential Height fog
As stupid as it sounds.... if we have bunch of sliders that confuse people who have never used unreal... So I was order to make a single slider
So what's the easiest way to add two transforms together, if this is illegal for whatever reason?
Ah HA! Compose transforms!
Hello, I have an actor BP that is my level manager. Essentially its supposed to, on BeginPlay, place all the actors and set variables from my game instance. I use it to load up a save from the main menu level. However its not running BeginPlay. Is there a reason why it wouldn't?
It plays when I run the level straight from PIE, but not when I run the level via OpenLevel node from MainMenu Level.
So one thing with BeginPlay is that AFAIK there is no guarantee about which order actors will have their BeginPlay function run if they're all in-level already. That can make race conditions possible if actors refer to each other during their BeginPlay code.
Is it possible that your BeginPlay is being called, but is exiting fairly quickly because it references something that could be invalid at that stage?
Well I was thinking that as well about the order, but I put breakpoint on the BeginPlay node and it only catches when I play level from PIE
It doesn't catch when I open the level from OpenLevel node.
sorry i didnt saw it only two for now but i want it somehow a bit scalable i just want to gather them in a list or array and randomise from it
@dawn gazelle you know any easy way to get all children classes of a class without having to query every class ?
@flat coral It's confusing because I believe every other actor is running its beginplay from the OpenLevel node
Don't think there's anything in blueprint that would allow one to do that.
Thought as much. Thanks for confirming
thx both of u i ll try to find something else or use the cpp tips u gave'd me
Could i gather my child class on an array and then use that array in the spawn actor ? in bp ?
Alright so apparently if I remove BeginPlay from the LevelManager blueprint, and replace it with a custom event and then call that event from the BP_FirstPersonCharacter BeginPlay it STILL doesnt actually call that event. Soo something is wrong with my BP_LevelManager?
That is what I was going to recommend but the gathering part is the problem
i see i feel like cpp will be require if i want to do something like this 😦 i need to learn how to implement cpp thing
That function I found should be fairly simple to implement I think
oh i see the one u gave'd me ? is it performance ok cause its cpp ?
Maybe you need to use proc gen for this tho
It’s still iterating over each class as far as I could tell but cpp is always faster
damn if its heavy i'd rather query each child
can I not call a custom event thats in the editor utility widget from a regular widget asset?
yep... the widget which I wanna call the custom event from also needs to be a editor utility widget
makes sense
Get actor bounds for spline mesh component is not working properly? Found random thread saying set start/end tangents of the mesh might mess w/ the dimensions. Any fix for this? Trying to set the box extent of a spline mesh component's box collision, after the mesh is resized in-game.
@flat coral Ok So it actually is working I was just setting some variables incorrectly. Interesting that BeginPlay still doesnt catch on a breakpoint, even though its technically firing.
My answers were because I'd also run into BeginPlay issues happening only in packaged builds where it SEEMED like a race condition, and the truth is I never really got to the bottom of why that was happening, especially so consistently. I just sorta fortified the code to be resilient to the race condition and that fixed the problem, but it would be nice to have Understanding too.
Yeah it would be nice to know whats happening but for now I'll settle for it just working haha
I seem to be unable to send the trigger between these two editor utility widgets
idk what I'm doing wrong
is it cheaper to check then cast? or just cast and use it as my bool?
Check what? And don’t worry about perf issues with cast at this stage, it only becomes an issue when you’re loading a lot of heavy assets at once
I am checking if an item is currently equipped. If not I equip it. But I was wondering if its cheaper to check if the class it = to what I want or just cast to the item and use if it fails or not as my bool
A cast is a type check
Because if I use it as my bool I could end up casting to the then like 20+ times
so if I use a check I am just checking twice?
Yes
So cast is better then
Thanks
Its hard to know because some say cast is expensive and others say its cheap
And I have noway of taring apart the coding to find out lol
I have this set up for picking and putting a note down, for some reason my input key (E) is not working. i placed an event tick in its place and the code started working, but once i placed the interaction or even plain E it dosnt work. can anyone help? i genuinely dont know the problem considering E works fine on all my other code. thanks
I tried using a random other key like Q to test it and it didnt work, but the problem isnt with the code itself so i dont know how to fix this. please help
(i tried debuging it when i first found out it wasnt working and it didnt get past pressing E, it completely didnt render)
is there a way to get feedback from decals so I can see what actors are "decaled" ?
How is this variable used exactly? I want to pass it through a call function and check if the action/button that caused is still active/pressed. Is that possible?
The reason people say to avoid casting is down the memory usage. Casting forces the bp to load the actor, even if it's not being used.
Over using casting could result in a single BP forcing your entire project to be loaded.
Ultimately though, you want to use a good class hierarchy where you can cast to base actors that don't result in loading large files like large materials, audio files etc...
Having said this, if the thing is going to be loaded anyway, it's not an issue.
oh and my E key works in other BP but for some reason not in the ones im using right now despite them both being an actor bp so im js super confused on why it isnt working in this specific BP
Ah I see
So if I cast to a BP that cast to 100 other BP it loads them aswell?
Yep. You can look at an assets size map to see what it loads. (Right click menu)
Have you enabled input on the actor?
Thanks
explain that in a way dumb person will understand please 😭
what is that?
I have the same issue as @fiery anvil
Only the player controller and the pawn it controls receives inputs by default. For anything else, it needs to be enabled.
well how do i
i didnt do that on my other bps and it worked but ill try
OHHHH
WAIT
What are they? Just actors you've placed in the level?
I REMEMBEr
i did enable input
i js forgot abt it
ty
ill try it now
smth like this right
if yes then okay ty
Yea.
Once loaded they generally stay loaded tho
This is because the game instance is only loaded once and the same one is used until the game is closed.
When you play in PIE, it has to load it. When you use the open level, the game instance has already been loaded.
You might want to use the game state if you're needing to spawn actors in a level when it loads.
From my understanding, unused assets will eventually get unloaded/garbage collected.
Yeah, if not in use, iirc
how do I add an item to a specified index on an array? I know insert does that but I want to over write the data at the targeted index not just insert
Set array elem node
thanks! good old brain fart there lol
How would I smoothly Interpolate a World Location getting updated every .5 seconds?
What do I plug into world context object?
Has anyone ever seen a function output the results like this in a animgraph?
Following a written tutorial and says to create a function to input velocity to then output the XY output I need,
Then just says to use the results in the anim graph but never done it like this before, theres no info on how to do this,
Any idea how this is done?
Right click a 2d vector variable, split struct. Works for inputs and outputs of structs, such as vector2d, 3d, color, etc
please excuse the spaghetti but HUH?
To me this looks like
void fill(TArray<FSideConfig>& SideConfigs){
int numToFill = FMath::Clamp(6-SideConfigs.Num(), 0, 6);
// print numToFill
for (int i = 1; i <= numToFill){
// print i
FaceConfig fc;
// init defaults
SideConfigs.Add(fc)
// print SideConfigs.Num()
}
}
Why is the output log printing:
LogBlueprintUserMessages: [Character_Die_C_0] 6
LogBlueprintUserMessages: [Character_Die_C_0] 1
LogBlueprintUserMessages: [Character_Die_C_0] 1
LogBlueprintUserMessages: [Character_Die_C_0] 2
LogBlueprintUserMessages: [Character_Die_C_0] 2
LogBlueprintUserMessages: [Character_Die_C_0] 3
LogBlueprintUserMessages: [Character_Die_C_0] 3
instead of
LogBlueprintUserMessages: [Character_Die_C_0] 6
LogBlueprintUserMessages: [Character_Die_C_0] 1
LogBlueprintUserMessages: [Character_Die_C_0] 1
LogBlueprintUserMessages: [Character_Die_C_0] 2
LogBlueprintUserMessages: [Character_Die_C_0] 2
LogBlueprintUserMessages: [Character_Die_C_0] 3
LogBlueprintUserMessages: [Character_Die_C_0] 3
LogBlueprintUserMessages: [Character_Die_C_0] 4
LogBlueprintUserMessages: [Character_Die_C_0] 4
LogBlueprintUserMessages: [Character_Die_C_0] 5
LogBlueprintUserMessages: [Character_Die_C_0] 5
LogBlueprintUserMessages: [Character_Die_C_0] 6
LogBlueprintUserMessages: [Character_Die_C_0] 6
sorry the picture is at the bottom
Does anyone happen to know if you can set this from Blueprints? I can change these parameters no problem but I want to change the actual layer asset:
I know there is more to this than what I have here.. I just don't know what it is.
Alternative to cast?
I have a Variable called [EnemyDMG] in ai_enemy. How i can change it from Player_Char without Cast to AI_Enemy?
why don't you want to cast
cuz it's expansive
that couldnt be further from the truth
and for bigger games, might be a broken feature
it's a very common myth
It's fr just a myth?
yep
I heard more ppl said it's so freekin expansive
and i was like, ouch. hope it's not freakin
with my resourse later.
Also, do you know how i could change the style image from a button?
in graph of a wg
I can get it work only with images, with set brush
but not with buttons tho
the "expense" comes from casting to something which is unloaded.
when you do so in blueprints, it has to load it into memory.
This cost can be virtually nullified by using proper code only base classes however
yeah there's a bunch of nesting you have to go through
if you get the button's style you should be able to break it into it's series of images iirc
for context, i wanna do a button for 3 ,,Items" you could buy from shop
got to work trough images, but not buttons
i see
Hello, I'm having a problem adding elements to a map. If the PlantsInWorld map from SaveGame's length is 2 then the for each loop should add 2 elements to the PlantsInWorld from GameInstance but it only ever adds 1. Also when I put a breakpoint on the return node and check the PlantsInWorld map from SaveGame's length by hovering over it, it shows the length is 2 but when I expand it Unreal crashes.
@thin panther Seems to like by breaking the style, ty
How can i get a my Hierarchical instanced static mesh component to save its instances when i close my program, i have a utility widget that spawns the instances, however when i close my program they disapear.
am I doing something wrong here?
Figured it out. Was trying to add an Object Ref to the map and I think it wasnt changing the key when adding more than one Object. Changed the key variable to a structure with all the object variables.
What is the class in WeaponStruct?
What is the actual type of the variable
Actor class reference
That's too general, Actor doesn't have an Alt Fire or Mag Current
Does every class you'll put in there have a base class?
should it pick the specific class on the data struct?
theyre all just actors
Then you'll need to either have a common base class or interface to talk to them all the same
or a component on them
yep sorry, think i'm missing some variables
What you're doing is saying "Get the MagCurrent of this Actor" and the computer is saying "WTF, Actor doesn't HAVE a MagCurrent property". All it knows is that the result of that get is an Actor, doesn't know any more than that.
are these all held items or something?
these are just weapon stats in a data table
What is the type of the Actor Class (purple pin coming out of your weapon struct)?
'actor class reference'
Then why are you trying to get them as if they're instance variables?
how do you mean sorry?
oh hmm
What are you actually trying to do?
this is for the fire button, when you press fire it's supposed to check what gun you have out and fire accordingly
i have actor classes for guns, and i want it to be ableto pick the right actor
why is it reaching into the world and getting the first actor it comes across of that class?
why not
Fire Button -> MyGun.Fire
thats essentially what i want to do
I'd make a base weapon class that contains that bigass struct as a variable so you can just reach in and grab that stuff
but it needs to know what MyGun is
alright that might work, thanks
as long as i can use actor sequencers in them
Equipping:
Spawn actor of class GunBase -> Attach it -> set MyGun
Firing:
Fire Input -> if MyGun is valid -> MyGun.Fire
GunBase can contain a variable of type WeaponStruct if you want to easily keep their runtime stats in sync with the data table
that is definitely what im trying to do, but maybe my approach is wrong
RandomGunSpawner:
SpawnEvent -> get random data table row -> spawn actor from class (it'll be a GunBase) -> ActorIJustSpawned.WeaponStruct = TheDataTableRow
now the gun has a copy of the data table row used to spawn it so it has its starting stats
and in GunBase you can do all your general Fire/StopFire Reload etc logic making it data driven by its WeaponStruct
in subclasses of GunBase you might just swap out meshes and stuff, you might not even need to do that depending on how data driven you can make GunBase
You could certainly make a system where you only have GunBase and everything else is just data, but that depends.
gotcha, thank you, i'll make a proper weapon base
Someone rescue me from this boolean hell. I've written this shit two ways and I hate them both, the readability is just awful either way.
Basically the goal here is to take a few inputs on a flying NPC, whether it's moving, whether it can strafe, and whether it's near an enemy, and use those to either rotate toward the target, or rotate to face movement direction.
I mean it's an either/or right?
why the 2nd branch
either you rotate to target, or to movement
unless you intend not rotating to be a state
Not rotating is absolutely a state!
when can it NOT strafe?
or is strafability a stat like some flying dudes can strafe and others can't
It's more like what type of flying thing this is. This is the superclass for all of it. A robot can strafe, a missile cant
Yeah, if it isn't moving AND it isn't near an enemy, it won't rotate at all.
@lunar sleet @dawn gazelle so a tech senior artist took a look at the function to drive Start distance of Volumetric fog in C++. He said it is actually one of the few parameters that Unreal Engine does not allow to modify in blueprint. Hence there is no functions to modify that specific parameter. Regardless, I appreciate you two's effort to help. Thank you again.
So a missile can't rotate to face a target like a heatseeker?
idk why strafing has anything to do with orientation
not being able to strafe is more like "Can't move anywhere but forward"
Oh because otherwise it's ALL strafing! The movement component I'm using is pretty terrible at handling rotation, so I'm doing it manually.
In the case of a missile, the AI component will just move it towards the target, but to make it LOOK like the rocket on the back is doing the work, I reverse-engineer the orientation FROM the movement
ok so movement is the free variable, and orientation depends on it + other stats
Yeah basically. It's like "I have no idea what 'forward' is, but I know what direction i'm moving, and i know where the enemy is"
assuming your boolean logic is correct then I'd just do the 2 if chain
Hey guys I am trying to calculate the velocity of an object using 2 points WITHOUT using physics. Physics will not allow me to use time dilation which is needed, but without physics I cannot use the get velocity nodes so It seems as though I need to calculate it.
I am wondering if anyone has any idea how to calculate velocity without using the games delta time as there will be a considerable amount of time between when I "pause" the actors and then "resume" them.
Hello All,
I hope I am using this venue correctly.
I am new to Unreal and am trying to put together a framework to build a larger game project in and I have gotten myself to a place where I am not sure what the next steps are.
I am streaming in levels using the LoadStreamLevel node in a Blueprint Actor that has a collision box component. Pretty straightforward stuff.
All of my levels stream in fine, but the various bots that I have in the levels seem to be disconnected from their controllers and Behavior Trees. All of the bots are child class objects for the class (AIC_WBGNPCs) that I am calling in the script.
I am trying to manually load the Controllers and Trees in the SubLevel Blueprint, and in the Loader. I am doing both because I am trying to load all of this after the SubLevel has finished streaming in.
(I guess I am a Pants and Suspenders kind of guy. I can clean it up after I get one of them to catch.)
I can see the messaging in the PrintString, so I know that we are getting to that part of the blueprint. I just don't know what the next thing I ought to be looking at is.
I have also bound a OnLevelLoaded event to the BeginPlay event in the level. This event is never gotten to at all and I am not sure why, but that might be outside of the scope of the core "Why are my AIs not loading their Brains?" inquiry.
I have tested these bots in persistent, non-streaming loads and they work fine, so I don't think that the bots themselves are the problem.
Any does anyone have any insight that might help me to get these bots working when streaming?
Thanks in advance for any insight that anyone might be able to provide..!
I don't mean to be mean but make your questions shorter
Sorry. There are always follow up questions so I wanted to get all of the relevant info out of the way.
You are not obliged to read it.
Just good idea to keep it shorter for answers ik the pain :/
That's just how long my questions tend to be. If it was a short and broad question I could probably find an answer on YouTube.
Fair enough
Anyone got any ideas on this?
Maybe if there was a way to get how long it took to execute a particular amount of code? I could just use that as the time between points
Hello all, looking for some guidance on how to organize a set of features in my blueprints.
I'm making a Little Nightmares-inspired game. I'm working on learning how to have pushable objects, objects that can be picked up and thrown, and levers/buttons/etc. that can be interacted with, all if the Left Mouse Button (Grab button) is being held, just like in Little Nightmares. I'm following tutorials for those systems.
I need help knowing how best to organize them. Should I make an "Interaction Component" that contains all the blueprints for the aforementioned things, or should I just drop it all in my player character event graph? I already have a climbing/mantling system that checks if the LMB is held, and I want to avoid these different systems conflicting with each other. Should I have a separate blueprint system that gets called on my characters Event Tick? What is the best way to go about this?
is to make use of EnhancedInput's InputMappingContext, so you can switch/override input context based on scenarios
Having an issue where Get Viewport Size is returning a larger value than the actual viewport size. Any ideas how to fix?
Red arrow at bottom right represents mouse lcoation when screenshot was taken
I think there is a viewport scale factor as well?
I think an interact interface would be good here, can put on any actors needed. Can pass the actor and pawn through the parameters to do what you need.
If you have tons of repeated logic then yeah function libraries and/ or actor component to cut down on duplicated code
there actually is.... print stringed it. I never set UI scale so why is it printing as 1.2...?
im making a sidescroller game, and im trying to add a feature that when the player clicks on the screen the player jumps towards that direction, but for the life of me i cant figure out how to get the mouse position into a useable vector value
Get Hit Result Under Cursor by Channel
Put an invisible plane that won't collide with the character on the same axis as the character. When the hit result collides with the plane you'll have the appropriate depth and a usable 3d vector.
ok thanks
does anyone else just have a thing that sometimes a certain node just cant be found?
Thanks for the advice, I appreciate it.
Nav Mesh in the Persistent Level. The answer was to put the Nav Mesh in the Persistent Level.
How do I get information from one blueprint to another with an interface? I can't find any tutorials that explain this. I used to know how but it's been too long.
I am trying to have a pushable blueprint with a box collider tell my Interaction Component that the player is overlapping. I can't have Inputs and Outputs with the same variable name on a Function in my Interface, so I can only set or get in the respective blueprints. How do I pass this information between the two? It's just a simple "canPush?" boolean.
The only way to pass info through an interface is all of the parameters. I've done things like "ParameterIn" & "ParameterOut" when I manipulate the value. And yeah an interface with a single function called "IsPushable" that returns boolean is an approach
So if I have a SetcanPush function and a GetcanPush function in my BPI_Interaction, and their respective input/output is named the exact same, it recognizes it as the same variable?
ie. I have the pushable blueprint call the set function, and then on the custom tick that my Interaction Component has, it can call the Get function and it'll be the value that the pushable set?
EDIT: I just tried this, it does not work.
If I make a single function like that, I can only give it an input OR an output with the canPush boolean. How do I give it both?
I feel like this shouldn't be this hard to do. I've watched several tutorials and it still doesn't make sense to me.
Can you show me an example of this? I don't understand what you mean by this.
Anyone mimic the editor advanced copy before in blueprints mind sharing whatever insight they have?
Discord: https://discord.gg/CHm7RZJ
Support me on Patreon: https://www.patreon.com/forsakenreality
Send Variables Between Blueprints Using An Interface - #3: How To Make Mario in UE4 - Unreal Engine Tutorial
In this Series we will learn How to Make Mario Power Ups in Unreal Engine. Mario is a Platformer game developed by Nintendo. We will set...
Thanks for the link, watched it. I'm still completely lost. Here's what I'm trying to do. It won't let me change the value to be true in the begin overlap and false in the end overlap. I'm sorry, my brain works differently and I have no idea what I'm missing here. I feel really stupid.
Something like this with an "In" & "Out"
Maybe something like this for your use case
where is the break hit that result from the trace when hit
I feel like I'm so close to understanding this.
How do I get my receiving actor (in my case, the Interaction Component) to know what the Cube actor set it to?
I'm coming to this a bit late so let me know if you've solved it, but it looks like you're not sending the interface to the correct blueprint
How do I send it to the Component of my player character? I tried using a Message but that doesn't let me set the value in the Pushable object. It's like the only way to do it is to cast, which defeats the whole point of using an Interface. I was told that casting clogs up memory usage.
In pushable, I want it to detect Begin/End overlap with the player capsule. On Begin, set canPush to true. On End, set canPush to false.
I then, in my InteractionComponent, which has a custom event "tick" that is running from a sequence in my player character, I want it to know whether or not it can push, and then I can worry about the actual pushing code, checking if the LMB is held, getting what actor it's pushing, etc.
I'm just trying to set a boolean in my Pushable, and have my players Component recognize what it has been set to.
I've worked with Interfaces before but my mind is completely spaghetti tonight on understanding this, like there's some sort of mental block lol.
Do you want to be able to push any static mesh? or just specific blueprints that you have made to be pushable?
My goal was to make this pushable be a parent object that I can then make blueprints children of, where I can set the mesh and Box collision in them separately (wooden crate, small metal cage, etc.). All box shaped meshes to make it easier.
I would recommend flipping your system around. Instead of pushable objects telling the player that they can start pushing, have your player tell objects to start being pushed.
So I'd put the interface on the pushable object instead of the player component. That way, you can have your player detect when they are overlapping with an object. The player can check if the object can be pushed, and if it can then you will tell the object to start being pushed. Then the player is technically always trying to push anything it's colliding with, but it will only do so if the object is marked as "pushable"
The way you'd fix your current system is by doing: get player character -> get component by class -> send interface
but that kind of defeats the point of an interface. Although, it doesn't really seem like an interface would be necessary in your current system. Casts really aren't that expensive if you use them in moderation. Especially if you are casting to your player character since (usually) the player character is always loaded into memory anyway. casts become expensive if you start casting from your player character to random things in your game.
Hey everyone, I'm new here. I'm having trouble integrating a key pickup item with my physics doors I created. If anyone could help that would be great
Could you add a little more specifics? Post the details of your problem and how you've tried to fix it, and if anyone can help they'll respond
Cool, I'll try to explain as best I can and provide some photos
Some I'm making this basic physics door
It uses a pivot so the player can run through the door instead of pressing E to interact
I made it so that the regular door is locked unless the variable HasKey is true for the player
In the video you can see how it prints "Door is locked" for the regular door
This is how I was handling the door locking for the regular door. I tried to change it so the physics door also checks for "HasKey" before allowing the OpenDoor event but it still opens even though HasKey is set to false
If you disconnect OpenDoor, so that it does nothing: does it still open the door? It looks like it's using physics rather than the timeline
If I disconnect it from where exactly? From the start of the regular door or the physics door?
On physics door, at the start of "OpenDoor" disconnect the execution line
Okay yeah I just did that and the door still opened
So it's not doing anything here
Okay, go to the door component in the PhysicsDoor blueprint and check if "simulate physics" is true
Yes it's ticked on.
Would I possibly find some way for it to require haskey to enable simulate physics?
Great, so set that to false. And instead of the timeline inside of "OpenDoor" set the "simulate physics" in the door to true
Where would I connect it? Would it be after the timeline or should I connect it to the flip flop
You don't need any of that now. Connect it straight to OpenDoor and see what happens, make sure simulate is set to true though
This might not work, so don't delete it all yet
I didn't delete it but the door still opens
I turned simulate physics back on in the details panel of the door
Does the door open even when you keep simulate physics off?
No, it stays closed then
It's ticked on in the details but off in the blueprint (not sure if that's how it works)
Nah flip that the other way around
Currently, the door is simulating physics interactions. So obviously when you run into it, it's going to swing open because you've pushed it open. If it isn't simulating physics, then the door is going to stay shut. What I'm suggesting is that the door should start with no physics (when you run into it, it is closed). And only when you have the key and interact with the door, should it start simulating physics and let you walk through it. Almost like you've unlocked the door
Yeah that's a perfect solution
I'm trying to fix my key pickup now lol
I should just set the haskey variable to true by default but I'm not exactly sure how
Nvm I figured it out
I had to open details and click on the variable
Set the default value to true
It works!
So now if the player presses E on the locked door it unlocks and they can walk through it
I need to fix my key pickup right now because I want it to destroy when you walk over it and enable HasKey
I think it's doing something else right now because Destroy Self is never getting activated
It'll only destroy if you interact with it right now. Put destroy actor at the end of on component begin overlap
as long as it has given the key
if you put a print at the start, does it print?
At the start of begin overlap?
yes
Did it when also print when you walked into it?
right well that's not ideal
connect "other actor" to the "in string" of the print and it'll say what its colliding with
But this probably means the collision settings of the box aren't set correctly
Oh yeah it's pretty large
I just downscaled the item
That all worked
It was the box collision
It was massive
Thank you so much I really appreciate it
Is there a way to have Niagara that plays till trigger is overlapped that would fade Niagara particles away?
May have to ask #niagara. For the bp side, I only know how to activate and deactivate
Will try as well
Anyway if I want to spawn something from actor ( I have plane that has some text on it) should I use add child actor component or spawn actor?
Spawn actor
It gives me error that current value of the spawn transform pin is invalid in action behin deferred actor spawn from class and finish spawning actor
Show screenshot
It needs a transform, or at least a location plugged in (you can break the transform pin) so it knows where and how to spawn it
Hello, any chance someone can help me out with something using blueprint
I'm extremely new, been using UE5 for 3 days now
congrats and welcome to unreal! Whats the problem?
hello wolf 🙂
So, I just started again, and am working on making a basic RTS game (real time strategy, top down camera)
Can anyone tell me what I need to do to get mouse X/Y event to trigger any time the mouse moves?
I've got camera working (once mouse is edge of screen, it moves)
and I'm a little stuck on selection of units
haha I am working on this right now actually
So, I have Draw Rect (drawing the selection rectangle), and I have Get actors in selection rectangle (selecting the units)
it works perfectly
issue is....
the draw rect is viewport based
and if I'm panning camera as I'm selecting...
it's not anchored to the actual game
but to viewport
get what I'm saying?
oh interesting problem
seleciton si fine, see
but if I draw same selection while moving camera
downwards
you can see that the rectangle is beign drawn on viewport, not anchored to world
id say this is a fine issue to have. Most RTS do not solve this if youre considering your sanity and steam with moving the project forward.. you could be fine with not solving this.
but completely understand wanting to solve this
i mean, solving it = learning right 😛
I'm only on day 3, so figure, might as well tackel problems early
yea haha
as learning experiences
Well, this might get expensive but youll probably want to store the rect in world space, but man cant imagine how youd specify which anchor to move, that is attached to mouse.
so.... I was playing with these two different things
but can't seem to figure them out, but a possible solution?
yea while panning the camera, with arrow keys or edge panning with mouse, youll want to store the world location of the anchors and update them as the camera moves
might need to save the world location as the rect is created
BUT
i am not familiar enough with this mechanic and how unreal supports it, to know what needs to be called out for say if youre mouse is dragging at the bottom right of the square and you cam pan down... youd have to allow that corner and its edges to be free to grow during the cam pan.
are you using enhanced input system for mouse movement?
not sure what enhanced input system is
I'm using pressed/released atm
hm....
i wonder... if I can use the world position of the camera
since it's moving at the same rate as everything else
and just add/subtract that from starting position
interesting
just ignoring the z axis
you might be ble to add or subtract the offset change of the pan to the rect box ..
yea
it wouldn't matter if tehre's no "drawn" rectagle, as long as it gets to edge of viewport
and this should work, since it's not limited to viewport
i need these lol thanks
you might be able to use this
i am not sure exactly how but seems related to the feature youre trying to make
that seems like itll give you the world location of the actual camera..
which I want, no?
i think so
then you math the difference into the rect
either during the pan or after.. but probably ideal during.
i want one initial camera position (on press of the left mouse button)
and one updating one
while holding
and if it's changing, the difference is added/subtracted from rectangle
yea
good way of thinking btw
i wouldnt have reached that solution lol
been in unreal for too long
welll.... let me see if it works LOL
my brain is literally farting left and right
since I neve rprogrammed before
overloaded on so many topics at once
thats unreal haha. its awesome like that
hm... x/y is inverted in 3d space right?
compared to 2d space
so x=y, and y=x etc. ?
if we're talking x/y/z axis?
in x/y/z, x = up and down right?
I think so yes. In 3D X is forward and backwards, Y is left right. This gets "inverted" in 2D (X = left right. Y = Up Down. It's not quite inverted hence the quotes, but for the sake of calculation, invert 'em)
Ok, I've gotten closer to solving the issue. When reopening unreal, said actor component turns into a REINST.
What exactly is this, why did this happen, and how do I fix it (Replaceing the AC is only temporary as stated earlier)?
how do i disable all input from player controller except one?
the point is if the player is "ingame" and he opens the option menu, i want him to be able to press the same button to leave.
Tab = open option menu
Tab again = leave option menu
A boolean for "InMenu?" could go in front of all input events
working 🙂
that was an annoying fix.... my blueprint is so messy
lol rip....
and that's only for drawing...
reroute nodes!
gotta do same for the selection one
double click a wire
is there not a simpler way, feel like thats a bad way to code it up
I think the proper way is to have a menu controller and a player controller being seperate.
But you probably dont want to set that up.
Well
Are you setting input to UI only when the ui menus come up??
question
this camera sucsk to track, since it's too high up (and distorts view if it's at an angle)
can i make something who's position i can track, at ground level, that always follows camera movement?
Assuming your using enhanced inputs, you can create an input context mapping for when they have the menu open. This can have the same input action you use to open the menu.
When you open the menu, you remove the default ICM and add the menu one.
I know you can't cast to a type known at runtime, but I assume with macros I should be able to specify the type?
I'm trying tomake an utility macrot hat lets you iterate over all components of a given type in scene. However the "get components" node when given a class variable returns a generic scene component because it'd do a runtime cast.
Whereas I kind of want it to be a macro wildcard, if possible
essentially the returned component should be of the type specified in input, and it won't be a variable, it'll be a constant specified on macro call
or maybe i'm too much wishfully thinking that bp macros would work like c++ templates...
What are you wanting to use this for?
So your wanting the camera location but at ground level?
Is the component from a plugin?
artist coworkers who want to turn on/off a different setting on everything every couple days