#blueprint
1 messages · Page 80 of 1
Are you able to help?
hi guys can any one know how can i get this node in bp?
Get your variable > Right click on it > Convert to Validated Get
i can't find
No, get it first in the graph
Anyone please ☝️ ?
How to get x y size of the downloaded image ?
i am confused man maybe i should watch the that tutorial first
Youve used the set node but not set it to anything
Id reccomend following some resources like the blueprint communication video pinned here, and some of the starter resources in #ue5-general
What's the value before you ceil? I can see you have a print for both.
I would imagine get size.
no
As ACuppaTea has said, you need to learn more about blueprint communication. For a quest system, you'll need a good understanding of event dispatchers. If your not using them, you'll run into a lot of issues and things will get messy very quickly.
When you pull from the 2d texture ref (I assume that's what it is) and you search for get size what options does it give you?
Wait, it prints 9.5 before the ceil, and 10 after the ceil, which means that's correct, that means something is wrong with the rest of my logic 🤔
somehow it generates 12 hearts instead of 10 🤔
That seems right. 19/2 is 9.5 which ceiled would be 10.
Yeah but why it adds 12 hearts to my horizontal box 🤔 ?
I don't know, you haven't shown how you add the hearts.
Oh it's a dynamic 2d texture. I don't think the get size nodes for dynamic textures are exposed in BP.
You'll need to minus one from the last index if the start is 0 or you'll get 1 more than you want. I'm not sure why you get two more though.
Did that, somehow it's all fixed now 🤷♂️
thanks 👍
Aye def do that
Hey! I have a question
In my Bullet_01Basic I do have the event HIT
i made the Print debug to see if it’s recognize only the enemy [the bullet]
I have 5 ChildBlueprints from AI_ENEMY. wich spawns random
The question is: How do i get ENEMY_HEALTH from every child, [they have different HP] And apply damage to it. Also, how Apply point damage works? the base Damage?
I wanna create a Top down Shooter btw. Ty!
Long short exp:
Event hit > Cast to AI_ENEMY > AS AI_ENEMY > GET MAX_HP .
Event hit > Cast to AI_HUNTER > AS AI_HUNTER > GET MAX_HP .
How do i cast to every AI child [ ENEMY IS THE ,MOTHER"] To get the MAX_HP, so i can substract the damage my player have SMTH like
Event hit > CAST TO ALL ACTOR OF CLASS > GET MAX_HP > SUBSTRACT DMG_PLAYER - MAX_HP .
can’t get it to work, any ideeas?
Srry for the long message.
I'm not home so i can't show photos
maybe i can convert it to something that allow me to get it size?
my problem is that after image was downloaded i want to change my image according to its size to fix stretching
why do you want to hit every single class of that type when you hit one of them?
That's not how bullets should work
Isn't there an option on the slate brush to do that?
i don't i just want to get the variable of GET Enemy_HP from the actor i hited.
That's the only way i know so far.
so why do you want to cast to everything?
You could create an actor component for managing stats such as health. When the bullet hits an actor, you can use the get component by class and get the stats component from the hit actor.
alternatively just make your ai share a base class that has health implemented
they should anyway
i'm just confused why you want all actors of that class
That's how i used till now to substract the HP, from enemy with, cast and substract, dunno i'm still learning some things
That's an ideea
ty
With you still learning, all I can say is everything has a manager, even the managers have managers and those managers have managers. 😛
Why isn't this in UE5
This post will probably help you.
https://forums.unrealengine.com/t/screen-percentage-unreal-5/510675/4
In case anyone has the same problem, what seems to be the happening is that the editor’s screen percentage overrides the project’s screen percentage. To disable that behavior, you need to configure the following settings: [file > editor preferences > general > performance > viewport resolution]. The main setting you are looking for is ‘override ...
Is it possible through blueprint to modify the "Image (Brush)" property of an image inside a Widget BP ?
Yea, there's a few ways you can do it.
How please ? I think there's this node to do that but how do you make it understand that the created widget should switch its image to the on ein the SlateBrush ?
If you just need to update the image, you can use the set brush from image.
can't find that node
Sorry, set brush from texture.
I disabled this thing, and I still can't find the setting in the blueprints
From the forum post, you would need to use a console command to change the screen percentage in UE5 by blueprints. You can call console commands using blueprints.
Dunno if you got an answer, but one common way BP corruption manifests itself is if the details panel of a component is blank when selected in the BP editor.
yeah.. thats how i concluded it being corrupted after seeing the bugged out lights
but my question exactly is how can i identify the corruption without needing to click through and find out through the details panel
otherwise there are cases where i can see it going unnoticed for multiple iterations
I don't believe there is a built-in system for it.
How would a program know another program is corrupt if it doesn't cause a crash? I don't think it would be possible to actually know unless it crashes.
noted, thank you 🙂
sure but first i need to GET its size somehow...
This node is probally what you're after.
maybe this can help, thanks!
download image returns dynamic texture?
Cast to texture2d and get size x and sixe y maybe
theres both i guess its ok
hm, ill try them, maybe this nodes can work
i am trying to open this drawer but i can't manage to make it follow the arrow, also there are some collision problems when i deactivated collisions with pawns
Not entirely sure of the issue but I'm surprised you don't get an infinite loop with that retriggerable delay.
no actually it's the only way i can make a loop
i use it everytime i need something like that
not entirely sure how performance will be affected
Swap it out for delay until next tick. Small timers aren't great, especially when it's 0.
something like this?
Yea.
well thanks, it works
Has that fixed the issue with it not sliding in the right direction?
no, i said it works because it acts like before
but it didn't fix the issue
Instead of getting the forward vector of the rotation of the arrow, try getting the forward vector of the arrow itself.
i need the relative coords of the arrow because if i take just the forward vector the drawer teleports away
btw the most that i can do is this, where the drawer moves on the x axys based off the camera
Store the initial grab point and then subtract it from the handles current location, multiply by the forward vector of the arrow. Add this back onto the initial grab location to get the new location for the handle. (hopefully that makes sense)
i'll try to do it
thats good, but i still cant understand what to do with it
i tried this but didnt helped
What happens if you just call the set brush from dynamic texture?
call the set brush from dynamic texture?
I've just realised you've not got it hooked up to 'OnSuccess'
oh yes, i forgot to recconect it,but it doesnt matter its not fixing it
What happens? (if anything)
well, english is not my first language so undertanding that wasn't simple, but i came up with this and the drawer teleports away
right now its just switch img with new streach one that it downloaded
only way around it i can see that you must force user to look at original img with and height and then set it by hand
before or after u downloaded img
but its really not ideal way to do this 😖
Something like this.
What happens if you do this?
yeah true
still streched
Are you sure the image it's downloading isn't stretched? What if you try with a different image? (One that's smaller)
https://i.imgur.com/GSPuXxO.png original
Is the image component itself set to fill horizontially or vertically?
Check the picture size and your icon size
nice, its really good as first step, really happy i fixed this, thank you!
Cool map btw!
not mine, its just for test 😄
sorry if i am asking too much, but where do i set the inital location? i have done this and my drawer isn's moving
hmmm, that looks right. Print the vector length of where you get the location and minus the initial grab point. It should give you the distance from the starting point. Does this length change at all? if so, what sort of values is it giving?
ok so i tried printing some values and the blue one is forward vector from the arrow and the yellow one is the final location for the set target loop
one last print i tried is the grab point variable and it prints the same of the yellow after it stabilizes
didn't think a drawer would be so complicated
You need to print this bit. Pull from it and get vector length and print the returned float value.
is it possible to show FPS in a packaged game?
Hi!
Do you have any idea about this? https://forums.unrealengine.com/t/inherits-from-skeletal-mesh-component-with-materials-property/1643878
Hi! I’m using Unreal 5.3.2. In the VR Template there is a class called B_MannequinsXR: I have tried to replicate it, but I can’t. There is a Materials property in the original class: That I don’t see in my custom blueprint class (which inherits from Skeletal Mesh Component): The B_MannequinsXR class has also a Thumbnail: This s...
Sorry, it has a lot of details to put it here.
Thanks.
Hey, I am trying to run some tests, I have an actor that moves in a circle. hence the x axis value has a HighestXValue and a LowestXValue. I am trying to store these values in an float array (ArrayXValues) and I use a for each loop to iterate through the values comparing them to get the highest and lowest.
My issue is
I try add these values to the array. But when I add a break point to view all the values in the array to manual check I am getting the right value, the array only has 1 index value.
So how do I add a value to a new index of an array?
Why an array? This seems like you only really care about two distinct values.
If you want to use an array to store these two values, you can always use the "Set Array Elem" node, and modify the speciifc index of the values, so like use index 0 for the lowest value and index 1 for the highest.
There is a blueprint class in the VR Template which inherits from Skeletal Mesh Component with a Materials group. I have created a custom blueprint class which also inherits from Skeletal Mesh Component, but it doesn't have the Materials group. Where does the Materials group come from?
Add your skeletal mesh, then the materials slots that are available will appear.
Hi everyone.
I am attempting to make my own game using blueprint.
I am wondering if I can find anyone that can help me on my journey by looking over my work and giving feedback and suggestions.
I’m nervous that I will make a big mess and am trying to address problems as I go before they get to be too big.
I sadly do not have any money to pay so I wonder if I could find somebody who can do a trade with me. In exchange I am able to help with what I’m good at - 12 years of experience with 3D animation, modelling, rigging, etc. I can cover the entire 3D pipeline.
If anyone has the skills in blueprint and is seeking help with 3D graphics please send me a DM!
You're better off looking over #instructions and posting a job offer (as a volunteer project) than asking in this channel for support like this as it'll just get buried. If you have specific questions or need help with a specific problem, you can post your stuff here and there's many of us here who are willing to assist.
Thanks!
what am i missing, why does it work when i move a slider but not from the game instance?
restarting the game sets everything to 100 volume again but the prints say that its being set at the right volumes
hmm adding a delay after init works. need to figure out how to check if the audio system is valid or something
Will do thanks
figured it out
Hey! I wanna know how to call a function from a different blueprint. Thanks!
you need a reference to the blueprint or use interfaces
if you're spawning that blueprint with the first blueprint then you can pass the value across
For Interfaces you still need the Reference...
Also Interfaces are not a solution to "How to get the Ref"
that sounds complicated...
well i want a widget blueprint to do a function when a third person character calls it
Check the pinned messages, there is a video, while rather oldish stil lrelevant, that talks about this
Blueprint Communication
It's long, but programming is also not easy :P
alright lol
Second last pin on desktop app
thx
tried to make smt, it didnt work...
Hey, anyone know if it is possible to make the actors placed in the editor that overlap eachother initially fire off the onbeginoverlap? Only seems to fire it off when beginning overlap that isnt initial from the actor placement
Maybe have it initially trigger from the event begin play node and then subsequent times you want your BP to fire have it triggered by later overlap events?
Yeah i just used GetOverlappingActors on beginplay
if you want to reuse the overlap event, you can re-set your collision size during begin play, and make sure to update overlaps
Hello guys, I made a settings menu but when I try to change graphic settings I don’t see any differences. Screen mode and shadow quality settings work well. How can I fix that? The engine scalability settings menu doesn't change anything either
double check your outputlog if there is anything that says, skipped setting scalability due to some higher level command, i forgot how it is exactly phrased
Everything in the engine can be considered an "Object".
An "Actor" is a type of object that exists within the game world and has a transform.
A "Widget" is a different type of object, one that is meant to display UI, it doesn't have a transform.
Widgets do not inherit from Actor, so you can't expect to get an "Actor" reference and cast it to a Widget.
By using "Get Actor of Class" and using "Actor" as the class you want to get, you're basically saying "Find the first actor in the world" regardless of what actor it actually is, so this isn't really what you're wanting to do.
To get you going, though not necessarily the best solution, use "Get Widget of Class" and specify the class of the widget you want to get. So long as there is only 1 in existence in your game at the time you're calling it, it'll retrieve that particular instance of the widget. You wouldn't need to cast or anything, you should just be able to call your funciton from the return value.
I have a strange issue. I have a flying pawn, like a jet. When i fly straight towards an object in the ditance, the movement direction suddenly tilts abit. Meaning i miss the target i was looking at by at least 100 meters and more
its really obvious too
i checked the rotations and everything
the forwards are the same continuesly
there is no change
That's all what I get, when changing something in scalability menu
fixed
In Blueprint, what would be the most efficient way to find the nearest Line Trace Collision?
I'm not sure if I should just do a ton of Line Traces from my Character in random directions, then pick the two closest or not.
I'm not sure how expensive that would be.
This sounds like you could probably just do a sphere trace. What is it that you're actually trying to do?
Hey! Sorry I'm late, but thx for the help, I had to use get all widgets of class and a for each loop tho because i couldn't find any "get widget of class"
I have a right click ability to grapple in the direction your camera is facing, and I want to find two points slightly angled from center crosshair to grab onto. This is only for Visual Purpose, and I need it to find another point if there isn't anything there.
Here are two examples I drew over to show what I'm trying to do.
Ideally, if you were looking straight up at the sky, I still want these lines to find a surface below or nearby
Actually, I'm guessing Sphere Trace is a Sphere I can choose the size of to shoot out, meaning that would work really well
I wasn't familiar with it's use case, but I can see how that works here
quick question, any way to add multiple texts in 1 widget blueprint or join 2 variables with a newline?
There is "Append" which allows you to join strings, or you could use "Format Text" which allows you to define {variables} in the format field and then provides with inputs for those variables.
If you want to add a new line, you may need to hit shift + enter into one of the fields.
I made a blueprint class with "Object" parent, but code doesn't run on it. Do I need to somehow spawn the Object in the level in order for the code to work? If so, how? Because right now it's just sitting in my content drawer.
construct object
and then keep a reference around of it, as it would be garbage collected otherwise
Anyone have any idea how to get the velocity of the world itself not just for a specific actor?
I find myself doing this function from scratch in every single project:
Is there this function already in the engine and im missing it?
It seems to me something that unreal should have
It needs to loop through the units and check who is the closest
thats it
there should be something that at least gets the closest vector from a group of vectors to a vector
Create yourself a plugin that contains a function library that has your commonly repeated functions.
thats it !!
find nearest actor
damn lol. how many times did i make this function
Hello.
I am trying to bind an action to a key press to push a debugging menu over the current widget (its a common activable widget)
However, it doesn't do anything. (edit : the widget doesn't respond to input at all)
what could I be doing wrong?
Not sure how this node works, but does it automatically add it to the viewport ?
no.. the problem is that the widget doesn't respond to the input at all.
I just realized that
Ah, if the Event Graph is from a widget, I don't think key binding occur there like they do for pawns. Try overriding the OnKeyDown/Press functions?
why is your key input in your widget ? why not create the widget and have a reference so you can call it like normal. I think keys are usually in the player controller or pawn
is self the widget ?
I just want a hidden debug menu to appear when a certain key is pressed.
I am trying to find the most simple solution.
OnKeyDown might just work, I am trying that right now.
or is there a reason for get owning player ?
Like engage said, just put the key on your Controller or Pawn instead
You can create the widget at start and hide it, then on the key just set the debug menu visible
That would probably be like the simplest
thanks for the suggestions everyone.
I tried @spice viper 's suggestion to override OnKeyDown and it worked like a charm. Additionally I had to set the widget to be 'Is Focusable' to make it work.
I dont understand well the difference between Text and String.
In my searches, it says Name is better for text that you will not change, like a ids, names, etc...
Whereas String is for text that you need to change and alter at anytime.
So where does text compare to string then? And why would i use text over string?
From UE Docs (https://docs.unrealengine.com/4.27/en-US/ProgrammingAndScripting/ProgrammingWithCPP/UnrealArchitecture/StringHandling/) :
FName - FNames provide a very lightweight system for using strings, where a given string is stored only once in a data table, even if it is reused.
FText - the primary component for text localization is the FText class. All user-facing text should use this class, as it supports text localization by providing the following features:
FString - Unlike FName and FText, **FString **can be searched, modified, and compared against other strings. However, these manipulations can make FStrings more expensive than the immutable string classes.
So basically FText only makes sense when used in the UI?
personally I use FNames for identifying objects, FString for debugging but I am sure there are better use cases and FText for UI
I believe so
thanks @arctic elm
Hello! trying to make a high score variable, can't seem to be able to figure it out. if i use save game to slot will it save the variables in the save game blueprint or the blueprint i call it on?
how to update all the child classes of a base class if some default property is changed on the base class?
i have a box comp in the base class, i resize it and it is not changing on child classes
it needs to open each and reset the scale
they are actors and placed in the level
if i place a new copy of the same actor, the data is correctly updated
i want to update the items which were placed in the level before modifying the default properties in their base class
are you sure all your child classes inherit from correct parent class?
oh, i just checked and they are parenting another base class 😄
thank you for the input, the issue is solved
anyone?
hey guys, im having an issue with enhanced input action and would love to get some help
issue: when i use enhanced input i get some sort of delay/doesnt act on the exact frame compared to activating something from direct input
i would like to get the same result as direct input(fast, computing everyframe) but on the EnhancedInputAction
I am using Lyra, and in the extended plugin it has an experience / level system. I have a widget, I want to show XPGained, currently its set up to track currentXP, OldXP Value, and NewXP Value. I want the difference from OLD and NEW so that it just shows the amount Gained. I am having trouble accessing this information if anyone could help.
for some reason my casting keeps failing on this blueprint, any ideas for what could be causing it?
Does anyone know if there's a good UI element if i want the player to select tags from a TagContainer?
hey so i have this event to make the player change its rotation to the cursor for aim
but the player keeps rotating and i understand why
is there any other logic to pull this off ?
Hello, can somebody help me please? I'm trying to do some ranged attack but it's not working i dont know why it was working in 2.5d but i think in 3d i need to do something different and i cant find it anywhere
I have an array of actors. And need to get a random actor from it,
Though with probabilities per actor.
So if i have 3 actors. How do i make the probability of actor 1 to be higher than the others?
Hello! trying to make a high score variable, can't seem to be able to figure it out. if i use save game to slot will it save the variables in the save game blueprint or the blueprint i call it on?
It’ll save the variables to disk, you load them from there https://docs.unrealengine.com/5.3/en-US/saving-and-loading-your-game-in-unreal-engine/
i do not understand why my widget animations are not working on overlap events
Apologies for posting this again but have tried many things to try and fix this camera issue and basically have run out of ideas. All I know is it's caused by setting the z value in the "Set Control Rotation" node during the camera transition. As far as I can tell the camera should be returning to the exact same transform every time yet it doesn't, it bumps sideways as shown.
so i need to loop through an array of actors, get a bool from each, and ONLY do something if all bools are false... how do you do that?
It’s too hard to read blueprintUE on mobile but debug and watch the values that are coming through so you can see what exactly happens
There's a way to print the transform for the camera throughout the BP?
are you using set view target with blend? or are you lerping it
Actually I think I know how to do that, still would leave me with the mystery of why it doesn't return to the transform it's supposed to.
reminds me of a problem i had when useing "lookat tracking" settings on a camera
🤔 you could maybe add 1 to an int each time that bool is true and then if the int == the length of the array, give ‘er
wouldnt track during the lerp
Print or watch value to see if the return xform is actually correct
After testing it a lot I narrowed it down to this value here causing it.
have you tried using view target with blend?
might clean that up a bit
plus has nice easing options
No, I did hear about that a while back but I had the impression it was for static cameras.
nah, its great for a lot of cases
i'd go down that route
Would this just address the jerkiness of the bump? Because the actual transform not being what I want at the end of the transition is what causes issues going forward with other things I want to do with the camera.
yeah it would
jsut blend between first person anf thrid person cams
half that bp would be a single node.
I mean I am fairly certain the transform is simply not correct at the end judging by how the grid on the floor is aligned with the edge of the viewport, how the angle alters more and more after each transition.
honestly, i'd refactor that with Set View Target with Blend
I'll give that a go for sure.
Always a good idea to actually debug rather than making assumptions but power to you
You might even find out why the issue is happening in the process.
It's not an assumption, I get printing the value is more certain but I can see the camera does not return to its original position quite clearly.
yo, save yourself an hour and just use set view target
If the xform you gave it is correct, perhaps your timeline track has a problem or you have some collision issue
It returns to the transform of a component that occupies the exact same transform with it at all times, that's why I find the whole thing weird (both components stuck on the same spring arm etc).
Maybe they are colliding then?
That was one thing I considered but can two cameras even collide?
Yes
Granted it doesn't return to the placeholder camera, I changed the component for a transform reference in to an arrow but the problem existed before that.
Where do collision settings exist for cameras? When I looked the other day I couldn't see anything.
this works, but i just would have thought there was a more graceful way to do this
if it works it works
thanks dude
anyone know which pin this is? I can't find a set pin
Name?
wdym
which pin are you talking about?
nvm found it
its a 'name' not a 'string' or 'text'
i hadn't made the variable visible and it didnt show up when i typed its name so i thought it was a different pin
oh
Set View Target seems to not work with actor components. Doesn't accept them as targets. Is what you suggested not supposed to be implemented in the player character BP?
wdym, use the player controller and get the camera component
actor > get camera component
its cannonical like that
This is within the character BP or the player controller BP?
wherever your camea is, charachter i'd presume
I don't understand what you mean by getting the camera component then, in this context, there's nowhere I can see that accepts it.
Just wondering what yall's process when gathering user input for display like on an interaction button or something.
I'm working on a proximity button where you walk near it, it shows a wdiget saying Press [InteractionKey] to interact but I actually want to fill that with what the key is. So not hard coding it to be E or something. I'm currently making use of the new enhanced input system and have a Interact input action and not sure how id' get the key value
Anyone have a pointer to how to hook into the "stop" or "pause" event for a Level Sequence Player in blueprints? I tried binding the On Stop and On Pause events but they don't seem to fire.
Also, I can't believe I somehow never joined this discord, probably could have saved hours of stupidly wasted time !
My savegame keeps incrementing every time I activate PIE. Does this have an effect on the save data itself or is it safe to ignore?
I imagine every time the a new instance is created it just references the data from the previous one if it was saved. Just seemed strange to me.
Hello. I have a sphere volume that I use to detect if they have overlapped a pawn. Now I am making projectiles and want to detect if the sphere hit a solid obstacle. Can I use the same volume to do so or do I need a second volume with different configuration to bind?
is there a way to set the default value of a variable?
there seems to be for custome primitive only
You should be able to use the Details panel.
I need a little push in the back, I've done vehicles before but I'm stuck on an idea.
I want to make a mech that is not a Pawn/Character but a "Vehicle/Actor" so not using the Character Movement because of some reasons but I have no idea how I'd make it move forward/backwards/sideways (input only, rest I can figure out)
Anything that has to do with input needs to be a Pawn.
Pawn does not need to be a Character, however.
The alternative is to make a special Input Mode that your character reads and sends commands to whatever vehicle they are part of.
does anyone know how i can make this go back to the start position smoothly without having to jump straight to it when i let go of my key?
You can change the play rate and use the "Reverse" input.
is there a way to make it stop looping when it reverses?
i tried making the release key go straight into reverse but it just loops forever in reverse
Ok so I'm setting the mesh location in an actor to a point along a spline path. But if I set actor location, and the player ISNT MOVING, it just goes through their body. so i added a secondary static mesh of the same shape, and scaled it down to 99% the scale of the original mesh, and it still doesnt overlap unless im moving. kinda just at wits end atm. any suggestions?
So when you play forward, you'd want to set new looping true, on release, set new looping false.
ooo ok would i have that go in between the pressed and play? and the release and reverse?
yep
ok tysm for the help!
i see people suggesting to make the mesh the root compoennt (this breaks a lot of things if i do that positioning wise with the spline, but even in doing this it still doesnt work)
Line trace against complex collision doesn't seem to work
sorry i didnt ask properly
i meant how to reset it back to the default value
that was set
so its 60. I change it to 10. Then need it to reset back to whatever it was
maybe need to create a second variable to store the original value, right?
not sure if you can do this in pure BP, but you can get the class default object and get its variable.
that is awesome
anyone know how i can modify this so it plays while I'm currently moving around and then when i stop moving it stops
is it possible to make asynchronous blueprint nodes which are executing commands in the gamethread ?
@frail onyx you need to get the value of the character speed from the character movement
My cast to actroll class fails, my set player is working i printed it, but not going any further than cast to actor class, any idea why ?
is there a way to activate it without using event tick?
Add on tick (it's ok for very small things like getting speed), get character movement, get lateral velocity scale/size, set that to a bool IsMoving which also sets the timeline is looping.
I would use it in the animation instance from the character
since its regarding to the players animation
Yeah, do in the ABP
Ehhh maybe on the pawn, he's altering the mesh. Not the animations
you could cast to the character from the animation blueprint
Also true
bump
wait would this world/be better than using event tick?
would anyone happen to know a good base to start with for a system similar to wave function collapse
im not seeing any plugins that will do what i want to do
is there anyone that has messed with this that could give me some pointers
the system i would like to make needs to have each piece have some attachment points on it and each attachment point is assigned a number and only other attachment points with the same number can connect
or if someone could direct me to some videos or documentary that would be great
Given an actor, how can I get its Player Controller, if any?
There's a "Get AI Controller" node but not one for PC
Found it, forgot I had to cast to Pawn.
How do you handle that kind of thing if the ASC is not on a pawn?
like if it's on a controller. Just check if owning actor is a controller?
Guys what's wrong with my Minecraft like "heart system" please ? The health variable is set to 2, the maxHealth set to 5. So the maxHealth is giving me 3 hearts slots, so that's good.
However Heart is set to 2 so it's supposed to give me 1 full heart only but somehow I have 2 hearts + 1 half heart.
How can make I make a static mesh component inside a blueprint change between being clickable and not clickable?
essentially block/unblock click on a specific object inside a blueprint?
don't block the clicks, just ignore the click logic
You don't block the click, you rather create a variable inside that blueprint and set it to true when you want it to be clickable, and false when you don't want. And depending if it's set to true or not you do the action you want to do
So have a boolean that prevents the execution going further.
Hey do you have a solution for my problem please ? 🙂 ☝️
unfortunately your bp screenshot is a little too small to read :P
What is your goal, exactly? 5 max health should resemble 3 hearts, the last one only half filled?
Yeah. 1 health = half a heart.
You can do it with some math.
Number of hearts = Ceil(Max health / 2)
Half Heart = Max Health % 2
I may be missing something but nowhere in that code are you using Health to fill in the hearts
which explains the 2.5 if your max health is 5
Where should I add that ?
Using the Health variable where you use MaxHealth should be better.
Figure out how many empty hearts you need to append afterwards
It doesn't work properly when replacing "MaxHealth" by "Health".
Health = 2
MaxHealth = 5
but it gives me only half a heart
By subtracting the ceil'd Health from MaxHealth
Let me write that up from scratch again because I'm confused by my own code
How do I do this for when a UI button is pressed? instead of just the mouse button?
If I were you, I'd split the code in two.
An initialization where I'd just create the set of hearts (widgets) that I would put in an Array (Your first code would be adapted to this, I'd just replace the SetBrushFromTexture with an Add to this new Array).
Then I'd create a function to update the life.
In this function, I'd use a local variable to store the life to be assigned to the hearts.
I'd do a while loop on the Widget array, if the local value is :
- greater than or equal to 2 : heart full
- greater than 0 : heart half full
- less than or equal to 0 : heart empty
using the SetBrushFromTexture function, and I'd decrement the local value by 2.
The first step is to check the "IsVariable" box.
The button should then appear in the list of variables.
By scrolling in the variable details, you can choose the event you want to listen to.
Ok I got that
now what?
Ok I have this first part, is it good till here ?
Like I'm trying to get the amount of heart icon that will be generated (empty hearts, half harts and full hearts included)
Looks good to me.
Sorry I didn't look at the rest of the code, I hadn't seen the whole problem.
I'm sure someone else can help you better than I can.
Now that's where my brain is melting
Yea I have no clue how to change a drag-and-drop operation over to a UI button pressed instead of a mouse detect.
Create an Array variable of type WB_Heart.
In your loop, all you have to do is construct WB_Heart and insert it into your horizontal box.
why would I need to create an array of WB_Heart instead of directly creating WB_Heart in the Horizontal box ?
The purpose of storing WB_Hearts in an array is to be able to easily retrieve these objects in another function and access "Heart Img" to change their texture.
But you're right, you don't have to store them in an array. You can probably use your HorizontalBox's GetAllChildren method, but you'll have to cast the widgets to WB_Heart.
How would you identify the respective wb_Hearts that you want to change the image of then?
I thought about choosing the right image of the the WB_Heart when I create it and add it as a child to the Horizontal Box. And when the health is refreshed, I clear all the children of the Horizontal Box and start the process again
I see what you are trying to do now. If you don’t have to make any changes to any particular items in the container box then yes this method can work, just make sure that you are creating them in the correct order.
what kind of changes are your referring to ?
Like if say for any reason you need to animate the last one or whatsoever
I will need to animate the hearts at some point
Then depends on how you code them and what is your use case
You’ll probably have to add>animate>add or something
mmhhh that doesn't sound the best option then, what suggestion do you have to solve this issue ?
What exactly would be your use case scenario? I wouldn’t be able to advise without understanding what you exactly need.
my use case on what ?
On this whole setup
What is your intended outcome and scenario
When you talking about animating, are you animating all of them, or just animating the last one, or a particular one in the middle
Etc
That kind of thing
I'm trying to recreate minecraft heart health system. https://youtu.be/NZrqJzyZpvo
You are free to download this to use for your videos.
Like for instance when there's a health regen, there's this animation https://youtu.be/PhbnlXetnbA
free GreenScreen of Health regeneration for anyone to use as they wish.
Let me think
I would think that Zhord’s method would be more efficient if that’s your usecase
So you have the widgets created and added to the container but at the same time you should add each one created to an array so that you know which is which
Esp the last one
And when you need to change anything or animate them you can simply run through the array instead of GetChildren and casting as it would be costly
Like in the case of regen it is basically updating the image of one item after another
So with an array it is easy to sift through and find the element index that you need.
Like if your HP is at 4.5 then you trunc it you get 4, which you can use as an index in your array to point at the 5th item, which would be the one with a half-heart image
Things like that
When I attempt to pull the variable and set it in the character bp
I'm trying to smooth a float from one to another, using lerp but it's not working as it should be (nothing is working lol)
Hi, I'm a beginner in unreal engine 5. When I run my game, why won't my player start actor move after I've used a transform variable in my level blueprint?
use the normal template already built in ue5
I'm sorry, beginner here, what is the normal template or where can I use it?
when you create an unreal project, you have multiple choices
Your talking about the blank option when creating a new project?
all the option, exept the blank one
So your saying then it will work? Also why wont the transform variable work in a level when creating a blank project?
yea it will
I would highly suggest you to watch some youtube videos or read about unreal engine 5 before starting something..
anyone know why its not letting me move this actor between these 2 points with the Q or E key?
Well I'm taking a course from Udemy and the instructor used the transform variable in a basic level from creating a blank project... ?
did you know about the new input mapping system in ue5?
i made a new actor blueprint put added a cube to it but it wont activate
that doesnt work anymore
Hey guys, in today's video I'm going to be showing you how to use the enhanced input mappings system in Unreal Engine 5.1 that replaced the now deprecated input actions system.
#UE5 #UnrealEngine5 #UE5Tutorial
00:00 - Intro
00:12 - Overview
00:58 - Tutorial
10:23 - Fina...
Hi I have issue with Get Socket Transform when shooting
Video:
https://gyazo.com/39b029d1e2213e50cf14c020bd5ea04c
My blueprint:
https://gyazo.com/05e95ca5ab042c591bed470d294148a0
Can anyone help me
Thank you for your help, also after doing some research I understand the engine better
np!
Does the vector variable change both the location and scale of an item while running the game?
No
A vector holds x,y or x,y,z coordinates (i.e. location only)
If you want location + rotation + scale, use a transform
but the transform doesn't work in a blank project, also your wrong, vector changes the location of an item, learned from udemy instructor. Is there a variable that changes the scale in game. Or is the location and scale both changed from a vector which I don't know...
It’s you’re* and that’s a bold statement but I’m sure you know best
Also no idea what “transform doesn’t work in a blank project” means in this context.
Transform is a type of variable that holds all 3 of those things
I have an important project to finish.
I need to save in gltf or fbx better a configurated design product made of cables and spline mesh in runtime. How can I do it!?
Could you make to me a script?
See #rules and no one can give you the code if that’s why you’re asking
Hi, I was wondering if/how I could get a component transform (world) from within the component not the actor?
Why my Event binding to a dispatcher in my WB_HealthBar isn't called when I call the dispatcher from my OnRep_Health function from my BP_ThirdPersonCharacterBP please ?
why does my character stop running if the distance reaches 350, but when it is less than 350 it just keeps running to the interact target? (checkInteract is running on event tick, and the second screenshot is from my interact target (a chest) )
Did you spam Print String in your logic. Is Current Interact Target valid?
Is CheckInteract being called? Are the floats for the branch check what they should be?
there may be something wrong with when i run stop movement immediately, because a print string will run exactly before that, but my player does not stop, i will look into that
How can I make the player look downwards with code?
I don't need anything fancy just a teleport
you can set spring arm rotation or try this
Y -90?
idk test it
get player controller
Is this an efficent sound trigger?
but you also can do this
oh
this way the sound will play once anyway
tank you
i need help with something else how do i make this work?
well idk, too little information
How can I increase the speed the player falls with a button press?
Set gravity doesnt seem to do anything for me in terms of speed
jump velocity?
it kinda works but it slows the falling speed temporarily
oh
i dont think its adding speed
i can cut the speed off entirely but not add speed
I'm working with the first person template. I made child classes out of the default projectile and made the weapon component spawn those. I added an enemy BP, just a basic character with a skeletal mesh, some chase AI, nothing too complex. I want the enemy BP to react to any child class of the default projectile. Now I'm trying to hit the enemy, but when I fire on it, I never get the print string (see attached). Am I doing this right?
Hey guys , i am trying to make quest system related with my inventory i tried interface for communicate between them but stuck here.
check projectile and enemy collisions
the casting is right
Collision of the projectile's collision component is set to projectile. Enemy collision is "pawn" on capsule component and "Character Mesh" on the character mesh. I think these are all the defaults? I tried using "Block All" on the chracter mesh and still nothing.
hi, if i have two transform values can i trace a line and get all the coordinates on that correspond on that line, maybe an array or something, and clamp another transform value on that line so it can move in a straight line? (don't know if it's understandable)
it might block all but does it overlap?
My projectile is set like this. My character mesh collision is same as yours.
tick overlap on everything on both to test
pls help someone
ok so I ticked overlap on everything (projectile collision component, enemy capsule component, enemy mesh) and my enemy fell out of the level and into oblivion lmao. I switched the enemy collision stuff back to default. projectile is still has all overlap ticked and still nothing
you have too keep Block and add Overlap
ur event is
begin overlap
but ur overlap is switched to false
I just need to make the player fall faster
I set the collision preset of the enemy (both the capsule component and the mesh) to custom and ticked overlap projectile.
Side note, I'm not getting that red line between on component begin overlap and the cast node when I shoot at my enemy, so the event is not triggering...
(the enemy is stationary in front my character, can't miss it)
Ahoy! I have come across a problem I am unable to solve with a Map variable inside a function... So when I set the value inside the function and print the value later, from inside the function, it shows the correct value.. However, if I get the value from somewhere else in the same BP but outside of the function, it defaults to 0... So I can have both a print inside the function and another in the main graph for example, at the same time, and one will print 0 and the other 1 or 2🧐
Here's the snap of code.. First map is to get/update damage values on components, and the second map sets 1 for damaged or 2 for destroyed. I want to know if a component is damaged or destroyed outside of the function:
https://blueprintue.com/blueprint/4nomqda5/
i would try the event on projectile
projectile collision component on begin overlap -> cast to enemy bp -> print does work, so that's cool. but i want to keep the collision logic in the enemy bp to calculate for health and such. should i just do on projectile overlap -> cast to enemy bp -> apply damage and then handle the damage calculation on the enemy using the event any damage node on the enemy bp?
yea thats how i do it
awesome. thanks a lot!
This interface communication does not work what am i missing here
thats because your calling it on an actor that hasnt implemented it.
your calling it on the player controller and not the objcraftitem.
so i need to make a objcraftitem object variable in bp_firstpersoncharacter
An actor var is just a pointer to the actual actor which would be empty unless set. Assuming the objcraftitem is in the level already, you would need to get a ref to it and call the function.
Increase the gravity on the character movement component.
this quest in the level so still i can not rach the object
You're trying to get the 'HasInteractedWithKey' var from an actor that has been destroyed. You'll need to provide more information about what you're trying to achieve.
Is there any way to stop data assets from saving in the editor?
i wan't them to stay static unless they are loaded from my save game object
Oh its a quest system. Really, you should be using event dispatchers for stuff like this. I would assume you have some sort of inventory to manage items that are picked up. When an item is picked up, it would call an event dispatcher (something like 'OnItemPickedUp'). The quest would then bind to the relevant event dispatchers so it knows when stuff has happened. In this case, the OnItemPickedUp event dispatcher.
Oh thank you so much for show me the right way man
No problem but yea, ideally nothing should ever need to know about the quest system as it should run on top of everything else. The moment you need to start communicate with quests directly to notify it when stuff has been done, it'll get very messy and become buggy. There would just be to many edge cases to account for.
So you mean this is too much for my level ?
I'm not sure what you mean.
i mean it's too hard to implement for all system
The current way you're doing it isn't scalable. By the time you've completed you're first couple of quests you'll feel yourself die a little inside at the tought of making another one. 😉
haha got it but i will keep it simple it's just for introduction not like a mmo
It doesn't matter if it's not an MMO lol. A quest system is a quest system. 😉
Can you recommend better or easier way ?
Yea, use event dispatchers. You would add them in places so other systems can now about stuff that has happened like, picking up an item, using an item, jumping, interacting with an NPC, dying etc... The quests would then bind to these events for what it's needs to keep track of. This means nothing would need to know about the quest system and the quests handle everything themselves.
Perfect thank you again
Is there a way I can open the Level Assets one after the other and perform some blueprint logic in between ? I want to do this either with a editor blueprint or in c++ if possible.
Anyone know why Play Sound at Location wont work but Spawn Sound at Location does? so confused lmao
I can't "Get player character" in object class for casting character @dark drum
the objcraftitem a child of uobject?
Child of other object class
is that a child of uObject?
Looking at your previous screenshots it looks like it. So uObjects don't have any context to the world so you need to give it a path to it. If you need to get the character, you could create a BPI function for getting the player character. You would then implement this in the BP that constructs the object (assuming it's it's outer). You would then just get outer in the object and use it as the target for calling the BPI function.
I already using BPI for getting player character
I dont know whats mean "outer" bpi also need object like casting
When you construct a uobject based class, there's an input called outer. This is like the owner of the object. In the uobject, you can get it's outer (owner) which is it's link to the world in a way.
can we construct anywhere like this
Yea, but it's normally a good idea to have a manager that handles it. The last thing you want is multiple quests objects having different outers as it'll become difficult to maintain and manage when you need to get data from the world.
If you have a quest manager that has a function for creating the quests and stores a ref to them. You can then include logic (BPI functions if needed) to get stuff from the world. (if needed)
So how I would structure it is having a quest manager that is of type Actor component that gets placed on the player controller. If the manager creates the quests, it can set itself as the outer so you know that in the quest objects, getting outer would get the quest manager, (in object form so you would need to cast if you need to call specific functions) you could also then get the owner which would get you the player controller (again you would need to cast to the specific type), and then from this, you can get the controlled pawn. (again you would need to cast if you need a specific type)
Assuming other systems use actor components and are placed on either your player controller or character, you can then use the get component by class node to get most of what you want easily without even using a BPI.
This is my 'AddQuest' function in my quest component as well as a function in my quest object base for getting the owner of the quest. (the player character)
I understand man thank you for all detailed answers
It's not gonna work
Today i guess
In your example, if the player character is constructing the object, the it would be the outer so you can just get outer and cast to your player character. No need to use the BPI function. (Of which you probably haven't implemented on the player character.)
If your code is correct the character should be moving diagonally isn’t it?
Would I be correct to assume your using enhanced inputs?
Oh right
In your Input Action, you can change the accumulation behavior. Setting to cummulative will result in the character standing still if pressing both forward and back.
Hello, I have this problem, that i dunno how to resolve.
- i created 3 comps , Health DMG, Death.
I setted the Health, the dmg and death, but!
When i hit the enemy, it's does the math [Enemy hp - Project dmg]
Wich is equal to 1.
But, whenever i throw another project, it's goes back to full health [150].
Why?
Also, i'm using Hit component sphere. [my bullets]
Hello! I got a button to open the main menu level, however, when i click it it flashes the main menu screen and gets right back to the current level. I also added a print to the main menu button to start the current level and it never triggers. What seems to be the issue?
I also tried adding a delay to where you can't click the start button on the main menu for 1 second after construct and initialize, but it didnt do anything.
As a guess, I would say there's something in the main menu that's making it go back to the previous level.
I dont think so, it only has 1 button and here's the code
as i said it doesnt trigger the print tho
space bar == no no
Probably not the answer you wanted.... i would look at the AnyDamage event. It might be strange, but it is what you are setting up without doing it from scratch. (It might mention damage types, but you dont need to worry about them really). As for the calculation, you need to keep track of health as it gets modified. For example, on Damage, currentHealth - dmg = currentHealth, then check currentHealth >= 0, if it is not, they are dead 🫠
you can't use the previous input system
nope it still doesnt work without it
what...?
Hey guys, in today's video I'm going to be showing you how to use the enhanced input mappings system in Unreal Engine 5.1 that replaced the now deprecated input actions system.
#UE5 #UnrealEngine5 #UE5Tutorial
00:00 - Intro
00:12 - Overview
00:58 - Tutorial
10:23 - Fina...
i did the calcs, as you said
ive been recommended this before, isnt there any way to avoid this?
no???????
Im going from the current posted pictures
you must use it, you can't use the previous version, it is broken and will not work when building your game
@brazen merlin Ty for asking, not really getting it, for a more detalied view : https://www.youtube.com/watch?v=tcqCO_YijpM, if you can ty
And about onanydamage, gonna look for it
Hmmm... from this video, there is collision contact occuring. I would print string to figure out what collisions are happening and also print string if the damage triggers. It might not, i dont know the complete setup.
The damage should be applied, not just to be shown in debug, it's crearly taking Projectile DMG from Enemy Health.. so idk
Well the old input system is depreciated so... yea. Unless you're far into development, you should switch over to the new system.
Having said this, I don't think it's whats causing your issue though. Do you call open level anywhere else?
On the Gate node, if something points to the "Open" pin, will it execute whats on the "Exit" pin or does it only open the gate?
it just opens the gate.
ty
Ahh, i'm in 5.3. The only way around it would be to split your move axis up into their own input actions then. (as far as I know)
anyone?
Possibly, backup your project and give it a try. If nothing breaks it might be lol.
How do you know the health resets?
after each shot, the Print string goes back to 100.
Show how you're printing the health
if i spam it, it's goes to 88 [health], then back to 100
@dark drum
Enemy's have 111 hp.
so the math it's kinda working
but it's resets
It's because you have the health component on the projectile. Each projectile will get it's own instance of the health component.
To be fair, it could all be handled by a single component. The health component would be on the character and with the 'OnRecieveDamage' event, have it call a function on the component that modifies the health.
The projectile would just call apply damage on the actor it hits.
nope (sorry im late)
I'm trying to add a slight rotation to the camera when player moves left or right, but I'm having issue with rotating the camera. The camera's roll is controlled using the player input, so I can't roll it blueprint-side. I tried using the "Add controller roll input", but the problem is that there's no "set" node, just "add", so it will just keep adding and never resetting back to 0
try this
target is player controller
Yup! For some reason the node wasn't showing up in search, but this works perfectly. Thanks!
When you execute "Open Level" anything you do after it can be thought to not happen as opening a level causes the engine to essentially destroy everything.
The only thing typically to persist is the Game Instance.
i want to make an ai that stops moving if i look at it (like a puppet or the angels in Dr. Who). I tried it with a box collision for the player (if the ai is in the box collision it stops) and it works but it's not efficient. Does someone know if there is a node that disables movement if the ai is just on screen?
"Was recently rendered" might work. I've used dot product before and that works very well
I am a tad bit confused, hopefully, somebody can assist!!! For some reason, the branch node is never going into the Clear and Invalidate Timer node.
This does get set... wait....
as I am typing this... i only do the check on event beginplay
Okay, fixed it moved the branch down to the PlayAnnoyingSound bit 🙂 perfect
If I want to make a short lived laser, should that be an actor ?
I guess maybe it's better to just attach a particle system to an actor instead
hello guys anybody nows why after players death and respawn my touch inputs do not work any more? and i get an error
Hello, can someone guide me on why my viewport resizes upon changing levels?
"[2024.01.27-20.24.34:885][238]LogViewport: Scene viewport resized to 1274x680, mode Windowed."
I am setting my GameUserSettings to different modes like Full Screen, Windowed Fullscreen...etc, but when I transfer to a different level, the screen resizes automatically.
Hi, I'm using UWorld::ServerTravel() and passing in options to change the game mode like /Game/Project/GamePlay/BP_GameMode.BP_GameMode_C, this appears to be working in loading the new game mode, but only the C++ class, it ignores the Blue print instance of that game mode I am referencing? Anyone encounter this?
when does construct run ? i imagine the reference is being killed, you'll most likely have to run that code again to get that reference.
after you spawn it
set the reference ?
or construct runs when the thing is being spawned ?
i have not used that event yet
that construct runs always by event begin play in the character BP its a widget
"always" ?
i would check the length of the array
see if they are both in there for some reason
because the reference your using is f'd i think
hmm ok let me see give me 3 minutes
yes always with eventbegin play so i want that widget as the begin
The reference is going to BP_Third Person Character
im not realy waht to check?
ok let me do that
it might be the get 0, if the array is actually empty
or there could be two in there idk
sorry im to new for unreal to get you right i try now to add a print string xD
But it shows me nothing ingame
well you have no "power" or execution going into print string
so it doesn't run
and you want the length of the array
that Get is not doing anything
im not realy sure how to get the lenght of an array
drag from the array, search for length
also, I'd recommend you to make them look prettier, more ordered, symmetrical, etc.
not only for you but for others to help you more
sorry it was the fast way
i cant connect now the length with the reference
the green pin is the output of the node.
just drag from there and use it however you like
thats waht i mean
you are trying to use a type of variable thats unusable for your input
I'd recommend you to start with much more basic stuff.
ya it seems like you should do maybe some learning of basic node stuff like what the white line does, what pins are and dragging out, into things
OK, let's forget my BP for the cell phone button settings, how would you do the whole thing so that when the character dies, the whole thing doesn't bug out like it does for me
yeah, so, you are trying to fix something at a much higher level than what you should be trying to learn right now.
for one thing i would probably get the reference different, i'm guessing you want the character your playing ?
where you would get the player, cast to that bp
yes
are you using the third person template ?
Yes, that's BP_ThirdpersonCharacter. I made a variable for this that serves as a reference
As I said, it just doesn't work anymore after I die once and respawns very strangely otherwise the whole thing works perfectly
so everything else works like your character moves and stuff when you respawn ?
does the print string show up when you load the widget ?
or is it showing at all ?
it should show up, i'm just not sure when
puhhh okok
thank you very much, to you 2 I have tomorow unreal lessons anyway and there is a teacher there too, so we should be able to do that...
but thanks a lot engage god bless you!
Any idea to make this without a select node?
Oh yeah using an array, don't know why I didn't think of that, thank you very much engage!
Hey guys. Can objects on the scene mess up UI onClick detection? I have UI element with buttons that renders near my character, but when i try to click or hover over them, nothing happens. When I move them far to the side, they do work. I don't know if there's some hidden collision object that interfere with them, or there's something else causing this issue. I tried to look at the collision presets, but I'm not exacly sure what to look there for.
How would i blow back my character ? It's walking left/right sidescroller and when he takes a hit from this thing i want to blow him back a bit.
i tried add impulse but it didn't work the simulate physics is needed and that f's up the movement
i guess i could just manually move him over time, but i thought add impulse would work
Help. I can't find my "Char Object Ref" inside my character's details panel to set the reference. How do I cast?? (New to UE)
wdym in the details panel ? it should be on the left
your not getting any details of the variable ?
I followed this tutorial and at 3:35 he adds a reference to the variable, but it's not showing up on my character: https://www.youtube.com/watch?v=IyTxIsjf77k
Discord 🐺 https://discord.gg/K28cmFAM5F for devs to lounge & make friends.
Patreon 🐺 https://www.patreon.com/werewolven
did you click on the bp in the outliner ?
Yes
The full details panel is showing up, it's just missing the variable + I have the variable as public.
you have it expose on spawn ?
No, in game, you click a button and it spawns the character.
i'm saying the variable
is it instance editable ?
expose on spawn
when you click on the variable
oh, no I didn't have it on. What does that do?
yes
it should expose it
when you place it in the level
so that you can get that reference
i'm still learning so i could be wrong
Hmm
could only be when you spawn it, not place it in level
Ok, so, this is my widget blueprint, which when the button is clicked on my widget blueprint, it spawns the character, and...
The problem: It casts to the character BP to trigger the character event.
But casting doesn't seem to be working.
the cast is just failing ?
Yes
It isn't showing on the character's details.
you said that picture was your widget ?
Yes
so that variable char object ref is on the widget not the character
atleast that's what it looks like @pine mesa
Yes
it needs to be on the character?
what exactly are you trying to do ?
Click button in widget, trigger event in character.
Get the owning controller of the widget -> get controlled pawn -> cast to your character BP.
Edit: as an fyi, an object based variable such as a character is just a pointer to the object. As it's in the widget in the editor, it can't be set as the object doesn't exist yet. Doing the method I mentioned above should allow you to get the character at runtime.
Sorry, but what is the "owning controller of the widget?" I don't understand.
Right click in an empty space inside the widget event graph and search for 'Get Owning Player' it should get you the player controller that owns the widget.
Hi @dark drum, I just sent you a dm about your maze generation tutorial with a problem, could you take a look? or maybe you prefer talking about it here?
The cast failed. 
Damn you found me. 😛 jk, what's up? Just post it here, there are plenty of smart people here that might be able to help as well. 🙂
What is Godzilla selection menu? Is it a character?
Is it a character the player is controlling?
No
What is it then?
A character that's spawned, not controlled by the player, but just to be there as a model in the game visually.
@dark drum I've been lucky seeing you in this channel 🥹 My problem might be linked to my wall mesh because its spawns in very strange locations, i'm not familiar with mesh editing and pivot point and don't know if i've done something wrong in the blueprint or not...
How is it spawned?
It looks like the rotations are off by 90 (or -90 it's hard to tell) you could try adding it when setting the rotations or adjust the rotation in the mesh itself.
Is this the same widget that you calling the other button click event?
If that's, the case, pull from the return value on the spawn actor node and promote to a variable. You can then use this variable in the other place. You probably won't need to cast and should be able to call the functions directly.
Like this?
I got an error message:
Blueprint Runtime Error: "Accessed None trying to read property GodzillaInstance". Node: Roar Anim Graph: GodzillaClicked Function: Execute Ubergraph Selection UI Blueprint: SelectionUI
Show how you set the ref when you spawn the character.
@dark drum I've tryied multiple rotation combinations thinking it was the problem first but none is functionning. My understanding is that the walls rotate on one edge and if I spawn 4 of them I would get a cross and not a square. Do you remember if the wall mesh have a specificity on the pivot/rotating point?
Not off the top of my head but I believe I mentioned near the start of the video.
I take it you didn't read my reply where I told you to pull from the return value on the spawn actor node and promote to a variable.
Oh no, I did!
I renamed the variable to "GodzillaInstance."
Show how you set its value?
The variable doesn't have a value?
So you're not setting its value to the character you spawn using the spawn actor node like I advised?
No, I am. The value is set to the character.
Then show how you set the value. I want to see the set node.
@dark drum https://youtube.com/clip/UgkxtRHX4-WHLMmq_rus_mhyxbDrbJZTvAq6?si=i6qHwYa8u3T8GR4D You did! Hopefully we met, I was watching on repeat the tile presentation but not that part 😉 Whatever, I don't know how to manage this problem, do you know any way in UE or I need Blender course?
14 seconds · Clipped by Jiiru · Original video "UE4 | UE5 | Maze Generation Tutorial - Pt 2" by Michael Pattison
I think there's a way to modify the pivot point in UE but I'm not familiar with how. Alternatively, blender isn't a bad option a quick overview should be enough to modify the pivot of a mesh.
Is this what you mean?
Yea. Is it working now?
YES! THANK YOU!
How do you cancel/abort an event dispatcher
@dark drum I'll take a look for it thank you for your help, I'll keep you in touch
No problem. 🙂
Unbind the function.
Can i send a message to unbind a dispatcher
The actor that has the message will need to cancel it
The actor can unbind all functions on its event dispatchers so call when needed.
Got it thanks
I used unbind all events xyz
Why doesn't enhanced input y work? This is the code for my look input, but the y-axis does not turn at all, only the x-axis turns fine.
Remove the modifier.
I did, but it did not change anything
Have you printed the y value to see if it changes?
Yes, it does print
So it changes?
Yes
Then it's not an issue with the input action. It's doing what it should.
Depending on the character setup, it might only be set to use the controller yaw which is why pitch isn't doing anything.
How do I check?
On your camera/spring arm or movement component.
First person is normally yaw and the movement and pitch on the camera. Third person is normally both on the camera/spring arm.
Edit: the first and third person templates have it setup if you need an example.
I did the exact thing the first and third person template did and it is still not working
You can get the control rotation and print it to see the values change. This would confirm if you haven't got the relevant components set to use pitch.
how would i apply some sort of force to my player ? like bump it in a direction
this worked ty i don't know why it didn't work i tried it before i must have f'd up the numbers
yeah sometimes they need to be deceptively large
Hello guys I am new to unreal and blueprints but have done some coding and I am trying to have a wave of items spawn lets say after 20 seconds and keep looping this is how far I have got
a for loop must execute in a single frame.
You'd probably want to set up your spawning on a timer, with an initial start delay of 20 seconds
So right after the event begin play?
if that's when you want it to happen, then yes
ok
Guys, I have two widget in a single blueprint. For some reason, one of them blocks the mouse input of the other. I have no idea how to solve this. I tried too google it, tried to play with the behavior section, but nothing helps beside disabling the widget :(. Changing their order would be all i need, but i don't see any option for that :/
Ok I fixed thank you very much 🙂
Is there a way to see/visualize a collision box? I'm trying to set an actor's collision box component's box extent in-game and am having troubles telling if it's the correct size.
My player y-axis looking does not work. I checked the first person template as an example and have absolutely no idea what's wrong. I printed the y axis to see if it changes and it does, so I have absolutely no idea what to do now.
Hi I am having a weird problem where I have made a functional enemy but when placing another in the world or making a child causes this error
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
I need to be able to make child blueprints of this base enemy however this error is messing me up, the only thing I can notice is that the child blueprints for this enemy dont have the general movement tab for character movement. I am very confused as duplicating the enemy in the world space works just fine but making a new one or placing another causes this error?
Is this an efficent way to have an invisible barrier untill a player does an objective?
why are you looping from 0 to 0
yeah i just realised im dumb lol
you probably want tick
or a timer of some sort
I got it to work by using my brain But i get this error and it works
but it works for some reason?
that runs on when the thing loads, but that error probably means theres something wrong with your boolean
or what it's attached to
im just going to take your advice i dont want to have to find out later the hole game explodes. il put it on event tick
It means “has been interacted with” is null (hasn’t been set yet)
or a timer of some sort
but if you do it on tick you can get rid of it as soon as you flip the boolean @wanton prism
Oops im just lost now
il try that i think cause its all mess up now
what is this ?
i forgot to name them the same
its just checking the object i found out the problem it turns out for some reason if i dont put a delay until next tick it doesnt work But now the destroy cube works while the sound one doesnt?
Still get this erro
from this one
are you setting a variable on it, then destroying itself ?
looks like it
oh
the set looks like it's in the bp
how do i fix
why do you set has interacted and then destroy actor ?
for the key
i mean you destroy it
so you probably want to set haskey or something
this is a key for a door ?
well you put that on the player
and when you get the key
set it on the player
thats where your mixed up
your setting it on the key, so when you destroy it
that variables gone
you want the other actor, cast to your player, get has key
theres other ways to do it i used an array of strings for my keys in a project
the has key is on door bp
but how to link that to the player ?
so he knows he has the key
doesnt its an interaction system that handels it
so that key only works for that specific door ?
yes
nice
Are you able to help me with a physics problem? Im having a glitch where the player can fly while picking up and jumping ontop the the object. I attached a video with my problem?
Do i just line trace to check if the player is on top of the cube or do i need the system to check the player velocity? and if its too high stop interacting
maybe shut it off after you take it off or it hits the floor, idk much i'm still learning
i make it velocity based as there is a make velocity the player can move at
nope didnt work
Just disable the collision with the player when you grab the mesh
Ok i seem to have a problem with an objective system? is someone able to help? this code is calling my objective system but its not working?
That error says it all. Mission Widget is not set at the time you’re trying to access it
I don’t see you creating or setting that variable anywhere
mission widget sets it
Does anyone know how i can get the y value of my camera? this is my first time using unreal engine and the tutorial im following tells me to do that however they are on ue4 and im on 5. I tried researching online but i couldent find anything, if someone could please help it would be very cool.
if someone knows how to help plz @ me
You can right click on the yellow pin and there's an option to split the structure.
alr ty
How would I fix it?
Hi I am trying to fix a problem with my character movement, I am trying to make a child blueprint of an enemy that is already working but I have discovered the character movement component is not valid, but the base enemy works fine? I am very confused as I cannot figure out how to change the character movement component
Idk what you mean by that
Did you just create a variable of a widget class or are you actually creating that widget and promoting that to a variable somewhere
One of the class
Yeah you can’t do it that way
You need an instance
Not just an empty object
It's in the player character
So use CreateWidget, and promote the return value to a variable
Ok
Am I able to ask but does this code work?
Idk, it’s your code. Does it work?😀
hello, I have this to spawn bullets, but how do I change how fast the bullets move forward?
Hey, can anyone help me try to make harvestable nodes?
I roughly know about data assets/tables. But I don't know how to implement them. Or how to make foliage's interactable.
How do you reverse for loop and break?
what do you mean by reverse ?
loop that goes from 10 to 0
You jsut put the first index as 10 and the last index as 0
I mean there’s also a ReverseForLoop node iirc
there's only a "reverse foreach loop"
Ah right
That won’t just roll over to 0? Nice
Adjust the velocity and max speed in the projectile movement component
Simple question : How do people make their First Person Character have a hand shown on the screen for them to be able to use it. But when they switch their camera to third person or viewing that character from someone else's perspective shows something totaly different, like the full body for instance.
By that I'm referring for example to minecraft, where in FPS mode you see only 1 hand on your screen, but when you're in TPS or seen from someone else's perspective, they see the full body and the arm isn't placed in front of the player like on the FPS POV, as the arms are placed along the body.
I don't know how to do something like that, any guidance please ? 🙂
So I have an array of float values. I'm trying to find the lower value of X.
I think they might be using OwnerNoSee?
for example, 1, 5, 10, 15. If X = 8, I want 5.
huh ? But 8 isn't in the array tho 🤔
correct
So you want the first value below your X ?
Idk about interacting with foliage, but if you use actors, making them disappear after a certain amount of collection loops is not too complex
Can actors still be used in the foliage tab?
Idk much about foliage sorry
- Order your array.
- Go through your array from 0 to the array length (so not in reverse).
- And you check on each iteration if the current number at the current index is smaller than X, if yes, you save it in a variable (for instance do that in a function to save it in a local variable) and you keep going through the loop until the number at the current index isn't smaller than X, then you break from the loop.
Array sorting is much easier in cpp
Also what about if you have 8 in your array (in other terms, what if you have a value being equal to your X) do you return that value or still the value below it ?
How do you order array?
I see a reverse function
Wait what ? How is that possible that there's no "sort"' method for arrays in BP ? Is that because in this case it's a float ?
Or just one of the things they didn’t bother exposing
That's stupid ...
Yeah. In cpp, they literally have a TArray:Sort
I guess you have to write the sorting algorithm yourself (or check tutorials to do that)
That's it ?
That’s what I’ve seen so far, but assuming this is #multiplayer they might also be using different replication tricks
Yeah
I'm gonna ask in #multiplayer to see if they have the same answer, thank you 🙏 🙂
Can i set a pointer to null by doing this?
yes
Hello!
I've changed a struct and now everytime I restart the engine it requires me to redo some nodes like in the screenshot.
I can just remove and add them again, but it's annoying. Is there a good way to fix this?
Where is this "Only exactly matching " criteria coming from?
Simple question : the zooming mechanic in games, is it done just by changing the FOV of the player or there's another way to do that ?
I feed a data table row to the struct variable on the widget, everything worked fine until I've changed a variable in the struct. After googling a while, this seems to be a common problem with changing structs later on, but not sure if there's a fix for it
Can you hover over these two and see what they say?
Interesting. The out row says "s_available_characters", which is correct. the Input says "Fallback structure struct"
I went into the widget and re-set the structure variable, that seemed to fix it!
thank you for pointing me in the right direction @distant hollow 🙂
Is there a way of binding multiple hit events for componants in a ForEach loop? I need to generate hit events for multiple componants at runtime as they are all dynamically created componants but this method is only able to create one event as far as I can tell?
hello i need help with my impact point when ever i dont hit anything with my linetrace it spawns the impact effect on random place and plays the sound too but i only want it to play them when the line trace is hitting something
I can't see why this wouldn't work as you're binding a function to the 'OnComponentHit' on different instances.
Changing FOV tends to be the main method but depending on the type of game, you can just move the camera closer or further away. (Change the spring arm length)
I want to make it so this doesnt play when the character is falling
only thing that comes to mind is (is falling) -> not boolean -> result but that doesnt work
also this is the walk run animation
hey guys, quick question on scene capturing and texture streaming. It appears that my items that i wanna capture for inventory icons are very often blurry ingame. Online i found the information to turn on bForceMipStreaming on the item mesh components so they don't appear blurry. I'v done that and it works, my question is now does that come with any performance drawback that i would have to worry about? There are about 500 meshes at the same time on the map, all with this option enabled.
ok wtf is happening my character doesnt move any more and if i spawn mid air i cant still move and i just stay mid air
Hi, I've been looking at how to implement an upgrade system for my game where every time you level up you get to pick from 3 different upgrades and apply 1 to the character. I was wondering what the best/easiest way to implement this would be. I would like each upgrade to have its own logic as the upgrades won't be as simple as just a stat change.
this should work but you have to make sure you set the variable to the player isFalling in the event graph as well otherwise it won't do anything
anyone know why this ability is either not dealing damage (even when hit is triggered) or dealing damage multiple times?
my joystick is not visible in any game or in any project i clicked on show touch interface nut still not working lz help
Does anyone use this instead of AI Move To?
Ai move to is really bad for performance
dropping to 50 fps with AI Move To with just like a 100 pawns with just planes, its not a joke
So getting just the path, and then vinterping the units in C++ is way better
Anyone know of this? Or other alternatives?
CMC is not very performant when there are so many of them
especially all the "accurate" movement default setting is on
depending on your game, you may not need the full feature of CMC? if so you could just do constant interp yourself
okay but its just 100 pawns with planes and sphere collision
in my case it seems i can get away with these checkpoints
though it seems weird to make games and being limited to 100 pawns
but if its an fps then maybe its okay
How can we change widget render opacity inside the widget ?
Im changing render opacity of a widget from a actor. But i want to reset the opacity when mouse hover inside the widget.
that doesnt work because the output of not boolean is a boolean and result doesnt take boolean
you can add it is a condition going into that state
i will try that thank you
how do I make this automatically spawn projectiles, instead of me pressing a button?
event tick was too fast, how do I delay it?
i was gonna say event tick lol
you could use a timer or a delay
do event tick and then add a delay node
use a timer...
it wants me to plug something into the event, or is this wrong timer?
put the spawn actor into a separate custom event and plug the red node of that into the event of the timer
and tick looping
how can I limit this so that my dummy will only receive damage once (instead of multiple times (if more than one spheretrace hits it))
try the do once node
Custom event
Then spawn projectile from it
there's no red node here? I made a new function on that sidebar
Not after set timer
when i tried that, damage didnt work at all...i wouldn't want to use it anyways though, because i could deal damage to 2 different enemies in 1 hit (for context, this function is running multiple times throughout an attack animation
like this
How would I prevent two objects being picked up at once
you could have a bool like hasItem and make it so you can only pick it up if it's false
Where would I put that boolean? On player controller?
it fires once, but doesn't loop eventho I tick the loop on?
Another question, how can I handle the switch in control schema, for example, when the player is walking around in First Person, but then a different set of controls when interacting with the objects
is anything blocking the spawn pos?
what version of ue are you using? You could try input actions and mappings if you are on a late enough version
