#blueprint
402296 messages · Page 920 of 403
that's a complex problem
do you already have an inventory system?
Not working
sorry for a dumb questions
just need to know if you are starting from scratch
hey i need help, and the faster the better, im trying to implement cars into my game, but im having a big issue, the cars work, the player as well, but i cant get the play into the car
im getting this error
i tried to following documentation of the creator of the pack but its outdated
help would be very appreciated, and thanks in advanced
I thought it would be, so I decided to take a look at the Horror Engine asset from the marketplace which is sort of what I am trying to achieve. I'll come back if I have any questions I cant figure our though, thanks @vernal lotus
if anyone could help me, please dm me
oke
Im gonna randomly guess that the problem is with collisions
how come?
Idk until u show us the code it says the error is at
in second error u most likely forgot to give reference to an object u want to send data to
Can you show what you have now? The steps I just gave you should work fine
when i click on the error it sends me here
and here
The problem is that whenever i try to multiply it by anything, the end vector just goes to the upper right corner
its casting to my player (i presume)
Casts to ur controller and not u
im kinda clueless im recent to coding
How do you add "handles"/gizmos to a blueprint that can be moved in the level editor? I can remember watching some UE5 project demo where they used gizmos i the 3D viewport to drive some Blueprint logic a while back.
Silly question, and probably was asked before but I couldn't find a consistent anywhere. The official documentation of UE5 tells to use BP_ to create a new blueprint class (https://docs.unrealengine.com/5.0/en-US/recommended-asset-naming-conventions-in-unreal-engine-projects/), but if check the assets in the Lyra project, you see BP and B. Is there a new standard naming convention and the documentation is outdated or this is just something that eventually ended in the project and it's not official?
I'm thinking someone might have forgotten the P, maybe? Haven't had that project open myself, but I could see someone missing it once or twice?
But seeing as they haven't changed the conventions in the docs, I would assume that the conoventions are still the same
you get it fixed?
whats the name of the controller your player character uses? do you know
yeah you want to cast your BP_BasePlayerController and promote the output to a variable
Hey guys, so right now, my loot items are instances of an actor called Base Item that are set and instanced on another actor (Base Chest) BeginPlay and I can't seem to figure out how to set up references- how would I begin to add this to an inventory component for my player character?
still nothing
still giving me the same errors
no, from "as Bp base player controller" connect it to a set dc_player_controller node
i assume you want dc_player_controller to equal your player controller
like this i presume
yes
yeah that code is too complex to easily troubleshoot, youre gonna just have to rewatch the tutorial your watching or watch a tutorial specifically on casting to understand it
how
i followed this doc/tutorial: https://www.youtube.com/watch?v=HIEbU047Mm0&ab_channel=DigitalDiveStudio
https://www.unrealengine.com/marketplace/en-US/product/driveable-cars-basic-pack
Discord Channel: https://discord.gg/W2mE6W4
This basic tutorial is ment to solve one of the most frequently asked questions of our Driveable Cars series: How can I mix Drivable Cars pack with my own project.
This video is divided in 6 simple steps:
1. migrat...
and nothing worked
im trying to get in contact with the asset dev, but nothing, his discord is also dead
I don't know why it's so hard for me, but
I've made a RTS controller for a part of my project, everything works fine, however, I want players to be able to rotate the camera, this obviously messes up the direction the camera moves, so I tried fixing it, however I can't seem to get it right. I know I probably need to use the forward vector, but I can't wrap my head around how to do it 🤔 👀
This is a screenshot of forward movement, without considering rotation, any suggestions?
@naive stag I made this quick. It' gives a line in the direction of the trace hit and it goes twice as far as the sphere trace
Impact point and location were giving bad values which is why I switched to getting the hit actor location instead
Anyone know how I can get rid of this annoying debug tooltip? It covers the entire node sometimes and makes it so I cant click it.
top right unselect the debug object
ah wow i feel silly, thanks a ton
no problem i tried to work it out for hours
haha, thanks for saving me that time
Hello! I have a progress bar that I have attached a binding to and my issue is, after my game gets paused, my function straight up stops ticking. If anyone can help, that would be great but I'm also not sure if this is the place to ask because it is in my UI widget
I'll also ask in the Ui section just in case
I know it stops ticking because after I unpause my game, the string stops printing
I got your idea, I modified it and now it works perfectly. Thanks a lot
ok
so how exactly do I get the CameraManager to communicate with my PlayerCharacterController and PlayerCharacter blueprints?
Currently want to create my game state blueprint. I notice I can't override HasMatchStarted and similar in the blueprint.. I thought I was supposed to do that.. is it c++ only for that?
(I derived from GameStateBase)
uh, are you sure you're doing something where it has to?
what exactly do you mean by "where"?
I thought all the match stuff was in Gamestate, not gamestatebase
Gamestatebase is the simpler uh... Base for it
well, those methodes are def. in the GameStateBase
/** Returns the simulated TimeSeconds on the server, will be synchronized on client and server */
UFUNCTION(BlueprintCallable, Category=GameState)
virtual float GetServerWorldTimeSeconds() const;
/** Returns true if the world has started play (called BeginPlay on actors) */
UFUNCTION(BlueprintCallable, Category=GameState)
virtual bool HasBegunPlay() const;
/** Returns true if the world has started match (called MatchStarted callbacks) */
UFUNCTION(BlueprintCallable, Category=GameState)
virtual bool HasMatchStarted() const;
/** Returns true if the match can be considered ended. Defaults to false. */
UFUNCTION(BlueprintCallable, Category = Game)
virtual bool HasMatchEnded() const;
/** Returns the time that should be used as when a player started */
UFUNCTION(BlueprintCallable, Category=GameState)
virtual float GetPlayerStartTime(AController* Controller) const;
What are you trying to do that involves PlayerCameraManager at all?
You running a camera component-less setup?
no
it's the default camera + spring arm
2nd mode where it follows character velocity ( can't control camera)
and 3rd where it locks on to the boss
and it all has to be a single camera too
If you're going for the camera manager approach I'd just lose all the camera components. Otherwise you can just move that camera component around however you want. I wouldn't try mix and match.
Yeah I'd do that. Just have some enum representing the camera state and switch on it to set things up.
Yeah dafuq
Make some enum with values like Free look, follow, lockon
E_CameraState or whatever
it's this thingy yeah?
Then in the character bp make a function UpdateCameraState that has that enum as a parameter.
Then in that function, switch on the enum to do things (disable use control rotation on spring arm, whatever.)
sry I never used enums before
oke
1.) create an Actor Blueprint
2.) add an component to the actor (e.g. Static Mesh Component)
3.) Drag the static mesh component on the DefaultSceneRoot in the BP hierarchy to replace the root component (now the Static Mesh seems(!) to be the root)
4.) place the actor in an empty level, and change it's world transform (e.g. move it up)
5.) save and reload the map
6.) actor at 0,0,0?
could someone test this for me?
preferable on UE5
Read up on them first. Enums are like a bool but can have many named states
I stead of true/false, you can have Apple/Banana/Cardboard/Ferrari
oooooooo
Whatever you wanna call them.
And you can switch and select on them.
Switch executes a different path depending on the enum value. Select chooses a different input based on the enum value.
Is it possible to get a reference to an object attached to a skeletalmesh's socket in runtime?
or an object attached to a bone
For example in my projects UI I have a UIState enum, with values InGame, MainMenu, SettingsMenu, etc. When I press keys like escape, it chooses a new Enum from the current Enum (state machine), and then a function runs that shows/hides widgets etc.
Making a game similar to a point n click adventure from the 90s. Basically it'll consist of like 4 chapters, and each chapter will be an entire level in UE. What would be the best way to setup default states for each chapter? Stuff like starting position, camera, inventory, etc. I was thinking variables in the level blueprint but I think you can only add defaults in the BP editor, right?
From what I can see the best solution for that would be
And then if true set the reference
Thanks Benj! I am having trouble setting the reference. My object is an Instance of a BP_Weapon. I need a primitive component object reference for a trace component to work.
anyone?
Not experiencing this issue Ben, sorry.
UE5?
Correct
thanks for testing
I'm starting to think enums aren't fit for this
are yout trying to change the actor's transform?
yes, but it resets for me if i alter the actors root component
cuz I need this to update per frame, always
for every state
and then also interpolate between states
I think thats because you are trying to make the Mesh the Default scene root.
i'm pretty sure that it's causing it
i just want some reproductions before i submit an bug report
maybe even track it down to a specific change in ue source
Maybe I dont understand the error your having.
All I know is, if I'm trying to alter the transform of the mesh, don't make it the scene root and it will remain the same. Keep the default root as is.
i'm not altering it in the BP
i'm changing the location of the actor in the world, and it wont save that location with a custom root component
hey, I have a problem with the resolution of my standalone game. not sure if this is the right channel to post it to - let me know if I should rather use anoither one.
if I switch my standalone game to fullscreen mode with a 4K desktop resolution, it pins itself in the upper left corner of the screen and changes its resolution to UHD (I think), but never the fullscreen. can anyone point me into the right direction of how to tackle this? thanks! 🙂
Maybe something like #graphics ?
You don't necessarily interpolate between states, just interpolate the results.
When you crouch, you don't crouch instantly, but you can have a state bCrouched. Same idea
Now my AI is moving to the first waypoint but after that it stops working if anyone can help i can post the Blueprints
Hi! I found myself doing this a lot
that being a print with a "Message-6 random letters"
so i can find that specific print later on with a "Search on blueprints"
does anyone know if it's posible to create a shortcut to a custom node that is the same as the print node but with -'6RANDOM LETTERS' As a default?
Or maybe just override the print node with that default text
I know I can just flip the door around, but how do I get the skull to enter based on the players facing direction?
Find Look at Rotation
start is the skull, Target is player
NM, i read your question wrong
i think you want something with Dot Product, i forget how it works
I don't understand how RInterp to works
Plugging in the right rotators it just snaps to the new rotation without any interpolation
It's the delta time and speed thing that's confusimg
yea, I need to get the players position and some how get the positive/negative of the facing x/y direction and blend that with the key position.
Just need to figure out the syntax
Do RInterp on Event Tick. For delta time, use the output on the Event Tick node, or use Get World Delta Seconds. Set speed to 1 and then adjust to taste
Get the forward vector of the player and the door. Plug them into a dot product node. Positive return value means one side, negative the other
how do I change double precision float to float?
for some reason a code I copied won't connect the nodes (dot returns double-precision float but Set "current Speed" node asks for normal float)
EDIT: never mind, it's just a bug. I'm using UE5, I guess the code is from UE4 so all I had to do was remake the nodes inside UE5. I guess everything got upgraded to double.
thank you
Hi, i have this timeline that has a 30 second float track on it which goes from 0 to 1, how can I make it so the cloud coverage is set to 10 by the last second of the timeline? right now it hits 10 at about 10-11 seconds into the timeline
i think you want your Lerp A to be 0
Thanks for the help. I dont think its working though as its being driven through the timeline node. It dot product did change the behavior though, it just started from the middle and didnt animate.
You need to use the output from the dot product and do a >0 check
Use that in a branch or a select node to get it to animate how you like
If i do that the cloud coverage variable will be set to 0 which i dont want, i need it to keep the current cloud coverage and add to it
Guys, can you please upload a tutorial on a belated camera rotation. For example, when turning to the side, the camera will first turn and only then the character's body will turn behind it
Is there a way to know if a key is held?
Is Input Key Down
Is this done via IK or is there another method?
Oh okay, and then just make a separate animation facing the opposite direction?
Or invert the current one
Hello ppl, does anyone have an idea why the BeginCursorOver event is not firing in game ?
- I have enabled
MouseOverEventsfor the Player controller - The StaticMesh of the actor in question has its collision profile set to
BlockAll
Is there something else I might have missed?
@buoyant moat add a print string. Iirc if events have no follow up they are ignored
@wicked osprey that can be done using the animbp.
How can I attach a physics constraint to a player and object during runtime? Thank you!
Hey guys, this is pretty basic stuff, but casting does my head in. Here's what I'm trying to set up: A light switch that will cast to scene actors (lights) and toggle them on and off. I have six different light styles, and have parented them all to a BP_lightsParent. I can cast from the switch to the parent no problem - I just can't figure out how to pass the command along to the child light actor.
@faint pastureHello ! It works like a charm except the relative location of the radar is not taken in account
this formula
That's my local rotation rotation is seems
casting is not that sort of thing, ignore the word "cast" in that way. however you make the parent actors switch on do the same way for the child actors. i have very little info to go by here but lets say you make the parent class turn on by "getting" the light(parentclass) then "Turn on" function.
for the child you would also, "get" the light(childclass) then "Turn on" function
if thats how you are doing it
I have a shooting animation and a running animation, can I use a blend space to have my character shoot while running instead of making a new animation for it
my game is on a 2d plane btw
Guys, I have a radar which is working fine.
The pink dot in the blue circle is the position of the enemy (green ball) vs the player pawn.
but I want my radar to have a relative rotation and the point to follow it.
Any idea to do that ?
if instead of the point I spawn an actor attached to the radar (blue sphere, which is a child actor), the enemy indicator actor will be rotated as well right ?
can you show how you are doing the radar
try "FindLookatRotation"
then maybe "SetRenderAngle"
Hello peeps
I am trying to move to level 2, after i complete level 1, so everything working fine, except that when i move to level 2 , either the character freeze or the level 2 freeze
this is part of level 1 blueprint that moves you to level 2
any idea?
sorry I know this is late, but look at how they do it in Lyra, it's pretty neat
?\
i don't really know anything about level loading, sorry.. the 'delay' node is kind of suspicious
what blueprint is this @finite island
level 1 blueprint
the delay is basically related to "fade"
so at the end of level 1, it fade, then it moves you to level 2
@potent laurel that's how I spawn/draw the point
can you show me more
I am just missing the rotation to be able to show the enemy indicator correctly if the radar is rotated inside the pawn
what event
gotcha
My radar is rotated toward the camera like this:
the red arrow indicats the forward vector of the radar
so its the enemy rotation thats wrong?
If I leave the radar with no relative rotation the formula works pefectly
the location of the enemy indicator (which is shown rn in the screenshot doesn't take the radar rotation in account). it's as if the forward vector was still pointing forward
if the rotation would have been taken in account the orange cube would have been shown on the yellow dot
(which I added in paint)
any idea?
but because my formula doesn't take the relative rotation, it is shown as if the radar was facing forward instead of it's relative forward: red arrow
see what I mean ?
and right now my radar has this rotation (and always this one):
i don't understand how I can use this rotation in the formula below
does anyone know if you can make a blueprint that has like a bullet mesh that will follow a line trace?
Thanks for the reply - gonna play with that in the morning.
I am trying to find the velocity of my VR hand, however it is only returning "0.0" Any ideas? Thanks
Does anyone know how to take a screenshot and save that to a texture variable i can use in a UMG image? I am trying to screenshot a custom map for a thumbnail on a load map screen. Thanks!!!
I’ve tried high res and capture scene 2d.
That's just a projectile with no gravity
Question?: I have 2 actors, Host and Client. I'd like the Client to move closer to the Host each second, then stop when it gets to the host. What does this look like in blueprints using set location? Its for reelin in an lure.
Newbie here, which BP class do I put this into? I tried the level BP but it doesn't seem to work (cycles through each camera and takes a screenshot in run-time) https://d3kjluh73b9h9o.cloudfront.net/original/4X/5/0/2/502783cce00b6bf26d7baa8991e78d9ebb8e4303.jpeg
Hey guys, I need help with a "enemy danger indicator" logic. I have it correctly showing enemy position at the side of the screen, but it is not showing the position correctly when the enemy is behind me. Can't figure out why.
Here is the logic:
problem shown on video:
https://www.youtube.com/watch?v=BkYCJqBJODc&feature=youtu.be
May need to take viewport scale into account?
Hi!
I have a question. I am compiling blueprints project in shipping mode. 5 warnings (shaders) 0 errors. The game's .exe file shows a fatal error when launched. Where to look for the cause? How to track down the error? I found little information on the internet about this 😦 UE5.0.2 (but the error was showing up in UE4.2 with compile-time development).
Assertion failed: AsyncLoadingThread.RecursionNotAllowed.Increment() == 1 [File:D:\build++UE5\Sync\Engine\Source\Runtime\CoreUObject\Private\Serialization\AsyncLoading.cpp] [Line: 3861]
0x00007ff79e8a440a UnrealGame.exe!UnknownFunction []
0x00007ff79e8ca4f8 UnrealGame.exe!UnknownFunction []
0x00007ff79e8c78ed UnrealGame.exe!UnknownFunction []
0x00007ff79e88f297 UnrealGame.exe!UnknownFunction []
0x00007ff79e8ead6f UnrealGame.exe!UnknownFunction []
0x00007ff79eb81bb9 UnrealGame.exe!UnknownFunction []
0x00007ff79eb81684 UnrealGame.exe!UnknownFunction []
0x00007ff79eba3bc1 UnrealGame.exe!UnknownFunction []
0x00007ff79eba3002 UnrealGame.exe!UnknownFunction []
0x00007ff7a28fa801 UnrealGame.exe!UnknownFunction []
0x00007ff7a28ea8b9 UnrealGame.exe!UnknownFunction []
0x00007ff7a28f95f2 UnrealGame.exe!UnknownFunction []
0x00007ff7a28fdb60 UnrealGame.exe!UnknownFunction []
0x00007ff79e979c9b UnrealGame.exe!UnknownFunction []
0x00007ff79eaeeb66 UnrealGame.exe!UnknownFunction []
0x00007ff79e97a608 UnrealGame.exe!UnknownFunction []
0x00007ff79e979c53 UnrealGame.exe!UnknownFunction []
0x00007ff7a3ceb24d UnrealGame.exe!UnknownFunction []
0x00007ff7a41060b0 UnrealGame.exe!UnknownFunction []
0x00007ff79e87b9be UnrealGame.exe!UnknownFunction []
0x00007ff79e8a7753 UnrealGame.exe!UnknownFunction []
0x00007ff79e856ec8 UnrealGame.exe!UnknownFunction []
0x00007ff79e8a47cc UnrealGame.exe!UnknownFunction []
0x00007ff79e8ca4f8 UnrealGame.exe!UnknownFunction []
0x00007ff79e8c78ed UnrealGame.exe!UnknownFunction []
0x00007ff79e88f297 UnrealGame.exe!UnknownFunction []
0x00007ff79e8ead6f UnrealGame.exe!UnknownFunction []
0x00007ff79eb81bb9 UnrealGame.exe!UnknownFunction []
0x00007ff79eb81684 UnrealGame.exe!UnknownFunction []
0x00007ff79eb98058 UnrealGame.exe!UnknownFunction []
0x00007ff79eba3b00 UnrealGame.exe!UnknownFunction []
0x00007ff79eba3002 UnrealGame.exe!UnknownFunction []
0x00007ff79eba4cd2 UnrealGame.exe!UnknownFunction []
0x00007ff7a3cbed42 UnrealGame.exe!UnknownFunction []
0x00007ff79eb87dcc UnrealGame.exe!UnknownFunction []
0x00007ff79eb592b4 UnrealGame.exe!UnknownFunction []
0x00007ff79e92379c UnrealGame.exe!UnknownFunction []
0x00007ff79eba76e3 UnrealGame.exe!UnknownFunction []
0x00007ff79eb88aaa UnrealGame.exe!UnknownFunction []
0x00007ff79cd9780a UnrealGame.exe!UnknownFunction []
0x00007ff79cd90cdc UnrealGame.exe!UnknownFunction []
0x00007ff79cd9101a UnrealGame.exe!UnknownFunction []
0x00007ff79cd9409c UnrealGame.exe!UnknownFunction []
0x00007ff79cda5854 UnrealGame.exe!UnknownFunction []
0x00007ff7a4e0eeda UnrealGame.exe!UnknownFunction []
0x00007ffb06997034 KERNEL32.DLL!UnknownFunction []
0x00007ffb080c2651 ntdll.dll!UnknownFunction []
You must translate 3d to 2d space. Is tge radar not always facing 'north' as players forward?
Stupid question but does gamemodes variables transfer between 2 levels? If not, where should save game variables for multiplayer?
In one game in multiplayer you teleport level to level, but need to still be able to store alive players and kick players etc.
when im using a widget switcher if i create the widget blueprints to be switched by it do i have to create them as the children of the main widget blueprint or can i just make them separately and then drag and drop them under the widget switcher in my canvas panel
is there way to set 'owner' other than Possess? i only know possessing can set owner. in my case i need to control multiple pawns, i set 'owner' variable with player controller but it's not real owner.
probably using a game instance
But game instance isnt for multiplyer
You can't possess multiple pawns at once. However you can set them to be owned by the pawn you are possessing.
Either by assigning it at spawn or using the set owner node
They pry meant it's not replicated
Yeah
what do you mean viewport scale? Currently when I get scale it's 1.16. I don't know where I should take it into account?
I'm developing a TPS game and I have a camera related question. PlayerCameraManager has its own camera. I have two choices. Either I will not use the PlayerCameraManager and use the camera I added from the component, or I will remove it and use the camera that PlayerCameraManager added. What are the best practices here? For what purposes and how does it make sense to use the PlayerCameraManager?
just use the camera where you have it
use SetViewTarget on PlayerController as necessary since PlayerCameraManager is driven by PlayerController
no need to try to bend your gameplay code to whatever camera is in player camera manager -- most of the time its first one it finds on your PlayerController possessed Character
see the above, because i forgot to ping
That's the simple way and works fine in many cases, however the player camera manager has benefits if you want more control
https://unrealcommunity.wiki/player-camera-manager-227ae5
The PlayerCameraManager is an important aspect of Unreal Engine and good documentation around it is somewhat sparse. This page exists to try and remedy that.
yes if you start using its API directly you can do lovely things separate from playercontroller 🙂
Been racking my brain for days now trying to connect Lyra's weapon setup to a combat component. All I need is a reference to a primitive object but Lyra has Lyra Equipment Instance Objects. I've tried putting the components on the weapons themselves but then I can't get the activate collision to fire at all. Anyone have a clue as to how I could proceed? Thanks!
Hey anyone played much with generating splines? I'm trying to get my ai to do some 'dinosaur movement' behaviour, and get them to follow a spline! Unfortunately the spline I generate from path points along a navmesh suck and was wondering if anyone had any suggestions to be able to get a more smooth transition?
could be a great topic for #gameplay-ai
we love that stuff 😄
Wasn't sure where to post, but I'll rehash that over there! 🙂
https://www.artstation.com/artwork/Oyegwb
Can someone give me a lead how this pp could be done?? Id pay the person but his product and sells page has been removed from market place
There's plenty of youtube tutorials on outline materials. Both post processing and otherwise
And there is also #hire-a-freelancer et al to advertise hiring requests
ok question but it is possible to make a blueprint that destroy a diffrent actor that isnt in the triggerbox right?
Yes as long as you get its reference
I knew it! all i need is to figure out how to make tge reference
Hey guys Idk if this is the right channel for this, But iam having so much problems with the cars in my project I just cant make them to work. wheels turing wrong side they dont even drive, If anyone can help me I would really appreciate it
well for one how is anyone meant to help when you dont post a blueprint or anything and also dont ask in multiple channels considering you posted 5 minutes ago in #ue5-general
There is littearly nothink in BP, you dont need just the animation BP, and the inputs for forward and steering stuff, I was asking in general if someone had that problem
if theres nothing in the BP why are you posting in a BP channel?
Also how are you trying to move
Thats why I said idk if this is the right channel for this.. ahah nwm ill figure it out
Thank you very much!
how do I detect if player stands on an object? (I need to make him unable to grab it)
Trigger box
then override the on actor begin overlap and then disable grabbing
then on end overlap enable it again
Thanks a lot
Now for real, I figured almost everythink out, Now iam confused why my car only steers to right!
Your a and d move in the same direction there
So does forward and backward actually
Ohh I see so I should just make 2 seperate line steering L and steering R
Ahhh thanks
Your a god love you❤
No problem
there's gotta be a way to detect the component a player is standing on through CMC
Guys, I'm trying to use the scale of the client start camera shake with a variable, but instead of using the value of the variable, it automatically changes to 0.
I'm not sure if this is a bug or what.
Version es 4.27.2.
Kind of a dumb question
Does changing a variable to the same value have a cost with regards to graphics?
Like if I go "set material" to the same material, does that have a cost or does the engine cull that call if it's un-necessary
Divide viewport size by it
ok, changed it, still getting stuck in the corners the same way, except with some margin :/
nothing happens. the address is already set so if you set it to the same thing, nothing changes.
thanks :)
Scenario! I have two BP scripts:
- ProximitySpin sets the relative rotation and position of its Owner using the "Move Component To" node
- ProximityFollow sets the position of its Owner using "VInterp To" combined with "Set Actor Location"
Each script has other logic associated with it, but these factors are the points of friction. I would like to apply both of these scripts to the same object and have their position-setting behaviors be compatible. If I were using Unity, I could create an empty parent object and attach one of the scripts to that and the other to the child. Attempting the same structure with these two scripts in UE results in wildly unpredictable behavior. Using both scripts on a single object causees one to override the other.
I've attached both scripts here so you can see what I'm up to. To use them:
- open a default Third Person project
- attach either script to a Movable static mesh actor in the scene
- add a large sphere or box collision component to that actor
- when the third person player walks inside of that collider, the behavior will trigger (For "ProximityFollow", the object will drift toward you. For "ProximitySpin, the object will spin to random positions at set intervals, spinning faster while you're farther away from it and slower when you're close to it)
The most obvious solution that I can see to this would be to find a way to exclude the position-setting behavior of "MoveComponentTo", which I'm using in ProximitySpin to set the rotation over time, yet don't actually need the translation part and am forced to utilize it. I suspect that involves recreating all the behavior of MoveComponentTo with a large series of nodes, excluding the Target Relative Location behavior. But if there's a simpler way to just exclude that pin, I'm all ears. Otherwise, I'm really just interested from a theoretical standpoint how I could have two scripts setting the position and get them to coexist, like I thought I could achieve by attaching one to the parent and one to the child, but with which I haven't found success.
Rather than using "move to" I'd use interp nodes and then you can set rotation and location separately
how do I set maximum force that a physics handle can apply?
That's what I figured, though I'd also want to recreate the nice Ease In / Ease Out functions of Move To. But say that, theoretically, I did have two separate BP scripts that I wanted to set translation with. Like, imagine one causes an object to oscillate back and forth locally and the other causes it to rise up and down. Ignoring the fact that's a strange thing to want to accomplish, is there a way one might have them operate in tandem?
Hullo! Question about collision objects as components in an object. I have capsule collisions under a SM components. I'm trying to toggle the collision on/off of all the capsule objects under the SM component. This doesn't seem to work. I do set collision (no collision) on the fire corridor. It doesn't pass it down to it's children? I can do the set collision (no collision) on each capsules... but I want to do something more efficient 😄
is there a way to expose these variables in the details panel?
I added a blueprint with editable variables as a CAC into another BP, but every time I have to open the viewport, click the body and go to 'default' and change it. But it is also buggy and messes with the rest
no, it's not possible
They are already in the details panel in the level.
By default you are looking at the class details.. Go up slightly to the component section and select the component you want to mess with.
Is there a way to trigger this function when the variable "In Field of View" is changed?
like some sort of event that detects if a variable is changed
@west sky yes, you'd essentially have to have one set the local/relative X location and the other set the Z
They won't overwrite each other because they are each only handling one axis
Ugh why is this so difficult,, nothing in ue4 works with logic 😭
now trying to make a list for socket names, does not seem to work with enumerate
Why not just use an array of names?
One is actually already provided if you call "get all socket names"
Yea but still I want to be able to choose
So make a select node and feed in your choice
no, you would want to create a setter method for that
like, SetFOV(float Value), which then sets your variable, and does everything else that's necessary
The variable is changed in the editor during play
can some one help me with this and tell me why this is not working? Its weapon sway. I added them in for the pitch and yaw.
Hi, i have this timeline that has a 30 second float track on it which goes from 0 to 1, i'm trying to make it so that it smoothly increases the current cloud coverage up to 10, but over the 30 second period so it only hits 10 when its at 30 seconds? right now it hits 10 at 10-11 seconds into the timeline, anyone know how i can make it work?
Lerp A is increasing. So when cloud coverage reaches 5, you are lerping between 5 and 10 with alpha as 0.5 gives you 7.5
Lerp A node should be constant. In this case 0.
That makes sense, but my problem there is that it sets the cloud coverage variable to 0, i need it to keep the current cloud coverage (which is set to 4 at the moment) and increase it up to 10 over the 30 seconds
I would connect exexution pin to "Play" instead of Play from Start
@prime stump try this.
you set the position of timeline based on current cloud coverage. in your case, cloud coverage is 4, then 4/10 = 0.4 and since duration is 30 seconds, 0.4*30 = 12 so the timeline would start from 12 seconds and it wouldn't start from 0.
note that this only works as long as Cloud Coverage is between 0 and 10.
and notice dont connect to PlayFromStart because that would reset playback position to 0.
Is it possible to save the edits made to a variable during an editor play session? For example, let's say I hit play and some changes are made to an array variable in a blueprint. When I exit the session these changes are lost, is it possible to not have the array reset? In other words, to edit the default value
Right click on actor, then
Hm it doesn't show up under Play From Here, any idea why? Also is it possible to only keep changes for a specific variable? Seems kinda dangerous otherwise, could screw lots of variables up
Nvm, I found it! Need to be playing while selecting the actor
But the other question still stands
I dont think There is an option to keep specific variables. but you can copy properties manually which is of course not always easy.
Hm well fortunately in this case, I can unplug all functionality and just edit the array since it doesn't depend on anything else
keep in mind, all actors are copied from editor world to PIE world, so most variables would be same, just be careful about variables that change including actor transform.
Alright, thanks!
How can I get a ref to third person character in a random bp?
you probably want to use the "get player character" node
tried, didnt work
actually
i can cast after it
so ye that will work
it worked, thank you
Hello there !
I'm trying to make a 2D grid with loop in blueprint but i need it one frame at a time
So i made a ForLoop but with a Delay inside
The problem is that i only have the first raw on X and the last on Y, i don't get all the "slot" of the grid like i have with a simple ForLoop
I don't know if it's even possible but i know you can multi-thread it in cpp but don't know how in BP
It's for a minecraft like generation, for generation the chunk
My code work perfectly to do that, but it's all in one frame and i need it one frame at a time for each chunk
Thanks !
What i have with ForLoop :
What i have with ForLoopWithDelay
My ForLoopWithDelay
And how i use it
If someone can save me, it would be super great 😅
(please tag me if you have a answer or if something is not clear)
delay doesn't give you multi threading though, once delay expires, it continues on the game thread.
Can I add getter/setters to existing variables?
I just want to make 1 chuck per frame, not searching to do a real multi thread and everything
you can add get/set functions but you can't change existing variables get/set behavior.
if you want to do it per frame, do it in Tick event. it runs exactly once per frame. you can have a counter that increments every tick. and use that counter to get X,Y index for your grid.
Can I then replace all get/set nodes of that particular variable with a function?
@slim wave any reason you don't forget the for loop and just run it on tick?
That way each frame you can increment the current chunk and once you hit the end either stop or go back to 0
I am in the tick with the ForLoop, but i make all the loop iteration in one frame
Thats how for loops generally work
what's the delay for?
Instead of that just make the tick do the looping
Yeah that's why i wanted a 1 frame delay between loopbody
use the sleep node to delay until next frame, set the sleep duration to lowest possible Edit: oh wait its called "Delay"
I see the idea but don't know how to make it so it's a square around a certain area like i have right now
you don't need delay at all. or i am confused
It's identical logic, just instead of a for loop, increment the current index in your chunk list.
Each frame will then only generate one
This would print hello indefinetely. You could hook it up to begin play
🤔
That's my code without any delay
it generate me a 3x3 chunk around the player
I see how i can generate 1 chunk under the player in the tick, but not a 3x3
@tawdry surge
That's overly complicated for generating a grid but leaving that alone.
Just delete the for loops and make a current index variable.
Increment it at the end.
if you have access to c++ there is a way to add get/set function without need to change anything in blueprint. but if you are in blueprint only, then you have to search for that variable (use FindAll tool) and replace them with get/set functions.
What would that look like?
i don't see how to do it without loop and don't know how and where to use a index variable for the tick
One minute
I have a similar BP i can share
there is BlueprintSetter and BlueprintGetter keywords for UPROPERTY. oh and the variable you are trying to fix should be also in c++. @spark robin
if i get class and check if its equal to a parent class, does it return true?
I see, so what file do I open to add those keywords/macros?
Im working in a C++ project already
no
alright, thanks!
hey hey i have a question i need to get data from a object to an task can anybody help
Has anyone have luck on using rigify for ue5 base rig?
I had a pretty decent experience using Mixamo (and the mixamo rig, not using the default UE rig)
this video seems to explain (i haven't watched)
https://www.youtube.com/watch?v=VMQ_Yw5uM5I
In this episode we will look into the UPROPERTY macro and cover the two specifiers: BlueprintGetter, BlueprintSetter.
He is using the C++ class as parent there though
Its a little bit annoying that I cant sort of just replace all instances of a node with another :l In text based programming its quite easy in comparison 😛
if parent class is not c++ you can't do that. you have to fix manually.
there is a tool in ue5 to replace functions with functions, or variables with other variables. but there is no tool to replace a variable with get/set functions.
This is mine with a for loop because mine I want to happen in one frame
this is an on tick version
i'm thinking on just going for that, but i don't want to loose all the default settings from ue5 : (
In your experience, how much took you to replicate the default mannequin functions?
@slim wave yeah its my total number
Got it to work, but it make me random size on one axe
This is for a chess board, so mine is 64
Like here, just 2 on X
It's pry an issue with the end of the code where its picking if it should change rows
Are you doing >= or just >
Set y length to 4 or add an =
This should work in logic, no ? 🤔
For exemple, RenderDistance is at 6, so i should have a 6x6 square
Hi, I am trying to improve the jump mechanic for my little pawn. I am using a pawn instead of a character because the 'player' is a ball that rolls around. I'm hoping to improve my 'check jump valid' method, but not sure what the best approach would be. Is there a better way to check if a pawn is jumping other than the component velocity?
🤔
You'd need 36 to get a 6×6
Well, i have a 7x12 square
How do I use the outer cone in the spotlight as a trigger box so if any object is inside of the outer cone it will make the object red
Haha np
Was just confused how you got 7x12
Math 🙃
If you don't need it to keep generating anything after it's done with the square you can call disable tick to make it stop
Or move it to a timer by event or function
Well, after that i need to generate in continue around the player ^^
like i did with the loop
Ah ok
Np
im working on my first game with my friends and i need to rotate my particles with player's rotation, this is what i have so far, but it doesnt rotate:
Lmao @ Piss
you mean set it's initial rotation or actually follow the player
follow the player
dont ask 💀
Hi, is it possible to create a character/Avatar customisation system using the Ready Player Me SDK buy doing the image upload within Unreal Engine?
Hello guys, I am using Physics to move my pawn and I have an issue:
the pawn flips when Pitch hits a certain value. I have set bUseControllerRotationPitch = false.
Any idea ?
I would to limit the rotation up to the point where it might flip (to avoid flipping)
clamp rotation on tick ?
Is there any reason a newly created player controller would not be able to move? I’ve got physics turned on and it’s also got it’s collisions set
Also I think clamping it might help
Well physics is 1 thing and controller rotation is another. So if you use physics, it will do the physics thing.
If your pawn has a physics asset, you can increase the dampening to prevent or at least pseudo lock the rotating
in game or after you start?
it's just that I noticed that If I leave this setting on the controller the applyforce/impulse doesn't work
I do have some dampening but I want to keep it at its value. Dampening is not an option in my case
why the controller? you should do that on a pawn or something
I do that on root component of the pawn that is physics enabled
but applyforce is done in the controller though, on the component
Like when I press start, it will be affected by physics, but not the inputs
and that's why I have to change those settings to make it work
sir yes sir
you use terms a bit incorrectly so I am confused as to what you are doing
no worries, thanks !
Lookup function (bUsePhysicsMovements = true), Pawn hierarchy: PhysicsComponentToUse = CollisionComponent / Settings for controller in code (yes, that's on the pawn, sorry)
last screenshot didn't work
is it okay if i run an interface 20 times per second?
it retrieves all gameplaytags on a given actor
make sense boss ?
also, for some reason applying the force on the collision component rotates everything under it, but not the actor himself
the rotation of the pawn is always 0 while rotation of the collision component is changing
not sure if that's a bug, a mistake from me, or something else
so I'm just trying to use the capsule's forward vector to affect the movement input
but even when I fully replicate the third person template, it won't move
this is the capsule's details panel
@zealous moth
Are there blueprint nodes for calling out to an API and returning the response?
Calling out how?
Is that a plugin? (it is https://www.unrealengine.com/marketplace/en-US/product/varest-plugin?sessionInvalidated=true)
I would bring it up in the #cpp channel since I am not sure what the repercussions would be of hardcoding it that way.
Well it's the same as doing in a BP
Does anyone know how to toggle visibility of a static mesh in a array using collision. I have a array of static mesh cubes and a animated cube that collides through them. Id like to toggle the visibility of only the mesh in the array that the animated cube come into contact with.
Just that I do nothing in BP except tests mostly
Is the pawn supposed to flip ? Because it doesn't feel normal at all :p
I read using the controller fix the issue but with forces ... Not sure
Is it bad practice to have something like this on the event tick
since it constantly is checking
I can also put it on the end of anything that deals damage so it only checks when player health is changed
but then this big chunk is gonna have to be copy pasted a million times into a bunch of different things
so which is worse for performance? Having it on event tick or having it run this health check everytime player health is changed by something (something being like a bullet making collision with me or i use an ability that does self inflicting damage)
or if this has been asked before point me to the thread. I checked but the way Ive seen using on begin overlap I cant get to work with a array
Put it there as in at the end of everything that deals damage? And I can’t make it a function cause functions can’t have delays
Hey, you could have a collision sphere / cube with overlap, and get the list of the actors, then apply the sethidden setting
I tried that maybe I didnt set it up right
onoverlapbegin and end would be your triggers to hide / set visible
probably
both colliding elements must be at overlap
if one is iignore, nothing will happen at all
I can do this to a single static mesh but its doesn't seem to work with array. Even if I get all children component of the array it just turns them all off. Also I cant set collision for array like I see people do for this set up
I'm still learning but is something like this requiring a construction scripts?
Question: I have Point A and I need point B to move to point A a little at a time. Not using pathing. What does the math/blueprint look like for this?
Have the cubes as separate child actors
get world location from point A and use move component
Then you'll have access to all actors stuff
If a blueprint is executing will you always see the connectors fire off? When you simulate
@onyx frigate they are separate child actors
but it ask me where to move it to, I don't want to tp to the A, I want to move 1 step closer, then another step closer the next second/click, what is the math on having 3 cords at a, and 3 cords at b, how do I get the locations between them to move to. How do I deal with negitive cords too. So I'm -100 on z. Vs z 100
@bronze quiver No.
Generally the debug object isn't set.
As long as it is tho, it will
@teal talon You could get world location from each point and use a distance 3d to get the exact distance
thank you, I didn't see that in the options.
@onyx frigate
this does not recognize the individual mesh of the array. And if I try to add a index or set visibility before collision happens it breaks
im trying to just move the camera up/down and not the entire character but i need to clamp how far up and down
You need a for each loop to iterate over the whole array
right now the camera can do a full 360 lol
@tawdry surge a for each breaks it
wdym
if I place a for loop between get children comp and toggle vis nothing happens
but I remove the toggle works but just for all
i think you @'d the wrong person but lemme look lol
I did my bad
@warm terrace do for each in array
Hey guys, simple question: is it bad to place a loop within a loop?
In BP, yes
Hmmm, okay, so how should I be implementing something like this? (This is an event begin play, where I'm checking if the light (self) is connected to a light switch - and if it is, to match its on/off state:
(the first loop is getting all light switch actors, the second loop is running the array of lights attached to the switch).
Guys I wanna make blueprint node that helps me move my character forward without physics
I am currently using this do you guys have any better idea
and also how can i increase my float variable over time? I wanna make like an endless runner and the speed increases over time
should inputs be in the player controller or the character
player controller
understood :)
wait, did anyone actually answer my question? Sorry if I missed it
im just trying to get my camera to move and not the character
so im tryin to figure out where to put my inputs
@unique turret I'd make an event in the light switch actor that sets the visibility on all of it's lights.
@pale flare is use control yaw turned off?
Lemme send you a screenshot from my old project
its turned on
Turn it off
thank you
i think its workin
anyway to change where the player controller camera spawns
Hello friends
I would appreciate an answer
has anyone sample a render target on a procedural mesh grid? if so, how?
Use other actor from overlap
Not your array. You want the one overlapping
@pale flare if you have a camera component attached to a spring arm in your character, you controller will automatically set your view target to that one
basically if i attach a camera i can no longer look up or down
if there is no camera everything is perfect but my view is in the com
im sure its probably a simple fix but im struggling lol
Did you do the up and down movement logic?
Is there a good reason I can't reparent an object to an actor?
just the basic stuff
i tried just rotating the camera
Yeah.. that should work
which worked but my camera could do a 360
lol
id prefer not to be able to look behind me like a horror movie
You can use the camera manager class to limit that
It's assigned in the controller's details panel
gotcha and the camera will inherit that?
i did this but the camera still does a 360
so when i do that the camera cant go up or down at all
The camera component should be using control pitch and yaw in its details panel
how do i have an event constantly checking if i am less than 1 hp
Why not have a setter functions that checks if you're less than 1 hp?
im still learning so to me as far as im aware i dont know how to have the game know i fell below 1hp without it being a tick or checking after every time i take damage
since its something that needs to be checked constantly
Are you using Event Any Damage?
Surely it only needs to be checked when hp changes ?
@pale flare use pawn control rotation
when you take damage make it check your health
oki ill try
have that now. Wanted to make sure im having it all setup efficiently as to not waste resources or make it more intensive
thats what i have now
ill resend the image
On your Event Any Damage you can check the current health to see if it’s equal to 1hp.
i believe that worked
Use Apply Damage and Event Any Damage
so event any damage will trigger anytime any damage is dealth with the apply damage node?
yeah try to have as little as possible on event tick
It's not a problem having things on tick. It's a problem of having a lot of things on tick.
Yea basically
yea i havent tried that but ill look into that
this all just kinda makes sense to me what i have now
trying to take it one step at a time
but ill try and learn those events
thanks guys
You can also add health by using negative damage for like a medpack item
here is a very simple way to do it
Anyone know a way to easily clear the localization cache? Seems we're getting some weird BS happening with old text caching.
There’s also other useful nodes like Apply Radial Damage for an easy to setup area of effect. @neon spear
^
How come I can't find a for loop node in BP lol
show me what is to the left
Seems to only happen on widgets
chances are it is triggering multiple times
so the reason could be that you are setting your health to the "explosive jump recoil"
after apply damage remove set cur hp
this apply damage box
doesnt even know what my hp is
right?
should i attached my current hp to the damaged actor circle?
so basically the apply damage sends a message to the actor saying hey here is some damage
well the actor technically doesnt have health
and your actor has the node "event any damage" and it spews out the number
i think the problem is then
all it is, is a message basically
tater is right. you are setting current hp to the damage amount
okay ill try and fidget that
yea i did that but i think i mustve missed an earlier earlier step
cause how is the event supposed to know what my health is
all i have is a variable called health
that isnt connected to the apply damage thing
make sure your health variable's default value is 100
Your health is the health variable. What's the problem?
When you take damage, set health to be equal to health minus damage, then check if you're dead.
okokokok that was my first time using that
i got it all now working
i didnt know at first that this was what told the game what my health was
i didnt have that setup right
thank you thank you all
@neon spearYou can just give your variables readable names. CurrentHealth is better, a year from now you might be scratching your head trying to read some of your variable names.
event any damage and apply damage are all connected without actually being in a line and when any damage is detected from apply damage it is to subtract that damage value from your current hp and apply it to your current hp
thats what i didnt get
at first
youre right i was following guides but i should just do a neat consistent way to understand it all
even if the text is slightly longer
Hence my name. They're ok for when you have no clue what you're looking at, but as soon as you can, try to do something tiny on your own. You'll learn 100x faster.
i learnt basic hud stuff
some doors and collision overlap
delays
emitters player lcoation sound stuff variable stuff
im trying to make a mini game with what i know
and make stuff i dont know how to yet
thanks for the advice
Hello friends
I would appreciate an answer
has anyone sampled a render target on a procedural mesh grid in blueprints? if so, how?
If it's possible, it's super duper hard and C++ territory for sure. How big of a render target are you talking, and how often is it changing?
wait
are you talking about using the render target data for CPU stuff, or just sampling the render target in a material ON the mesh?
i want to loop through the vertices on my procedural mesh and offset them based on the height values in the render target, no materials involved
There's a GetPixelColor node, good luck, it'll be slow.
oof
If you figure out how to get the render target data back on to the CPU for gameplay purposes in a simple and fast way, let me know. I started out thinking about doing that for my field of view mechanic but am now going in a different direction.
sure ill let you know
@dusk dustFrom all my research and dev on it, GPU -> CPU for gameplay is a non-starter. You'll need to get deep into the weeds in C++ to get it even somewhat performant I think.
I'm not aware of an engine where it is. Old article but this can get you thinking about the approach.
https://michaeljcole.github.io/wiki.unrealengine.com/Render_Target_Lookup/
A static site pulled from the internet archive
Hi! does anyone know if there's a way to run some event/method when game instance starts?
I want to populate some variables on the game instance, like "Player settings".
I can populate them when the controller of the main menu starts, but it makes more sense to let the GI handle that
Thank you, that worked really well. Lots more to do, but you rock solved a frustrating issue.
how do you async load a streaming level in BP?
i tried this:
and it doesnt make it visible after loading
oh wait nvm i see what's going wrong
Hello BP gurus, how does one get a blueprint editor utility actor to tick / update in the editor realtime?
I've tried the timer with a call in editor function but the official docs say that BP utility actors don't allow call in editor 😩
Isn't Editor Utility BP always run once?
Hey, I have a hopefully quick question. I have an AI with a Widget Component. In the AI I am specifically setting rotation on owning client to face the player camera. The component is not replicating, however, the rotation is still replicating to all clients. How do I stop the Widget Component from replicating its rotation to all players?
But this requires cpp, if you are comfortable with it, it's basically a solution
Ooh awesome!! Thank you so much!!
Is this an error that'll hurt me? I don't want any, but whenever i use this function on nothing it returns this error?
Nothing breaks with this error
its nice to avoid any errors even if to make it easier to debug later on.
You could do a check for valid.
ope yup
I added another branch for the return value on the line trace so it doesn't execute no matter
whoops
Ey, when i spawn my character, it just falls over 😂
is it better to create widget designs custom in photoshop or something including text and then just use them on buttons in widgets or use designs from UE itself. For like simple texts like lists of items what is more common ?
You usually design the icons and borders outside UE as textures, but use everything else from UE
Specifically since UMG is meant to be used with lots of custom widgets that can be reused by exposing parameters. E.g. a button with a text that has the text exposed
You import them
like i have to import fonts so is it just better to design the enter UI outside UE and then just put invisible buttons over it ? @surreal peak
Despite the graphic part of the UI, stuff should be inside ue
Text and fonts specifically so you can properly localize the text and ensure your font actually supports all the different languages
Again the only stuff you'd design outside is maybe a mockup and then the actual graphics. But everything else is usually ue
alright thank you
If I have an fps and I want to have a line trace in the direction of the players input rather than the character's forward vector, is that possible to do?
I might sleep soon so if you have some info for me let me know
Depends on what your goal is, but to answer the question directly: Acceleration on the CharacterMovementComponent can be normalized, which results in the InputDirection.
thank you, i'll try that and see if it works in the morning
something like this then?
not sure where the end is supposed to be, I need it to be a certain distance from the the player in the direction they're holding.
Yeah that should work. Not sure if the acceleration is sort of invalid if you deactivate the CMC or stuff like that, but I would start with this.
im going to add some fixes and see if it fires correctly
That's always the same boring math.
Start = GetActorLocation
End = GetActorLocation + (Direction * Length)
Length being some float or double variable fwiw
does my math look right
Yes
45 is a bit short, but yes
You can simply use the debug draw mode on the line trace node to make sure you are doing it correctly
How do I set the rotation of a 3rd person camera to a given rotator? I'm working with UE5. The internet says that UE4 has a specific command, (something like "set control rotation,") but no such command seems to exist for UE5
Context: I'm trying to get a 3rd person camera to rotate around the character so it always keeps the player between it and a set point.
I have an actor component that implements an interface, and Im trying to send it a message via this, but it's not triggering
(this is in an actor component)
is there some secret I need to send interface messages to actor components?
it seems like the first set of nodes should realize the actor implements the interface via the actor component
(Set Controller Yaw Input doesn't work for what I'm doing, I tried deriving an amount I need to rotate the camera by and plugging it in, but it multiplies the input by some odd amount that I can't seem to access in the math)
(Camera booms don't rotate, apparently, and rotating the camera just rotates the camera around its own, personal axis, obviously, and attaching the camera boom to an added component like a cube doesn't do anything... I can rotate the cube, but the camera and boom don't rotate with it.)
(This seems like it should have a REALLY obvious way to do what I'm trying to do... all I'm doing is trying to reorient the camera. But nothing seems to work.)
Hi all!
I have an instanced material with some exposed parameters.
I want to be able to change the values of said parameters at runtime.
So far i've managed to change the color with an keyboard input but i want to complicate things a bit.
I want to have 4 keys for each parameter so when i press one of them i will then be able to change that value with + - buttons for example.
So it should be something like.. if key 1 is pressed enable control of param 1 with + -, if key 2 is pressed enable control of param 2 with + - and so on..
This is my first unreal project and this sounds like a fairly simple thing to do but i'm unable to find a suitable tutorial : (
Can someone help explain why this BP keeps screenshotting an extra random photo?
i.e. I have 3 cameras but end up with 4 screenshots.
Guessing it's because this actor variable doesn't have a default value of my first camera but I can't seem to change this default value. It just stays as "None"
Just tried to grab the controller for player 0 to try to rotate that aaaaaand it killed Unreal engine dead. (Something about a render error.) Which also took discord down with it so now I'm on my phone waiting for discord to open. I am frustrated and hungry and am going to go eat.
No idea why something as basic as rotating the players camera around the player is so unintuitive. I've tried everything ----
I've tried the command add controller input yaw (or something like that,) but I can't figure out the math for how to get it to move to a specific angle, (presumably you would add the difference between the float value of the current rotation and the desired rotation, but add controller input yaw multiplies whatever float you add in by some number I can't find anywhere.)
I've tried rotating the camera boom, but I guess they dont rotate. (Rotating them in the component viewer does nothing to anything else. Apparently all the boom does is change the cameras location to keep it from intersecting things.) I've tried moving the camera manually, but the camera does weird stuff as the pawn itself rotates.
I thought about removing the camera from the player and making a new pawn for it that follows them, and I might still resort to that, but it looks like a nightmare of it's own, (I'll need to figure out how to make a pawn spawn another pawn, would should hypothetically be easy, but while I havent looked it up online l---- I got distracted by my new idea for a way to rotate the camera --- I couldn't find a relevant command on my own.)
I've managed to rotate the camera around it's own axis, and move it around, but its motion is bumped around and the pawn's movement, naturally, so that's a no go, unless I want to somehow adjust for that, but that seems like itd be very inefficient and clunky...
So I'm about at my wit's end.
Sorry for big paragraph
if i have an actor like a widget in which i want to make some variable is there a way i can keep track of the variable if the widget gets destroyed
Store it in a variable in another blueprint. Such as Game Instance or possibly game level. Depends on what you might be doing.
alright
For example, I have a volume setting that I need to remember from a Main Menu. The player may go press pause while playing and decide they want to change that volume on that pause menu. So I have a variable that stores the volume level setting in the Game Instance.
@golden garnet just outta curiosity has anyone suggested you take a look at this?
https://dev.epicgames.com/community/learning/courses/kry/build-a-third-person-character-from-scratch/mDv/build-a-third-person-character-from-scratch-introduction
No, but I'll take a look. Sorry for being frustrated, I was feeling hangry.
@cosmic kelp i made a separate bp. how do i reference the variables from that? do i cast or just create a variable of that bp
Either one will require an instance/object of that other bp
It won't just get it from thin air.
i referenced it by creating and obj variable of that bp but its not storing the updated data of the variable
Hello. Sorry to bother, I've been looking around for this for quite a while now and I haven't been able to find exactly what I'm looking for, so I figure i'd rather ask more experienced people who have certainly come across this situation.
I'm studying the Blueprint method in Unreal and I decided to give it a try and create my first prototype. However, for the kind of game I want to build I will need to create arrays/data tables similar to the one on this image.
This can be commonly found on .dat files as well, where tables of data are structured like this. However, after looking at blueprints, I noticed it's impossible to layout an array like this.
I've also looked at Data Tables and Structs, but apparently theres nothing like this, or perhaps I've been looking on the wrong place. What BP would I have to use to lay out a structure like this?
Create a struct that defines a row.
Create an array or data table that defines the table.
How did the array/struct combination not do what you want?
I haven't gone to the combination yet. But in C# for example, I can create that array directly, as you can see in the image. So i was looking for a direct counterpart in Unreal Blueprints. I noticed that by creating an array you'd only get 2 colums: ID and whatever variable you set.
Maps only allow for 2 columns, as well as data tables, so I was wondering what i was missing, or if this is was a limitation
I'll certainly give the combination a go 😄
@next zodiac you are talking about an array of structs
if you want to do this in blueprint, create a struct with those headers, and just make an array of them
this Item_Data is also an enum
thank you @mental trellis and @barren flower
I'll looking into the structs + array combination 🙂
This is what you want
Okay gang, now I have a question. I'm importing over a thousand meshes, and its slow as heck, like 14% over 3 hours
Each mesh has a ton of materials I think is the problem
is there a way to batch import this stuff, rather than relying on unreals importer, which seems painfully slow
For static data like that, you really do want to use a data table, though.
There's probably a plug in but it won't be free
guys I have a Map (dictionary) and I would like to sort it by the values... how can I do that?
Im not sure if this is part of the extended library plugin or vanilla
but you can can drag off and get just the values, and then plug that into a sort node
If you are talking about like, actually re-ordering the map, the point of them is that they are unordered and thus extremely fast to access
You would in that case need to create another temporary map and do your own sorting algo. Loop through and find the smallest, then add that to the new map then the next, then the next, and keep looping till its sorted
ok
any idea how i can get this to work?
the point is that after that I need to loop through them and I need to have them in order
I have to save the player and his time in it
Hi, how can I transform an actors movement so that it only moves along one local axis of another actor? Like it is tied to the local rail of an actor but can still move freely along it?
If it's a small map, it really makes no difference how you do it.
Can't disable collision for HISM
- I disabled it in code
HISMMeshComponent->bDisableCollision = true;
HISMMeshComponent->SetCollisionEnabled(ECollisionEnabled::NoCollision);
- I removed everything related to collision in the asset
What's going on?
what do you mean?
try "get owning actor"
instead of get pawn owner
Just grab the values from the map, sort them and loop through that.
Or create an array of structs based on the map, sort that array and look through it.
How many entries are you going to have in this map?
I am asking how to sort them
Do arrays not have a sort function?
may vary
no idea
-.-
Should be free last I checked
who knows why its not included
Most people do such in cpp
PredicateSort in BP. Neat.
Pry cuz container sorting should be in cpp
It can get quite expensive so not much point to doing it in bp
So sorting that array, even with the worst sorting algorithm in the world, is not going to be expensive.
Get that plugin ^
yeah ok, so I'll need to make my sorting algorithem
You can just get the plugin too
yes
Then you need to convert your map to an array of structs and then sort that.
Or you will lose your associations
Unless you sort the keys, not the values, and use the map's key/value pairing in the sorting predicate
I think I can use a find(?)
Or just use a regular float array, and just assign each player an index number that corresponds to their time
E.g. Sort(A, B) { return Map[A] < Map[B] }
What will that solve, MW?
If you sort the floats, you're still going to lose the index association
well... if I sort the array... I'll then find the Player that has the same time
Arrays are sorted. If player one is given index 0 then I just need that
Arrays are not sorted.
They can be.
Not sorted. I meant they don't change positions
But if you sort an array of {1,5,3} you will end up with {1,3,5} and now player 2's value (5) is now wrong (3)
Either way, you need to sort the keys or an array containing both the keys and values
You can track who owns what data with tracking the index rather than having a map and doing a bunch of work to reorder
Find will search for a specific value, not really useable for sorting
That's exactly what his map does, it maps player to value, you don't need an index with a map.
I know... but if I sorted the time array, I can find who had that time that way
And it would not solve his problem
That is true, @jovial lagoon
Unless 2 players have the same time.
Then instead of player 1, player 2, player 3 - you will end up with plaeyr 1, player 2, player 2
true
It's not that complicated use a struct and write your own sorting algorithm.
but unlikely
Because unlikely bugs you can foresee bug ignore are fine?
not saying that
I'm still fixing it
Get your array of keys (player references, I assume)
And then sort that list based on the value in the map
When you compare Player 1 and Player 2, actually compare the values in the map associated with those players
I mean
I'll have to change the positions of the players also, using the sort of the times
You would sort the keys array (which would not change the map, the map generates an entirely new array and gives it to you when you ask for its keys)
This is why sorting tmaps is bad
ok, ALL OF THAT finally disabled collision
variation.MeshComponent->bDisableCollision = true;
variation.MeshComponent->SetCollisionEnabled(ECollisionEnabled::NoCollision);
variation.MeshComponent->SetGenerateOverlapEvents(false);
variation.MeshComponent->SetCollisionObjectType(ECollisionChannel::ECC_WorldStatic);
variation.MeshComponent->SetCollisionResponseToAllChannels(ECollisionResponse::ECR_Ignore);
Even though ->IsCollisionEnabled() still returns true, but that is fixable
I think that's enough unreal engine for today...
I know it is
But I didn't want to change it, so I was looking for a solution
but ok
It's cool. You have a very small map. Optimising this part and screwing over your other code is pointless.
Just go with it.
thanks
Hello everyone
I just recently started learning UE5 and was scrubbing through the advanced locomotion system
I have a super weird issue. In my game players can take a seat in a lander craft to go down to the planet and back to a space station. The system uses possession of pawns (seat is a pawn). When the lander craft reaches the planet surface and you leave the seat it works perfectly. But when the lander craft goes up again to the space station and I leave my seat my character is suddenly teleported a huge amount up in the Z direction. Now I've tried everything I can think of, turning off all of my code, trying different ways to have the character leave the vehicle, but every time when I reach the space station and leave my seat my character is teleported up. I suspect it has something to with the character movement component we use in our character (Unreal default). I'm thinking it may have something to do with the ground check or whatever. Does anyone know what could cause this?
I just wanna know how to create the node on the top without creating 2 nodes like on the bottom
Right click the pin on movement model
Split struct
ah thanks
How do I make AI charecter to move
I wrote a script and it works, but for some reason the character itself is just stuck to the same place and not even falling down
So how do you know it works?
First of all, I got it from a tutorial because i needed basic info on how AI works
Second of all. It runs input and returns output through successfully
First of all, have you give it navigation meshes/invokers?
I have no clue what that is.
You mean the target mesh it will move to?
That's the missing piece of the puzzle.
Basically them AIs use navigation meshes on the map surfaces so that they know where to go to other location.
Great and how can I do that
You have a nav mesh in the level?
no, idk how to add one
Place actor panel
Nav mesh volume
where can i find it
Hit p on the keyboard to show the visualization.
It's in the place actors panel.
Search nav mesh volume
where do i hit p
nvm
i found it
thanks it works
how do i add animations doe?
Hey guys, in today's video, I'm going to be showing you how to set up and create an animation blueprint and blendspace for your characters in your game in Unreal Engine 5.
Mixamo: https://www.mixamo.com/
Directional Movement: https://youtu.be/OSWX3vEgRcE
#Ue5 #UnrealEngine5 #Ue5Tutorial
________________________________________________________...
hey guys. i have run into a snag and im not sure how to get around it. I am trying to create a bp_controller to use as a single control setup for multiple pawns (characters with different skins essentially) I currently have input controls from gamepad axis to control the movement but i cannot find a way to output anything from inside the controller to the controlled pawn. everything i have tried to put in says "target self is not a pawn" (which i know it isnt) but i cant seem to find a way to define a pawn. even dragging the pawn itself into the node editor didnt let me set it as the target. I dont want to have to create the entire control code for every pawn but im not seeing any other way around this. the closest i have found is "get owned pawn" which only targets the HUD and still requires a defined pawn.
GetControlledPawn will return the pawn the controller is controlling. Is that what you are looking for?
loading it back up atm ive tried so many ways i dont remember if i tried that without looking at it
i think the getcontrolledpawn is what i ended up with in my current code without error.
which led me to realizing that the engine doesnt natively recognize gamepad inputs
ok this is what i had ended up with
movexdirection and moveydirection are the binds for the gamepad x and y axis inputs
everything else was named by the engine
i think this may already work but i havent been able to get the gamepad going to test it.
It does not appear to be giving them a direction. Try removing GetActorLocation from movex AddMovementInput, pull from GetControlledPawn and get ActorForwardVector and plug that into the AddMovementInput. If that works, remove it from the second one, pull from pawn and GetRightVector and plug into the second one.
the control is for a dual stick setup. left stick is up down left right not forward back left right. i dont need the characters orientation at this point. just its current location so that i can move its current location.
Fair, but by passing in GetActorLocation I would think you are not telling what world direction you want it to move. You are passing in the current location and a value to move in the exact same spot you are already in. I could be wrong, I have never programmed for gamepads though.
i was just seeing the same thing in it.
i got the axis to tell it how much to scale the movement but i see that it isnt telling it a world direction to move
It might be worth a test to use ForwardVector in the top one. This is the Pawn's X direction and not necessarily forward and back.
the get actor location is most likely a coordinate not a direction
ok so swap get actor location with get forward direction. brb lemme see what it does lol
The ole "Plug stuff in until it works" method 😄
oooh
good find
oh dang...
mine wont work...
im pulling the forward vector from the inputs not the actor
although finding the 'make rot from xy' is lovely. going to allow me to combine the 2 axis into one input.
Yeah, you might have to cast it to a character. Sorry, feel like I may have confused the issue more for you.
oh... i dont need the actor's vector. i need the world's north vector...
I have a BP actor with bunch of static mesh components inside of it. No code. I need to decompose this actor, so to speak, into meshes back into the level, while retaining all transforms. How do I do this ?
and i dont need to define a direction if i hard code the add move to a specific value
sometimes simple wins out
this will scale the x direction based on the x axis input and same for y
i can make him move faster or slower by increasing or decreasing the x and y directions
now on to figuring out how to install this gamepad into unreal 5
thx
Im not sure how to word this on google but basically from where I spawn this will launch me diagonally to the right. With Blueprints is it possible for it to launch me to the right of where im facing as opposed to me being forced to look a certain direction in order for me to launch to the right ( i have mouse and camera locked together already) Do i add an invisible mesh to my character diagonally off of me that follows me and i can set it to launch me towards that mesh or something? If its too complicated to explain I can research it on my own I just need to know what to type in. Is this camera blueprints? ect
done ❤️
Hey all, I have a construction script for a flickering light BP, where I’m using a Random Float in Range for two Set Scalar Parameter Value nodes - one to affect the Point Light’s Light Function and another for an emissive Material. The problem is that using the same Random Float in Range node appears to output different values for both these Scalar Parameters. How would I generate the same random number for both the Point Light’s Light Function and the Static Mesh’s emissive Material within the same Blueprint?
Could set a local variable
Could you explain how, briefly? I’ll look into it also! Would this maintain the random per BP instance I need when placing multiples of this actor around my scene?
You right click on the output of the random float and click the option that says local variable. I honestly can't remember if you can or can't use local var in conscruction script, so if it doesn't say local variable just make it a normal variable. Works the same
then you get that variable and connect it to the set scalar parameters
Fantastic! It works! Thank-you, I’ll look into variables more now I’m delving into BPs.
Quick question, I plugged the exec from the Set Light Function Material into the Set Random Local Float Variable just after it - is this okay, or should I establish this local variable beforehand, such as after the Construction Script node at the start? Does it matter at all?
If it works!
How come OnComponentBeginOverlap doesn't detect overlapping with default cubes?
are you using box collision?
Maybe they don't have collision?
Hi, does anyone know if there is any difference in performance between placing meshes individually or using a spline tool to place them?
How do I save variables that are not of the player character?
What sort of variables?