#blueprint
402296 messages ยท Page 919 of 403
trying to make an array that contains 3 blueprints that inherit from LyraTaggedActor, I set the variable type like this:
I can't add any default values?
it depends on what you're doing and how you've set things up, it's too broad a question
No. The event you have up therre has Tile in it. You can get Tile, and get Attached Actors, or Attached Components, and iterate over them.
okay sorry
SetViewTargetWithBlend in Player Controller on the actor after spawning it.
it's okay dude, you just gotta figure out more specifically.. are you starting with a template or something?
nope all from scratch
But how do I reach the children from the parent Tile? I think this is where Im getting confused
maybe check out Lyra as a starter guide.. or grab some demo and look at how they do it
Or just call SetViewTargetWithBlend after spawning it.
cool thanks for your help everyone!
It worked thanks guys!
There is GetPointDistanceToSegment. Is there equivalent of it for surface, like rectangle? I cant find it, but maybe because I cannot guess its name.
like why can I add elements but then not set them to anything but None
how do I choose randomly between N classes, or make an array of N classes?
Fairly sure you can do this.
Will try it thanks alot
Guys
I made a tutorial
That covers the setup of the reload system used in Insurgency Sandstorm (because there wasn't any and it felt a bit complicated to me but it's all math)
It uses 3 magazines only (because I have a use for just 3) but you can improve the code for more magazines.
#UE5 #unrealengine5 #ue5devlog #unrealenginedevlog #gamedev #tutorial
Hey ! I am a solo developer making a game, hence making Wolf Wire Studios as a one man game developing studio. Trying my best to make a quality game
This tutorial will guide you on how to setup reload system similar to that of Insurgency Sandstorm.
Timestamps -
0:00 - Intr...
how difficult are climbing systems (like assassins creed but simpler) to make
im just trying to work out while im taking a mini break from coding AI what i can use to make getting round a level fun
How can I expose this parameter in Groom actor to animate it in sequencer or how do I change it from blueprint?
@hollow inlet i have to imagine your using a actor object reference and that is a world reference you would need to expose your variable(set instance editable) and set them in world as its not a class ref or something else but the object itself so you cant set it in the BP where nothing exists it needs the instances you placed in the world. now if your trying to set it to something not in the world which i doubt you can use soft references or another variable type
Can anyone help me figure out how to get the number of clients?
What do you guys think is a good way to implement a 3d platformer character 'skid' (like in 3d mario games, when you're running in a direction and suddenly change to the opposite direction, mario skids a little bit before actually changing direction)?
Make a function. Get GameState's PlayerArray. Iterate over them and check IsABot != True, if true, add to local array of playerstates, return local array at end of loop. Then you can get the Num of that return. Then you can also use that function elsewhere like player UI
O.o That's simple.
I didn't say it was hard
I said it was convoluted
Also GameState's player array? I don't see it
Also that doesn't work, still says there's 1 player
Even though I fire 3 clients
What says 1 player?
How do I get degrees out of a Rotator?
Get Num of Players, as well as getting the player array from GameStateBase
I'm firing up 3 clients with one as listen server, not counting the server it should say 2 players right?
break rotator?
@trim matrix
@sweet reef I used FindLookAtRotation() but that gives me a rotation not an angle between the two points
Was wondering if I could get the angle out of the Rotator
If you're firing them on beginplay or a certain actor, the player attay may not have rully replicated yet.
Just to test, try printing something on tick
Which actor's beginplay is this?
You are right @mental trellis it updates on tick
GameMode @maiden wadi
That begs the question, is there a way to know when everything is fully loaded?
Like a specific event
A rotator is a Vector composed of the rotation angles of each axis, in degrees.
Do you want the angle between your initial vector and the x vector of the LookAtRotation?
Depends on the necessity. Beginplay doesn't run until GameState exists. So you can safely assume Gameplay is available on any client at Beginplay. This is why you should use it as a place to put important bindings that can be called when things are replicated over that are needed. There is no way to know when everything in your personal project is replicated and available, because Epic can't account for that. To do that, you would require your own system where important things register until all are available and then run a project made event of your own.
Yeah I just want the angle
Most times it's enough just to have bindings and the necessary things to update when their relevant things arrive and call their delegates in GameState or gamestate components.
But what angle?
The angle between the two vectors
Is there a built in function to find the angle between 2 points (2D and 3D) for HUD and World? I love SOH CAH TOA, but l love clean code/blueprints more
if that is an array of actor references, you cannot set them because the engine does not know which assets exist to set a default value
is there a way to add a bunch of options to a SELECT node at once? (i want to add a bunch of materials)
You could create an array of your materials and just get the value at a given index
I made a level blueprint variable but I have no idea how to set it in the editor.
how can i specify which materials go into the array?
Add it as a variable in whatever you're doing or use make array
hey guys! thank you so much for the help the other day, my project is looking really good
i have a question about UI
How did you make the variable?
I have my coins, lives and score up on the screen but i was wondering how i can display that same information to other screens like game over and pause. i have a set up for showing it on my HUD but i don't know if i have to do the same thing for every single UI with my coins and score displayed
@mental trellis thanks but this still requires me to manually specify which materials go into the array; is there a way to drag a bunch of materials from content browser into an array directly
this is the HUD blueprint i have
With the make array node you can sort of do that?
How do you specify which materials you're selecting from without specifying the materials in some way?
looking good for a first game
Hey guys. How are you all doing? Can someone help me? Just for context, I am new to Unreal and have a little experience in Unity. So, I have two Actors each with your own Blueprint and functionalities. In this case, I have created a Wall with a hidden Door (one actor), and a Trigger (another actor). Once the Trigger Actor is triggered, it opens the Door. So, my question is: is there a way to make a Actor with two separated blueprint, so I can have one Actor in the scene? In Unity, for example, we have a Prefab for that. Is that possible in Unreal?
Heyo, everyone ๐ guys is there any chance to use a free camera while sequence playing? which is focused at character and you can just move around and take a look
@mental trellis i was hoping i can highlight/drag over all materials in the content browser, and move that into a blueprint
I don't think the editor is that nice to you.
In the level blueprint, just defined a new actor
Am i doing this right? im trying to make the actor who has this component follow the path in the array
What's the best parent class to use for a logical blueprint? (it won't exist in world space, but will be instanced in logic systems)
Object i thik
Then you set it in the level blueprint. The level blueprint is kinda insular. You're not really meant to access it from outside?
thanks, thought so too
is this logic right for moving the ai to the next path point
if you wanna see the helper functions just let me know
I tried that, but when Iselect from the drop down or eyedropper it, it just stays Empty :/
@slim fern how did you add extra dots along the way in wires?
double click where you want it
@slim fern thanks!
hey guys, a noob question. I am trying to save an array of integers by using the node ADD. On the first attempt all good. when I load and add a new element to the array it always give me just the last one. What am I doing wrong? Thanks
guess whos back
Don't worry this one will hopefully be simple
So, I kind of just wanna make it so that the game pauses whenever I open my inventory menu
I thought maybe I could just do it by setting game to paused, and then set it to unpaused when leaving the screen
But when it pauses
There is no unpausing it
Wait, is there no accessible constructor for UObject blueprints?
Your unpausing actor might not have tick even when paused
Essentially what im doing is using a flip flop node that switches between the inventory, and the actual gameplay
Here, I'll take a screenshot and show you
I have a hunch the flip flop node is in an actor that doesn't tick when paused.
I have no idea how to make it tick
Player Menu is the inventory, and main hud is the, well, main gameplay hud
Input action is the Tab Key if that is also relevant
how do you change the ui style to that flat style?
Uhhhh it's a plugin
If you have about $9 USD to spare I can give you a link to it
Because the UI isnt free :')
ok, I'm good then ๐
Is the input action set to ExecuteWhenPaused ?
N o p e
if you click on the input action node, in the details panel, you can change it
That would probably be a good idea to change wouldnt it

I am not sure the issue. "when I load and add a new element to the array it always give me just the last one". The ADD nodes creates a new entry for the array and places it at the end of the array. This sounds like expected behavior so I am not sure to problem, can you elaborate?
sure
I have 8 sphere, each of them have an ID.
Every time I do an action I need to 'Add this sphere ID to the array and save it'. This way, when I load the game it will load only the list that I saved
If you means some sort of ConstructionScript function like an actor has, no there is none.
sounds super easy and I'm sure I did this thousands of times, for some reason I am getting always and only the last ID that I add
- What does your "get" look like?
- What are you expecting to get?
Also 3 might as well show us the Add call too
So... you're searching the array for the ID you expect?
So you have an array of Sphere IDs. You want to look at each element in that array, find the matching sphere, and show that sphere?
looks like it's working with contains
Thank you lmao, this immediately fixed it completely
I think you were trying to do a contains but what you actually did would call BOTH sides of the branch, and call the "false" many times
how the contains work? is it looping all the elements?
Presumably. And then return true if it finds the thing or return false if it reaches the end of the array
can you help me understand why they omitted that?
mmm still not working properly tho
I have 8 sockets, and every time I add a new sphere I want to set that ID and save it. In this way when I load the level he will show me only the sphere I snapped making the mesh visible
very simple ๐
Unreal has weirdly restrictive opinions about what "Objects" are or arent. It uses them more strictly as abstract or data carrier classes, than other languages.
Just get comfortable using Actor for things that don't get instantiated. Like I'm pretty sure GameMode and PlayerController subclass Actor.
Fun question: I accidentally clicked on a C++ class. When will it stop trying to open an IDE I don't have installed? This has been going on for a few minutes now
Is there anything I should be aware of before I start using Actor for most things? I'm not new to programming but I am new to unreal, so I just want to make sure there isn't some fringe cases I need to be aware of before I spam Actors HAHA
I'm using them mostly for logic too btw
Just make sure to disable actor tick.
^
Ok, well maybe I'll tackle this from another angle. Let's say I have a bunch of static cameras on a level that are cycled through (Like an adventure game). What would be the best way to set the default starting one? Obviously a save/load would override this.
easy as, thanks teamers 
Actors are for encompassing components, or for networking. Components for anything else.
^
Didn't they fix the tick thing so that if you don't have any logic running on tick then it won't tick
You can use objects to handle game logic though to in some cases. Dont be scared to try.
Just have to be aware of the limitations
I hope so.
Pretty sure they did back in like 4.21
I made a prototype of a tool for Data visualization. https://youtu.be/lTS4jGMuCm0
If you need more help join me on discord: https://discord.gg/DgUTZwm
Support me on Patreon to get nice assets and tools: https://www.patreon.com/bartkamski
Check my UE4 marketplace assets: https://unrealengine.com/marketplace/en-US/profile/Bartosz+Kamol+Kaminski
any reason the line trace by channel blueprint no longer detects hits on this?
it was detecting hits when i put the camera in 3rd person but doesnt in first
weird
can anyone hint me to tutorials where I can learn about how to make building system that will work something like this? floor by floor based with grid
You can look into making runtime map editor.
thanks! but looks like there are only plugins tutorials and not how to make it from zero..
I used to make some stuff for couple years and know a lot in ue, just don't want to make it from zero by myself cause obviously there are better solutions I'd check first
You just said you could only find plugins and tutorials and now how to make it from zero
And now you don't wnat to make it from zero
Well, the basics are runtime map editor
At the very least runtime map editor is a lead for you to break down
I meant tutorials for that plugins not tutorials for making that "runtime map editor"
It might help if you're able to break it down to simpler mechanics. Search for the building blocks, not the step by step
yeah I understand. since there are no such tutorials in youtube for ur I think to peep about things from tuts for unity ๐
yeah and that's what I need
Hey everyone, is anyone willing to hop on a call and help with a loot system I am developing using blueprints?
There probably won't be any tutorials on that. It'll all depend on your games context. Just start simple. Start by thinking about what the save game for your level looks like, and how to modify it. Then make the tools in engine and build it up.
Start with placing cubes on a grid and being able to save and load it.
Once you're comfortable enough with the engine to pull something like this off, the path forward will be pretty obvious.
For example, my project has a vehicle builder on a grid. My PlayerController has a build mode and my vehicle pawn has functions for building from a struct and saving to a struct.
Hey is there any way to add new keywords to existing nodes, like if I searched 'Wait', it could bring up 'Delay'?
For nodes you make yourself yeah, there's a keyword field. Dunno about engine provided ones without modifying source
dang, that looks fun. are you planning to release it some day, or is it just hobby?
Hello - gonna ask a really dumb question (i'm a sound designer looking for a project to practise on, for context) but on the Unreal Marketplace, there's this Low Poly level which says "install to engine" so I install it to my 4.27 UE but I can't find it anywhere. Any ideas at all where I might find it now that it claims that it's installed to the engine? this is the level https://www.unrealengine.com/marketplace/en-US/product/low-poly-shooter-pack-free-sample
@kindred remnant I have limited experience with marketplace assets. In the Epic launcher โ UE Library section, is there an "add to project" button? Or what if you look up that asset in the store?
Normally there is! for this project for some reason, it just says "install to engine" in lieu of "Add To Project" like the others for some reason! https://gyazo.com/635e3399b9c6c66ac31e42703742750a
It could be code plugin instead of a complete project.
Yeah that seems likely
The limitation with marketplace is that anything but Code Plugin can't contain C++ code
That project might use C++ code, so it's packed as plugin.
Ohhhhhh I get you! Yeah i've just checked on the devs website and there's an external project template on there so I can only assume that they've just split it up for some reason
You might also want to try enable the plugin and look for the content files in Content Browser (make sure you have plugin content visible)
Probably contains C++ code, again, anything but Code Plugin can't contain C++ code whatsoever
projects can contain c++
Proof.
city sample / lyra
Oh, UE5 thaengs
so that is a new feature?!
i don't see why projects shouldn't be able to ship c++ code on ue4
anyone know how to reference a camera actor to a widget blueprint?
Hey guys, coming from C++ to BP, how do RPC work here? Do I gotta make a dedicated function to set variables on the server as client or do BP's variable setters allow you to do it by ticking a box somewhere?
They work pretty much the same way, except the BP does all the under the hood stuff for you.
You just make an event, tick "run on server" and off you go.
Something like that.
You can just set repnotifies for variables too iirc
(but they don't work client->server)
oh sweet, thank you very much
I am trying to have a button in my pause menu essentially relaunch the current level but as a listen server... This node setup doesn't work unfortunately. Is there something I'm doing wrong?
Release eventually, gotta find the game in it first though, and turns out networked physics is hard?
Hi! does anyone have the diagram with the live of the diferent default BPs?
I need help figuring out how to get my ai to switch the bool to false when the player is out of sight. I don't see a end see pawn node or something like that I could use.
Can't remember if there is supposed to be a ? in front of Listen or not. How are you testing this though?
Hmmm okay, so, I made a model that's just a simple apple, and I want to make it so that this is a material the player can pick up and store. Any ideas?
Only for the actual collection of the apple itself, the inventory part I can work out
What I kind of want to do is have a box trace that surrounds the player out to say, maybe a meter, and anything that can be interacted with that comes within that range, can be interacted with/picked up
how do i posess multiple charachters at the exact same time?
Nvm I got it
Can blueprints read json or only on cpp?
If I retrain as a video game programmer here at age 50 realistically what are my particiipation changes in industry?
By faking it.
lots and lots of json parsing blueprints on the marketplace
VaRest is an example
So I have a dict mapping an integer to a string. Here are 2 examples. (pic 1)
And here's how I get them in code (pic 2)
Top one works a-ok but the bottom one is outputting "None"
Any help?
(finding "5" and below works fine, finding "6" and above doesn't)
Okay maybe a development? But I tried to change the value of the working one "5" and it's changed but not actually reflecting the change, so the value output is still "test" not "new value"
Is there a way to define the "static mesh component" from a variable instead? I can only change it from the details menu of the node.
does anyone know how to have this style of linear nodes in BPs? it looks cleaner https://pbs.twimg.com/media/FUWCUn7UYAASxdn?format=jpg&name=4096x4096
its a plugin
electric nodes?
Thanks, I wish it was supported in the engine directly
Use the function called SetStaticMesh?
That did it. Thanks man
I would assume that NPCStorylineSubtitles does not have the correct values at the time the Find node runs.
Unfortunately it's not free
Pretty sure you can play with line interpolation settings in editor preferences
when i set Time to 10 then with Start Variance how much it would be?
how variance works
+/- a random value between 0 and your variance to the start delay value
Tbh I'm very reluctant to spend money on things that are just in the editor and not something that can end up in runtime/shipping build
so if Timer == 4 Start Delay == 10 Variance = 5 then start will be between 9-19?
Yeah
They're set with the "default values" so they should be there instantly?
Okay sooooo
Im using a box trace which surrounds the player to check to interactable items around the player
The problem being that it doesn't want to detect any actors
Well, human actors
A sphere trace does, but a box trace isnt.
Actually I have an idea
So, what this code should do is enable the input for a door that was blocked with a padlock, the padlock is a different BP, when you break it you can open the door, the problem is that i dont know how to call the padlock bp to the door bp to confirm that you can open it
This is the code i have but it donest work
Personally I wouldn't separate the lock from the door.
However you could set the reference to the lock manually on the door instances in the level.
Just make a variable and mark it instance editable
Okay so im actually worried that my dialogue system WILL cause issues down the line so im just gonna scrap it now rather than later
Now that i think about it maybe i should just put it all in the same BP
But ill try to just make a reference
I think ue5 has a system for setting up dialog. Can't remember the name tho
So, i put the variable reference but it doesn't work
Is this how it should be done?
Can anyone give me any information as to how to get this CSV imported?
ive created a struct and I just get various errors
= (
what isnt working
@severe tendon did you actually assign the variable on the door in the level?
Or just make a blank variable
Blank
Check the instance editable option on the variable
And then in the level, select the door and assign the variable to the lock you want
Anyone got ideas why A*-1 gives error in math expression?
This happens
Any other ideas...?
Any idea why?
Could be that A is zero?
whats the error?
Well, what else do you need to know?
Don't really understand it tbh
its prohibited
but why
unary operators are prohibited
do a one minus or something
There is a dedicated negate float function btw
Hey bumping ๐ฆ
I really cannot understand the fault and the documentation isnt great
replace the get candado with a validated get
you're trying to access it after youve already deleted it
So should I be using UE's built-in damage functions or should I just roll my own interface?
You can use the former as the built in one also have networking stuff ready to go, but you can do the latter if you want to
you can do A * (0-1)
that might work yea
@elfin wolf Now when i destroy the padlock it doesn't get past the get
Should be something like thsi i belive?
can you send the padlock code?
Sure
Fair enough, I guess the only reason why I might want to roll my own is if I need to extend it in terms of functionality
This
How are you supposed to check an object you deleted?
You can't destroy it and then access it
Why not just check existence? If the lock doesn't exist, then it's likely not locked.
Does anyone know if there are any actual performance differences between spawning a BP with various begin/end overlap logic and creating a child class of that BP and spawning that one instead, since it's all inherited wouldn't the performance hit be the same?
Identical performance. There will be a very minor memory overhead for the second class, but it'll be so insignificant that you will literally never run into a case where it'll harm you.
Perfect thank you for confirming
i have the problem that unreal keeps placing some of my actors at 0,0,0 rather than to their supposed location where i placed them
that issue kind of started with UE5, anyone had this, too?
Can any of the spawn code return zerovector as a location?
there's no spawn code, they are placed in the level
i guess it has something to do with some of their components mobility
Odd. O.o
on a side note, they are initially loaded at the correct location when i open the map, once i hit begin play they teleport to 0,0,0 and stay there when i stop the PIE
guess i'll have to run in debug, to see what happens
Hey, everybody, very new to blueprints and Iยดm struggling to make a seemingly easy thing work...
Lets say I have a blueprint with several static meshes in a construction script.
And I wanna have a few checkboxes to set their visibility.
But I ONLY want to have ONE of them visible at all times.
Is it possible to set up a flow that has some booleans and they all trun each other on or off or something?
SO, if I set Object A to "visible", it would make Objects B-D invisible, if I set Object B to "visible", it would set all others to "invisible" etc.
run a for each loop iterating over all of them, provide the index where the flag should be true, and compare the loop index with your index, and use the result for the bool
that's not exactly what i meant...
the approach with having several bools where only one should be true, is also kind of weird
you may want some other way to select which mesh should be visible
Personally I'd rather use int directly and just do for (each) loop to set which mesh in the array is visible
e.g. an enum, or a static mesh variable with the actual mesh that should be visible
so you can compare against each component if it is the mesh that should be visible
Agin, complete noob here.
Assuming only one can be visible at given time, I feel like For (Each) Loop is more sensible approach
I can kinda dissect an existing flow, but I have no idea how to create anything in any logic...:)
I have about an hour to figure it out and then I just have to live with what I got.
I think to do this in BP, you need an index of an array and an array of bools. May work. More realistically this is much easier done in C++ with PostEdit functions.
Yeah, realistically I have about an hour to figure it out, I think I canยดt learn C++ in an hour...:)
The whole setup is a complete hack anyways, I hate that I just canยดt find the time to learn any programming properly.
Already paid someone 250 bucks to basically add two nodes to my blueprint.
And I still had to figure out to have it work teh way I wanted.
Pretty simple I think
This should be executed once you make the mesh components from the static mesh reference array
then you probably shouldn't do it in the first place?!
how do I get the "Mesh components" node?
Well. Everytime I am at this point, I already spent dozens of hours doing it "hacky" or "manually", because I didnยดt realize I would have to do the same hacks or manual labor another 20 times...:)
That's a variable you make to store the references to the mesh components that you generate from the static mesh asset reference
What kind of variable?
An Array of Static Mesh Component Object Reference
You already have this kind of setup, right?
The part that I'm not highlighted is the component creation part, followed by adding that newly created component to the array
Though I think the array has to be cleared first ๐ค
No, its completely different set up here:
They are just added on the left side in the components list.
Ah, so not generated by code.
No.
Its an existing marketplace asset and I just added some more components and the visibility switches.
So you want a bool for each static mesh?
Yeah, but only ONE can be active at any time.
So if I switch one one, the others need to be switched off.
Its a bit more complicated than that with some material changes as well and in the end I need to move it to the event graph, so I can call it from the sequencer.
Okay the setup should be this first
Then on loop completed, do the int switching thing
Couldn't you directly on that loop just check for the bool and set visibility?
Ofc if not needed at runtime
It might not be optimal, but in construction script it's not like it's executed every frame on runtime.
Or int yeh
Yeah, like I said, in the end it needs to go into event graph, so it can be called via a custom event in sequencer.
I got that working, but basically for each switch right now I have a custom event chain with 10 booleans to switch on/off.
Its doable, I was just hoping I could simplify it somehow.
If you do a branch chain, most of the times there is totally a better way
This would be the setup after the first loop
Considering you said only one can be active at any time, int comparing would be more sensible
Hi, How can I set "isAttacking" variable when attack animation end? is there any node for checking the animation status?
Use anim notifies.
Thanks
Ok, this looks like something I could figure out now, but Iยดm still stuck at this part, lol.
And I donยดt know where a/b/c should then go.
This would be the full picture.
I'm not entirely sure if AddUnique considers reference to premade components the same. Debug the array, if it explodes when moving the actor around, add the Clear node back.
Also you can replace the int with an enum
I was assuming you have the mesh generated
Connect it to the Array input first before doing anything with the array element
Ah, ok.
Can I then also use the "children" node for the "mesh components" node below?
Actually yeah, I think you can skip the first loop
Okay, simplified #3
If the child components are all static mesh component and no other type of components, you can also skip the cast node. I just put it there because I don't know the component hierarchy
Simplified further and this is how it looks, assuming it's all static mesh components
Hm its not doing anything...
I just dragged of the pin from the equal node to an integer and named it "Visible Mesh Index""....Is there anythin else I need to do with it?
Hi! does anyone know where yo save user preferences between games? (i'm not sure that user settings is the best option for this, since i want to save things like "selected character")
Depends. You can pass information between level loads. Or write it to disk in a savegame and reload it in the new level.
Personally. I have a few different savegame objects that are mostly owned by GameInstance, they live there as instantiated objects that I can write and pull data from, and write to disk at any time with a simple call.
I tought of this also, but maybe there was a better option.
The idea of rewriting a save game to disk whenever i change something so trivial like "selected character in main screen" sounds bad. But what ever, i'm gonna have to do that.
You don't have to write it to disk. You don't even need a SaveGame object. The idea was more to have an object that can hold state, that exists between map loads. I use SaveGameObjects because they're basically UObjects with the ability to write to disk when I finally want to, which I rarely do without the user requesting it or auto save stuff. Beyond that it's just a place where I store data that anything can read from by accessing GameInstance and then the save objects.
I'm thinking of doing custom Getter/Setter for each variable on the SaveGame for the user settings.
When doing a get, if the SaveGame is not cached already, you cache it and read.
When doing a set, you take the current SaveCached and write directly into the Disk.
Is your approach different and more efficient?
You can do pretty much the same thing by having only Objects owned by GameInstance if you don't need any data to persist application loads.
This should be for things like "when you load your game, the selected character was slot number 3, so that one get outlined"
I want those things to persist across game sessions
for persisting variables across levels i'm using Game instance and that works fine
That would just be your game setting itself up from Beginplay from the data in those objects. If data isn't set, use defaults.
It more or less is just using game instance. I just like to hide away state in compartmentalized areas. I don't like muddying main classes too much if I can avoid it. It starts with a few variables. Then a few more. And after a while you end up with a ton of stuff.
yap, makes sense. Thanks!
guys, is Sphere Bound are the same as Strict Bounding Box?
No.
Sphere Bounds are less accurate bounding area than Bounding Boxes.
Unless your actor is spherical lol
*perfectly spherical
wow
ok great to know!!
and which node represent the blue box?
bounds?
also do you know how to move the pivot of an actor to its lowest Bbbox face?
Like I need to have it actually do it however because the player will be able to use a motorcycle for example, but STILL staying active so they can receive damage n stuff
You don't have to possess something for it to receive damage or perform other logic
Hello Guys, ive already asked in general and in editor scripting, but nobody seems able to help me (or maybe they dont see my question)
can i SPAM a problem i have also here? is related to blueprints and movie render queue pipeline
When I spawn an actor, "Ai move to" node does not work and the actor does not follow the main character. How can I solve this?
Hello i want to call a function when all the array elements come out to be true. How do i go about doing this?
If you built a function, it'd be a good use for a local variable. In any case, you need a new boolean variable. Set it to true before the loop begins. If an array element is false, set your boolean variable to false. (If the array element is true, leave your boolean variable alone.)
On completed, check your boolean variable
How can i get the UnrealEditorSubsystem?
I think that node might only work in editor utility blueprints
BP_Foobar has natively added scene component(s), but none of them were set as the actor's RootComponent - picking one arbitrarily
I am in an editor utility actor
did anyone have this problem before?
the blueprint in question has a scene component as "root"
and idk how it would get messed up ๐ญ
C++ base?
nope
but i'm considering making one where i try to force the root component
i feel like... it's some issue with component mobility, where it for some reason resets something to mobile, and detachs all static childs, which then are all at the root
which should be impossible tho
i have a wild guess...
i replaced the actors DefaultSceneRoot with an empty scene to get rid of the default icon...
How come stuff works on youtube tutorials but not on my computer? Specifically a flying A.I. that patrols, attacks the player if it sees them, spins around if it doesnt then returns to patrolling. In the tutorial they used an enum for floating pawn movement states. But the aggro and attack player didnt work it just froze at line trace hit spun around if you walked away then returned to patrolling between placed actors. I ended up using a completely different blueprint set up from another video to get the attack part right but now it chases you through the floor. Only returning to the air to patrol again.
there can be lot's of reasons for that
most likely one of you didn't use a default project, and some custom stuff within the project
so you didn't replicate 1:1
Make sure you understand exactly what you're doing and why, and not just blindly following along
Is there anyone that may be interested in helping me make an inventory system like the one found in fallout 4?
I get the just of it just not the syntax or name of every node
how should I make the player unable to fire his weapon when sprinting? My best guess is to check IsSprinting or something every time when the fire button is pressed, but maybe there's a better way to do it?
That sounds like the best way to do it.
Having a problem here that the character is still rotating/turning even when his movement mode is set to "none"
these are just basic ai roaming agents with a nav mesh
Show code for movement node.
npc bp
from player bp
^
In that picture, you are setting the NPCs, movement mode to none.
Not the players
yes
it was never for the player
they still turn though like in the video
So they player is allowed to move/turn? The issue is that the NPC still moves?
yes and yes
they dont really move but they turn
like in the vid
The NPC is still running its AI moverlo script most likely
It is trying to move, but it canโt
So it just turns towards the movement point instead.
Never actually moves there.
yeah but look at the picture If DontMove is set to false then it runs the rest of the script
when i talk to them their dontmove is set to true
so it shouldnt be running
Yes but look at the delay
You mean the one after the branch?
If the delay has already started, this whole donโt move variable does nothing
Move the donโt move check after the delay.
Okay great it works fine now, Thank you!
Is It possible to use "Move Component To" node without the rotation being affected?
how do I clear the actor reference? Do I have to create an empty variable then set the reference as it?
Anyone here familiar with Combat Components? I'm trying to activate the collision event inside a Weapon Bp that is attached to my weapon actor. Normally it is setup in the player character on an actor component.
@trim matrix you are giving a different 'delay - > move' command each tick, rather than waiting for moves to finish before issuing new commands.
yeah
Has someone a better solution for a hitsystem? sometimes it hits twice although i have a "doonce"
Can a sphere trace only see different objects in it's radius or can I use a sphere trace to get the data of a polygon in a mesh?
For instance, in my case I want to get the normals of all polygons range of a sphere trace. Can I accomplish this or will I need to consider another approach?
If I cannot, what route might I consider looking into in order to accomplish something along these lines
Is CombatComponets a plug-in or something of the sort?
Yes it handles collision from sockets on a Mesh. Similar to AGR Combat Manager Component and the likes.
I am not sure then
yeah but, if i do a do once without a reset it will never fire again
is it possible to save level data when level streaming? Like corpses and thrown around physics item to remain there when exiting in and out of the level through level streaming
Like in the elder scrolls games that stuff remains even when you exit the cell/loaded area
hows it done/whats that called so i can look it up
how do I make child blueprints inherit variables?
thank you for your help, i will look into the montages ๐
I have a general blueprint for objects that you can pick up and child blueprints that are specific objects, I need the child blueprints to have the variables but be able to set different values in them for different objects
Quick ?: In a For Each Loop, does the "Array Index" Output start at 1, or 0? I've been getting a few errors where code is reportedly trying to access Index 3 in an Array of Length 3
0
that's what I thought. WOnder why it's looking for index 3 then
It says the Branch Node was looking for the 3 index
What your describing is exactly how child blueprints work.
that was the idea, but I don't get the variables in child blueprints that I have in the parent
They are there, they just are not shown in the variables menu by default.
Right click anywhere and type Set VariableName
It will come up
I see, thanks
If you click the display options at the top of the panel the variables list is at, there will be an option to show inherited variables.
How can I attach a cable component end to another actor?
I think I'll need to try changing some of my for loops to For Eaches. Seems like For Loops are running 1 extra iteration than they should be sometimes
Itโs just an error in your code then.
Thatโs probably it yea.
The weird thing is that sometimes they do the extra, and sometimes they don't.
When you change the type of a map/set/array, is there some tool/trick/way to make it auto-update all the names in gets and finds and such?
No
that's a shame.
They are completely different kinds of data
hu?
oh, you missuderstand me
I do not mean to convert between those
just their internal types
The goal of my current piece is to search the roster of a pack of enemies for recurring entries, (ie: Count how many Bats, how many Ghosts, etc). then, I want to assign letters such that if there's say, 3 Bats a Ghost, they'll be BatA, BatB, BatC, and Ghost. While 2 of each would have BatA, BatB, GhostA, GhostB.
I don't expect a magical "everything works" result, just that most of the refactoring work is already done
By type do you mean class?
Look, simple example. You have an Array of class MyController.
You do get and set and etc on that array
then you decide to change the class to, e.g. MyBetterController
all the finds and gets should auto-update to that new type, even if their input pins break then
I understand what your saying
and if it is a little smarter it could even replace casts from the previous type into those pins
They should auto update but most of the time they break
I did see a long time ago someone knew a trick for this
Shame I can't remember lol
I wonder how hard it woudl be to implement that as plugin
well, I haven't seen it
I thought it was the "clean up references" button but maybe not
That's the half-way thing I mentioned
it leaves gets and finds untouched
like, it only replaces the variable get/set nodes and that's it
Is it still like that in ue5?
Or even simpler: A "reset type" option on the find / isEmpty
etc nodes
but not even that ๐ฆ
Yeah it is
๐คฆโโ๏ธ why don't they see our pain haha
Yeah they go to a wild card that allows you to just hook it back up
Hey! so I'm trying to save my character's position when my save point is shot. In my first screenshot (which works), the custom event fires when my character touches the save point. then I try to add the logic that says to save if the other object is my bullet class and it doesn't cast. anyone know how to fix this?
The bottom bp is saying "if your a bullet, go through branch 1, then check if your a player, if you are then go through the cast". Im assuming you have no item in your game that counts as both a player and a bullet, so no matter what hits overlap it will not work.
From your description i think you should check if its a bullet, if it is then save, but if it isnt THEN check if its a character that overlapped, and if it is then save. Checking both before saving is the problem here.
also, GetActorOfClass will be inconsistent here because you might have more than 1 bullet in the world, and the actors will not always be equal. That node also causes a bit of performance loss. Id use another cast there.
I suggest doing a cast to "your bullet class" at the beginning
Just to make sure it's only a bullet that triggers the rest of the event
From that u can "get instigating pawn"
You'll get there, keep trying :)
Thank you for the replies, guys! Might have a little trouble because I dont think I 100% understand casting yet, but I'll mess around with some of this and report back.
Casting was a huge hump for me when I first started. Its like a branch that you did before. It makes sure that the object you plugged in is the same type as the object youre casting to. If its not then it will fail.
You will get there, keep trying:)
^
Much appreciated! This is super helpful!
when you say to check if it's overlapped after checking if it's a bullet, what instigates the event? right now, this fires when any component begins to overlap and then it checks if it is a bullet
THe event is triggered when anything overlaps the box, thats correct. I might have made a mistake answering you, but youre right. What I was suggesting would look something like this. 2 options the bottom one is more similar to what you have
Hi guys. I'm just now learning blueprints but think I'm misunderstanding something fundamental. I'm trying to connect the Y axis of a cube to the mouse X axis. No player character. I'm trying to use the Mouse X Event on a script attached to the cube but keep getting messages about input not being enabled. How should I be going about this? Thanks.
Actors don't accept input by default. Either make it a pawn or enable input on the actor
Ok thanks. How do I enable it on the actor if I go that route?
Class defaults or settings at the top of the screen
Don't remember which
In this case I created an empty actor then added a cube and a blueprint to it, then supplied a ref to the actor.
It's probably a reference to the static mesh component that you assigned the cube to
Either way inside the actor's BP, at the top of the screen you can access the class settings and defaults
Should be a check box in the details panel for enabling input events
I see. So what would the 2nd box collider be? I see thereโs one (Box) and another (Box1). My save actor only has 1 collision component. Also what is the character ref being plugged into the save checkpoint event?
Probably just there for the example
Hey, I'm trying to make a smooth animation between my First-Person-Perspective and my Third-Person-Perspective. Problem is after going to TPP and back (FPP is set at spawn) The FPP camera has an offset or a zoom. Why? I'm only transforming the TPP for the Animation.
(FPP Before)
(FPP After)
I'm still not sure why this doesn't print anything
Any reason you don't just use "set view target with blend" node? @grave oak
@brisk comet my bad you gotta do it from the event graph.
(I usually avoid this)
https://docs.unrealengine.com/4.27/en-US/InteractiveExperiences/Input/ActorInput/#:~:text=Enabling Actor Input&text=On the Event Graph tab,add the Enable Input node.
@grave oak It transitions the player view from one camera to another over a set amount of time
Thanks @tawdry surge
oh those are just to show that theres 2 ways of doing it. you can pick which one you want
so I used the top method, and I'm getting an error: "Blueprint Runtime Error:"Accessed None trying to read property Character_Ref".
you need to populate the variable
so somewhere, you need to set that to a reference to your character
this is the details panel of that variable. the variable type is my player base class. is that a reference?
no
so a variable hasa type and a value
you have made it of the correct type
but it also needs the specific character you are referencing
If it's single player you can use get player character(leave index at 0)-> cast to your character type-> set the variable
got it!!! My save works!! Thank you all so much ๐
default values will never work for actor references, as that reference is never going to be static, you can always assume that a string will have its default value, but seeing as an actor will change and not be the same actor between levels and play sessions, it cannot have a default value
Is there anyone who can help me break down how to set up an inventory system, I want to avoid watching tutorials and picking up bad habits
hi guys ! Quick 3D question ... I have a "radar" which is shown on the player Hud. This radar is a 3d sphere, with its own relative rotation in the pawn (See rotation in screenshot)
I've managed to calculate the location based on the sphere size etc ... but I am not sure on how to make the debug circle location relative to my relative rotation shown ...
Any idea ?
instead of getting the location etc etc, I thought of using find look at rotation, add my relative location, and project the location based on the radar world location + distance + rotator
Which ui element is which?
the blue sphere with the red arrow is the radar. red arrow indicate the X axis of the sphere
green ball is an enemy
screenshot it taken from the player pawn. blue sphere (radar) is rotated toward the player so that he sees his "pawn" (center of the blue sphere) from the top
in this case, the green ball is represented by the white draw sphere and should be almost directly in front of the player in the radar
You will likely need to convert world space to screenapace.
are the arrows world space?
Yeah. If your sphere is world space and arrows are, you can use the node called convert world space to screen space.
It's from the player controller
in my case, it's a real 3d sphere
and my goal is to have at the end: enemy indicators (actors) inside the radar sphere, moving based on the player position and rotation
screenspace is 2d right ?
is there a way to rotate a world location based with a local rotator (my local rotation of my radar) from the radar world origin (location) ?
Enemy world location TO enemy scale world location TO enemy scaled world location rotated based on Radar world location and local rotation ...
not sure if it makes sense
oh yeah, the other way, If it's possible ...
find look at rotation between pawn and enemy (gives a rotator LOOK_ROT), calculate scale distance SD, project final enemy indicator based on Radar world Location at distance SD in direction LOOK_ROT + Radar Local rotation ?
quick question. why do images in my umg seem to create a duplicate when i move them around dynamically?
Did they remove the clean up blueprint button in UE5?
setting the translate on a tick for instance
What is your end goal? You're not making a lot of sense.
me the player have a detection radius of 15000 units. I am looking an an enemy which is at X:500 / Y: 500 and Z:0 units from me
I want to show a point which is relatively correct in my radar (blue sphere)
thing is: the radar component has a local rotation inside my pawn
Point location = radar center location + SomeSmallNumber x (EnemyLocation - Player location)
This will take in account the local rotation of my radar sphere ?
Sure if you do everything in world coordinates. Are you following the math?
That's your scale factor. If it's 1 you'll draw the point in 3d right where the enemy is. If it's .01 it'll be 100x smaller etc
I know that I have the scaled factor of my detection radius sphere in real world vs radar sphere real size in the hud
Ok so that's this number
Is the radar sphere in 3d or 2d?
3d
Ya so try it and report back
Thanks man ! I'll try that.
I would like to ask another stupid question...
How to check if an actor is over or under the player in 3d ?
(Other actor location - player location) x player up vector ?
Something like this ?
Can't test yet but can't sleep without the answer ... XD
How do I output the mouse's x position every time it moves?
Get Vertical Distance To is my answer I think
Calculate between current and last position ? I think there is a function for the last, but if not keeping it in a variable should do the trick
If I am not mistaken input are always firing so it should do the trick
I just want to know how to print string when mouse x changes. I can't figure it out.
Create a variable oldX, compare mouseX and oldX. If different it moved. At the end: update old X with mouse X
This is my bp for a pawn with a cube.
No idea why I'm not seeing a bunch of output on screen
I can't the mouse X event to fire at all
Mhhh. Do that in the controller instead, and maybe create a binding instead of using mouse X directly
If an input is consumed in the controller it will not be fired in the pawn
Maybe that's why
How do I tell the AI to go back to wandering after the Player is out of sight? My AI just sticks to following my player.
@onyx frigatewhat do you mean "in the controller" ?
I am trying to make a collision box enable a user control when entering the box and disable when not in the box. The hint widget I created when entering pops up so the box is working but the control I have set up for the actual interaction is not. Did I do anything wrong setting up the player control?
Have you confirmed that your LineTrace is hitting the DeskControl? I'd add a Print node to print out the hit actor(s) to confirm what it's hitting.
Also, depending on what your hit actor is, you may need to change your LineTrace channel to Camera and not Visibility.
Why is this so ridiculously hard!? I just want to output the damn mouse position on the screen! Nothing matches what I see on youtube/google. Menus they use are greyed out etc. This shouldn't be so elusive
Because you're overthinking it.
https://docs.unrealengine.com/4.26/en-US/BlueprintAPI/Game/Player/GetMousePosition/
Get Mouse Position
First lol
Do you have the debug actor selected?
Oh, I guess it'd be printed regardless
Thanks but that doesn't explain why the Mouse X event doesn't work
Is this new pawn possesed, or is it set in the world settings to be the player?
no clue what that means. The tuts just say enable input and create a mouse x event node
Thats probably a mouse input. You have to add the input in project settings.
The create the node in bp
Also, stop following tutorials step by step. You wouldn't learn that way.
Watch through first and understand what is going on
YouTube tutorial?
So far as I know, Mouse X doesn't work out of the box on an empty project. If you start with the First or Third Person content then you get a fully functioning character pawn, a player controller, project input settings and other things. The code you posted will work out of the gate in that base Third Person project. If you're using a blank project, you'll have to make that things necessary to get those mouse events captured.
Are clients able to access the game state via get game state?
#multiplayer but yeah. Game state is replicated
oh sorry thanks.
Np
Just curious about Widget anchors. How do you determine specifically where you should place the anchor. I mean wouldnt you just want to place it in the center of your widget, or make it full screen most of the time, what would be the significance of the other options.
It makes a difference when the UI is scaled for different screen resolutions and aspect ratios
Try the anchorings and use the arrow in bottom right to resize it and see how it behaves
Centered would mean youd need to update the offsets whenever you resize the viewport
If you wanted to have some widget up in a corner etc
Anchoring it to said corner instead solves this
difference between on clicked and on pressed in widget button?
Can anyone show me a basic blueprint of using ray casting to open and close a door?
Click is press and release
aah
Hello guys, In unreal by default when the character run into a wall movements are slow down. I would like to remove this effect and being able to run into the wall without affecting the speed. (Even if we still have a running animation). How can I acheive this ?
If you want to run through it, just remove collision on the wall
No I dont want to get through it. I juste want to "dont" slow down the speed when I run into it
Using blueprint - if i add a component to my pawn at runtime - the dynamically created component seems to exist if I do a few printstrings - but its not visible when i eject from my pawn and i look in the UI.
Seems like unreal isn't updating the compents that are visible in the UI.
Google seems to indicate it migght be possible to do this in C++ by adding and removing the UPROPERTY of something or other - is it possible to do this in blueprint?
What component are you adding? Sometimes the components don't show up in the hierarchy when doing this, but they are there.
What uproperty are you mentioning to remove?
Oh, your saying that in cpp you can set it to update?
I didn't know this was a thing, I assumed it was just a lacking feature/support.
what is the correct way to cast this im trying to implement my functions from the component into this Task
hello everyone, I come from Unity and I am now trying UE5, and some things are confusing me. For example, I want my windows to emit an emissive colour that has a random value for each window, so I am setting the scale value multiplying it with a constant and a PerInstanceRandom, this should give me a random value between 0 and 1, then multiply it with the given constant, and set the scale of the emission to that number. Except for some reason the PerInstanceRandom seems to always return the same number, every window has the same emission value, which seems to be 0. Now, the part that is confusing me is that every actor in my scene is considered an Instance, and they have a mesh component. Do I have to use an Instanced Mesh component instead?
how to get the count of 1 element in array in BP? any helpers I can use?
Do you mean the "index" ?
as in count how many of one item you have in an array?
what is filter array?
yes
Its an extra node.
You can call length on the array directly
that's only for actors though, I want for any type
Same thing. It's a general array node
goddamnit blueprints is so limited
Oh you meant the filter node. I thought it was for length.
i hate having blueprints be this liited
limited*
now I have to create a map to get the count of each individual elements
ANNOYING!
That node filters by class.
You would have to build your own function to filter based on a set predicate.
Equality or something else.
Lol. I understand.
You can just do whatever you want in C++ then
yes but then I have to return the result back to BPs because this is my UI widget
I don't need to do anything else in C++
1 whole class with just 1 function just for 1 function
dumb
or maybe epic can work on expanding the APIs for blueprints
Hmm we have the tools to do so ourselves. K2 nodes. Ufunctions.
lol
wait can I write a UFUNCTION outside of a class and expose it to BP?
how can I access it globally?
Nope but you can use a blueprint function library
It's technically a class but you don't have to instantiate it.
Just mark the functions as static
And they'll be accessible anywhere in Blueprints
Globally
man
idk
filter, reduce, includes, these are functions that you expect out of the box
if blueprints is truly trying to be a replacement for scripting
You have a point.
I've never given it much thought tbh. I always write my own filter functions
Hi. Could anyone help, is it possible to covert global variable to local? How can I do it?
Global variable?
There's no global variables
If you mean class variable to local function variable. You don't convert such things. Just add a local variable in the function as usual
Don't know if this is still free, but someone already did it for you
https://www.unrealengine.com/marketplace/en-US/product/array-helper-bp-library
why don't they just merge this into the engine
how do I get local player state in widget
Get player owner first perhaps?
Widgets are client owned and not replicated, aren't they?
Why is it that when I print my player state in widget, I get the same player state for client 1 and 2?????
Sometimes I get the correct list (0,1,2), but other times I get (0,1,1)? WHY????
Can you test clients in separate processes?
but I've never had this issue before
literally this is bare minimum...
I was assuming you're testing it inside the editor, not as standalone process. The former is more expected to have less reliable results at times
but why?????
how in the world am I supposed to test anything multiplayer related then
am I supposed to tick standalone game?
Man, Ro has it out for unreal today.
True dat
im a longtime unity user
and I saw all the unreal demos and went "wow this is so cool, this is probably defacto better"
and this is honestly one of the worst programming experiences i've ever had in my life
Seriously I'd pick unreal any day over unity for 3d stuff.
You just have to be patient with the engine and take time to learn it properly.
Most unity stuff don't translate to UE and UE has more features.
i know unreal is better
but this entire programming <-> UI flow I'm having a horrible time
I think next project (or maybe even this one) i think I'm going to nuke everything in BPs, move it into C++ and do only UMG stuff in BP
I'm straight up having a bad experience
I do most stuff in C++ but bp is indispensable in several aspects. Especially when interacting with assets.
That will slow you down so much it's not even funny
Direct C++ development is way slower in a number of ways then BP
Better off just learning BP from the ground up and then convert later as needed
i'm having the exact opposite experience
cpp feels much faster
I'm building a board game so very logic heavy. lots of test cases that I've gotta be meticulous about
etc
Array/set/map operations in blueprints feel like crap
I'm new to Unreal engine blueprints. These days I'm learning blueprints step by step.
I created a blueprint that can be the Number of tiles on X, the number of tiles on Y, Size of tiles (1000/3000).
Tiles array - An array with an object with the reference to a tile and an index for where the tile should be placed. Example: {tile: Tile01, position: You will then check this array to place predefined tiles and then populate the rest of the grid with filler tiles.
Filler tiles array - can provide an array of tiles that will fill the world
But I'm struggling to do Players should be able to walk around the plane and as they walk tiles will generate in front and tiles behind will be destroyed to always have the same amount of tiles loaded at any time.
I reached several ue4 blueprints programmers but it all end up in vain. plz, provide me assistance in this matter.
Can't say I have a problem with any of those. However loops and container iterations are something I'd eventually put in C++ along with structs, networking logic, and anything I want to hide from designers.
For anything I haven't fully finished deciding on the logic for, I put in BP for the quick compilation and testing cycle, and BP node search kills any intellisense I've ever seen
yeah this is something I'm realizing the hard way. Mine is accidentally a 50/50 split in logic
hello, im using a timeline node to control the angle of the sun on the Y axis for a day/night cycle but the Y axis rotation is weird and it breaks
how can i achieve a set time rotation (example, 24 minutes) without it going crazy?
this is how im handling rotation at the moment:
CurrentTime goes from 0 to 24
YRotation = (CurrentTime / 24) * 360
if anyone knows how to help, please do 
And it's really bad rn. for eg: I have a custom event that's (Server, Reliable) that calls a CPP function. Def made some mistakes
You can do that. It's trying to access BP stuff from cpp that'll get messy
I know I can, it's just worse. ishould've kept it all in CPP
Perfomantly speaking it's only slightly worse, and you can always move it later
Can anybody tell me how to add or remove a curve in world
ok however if i have a vertical box lets say in the middle of my screen do you think it would be best then to make it a full screen anchor? sorry for asking i am super green with UE5
is there a way to stop it? It's working as intended but ue thinks it's not
sounds like youre trying to get the grabbed component when there isnt even one
add an is valid node before you the make array
Hi! I have recently learned about unreal engine 5 from unreal senseand a couple of tutorials about blueprint and understood the basics,but my reason for going to unreal is to remake this game of mine i made in unity,the controlls shown in the video are basic,the character is a rigid body that when the wasd keys are pressed,a force is added depending on the forward direction of the camera as well as the right of it,and if holding shift whole pressing a key from the wasd an impulse is added in that direction as awell as pressing space,and finally the camera is rotated with the right click,so if anyone is just free and kind enough to teach me how to make that in unreal with blue prints and explain how they did it,i would really appreciate it!
@flint pier literally use the 3rd person template and study the third person character blueprint. It does all that out of the box.
I did try that of course but i don't know how to apply it with a rigid body character
Just add the mesh as a static mesh component
By the looks of your vid you want to add torque. There is a ball template that does that
Thanks i will try that!
if i add say, 5 items to an array, and then remove those items again, will the array still return a length of 5?
Nope
Hey, is there any way to nullify an actor's velocity through blueprints? Just set its velocity to be 0, to stop wherever it is?
thank you ๐
What kind of actor?
A regular actor or a character.
If regular actor use SetPhysicsLinearVelocity
A character, with a movement component.
StopMovementImmediately
Or you can set the maxwalkspeed to zero if you want something a bit more permanent.
Hi all, can I somehow test a Timeline in the editor? I have some transition effect between effects on Timeline and I would like to test it without jumping into the game.
I have a Custom Event that I can Call In Editor, but it does not start the timeline, nor For Loops (I thought I just make a ForLoop with a Delay to simulate a timeline, but does not start).
Any ideas?
That's not exactly what I'm looking for. Essentially the character is either falling or being launched upwards, and I want to hold that character's position, wherever that may be. Disabling gravity doesn't really do anything, because the upward launch or the downward falling has already taken effect, and the character is already carrying some amount of falling velocity. I'm looking to completely disable that falling velocity.
Hmm. I don't think there's a way to directly set the character velocity. Let me check something
Character movement has a set velocity function you can call
Actually you can set the velocity.
can I ignore PlayerCharacterController?
I really don't understand what it's doing
( I'm making singleplayer stuff )
PlayerCharacterController? Or PlayerController?
If the latter you can't really ignore it.
As your development progresses, you'd find reasons to subclass it.
Is this a template or something? Cause that BP class isn't created by default unless in a template
3rd person template I belive
Oh. Right. Like I said as you progress, you'd be adding more logic to that class.
But you can ignore it for now. Just don't delete it.
I'm trying to get the camera to look at the character velocity direction
with this:
and the thing is
I know exactly what I want and how to do it
but
I get the feeling that my way is "incorrect"
like
I would just force it all to happen within this one blueprint
Is FindLookatRotation better than using Forward Vector?
I think it is?
I don't have the character turn to face their velocity so
- this is for some flying stuff, not walking
If it works. I guess so.
that's what I think too
but I'm also scared
that unreal will get upset at me later
The code looks clean. I'm not exactly sure what it's meant for but if it works, it works.
If any issues arise later, you can just deal with them.
alrighty then
Hello, so I want to make a beeping system like those from metal detectors where they beep with a speed based on the distance between the device and the metal. Same system I want to apply here. I want to play a beep sound in tick event with a delay. The delay between the beeps is map ranged to be much smaller so I can use it as seconds. Everything works as intended but there is a problem. If I am at a distance of 4, the delay is gonna be 4 so it will wait 4 secs and then it will play. The problem is that I want the delay time to be changed dynamically. If it waits 4 secs for example and I'm getting nearer at the object, the distance gets smaller, so I want the delay to change with it. From counting 4, 3, 2, 1 to count for example like this: 4, 2.5, 1. TLDR: The wait time of the delay to change in real time. Not to wait until it successfully finished counting.
The custom event is wired to event tick
@vernal lotus you could also tick the "use control yaw(pitch,roll)" box in the class defaults of the character BP and it will make the camera rotate with the character
it's ticked
I need to switch between 3 camera modes tho
the default one being used for aiming
The controller has a camera manager class that might come in handy then
can I call static functions in BP?
THIS
I ALMOST LOST MY MIND
I can't find anything about this mythical camera manager
only some functions that seem useless
Its attached to the player controller class
You make one from the details panel in said controller
ooo
this?
and then what when I set it?
do I just write camera code in that instead of Character Blueprint?
kinda like anim blueprint?
Yeah you can hit the plus to make your own and it'll give you access to alot of camera movement settings
I've never used it very much beyond limiting the pitch and little things like that
ok I'll fiddle with it
I'm already lost
In line trace, how can I make the line 2 times longer?
multiply it by 2?
The end vector?
yeah
It was the first thing i did
It didnโt work
I need the line to be 2 times longer than it already is. How can I do that
Did you do the whole thing or just the part before adding it to the start vector
Itโs literally just line trace by channel and start, end Input
No
Iโm literally talking about normal line trace without anything
the 'Grapple range"
Show an image, cuz tutori did it right
I only have Start and End vectors. And I need the end trace to be 2 times longer but still facing the same direction
Thatโs all
I already have that
and then travel a distance to reach the endpoint
I just need to know how I can make the line 2 times longer
But still facing the same direction
You're repeating the question. They're trying to help
can you send a screenshot of that line trace?
Shift + Windows + S
then drag a window
They donโt really understand what I need, thatโs why Iโm repeating
Ok so
yeah and for that I need the image
Send a screenshot of your code
No we got it, but you don't seem to get how vectors work so we need to see the trace set up
I have start and end vector, I need something that will make the end vector 2 times further than it already is but still facing the same direction
my code that u were asking for
i hve given start and end vector
hey everyone, im not sure this is the right place for this question, but im trying to use deformation of the landscape and a collision box in a blueprint to tell if the landscape is inside the box after the player interacts. i have been unable to get the landscape to say its overlapping the box. im not sure what to do from here. thanks for any tips
like this
I needed to know how you define the "start" and "end" vectors
the same way as they are defined on the Node that i mentioned
"Literally just a line trace" confused me
cuz I never see line traces uses "Just by themselves"
'Line Trace By Channel'
they are always inside some type of system
is there some way to detect if something's lit by a light source?
you should check collision settings for both
and see if they match
they should have response set to overlap or block for their respective object types
@vernal lotus unfortunately, its not working
what is the value of "start" and "end"
its not blank, if thats what u are asking
it has to be anything other than zero
so do u have any ideas?
how can you tell it's not working?
because I have visibility turned on and I see that the Trace itself ingame isnt going the right direction
Are you trying to get it to trace down?
No
Up?
Z is up and down
Can somebody help?
I tested this code before and it worked perfectly
and thats for Offset btw
its supposed to get that Offset and subtract it from end vector to make it smooth
you should get the distance ( vector length ) between the metal detector and the nearest object
Thats not a problem...
then you can multiply the delay by that distance
I did all of these
gl
The issue is that lets say the delay time becomes 4 and I run at the respective object, it will not beep straight away, it will wait for the delay to finish
Use Rettriggerable Delay
ya both have overlap for world static, and both are world static. they are both generating overlaps as well.
Can I make a mesh remain the same size relative to the screen/viewport regardless of the distance between the mesh & the active camera/view?
It does nothing because the event tick keeps calling it
Oh I see, its a bad idea to have Event Tick with delay connected together
try Event Function Timer i think its called
Set Timer By Event
mb
are you using the "Hit Event" or the "Overlap Event"?
looping off or on?
If u want it to be like event tick, then yes
yes meaning on?
and the event pin to the custom event pin?
yes
overlap event
the output pretty much
huh
you have a print string to check if the event is triggering?
you know what tho
Aight so I've done that and it ignores the variable assigned to the time pin
on the level blueprint i added a is overlapping on the tick even with a print string for both true and false.
It plays the sound without delay
it could be that the deformation doesn't affect collision of the landscape
I know for sure that displacement in materials doesn't affect collision
ya its a displacement in a material
ahh
so there you go
it won't affect collision
cuz displacement runs only on the gpu
meaning it will use the original, pre-deformation collision
either simple or complex
it doesn't matter
connect the input for Set Timer by Event to beginplay instead of event tick
alright ill have to figure out a different way to tell when the area is clear. thank you for your help
np
How can I make it so that my line trace would be 2 times longer than it already is?
this is not "literally just a line trace"
@naive stag so you are taking the (impact point - start trace) then taking the Z value and inverting it,
Subtracting the impact point again, doubling it, and adding it back to the starting location
After working that out on paper I have no idea what you intend for that to do, but it definitely has the most drastic effect on the z values
?
Before that line trace im using a Multi Sphere Trace By Channel, so I needed to make the result to be around the character without it being a bit down or up. So I just made an offset for that
To double a line in the direction it's currently going you need a normalized vector (aka a direction) and a scale value(multiplier) then you add that to your trace start and it gives you a variable length line in that direction
To get what you want with what you've shown,, Subtract the start from the end, multiply the result and add it back to the start