#blueprint
1 messages · Page 352 of 1
if it's in 3d space just put a plane behind them with the relevant material on them. If the camera moves you can even have the plane move with it if needed. (might get some clipping issues though.)
Create macros and functions for parts of your code that you re use
other than that i guess get used to it
I am new to Unreal Engine, so I don't have much experience with this. I tried some things using ChatGPT and YouTube. Wait ill share the screenshot of it
See the first image, which is a minimized screen, and in that, see the plane on both sides stretched out of the window.
And see the second image, which is maximized screen, and in the plane is small compared to the screen, and I can also see the world outside
if the background fits perfectly, then I can fit my chat window according to the background image to make it look good.
are you playing in standalone or in a new window ?
It is not much code, yes, but if you ask in general
- stuck in mud and being in the water seem exclusive. Create an enum for them instead (easier to later add other possible states affecting walking)
- with an enum you don't need branches, you use a select
- before select you can use a sequence. So the first pin of the sequence goes into the select - the select handles state specific info. The second sequence pin continues to the general code that should happen after each state, no matter which one it was
for looking or testing, i am just using a standalone window
If you don't know how complex something will get you can always change it later when there are scaling problems. No reason to worry about when you just don't know yet.
New window will never work, it doesnt properly scale ui elements no matter what you do
Use enum and switch state
If it works for standalone that's also fine, mainly that works when we packed the project
any ideas on how i can fix this? rn the issue is when trying to add the new ids to the struct’s string array, it dosnt save properly/set properly and on reloading is back to being empty https://blueprintue.com/blueprint/ordd0178/ https://blueprintue.com/blueprint/2v24ecfh/ https://blueprintue.com/blueprint/whwljuzl/
I can't access BlueprintUE due to the online safety act. 🤣 (Not sure why it needs age verifying but hey) Can you share a few screenshots?
It's because of all the swear words included by disgruntled developers /s
#X#** this #X#** function and #X#** this #X#** event too, this #X#** function here is a piece of #X#** it adds data in our #X#** struct but it bareley works because whoever coded this is a #X#**
yea ill get a few once im back at my pc, thats so stupid n so funny that its blocked😭
So in here. Ok, you at the start assume that ever clip should be initialized. It's good. So for each pickup, you initialize it, but then
Startingroom of the clip if it's self? Roomamanger.. ok so It's roomanager checks if any of the clip should be added to that room count or something like that.. ok
and t hen there is 2 more checks IsClipActive (please fix namings of your bools)
If Clip Is Active AND the Player Save doesn't contain that clip then add to Clip Pickups for that manager I guess and Remaining clip count +1 for each.. okay.
On the second photo, you are literally just passing the array to be like Set This Array to This.
You need local variable for that array. Add to it. then plug that local array to the struct.
can composite data tables be composed of other composite data tables or it needs the regular ones to work properly?
AI is scary. It managed to code C++ plugin for Blueprint so I can bind On Actor Move. 1st try, no mistakes. Exciting and scary.
That only works for simple code
Ai totally breaks for more complexe stuff
But oh well give it a few more years and it will also do that without problems
The actual amusing part of this is that it only does this if you don't guide it. It's perfectly capable of creating and designing large complex systems. But you have to lead it step by step. It works out rather well if you yourself are trying to get into a concept without wanting to dig for the material yourself. Because you have to go slow and step by step, which makes it do the same.
I would also caution this to some degree unless you're C++ familiar. Seen a few people get themselves pretty stuck. 😬
Maybe if you do baby steps
But outside of unreal for c it wrote me some of the worst code i have ever seen
Like style, or logic?
For example it created me a 3d array for something that was perfectly doable with a 2d array, it didnt free any allocated memory and put no guards whatsoever in the code for malloc
Hi all. is there anyone who could quickly help me with a blueprint in vr. I am trying to make something work for a month now but I cant seem to do so and I have the feeling I am very close but since I have 0 prior experience with vr and BP's I would be extremely thankful if I could be in touch with someone to whom I can show my project
I'm using AI for JS and CSS at work, since I often need small things and can't be bothered. One dumb example was that the ai created a DIV element, but gave it a name LI. Then proceeded to treat it like an LI, breaking a bunch of stuff that was expecting list elements, not divs
I can see that happening.
So it works for selfcontained tasks, but you still need to check the code
Well whats your problem? Sharing your code here might already do the trick
Many vibe coders would say otherwise 😂
Makes sense. I guess ok as some introduction. I was just expecting it wouldnt be able to do even this stuff.
How is your game going btw i watched your stream here and there a while ago you were creating a farming game
Oh, I was thinking the name sounded familar. I started and abandoned two more projects since then. So it is going well 
Yeah. I know that from other examples. Doing C++ and not knowing enough about will allow AI to slip through with bad stuff, huhu
Haha i cant count how many projects ive abandoned already
Yes so I have a simple cone I want to change the material of when I click on a swatch. I am using tags and Gemini pro 2.5 to help me step by step but ofc it gets it wrong. I had a ex colleague of mine who told me the approach he would use but I am confused with the lingo a bit. I will put the message here: "Trace a ray, check if it hits a component that contains the material, save that material as a variable, and then send it through the interface to the object that should change."
Are you still streaming?
I already tried to debugg and I know the trigger press works (left trigger from the oculus)
I'm planning to once I have base systems for the current project in place (chill tavern management). Buuut it is probably not the correct channel for this
You are like 90% there
What would you suggest I do to make it work for sure? I am using component tag since the swatches are attached to a rotating disct (which rotates around the player) and I thought that would be better than the actor has a tag since it would reference the disc
If i understand the code correctly what happens is this
If you press the button on your vr controller you call this function correct ?
I thought it would be triggered when this button is pressed since the "Activate Selection Trace" runs constantly through out the "game"
i see
Alright so to what material do you want to change the cone ?
Like do you want to click on cone 1 save that material click on cone 2 and apply that ?
so this project is a vr configurator, and I want to change the cone which is a placeholder to the material on the swatches. Since the materials will be specific for the configurator, I will scan them from the client and add them on the disc. Then when the player hovers over a swatch > trigger is pressed > the swatch material is applied to the cone
Where do you set up the material on the swatch?
these ones are imports from megascans since i still dont have the final rl materials
so they use the paretn framework for materials
and are all instances
my initial thought was that the issue could be the "SC_Selection_Trace_Left"
this is my actor selection BP
You most likely never set 'OutHits'.
Also, the access none message is because the static mesh component is null, not the material. You probally don't set this either.
All you really have to do is this
on your trace you check for hit actor (your cone)
Either by comparing the class or checking for a interface
if that returns true you have hit your cone
im not familiar with this node picture 1
In your cone you implement the interface in the interface you add a function to switch materials and a input fo your swatch
Also what is this supposed to do? Is the 'Hit Actor' interface event implemented on the components its getting?
In your cone after the switch material functions from the interface fires you take the swatch reference get its material and then you set cone material to that
Comfyui came out with a tool that would be a great addition of ue5's user interface. Imagine not having to click and drag to seek around large blueprints, but instead just drag a small box that represents the current view around the large blueprint.
@last peak @dark drum Thank you both for the explanations but I am afraid this is beyond my understanding.. its a pity I got this project since i am the UE Cinematics guy in the office and now im in this jungle hahahha
I understand the language just fine, and even I'm confused by what your ex colleague meant.
One second
Might be okay. But I'm not sure how much real use it would get. Usually you can navigate to pretty much anywhere based on the function list on the left.
Material graph on the other hand. That could use that for sure.
First create the interface picture 2
You simply add 1 function in there and call it change material
Add 1 input there (either material or material instance or wahtever else your swatch material is)
in your trace function picture 1 you check if the actor you hit implements the interact interface
If yes you get a reference of your swatch and then you get its material
Now you call the function Change material and you give it the just extracted material from your swatch
In your cone picture 3, you click on class default and in the right details panel under implemented interfaces you hit add then you select your just created interface, compile
Now in your event graph you see the added interface function "change material" in your left side panel picture 4, you right click it and you select implement event
Now all you have to do is what you see in picture 5
In unreal if you are saving your game and than loading it. You cannot save object references right? I would have to break that down into something like a struct and than save it.
yep
No
You can save object references. But it requires some very specific setup and C++ actor spawning or lookup to be able to replace them.
right, but in general you can't really do it.
Gotcha.
Im useing BP only so i can do a work around for this.
Then you 'can'. But it would be only to things spawned on the level. And you'd want to use soft object refs.
Er. Bad wording.
But it would be only to things spawned on loaded with the level
You need to serialize it 🤷
Guess you could save a id and relink later on
If you use C++, you can save pointers. They serialize as pathnames. Which means if that thing exists when you put the data back, it points to an object.
The general trick is to respawn everything with the same names, or look it up if it already exists. Do this for every object you've saved.
Then now that they all exist, serialize the data back into them. They all exist, so all pointers saved will point to the correct thing again.
Is that faster than just breaking everything into structs? ngl its quite annoying to do that
Mannn thank you so so much you have no idea how helpful this is! I will try this now and see if it works! One last question since your line trace bp is a bit different from mine, should I change the last nodes as per your suggestion and keep the rest as it is or should I build it as you have it? I will let you know if it works but regardless if you ever find yourself in Berlin shoot me a message I owe you a really nice dinner!! ❤️
Just replace everything you have after the linetrace with what you see in the picture everything before that is fine
Lets wait with the dinner untill it actually works 😄
How do you mean by faster?
Like to work with, or to process?
Right now when i want to save something i get the actor and then i pull all the data out of it
Location / transform
All variables that need to get loaded like current health, stamina, mana etc etc
If i could just save the entire ref that would spare me a lot of work
are you talking about a physical switch like a keyboard or something?
@last peak so I did everything as you suggested but I am a bit confused as to how I can add the blue swatch node on the line trace BP 😅
haha no its the material boxes in front of the cone, they are simple virtual material swatches
ah
You need to get a reference to your swatch
I also added the change material interface within the "does object implement interface" node*
ahh make them variables right
I dont know how youve set it up
What is your swatch? is it a widget? a 3d object?
Ok so
get all actors of class leather black
plug that right before you do change material
1 sec
That's how the system works. 😄 The Savegame flag. Anything that has that marked in BP or C++ gets serialized. Anything from ints, floats, strings, names, text, pointers, etc.
And it works by just serializing the UObject. So if your stats exist in a single component for example, you'd serialize that component and then replace it when loading.
line trace by channel -> break hit result -> drag out from hit component -> get face index -> then right click graph and bring in the get material from collision face index node
there might also be a get material from hit comp also but i don't have ue5 running right now to confirm
he wants to grab his material from his swatch then change the cone that he hits to that material
yup there is
@lucid ore
Do you want to click on your swatch first and then suck out that material and apply that to the cone as in do you have several swatches or one single one ?
Hey guys, I have some errors in my code that don't affect gameplay and I'm not sure how to go about fixing them. One involves one of the UI systems and the other has something to do with spawning players in.
Do you have 1 single swatch or several ?
That you change on runtime
no I will have approx 25 swatchews
Ah crap
yeah I realised that this would work with a single one
or that multiple will result in a issue
Ok not a big deal then do what Cecil said line trace by channel -> break hit result -> drag out from hit component -> get face index -> then right click graph and bring in the get material from collision face index node
How is your swatch actor setup does it have a parent ?
Swatch base actor -> leather black child
they do have the disc as a parent since the disc rotates on controll
and they are movable
you can then set an interface on the cone actors and have a boolean that enables or disables the application of the material change when you click on one of the swatches
that'll handle being able to set an arbitrary number of cones at the same time
He needs to check if what he hit is a swatch first after the trace, no ?
no, the cones will aways be listening for the event to fire off, which won't happen until you select a swatch
He has a linetrace on tick without any check
This was his original
ah ffs, how big is your project ?
And what unreal version
I guess he has a component with interface on the swatch and that executes the material change code ?
It confuses me hardcore
its only 2.38gb ue5.4
idk, there's a million ways this can be done. each one fitting the situation more than others
i apologise for the confusion :/
i am also so confused never done such projects
its driving me crazy
Its just that im not 100% sure how its set up
i only have 5.5 and 5.6 :/
Otherwise i could do it on my machine
Does your swatch have a component attached to them ?
- a interface
No nothing
This one is it added to the component in your swatch `?
besides the ac_actorselection which is used for applying a overlay material when hovered
the swatch being an actor, would probably have a static mesh or cube in the blueprint that the material is set to
yeah I tried doing it on 5.6 but it had a lot of issues with the TAA and everything looked like it had vaseline smeared on ot
Yes sure but what he does here
he gets the hit actor then he cheks all components who implement that interface
Then he calls hit actor in one of the components
Youll need to disable the "Play on Open" option within the Bink asset and manually open it whenever desired
Ok 1 SUUUPER simple and fast but dirty fix
Create a new interface, call it "swatch interface"
Add it to all your swatches in your case now to leather black
Tell me once youve done that
Create a new one and call it Swatch Interface
Dont add anything into it just a blank interface
Restore your first trace bp to what it was originally
This is where it continues
Open the interface where the function "hit actor" is stored it should be bpi user interaction
Add a new input to hit actor
Type material(or whatever your swatch material is)
the very first one right?
Yes
i added the interface to them all
The one you had originally
oky give me 1 min
XD i think that was useless sorry lmfao
But we should have it now ive send you on a goose chase
done
haha id take this every day rather than gemini telling me 20x per day "youre right to be frustrated, here is the final solution"
so i open bpi right
yes and you should have the function hit actor in there
Click it and add a new input
Details panel bottom right you have to scroll all the way down
yes what am i looking for
Try Material interface
done
compile and maybe name it swatch material
renamed and compiled
ahh it crashed, ill redo the last step quickly
and when i do this i do it inside the line trace selection right
yes
alright give me a few minutes I am so sorry
sorry my heads a bit of a mess now, how do I get the change material node again?
otherwise I have everything set up as you reccomend
ahh you said it before
i check it now
bcs now since i deleted the other things I dont have the blueprint interface change material
only the swatch interface
What we have now is Linetrace hit swatch - takes the material - sends it to actor selector component
Correct?
from what I understand yes correct
i am keeping the hit actor for the highlighting feature*
Lmfao
I wish i could take a look at the entire code haha 😄
Can you pack it for me? i cant send it back since i have to upgrade it to 5.5 but i would understand wtf is going on in the codebase
Dev
To be honest if I got no errors on the first packaging of my project I would go buy a lottery ticket
Right now im doing a rpg, i havent tried building it yet .... i dread the day that i have to for the first time 😄
At least cook it, thats what you should probably do intermittently after pushing changes and new features into the game
Or do you have a github where i can jsut clone it from ?
No i unfortunately dont :/
I will just zip the whole project with all its contents and send it to you
God bless
how should I send this?
Google drive ?
oky
or github or any other file hoster of your choice
alright gimmie a sec
Hello!
This may be a stretch since im using something from FAB but ill try and ask.
I currently am using this player, i converted it to top down from thuird person with controls and everything, but the issue is the player is looking at the ground.
I want the top down effect wherte the playuer ios constantly looking forward.
(This is like real early on its all placeholder assets from the fab item. its called ultimate chjaracters)
I can show the blueprints if needed just wanted to knwo if anyone had any initial ideas. I was thinking it could be something with the IA_look control but meassing around with it i cant figure it out. I also tried messing with some pitch variables but camera math confuses the heck out of me.
thank you guys!
It’s probably the use controller rotation setting on the character. Disabling the Z axis one should keep your mouse from moving his head up and down
thank you imma find it! its hard with it being something off fab cause its amazing i just thionking im doingh weird stuff with it
For anyone interested in this problem it was just a missing tag on the cone he wanted to change
hello all im applying an impulse to my ai and its not able to apply the impulse I simulate physics and etc but its not working. when i take the root physicsbody out of my physics asset it applies the impulse which is weird my constraints are good as well. If anyone can help that would be appreciated thanks
I can not get "AttachComponentToComponent" to work
I know for sure I am using that mesh and set it prior to attachComponentToComponent
how can i get something like radial force actor but directional?
Mh, what do you end up with ? Who is the owner of barrel and who is the owner of Carriage ?
Physics could be at fault here, I don't remember the exact conditions but I think enabling physics one Barrel after attaching will detach it for example.
You can try to tick "weld simulated bodies"
Yha I turned off physics and tried weld simulated bodies but no good. I went with diffrent route. Thanks for reply.
I use GetSocketTransform of parent and set relative transform of target
ive figured out its an issue with the spring arm, the player just isnt ignoring the pitch when al;l of the settings are checked is the issue so i gotta figure out why
On tick ?
No, its called on a function when cannon is spawned
I guess that as long as it doesn't move you're fine
@lofty rapids hi there
?
Hi guys i wanna make some tutorials but don't have any idea or topic, please suggest me some ideas
i don't see where you actual add impulse
its not that because if I remove the root body in the PA it works just fine
but i have to have it so they can stand up right
Well, what’s your expertise?
why is component not self ?
Multiplayer games/ replication, optimization
this is a component attached to a character, the component im passing in is the mesh
im getting the owner->mesh
Not a lot of BP-focused tutorials on optimization. Maybe make a hypothetical indie game that runs awful and then have a tutorial series cleaning it up?
Along the way you can make much more constrained tutorials on BP features that you use while building or optimizing
again this all works fine if i delete the root body in the PA, so there is an issue somewhere
in the ragdollstart function I do this
you have an npc ?
yeah
@lofty rapids works fine in the PA
and what kind of grab ?
can i talk in private?
It must be some proprietary npc grab system lol
That’s actually a great idea! I really like it, I’ll definitely make a tutorial series around this. Thanks for the suggestion
yeah
i usually talk in here, and thats a bit nsfw type of shit
i see
Those types of grabs will usually require your models or art to be created in a way that supports it
What aspect are you stuck on?
good question, i stuck thinking about how the NPC will react on different sides of this "grab", because he will be pulled closer to the player like the gravity gun in HL2
Yeah, any type of synced animation requires both actors to kinda be interped together
I said pulled but dragged is the more correct term
yeah
i remembered now the whip mechanic of Indiana Jones TGC
Hey guys, when using blueprint structs I'll often run into an issue with unreal dropping saved instances of said struct when I close and reopen the editor if I make changes to it - ex: adding a variable. It's pretty much unusable. Am I doing something wrong?
Can't say I've ever had an asset that was saved revert.
you using source control?
Not for BP no
ahh i have issues with it doing that sometimes, thats why i make sure to have all my data in the struct, but unfortunately if the structs break you have to go in and refresh them
I try to too, but well, sometimes things change, so that's pretty unfortunate
hello guys, so anyone experienced with gasp?
I am not sure if I understand it fully or not but I am trying to achieve topdown with it so I want the character to follow the crosshair
my system checks if we are aiming if we are it calculates the look rotation of the player character and the upper body which is blended over gasp follows it yet gasp doesn't follow it I figured out that the character transform (which follows the crosshair) is handled differently from the root transform so I made sure that the root transform is equal to the character transfrom if we are aiming yet the lower body (gasp) still faces forward refusing to follow the upper body, the character and the root transforms resulting in abominational anims as the player is 180 twisted the rotation mode is controller desired rotation during the aiming state and orientation in the default state what do you think might be the issue?🤔
@lofty rapids i figured it out
I'm not sure if it still works, I myself moved to C++ structs. But one advice I heard was to never save the struct right away. Add you variables, don't save anything. Go to the level, launch PIE - it will force the editor to recompile changed blueprints. Then you can stop the PIE and save.
Supposedly it makes some issues with bp structs go away (it has to do with how the engine names bp structs, there is some weirdness to it) but not sure if yours is one of them.
i have found it depends on what you do
like renaming will break it
but adding one won't break it
probably deleting will break it as well
because it's connected to a pin that no longer exists
In this case the structs in question were just holding data in data assets, so, not an issue with blueprints that use them breaking, just a bunch of configured data being lost
'just' its a huge pain!
so I guess I'll move over to CPP structs too, kind of annoying though
@lofty rapids had to use a different function
oh nice, looks cool
launch character ?
whatever works
Unreal treats the root physics body as the anchor for the whole skeletal mesh. Even if you set it kinematic or free, it acts as the reference body. Radial force functions will not propagate past a non-simulating or special-cased root. AddImpulse/AddForceAtLocation resolve bone names back through the hierarchy. If the root is kinematic, the solver often assumes “no motion possible,” so children don’t get force even if they’re simulating.
I’m trying to create a Mordhau mod for my server without turning it into a modded server I want it to be a server-side mod. Based on this brief explanation, I’m looking for a solution to my idea: I want to modify the widget shown in the pictures so I can add any text I want and also change its position for example, put it in the middle of the screen or scale it up. Is this possible through Blueprints (BP)?
I’m using the game’s SDK, which is an Unreal Engine 4 template that includes all of the game’s Blueprints.
is there a good way to get a black fade-in on startup so it covers up the popping in of the textures and menu UI?
I tried putting in a black screen on game instance init but it didn't work
Its likely possible through BP, unless the game itself does some weird shit.
But, that also would need to be a "modded server", and not a "server-side mod"
Server don't know what widgets are, let alone edit the clients widgets.
i really need it as server side mod
without making my server modded
Then, not possible.
I believe server build doesn't cook widgets, so can't pass values around, to even attempt edits.
Even if it did cook widgets, still no luck.
not possible with Replication ?
Replication would involve a modded server
Doesn't matter if the server did. The client still needs the widget.
Cuz, base UE, and I doubt that game has pre-setup client side widget editing
Yeah, widgets are 1000% client side.
No way to edit widgets from the server, without a ton of prior manual work, for little to no gain (aka, no one would ever do it)
I mean, the client already has the widget since it’s built into the game engine, so I think it should be possible?
Sure, but client needs to be told what to do, via replication.
Which would require a modded client, to know what do to with the servers modded replication
with just passing the values with replication as i know ?
Can't just add new replication, both ends need it, which would need a modded client
If server tries to replicate something, the client needs to know of it.
Which would require both things being modded.
I tried replication in a BP I made to build pre-existing structures in the engine, and it worked perfectly as a server-side mod. So I’m assuming it would also work with widgets—or is it different when it comes to widgets?
Widgets don't replicate for a start. Only Actors, and ActorComponents by default, or a subobject of one of the two that have heen explicitly designed to replicate.
That sounds like you just spawned in things already in the game.
Which means the server was just managing them, not actually changing them like you want to do.
This "issue" applies to everything, you just have yet to run into it.
No matter how much replication you do.
If var A doesn't exist on the client cuz its not modded, then var A can never replicate to the client sorta deal.
Same with widgets, but more so flipped.
Server doesn't know of widget A, and client doesn't know of any new modded logic to edit widget A.
That’s kind of frustrating. i wanted to add a feature to my game server, but is there any other way to implement this idea without making the server modded?
If the clients not modded, you can't do any form of replication.
So, you can essentially only call pre-existing game functions.
So, what you want to do is impossible in about every possible aspect
So, in the end, replication work well only with Actors. right?
It can work with everything, except for widgets.
The other stuff just needs a bit of extra work, or is perhaps less used, depending on the devs.
But, type/ method of replication in this context of server only mod won't change anything
ok then, if i can’t change the widget itself, can I change the data inside it from the server?
You'd need to find that out from the game itself.
May not be able to depending on where, when, or how it gets the data.
how should i implement damping using nodes in blueprint
can anyone explain to me, why the rate at which an RTV updates has changed from 5.5 to 5.6? The first clip is from a world partition world, the second is from a regular level, but I don't know how to increase the update speed in the world partition world. This was not a problem in 5.5
Under a UI widget, what is priority under the Input section?
If you bind input actions to a widget, it'll try to use that priority for them. I think the Listen For Input Action or similar nodes.
I figured out why my drag drop operation from a bag into the world is not detecting 'cancelled' or 'drop'
The cancelled isn't part of the original tile object, it's detected in the drag drop object. So, adding the drop cancelled call into the drag drop object fires... which doesn't give me all the stuff I'd expect.
Like, i have an actor component that acts as a world item, that can have it's mesh set, item reference, etc.
Oh, okay, thanks!
Struggling with how to address this.....
I think I understand the flow. Current widget detects drag / drop. Then, a drag / drop operation is created on drag, passing the required info to the drag / drop operation. During the drag, when I release the mouse button out in the 'world' it detects the drag operation cancelled. But, it is called on the drag drop item.
I thought.. Okay, I can just get the player pawn, spawn the item next to them. But, inside the drag / drop object, there is no 'get player', 'get controller' or anything.
Soooo, anyone dealt with this?
Hi all !
Can someone help me for Spawning actors/meshes along the circumference of a semi-circle please ?
I already know how to do this for a full circle but when I change my value from 360 to 180 it acts weird
I mean my "semi-circle" of actors is not in front of my main Actor but on the right side
Sounds like you just need to rotate your starting point by -90 degrees.
I already tried that but it's not on the right side by "90" degrees exactly
So I need to rotate it by 108 degrees
The issue is that when I do that, it only works when I spawn 5 actors.
If I change this number by "3" actors, all is rotated
are you using spline??
No, just maths
Here is the code, simple
What is weird is that when I change this 180 by 360 for a full circle everyting is perfect
But I only need half
How many did it summon
3 actually
I want that if I spawn 1 actor, it should be in front of this "main" Actor
And if I spawn 2 actors, in front but in a "semi-circle" equally
3 actors etc...
ohh i get it now
I feel like I'm missing some maths
Because when I change 360 by 180 degrees, I feel that I have to divide something
i dont know if my solution would work but could you try starting loop with 0
and use +1 when passing index to multiplication
@odd kiln
or leave it i dont think it would do anyhing
It did something but now I have a new issue..
When I set the number of spawning at "1" it's well aligned
But when I set it to "2" for example, it goes in the opposite direction
I mean one actor is Up and the second is Down
I need the center of the "main" actor to be between the 2 spawned actors equally
Ok found a workaround. Now the issue occurs only when the number of spawning actors is "1" so I just have to use a "Select" or "Branch" node so when it's "1" I just rotate to "-90" degrees
Thank you all !
How did you solve it??
Like you told me, I set the "first index" of the "loop" to "0" and substract my number by "1"
And then the only issue was when the "number" was set to "1" so I just set a branch
then use safe divide
I used an "add" node
ok
I would change the math you use to calculate a point on the circumference of a circle. I usually use something like this if it's a circle (2 axis).
You can just clamp the angle between 0 - 180 if you want a semi circle.
Not a problem but rather something mildly interesting and maybe someone knows the answer?
When setting the mouse cursor to the middle of the viewport in BeginPlay of PlayerController, it won't work unless you have a delay. Here's the interesting part:
-
Using the upper method with a simple delay, will make it not work if your FPS is low.
- When locking the game to 60FPS it works.
- When locking the game to 10FPS it doesn't work.
-
Using the bottom method with a timer (with the same delay length), it works regardless of what FPS
- You can even put the delay length to something lower and it doesn't matter (putting the "Time" to 0.0 obviously won't work but you get the point, you can put it to 0.001 for example and it will still work, regardless of what FPS you have)
So how come the upper method breaks when the FPS is low?
why montage set play rate is highly unreliable?
Looks like it works when it wants to
sometimes it triggers some time it doesnt. exactly same parameters and how I trigger it.
and sometimes it works but triggers too late in the montage animation??
It doesn't really have anything to do with the FPS. The actual cause is down to the view port size not being finalized (with everything still loading). This means the calculation results in the gotten view port size being 0,0 and will just place the cursor in the top left. 2 ticks is normally whats required for the view port to be finished setting up.
I cant remember if this is just an editor thing though.
In my limited experience with gamejam projects I can say UI very often behaves differently in PIE and in the built game. So it may very well be the case here.
Yeah just tested a shipping build and here's what I found:
- The timer still works
- The delay doesn't work anymore
- Putting 2 "Delay until next tick" works the same as the timer in editor
- Doesn't work in a build
If you really want to see what and why is happening, I would add a loop and prints to the delay. After the delay print the viewport size. Then add a branch and if it is 0.0, loop back to the delay
It would be weird if the delay itself didn't work
Also from my knowledge timers and delays are not affected by fps - at least not directly. Low fps can make them trigger slightly later than expected but they should always work
Yea definitely a load order thing. Give me a few mins, I'll check how the Get viewport size function works.
Well this is a journey. 🤣
Hey, is there tool in UE to build story? I mean to know what has been seen what needs to be found? or it's just lot of IF condition somewhere in a place like game mode?
Interestingly, it loads the GameUserSettings before creating the game instance. Anyways, it creates the game instance, of which it does it's thing and initializes all the subsystems. There is something to do with a dummy world as well which could be a factor. (Used until the world has actually loaded)
After all this it actually creates the viewport client which then triggers the local player to be created. Still not found at what point the viewport size actually gets set. 😅
So like a quest system?
in a way. so for example: Zelda
- You start in the bed > dialog
- Need to go to the castle (everything else is locked)
- at the castle > dialog
- Continue the progression
So to be sure when you don't come back to the castle the castle dialogue run again.... is there a kind of tool in UE to achieve story ?
Hi all, I'm running this custom event off of my game instance and it works fine. But when I finish play testing it I keep getting a run time error. Does anyone know why? Thanks
Im not aware of anything out of the box. How you would handle it can become very specific to the type of game you're making.
With a robust quest and save system you can pretty much get this sort of thing.
ok 😢
i will seach info about quest system 🙂
Its because of the 'IsPlaying', the variable thats attached isn't valid. Most likely because the first time you call it, the component doesn't exist. You can do an is valid check on it and only check if it's playing if valid.
I would recommend a uobject based one. You'll struggle to get the flexability you want using a structure based one.
any good video recommandation for that?
because first one i pick is based on structure 😄
lol
Good question. I've not come across any myself but I've not really looked. 😅
Thanks I switched out the is playing for is Valid node and it works fine now
However a few things you'll need to know about before attempting a uobject based quest system are:
- Actor Components
- Custom uObjects
- Hierarchy
- Event Dispatchers
- Soft References
As a quick overview, you'd have a quest manager (actor component) that would manage a list of active quests. (Custom Uobject) When a quest is added, it would create an instance of the uobject and call a function that would initialize it. This init function would bind to the relevant event dispatchers on actors so it can keep track of what's happening. When completed, it can let the manager know (via event dispatcher) so it can update it's lists.
You're custom quest uobjects can also have a function that is called when completed. When you create child classes, you can then override both the init and completed functions to setup the specific behavior.
When it comes to the UI, it'll just be pulling data from the manager.
When approaching it, you have to think of the quest system like an invisible thing that nothing knows about.
Having access to C++ can make some bits easier such as 'Edit Inline' and 'Instances' properties but still doable without.
I know all of theme except the custom uObject. What is hierarchy? What do you mean by that? A tree? Procedural approach ?
boolean, ftw
A self made state machine would work for that
Hierarchy refers to class hierarchy. So this is where you would create a base class and then create children of it to extend/change it's behavior. (through overriding functions or change property values)
Custom uObjects is just a class using 'Object' as it's type. This is the simplest class you can make in the editor but there are some restrictions such as not having world context. (This can be added if using a C++ base class)
adds the 517th bool
This is ok right? 😅
lol bool hell
What do you mean???? you wanna tell me 500 bools is bad practice? 🙃
For smaller size projects you could also use a gameplay tag container stored in one primary place. And add flags as tags for specific thing. FE ZeldasCastle.DoorOpen. Then you query the container if tag is there and act accordingly.
I would say it is better than random bools, but a system like pattym described will definitely work better with more complex worlds/quests
i use a system which is an array of quests, that have booleans for accepted/completed
so simple
I find that having things function without ever knowing there's a quest system works better.
Most doors would have some sort of 'Enabled' bool for if it can be interacted with. Having it start as false is easy enough, then having a quest change it to true when completed. From their the save system just keeps track of if its enabled or not. No need to check if x quest has been completed.
for me adding quests is simple as adding an item to an array on an npc
done
but tbf it's not very complicated and is just a simple system
if you have requirements -> get reward
I worked with a data table based quest system at one point. There was so much redundant data. Got a little confusing keep track of everything.
my code for this quest system is ridiculously spaghetti lol
I guess its just knowing the scale/scope of what you're wanting to do and using the most appropriate one.
for me i just have ideas on how to program things
so it's not a well tested thing, just what i have made
The nice thing about gamedev is, no one gives a crap how the code looks like once its done
and it works
yes and it's not open source
it's about the game, not the code
i think as long as it runs well
theres no issue
but looking back at the code and making changes right now is out of control
That's where refactoring comes in. 😅 Spending a few weeks with a broken game lol.
The 'What the f... was i thinking' moment.

i keep saying i'll just do this and fix it later lol
but it works really well
it's just a pain in the ass to edit
thats a good one not the worst i have ever seen (or created) but top 10 😄
I pray you never need to make an edit lol. For your sanity.
yes its nearly impossible, takes me awhile to track down what is going on
I can imagine lol
This is what my stuff normally looks like. Granted this bit of logic needs another pass. lol.
ya that looks nice. I tend to keep making edits and jamming a bunch of stuff in together
most of my code looks pretty good, but the more complicated stuff i've never done before so its a mess for now
Yea, sometimes you need to throw stuff down so you know what you do and don't need. Its just finding the time to redo it at a later date.
i feel like i'll redo it when it becomes to a point i can't actually edit it (because i'm too confused) or when it becomes a performance issue
burn it
its the current state of my quest system, thats pretty much all the code for it
I mean, sometimes BPs can get more complex and maybe you don't know how to make them smaller/better. But you should at least try to make them somewhat understandable with a few tricks - like not crossing wires too often, keeping branches on different levels etc. It can improve bp's readability even if you have a bigger event:
personally i hate having to click and drag
so i cram everything together
for me right now, the more i can see on the screen at once the faster things go
i'm not use to click drag, i'm use to scrolling
i'm also a lazy programmer so when i put something in the middle of a line of execution i just plop it above and connect it
i don't realign everything lol
it reminds me of basic with line numbers the way you need to insert
This is where I would use class inheritance and hierarchy. Trying to add all the edge cases into a single functions can make things difficult to manage as you add more stuff.
You normally handle a lot of things with a few base functions that you override in child classes.
Yeah, I know. I posted it as an example of "bad but somewhat readable"
In this particular example I'm not yet sure how to design it better, since the objects the interaction happens with are different and can't inherit from a single class (one is an npc, one is a furniture piece, one is an item on the ground). There is an interface on their end to handle what happens to them independently but yeah.
But it works for now and covers all of the cases I need
so I have a frustrating issue with unreal collisions in unreal 5.5. I've built a world with 2 rooms the rooms have collision volumes that should trigger when the player overlaps the room. the first room collision volume seems to only overlap if the player is jumping on the jump and then again when they start to descend. the other room never overlaps. when it does overlap the overlap function does the thing it's supposed to do. Everything else seems setup properly. I've set things like this up before but this specific object isn't doing the trick and I'm wondering what I missed
ok, so hierarchy i know it too. juste to learn the uObject and see if i will be able to use that uObject
on a blueprint approach because you sound like a c++ feature
You can use them in BP only, just need to know how to work around not having world context. Not having it can sometimes be a good thing though lol. Just means you have to pass references to things they need into the functions.
ok, i think i understand the idea
huh ?
On that note - is it possible to use your own Blueprint Library Functions inside UObjects? I saw some people saying it is, while I myself never managed to find a way to do it. I know the world context thing, but I would like to have access to some of my functions that are not world interactive (like calculating something, converting tags etc).
so one of your collision boxes isn't working ?
was something specific confusing? I have 2 volumes set to overlap they're the same blueprint collision box. the player starts overlapping the 1st box but only triggers the overlap event when jumping. the second one never triggers. both should trigger on first overlap because that's what the on begin overlap is supposed to do or in general does everywhere else it's being used
Unfortunately not, a uobject requires world context to have access to function libraries.
so your collision box is only firing when you jump ?
so you have two problems then
you should take one at a time
so you can overlap any amount, but the begin overlap only fires when you jump ?
does it fire every time you jump ?
like you walk into it, and then jump it fires off, jump again, does it fire again ?
also just put print strings on the events
check when its definately firing
the second box never fires. it prints a string to screen so it's easy enough to see what's happening when it fires. on start it doesn't fire then on jump and then again when the velocity takes you back down it fires again. I can leave room 1 and go to room 2 but room 2 never fires even with a jump. but if I go back to room 1 it still fires on jump.
your doing too much at once
so room 1 fires every time you jump ?
Sounds like it could be a scaling issue but I guess you already checked it? You could go into PIE, decouple from the player and then enable Collision display (Show -> collision in the left corner of the play viewport). Maybe something scales the volume by accident during play. Check if the player and the Volumes are as big as expected
and it fires twice when you jump ?
yes room 1 fires every time you jump. and then again when the direction changes. but it's totally an onBeginOverlap it's not really doing a ton of stuff. it tells the camera how big the room is which should only happen when you change rooms.
so if you put a print string directly on begin overlap
with no other code
it fires off every time you jump ?
check with a print string only
it sounds like the bottom of the collision is higher then the character
it's not a very robust function. but yes it fires on jump and then again when the direction change comes and you start to fall
the player is a normal capsule collision sprited character
so it fires twice ? and you show the bounds in world with a ss ?
thats odd it fires twice on up and down
sounds like it's small on the z
and so its printing your character both times i would imagein ?
yeah it's super weird. it's depth is 150 units it's bigger than anything else in the world because I thought it could have been too small as well. but that didn't change anything. there's other collision volumes on pickups that trigger the overlap when they begin properly so I don't think it's the player. it has to be something about the room collision
yes it prints the player name twice on jump and if you break it's when the direction change happens which feels important somehow but honestly I don't get what I setup wrong about this one specific collision instance
show the volumes in world with a ss
as far as super weird
programming is about logic, so hopefully something logical is happening
twice on jump could be both your mesh and capsule
print the display name of the component
other comp
or if you have some other collision boxes
could be anything ig
the othercomp is the capsule the OtherActor seems to be the character class. which I know because I cast it to call a custom function
it prints the capsule twice ?
no the first object seems to be the blueprint for the player
if I print the come it prints the capsule name
twice ?
that gives me the capsule every time
so you still have not show the collision in world
to see the bounds
it's ok I said I did it too but it's good to idiot check as I obviously skippped something or wouldn't need help because this seems like an unreal 101 issue that I don't understand why it happened
^
I'm sorry I don't follow
show the bounds of the box
Show the trigger box in the world.
make it visible and not hidden in world
it's the oversized blue box around the tilemap
it displays the same in game if I pause and eject from the player controller
so it's 150 units in Y
I think it’s just a simple collision issue. It’s probably using a blocking object channel on the capsule collision, you just need to set it to ignore.
well these are horrible images tbh
sorry. the black background doesn't make it the easiest to capture I guess I could increase the line thickness and set an easier color to see
which is z ?
Z is height
Instead of sharing an image like the first one, share one like the second. We need to see the whole picture.
if I took the picture from that far away it's too hard to see the volume but ok
yes but in the image is z left to right ?
think the best solution for this is to create an object channel in the project settings, something called 'Trigger.' Then, set the capsule collision to ignore the Trigger, set the character mesh to trigger = true, and change the collision object in the TriggerBox to this new object channel named 'Trigger'.
and those red collision spheres are pickups that do work properly
as in they generate overlap events on the player pawn and are world dynamic objects. the room is world static but only captures pawn overlap on jump for some reason they're both normal unreal collision volumes
so are you just using these to trigger when you get to a point ?
I'm trying to clamp the camera's movement to the room, I calculate the size of the room based on the tilemap size. the numbers all check out right
is your y thick enough, make it thick. i'm guessing you just want to trigger when you enter/exit the area ?
the Y is like 5x thicker than anything else in the game
i mean are you constraining the y ?
the character can't move in Y because the game is 2d so it should always be inside that box because it's thicker than anything in the game
can you show it while the game is running ?, maybe it changes
the character starts inside the box. I had a different setup that did register the overlap properly but for some reason unreals orthographic camera needed this other setup in order for setWorldLocation with a clamp to function properly
if it starts in the box it won't fire begin overlap i'm pretty sure
untill you leave and go back in
this is what it looks like in game I changed the color/thickness so it's more visisble
show the bottom
the whole side would be nice
capsule radius across the board is 35, the Y is 150
^
it's around 4x /5x bigger than any other volume in the game. if I jump in that room it does fire twice as formerly stated. then if I go into the room on the right it does not fire on entry or jump but going back to the first room it fires on jump again
both rooms are separate blueprint objects if that matters.
anywhere in the collision box when you jump the begin overlap fires off ?
do you have any code with isfalling ? other then probably your animation ?
are you changing collision setting dynamically ?
no just on the animation blueprint which uses the paperZD plugin.
the collision box extents are figured out in the blueprint constructor based on the size of the tilemap.
there's a box for camera extents and the player collision volume. the camera extents box gets the correct values in it because when you jump the camera clips properly
I didn't do Y yet because why bother if the overlap isn't working in a way that's testable
but the camera does track the player
wdym you have a collision box inside this one ?
it's not inside there's 2 but the second is disabled
the second is just used to determine the absolute outer bound in screen space where the camera should clamp
i feel like these are conflicting
your probably jumping in and out of this other collision
then you take it's outer bound in world space +/- half the camera's view
which would be like the only thing i can imagine
you have another collision that surrounds the player ?
is what your saying right ?
yes, but it's not set to generate overlap events. actually it's set to no collision as it's type. it's just used to figure out scale
move it away from the character
does the begin overlap still fire when you jump ?
oh like way far back in Y because that number doesn't matter. I'll try that
it did not make a difference moving it -110 units on Y but did move the box out of the way. the extents scaling was still the correct numbers though.
it's still firing when you jump ? show the character with its collisions and components
also remaking the thing will help to find if it's just bugged
which i unlikely but possible
Hi, just a quick question; I have a pawn actor car, I want a turret cam and a car cam, is it better to lerp between cameras or have a single cam?
yes it still only fires on jump. I could try to rebuild the whole thing. too bad there's not a way to force unreal to recompile a blueprint properly.
define "better" ?
i mean just try to redo that one collision
see if it's fkd
easier to deal with, more performant?
"One camera is more performant than two"
but two is not so bad like 10
to deal with would be similar to deal with i think one way you will have to lerp transform, the other you can just view with blend it's a node
ok, umm... hmmm thanks...
it's imo a lot easier to just have two cameras and blend them
k, thank you
or atelast if you are using transforms have a reference actor or something so you can change the points
that's actually part of why I switched how I was doing it I had one camera in every room setup basically the same way and it switched cameras when you moved rooms but the performance hit was massive as the level grew. go with 1 if you can any time you can
is it view target with blend?
yep
i see so your trying to when you are in a room, set the camera to that specific point for that room ?
I have a 360 omni directional car that I need a turret with that follows the camera... its been for me difficult to switch states of the spring arm back and forth
thats why I was asking about two..maybe it would be easier
geez big world, cool car it can drive in any direction
yes so that it stops tracking the camera as you get closer to the outside of the room then switches the camera to the next room when you leave. I had a different object that did the overlaps properly but it had 1 camera per room and didn't want to move the orthographic camera properly as it wouldn't clamp no matter what I did. now it clamps if I can get it to detect that it's in the room. rebuilding the collision volume no no longer registers on jump or on overlap begin. wait now the jump trigger is back. no idea why.
thats where this whole orbital turret prob comes in
the fact that it went away on setting up a new collision box then showed up on jump suggests it's a setting on the box that I didn't configure properly though, however I've no idea which one
Hello everyone
I'm doing some sort of excavator, I modeled a skeletal mesh on blender, with 1 bone per mechanical part
I tried to use the animation BP to control the rotation of the bones, while having a collision response. But it doesn't work...
Either I set the physical bodies to Simulate and I loose control over rotation
Or I set them on Kinematic, but I lose the collision response
I'm stuck on this for several weeks now...
Is there any workaround or a totally new way to solve this issue ?
you could try using three sets of bones. keep one as the physics object and the other as the controlled bones then interp between them as you need. classic space switch
it's really strange that it would do that, the only thing i can think is you have something around your character position that is overlapping as well
similar to how you would setup an IK/FK rig for legs in animation. one physics rig the other player controlled the third controls the asset then you control which rig you pull info from
and your jumping in and out
but idk, could be anything
its also really weird it fires off twice
yeah it's super weird, for all reasonable logic it seems setup properly. the player starts in overlap which worked fine with the first camera system. the double fire kind of makes sense because those are separate events in the player controller but they shouldn't be going into the overlap generation
but overlap events work fine everywhere else they're used
and if you make the box extens on the y like 5000
and the z like 5000
does it do the same thing ?
the z is the size of the room. but I could try to do it that way on Y
i mean x is left/right right ?
z is up down
i would just exaggerate them
y and z
just to test
just realized my car doesnt backflip...this must happen
all unreal cars love a backflip.
the height calculates per room. it's not as easy to detangle. it's also way more than all the characters
it's still triggered on jump. which is so weird.
ok so you know it's not the y, you can't scale the z ?
I could I guess. I calculate the size of the tile map on construct. then the room entry collider is 1 tile smaller than the room on all sides which is easier to get because of how the box extents scale works from the middle of the object
I could just disconnect it I guess and make it 10K or something
so player confines box is the one thats triggering ?
oh so this is weird/ fun. disconnecting the Z stops it from the jump triggering onBeginOverlap. but it's way too big to pack the map properly
so theres your issue
the z is to low most likely
yes the player confines box triggers on room entry. and if I make the values of the player box super high/wide it does trigger but not on game start. the Z is the height of the room
well the height of the room minus one tile the whole way around
yes it won't on game start, you have to check if overlapping
because your already overlapping
so begin overlap i'm fairly confident won't fire
why would I need to do that in this example. I'm asking because I did this same 2 box thing in the 1 cam per room example and it worked in that setup
like I can put the other camera in and it triggers on game start and that still works if I went and did it now. which I did try earlier this morning before asking
what ? changing the camera changes teh collision ?
oh you're saying because the other example had the box as a component of the camera and not some random actor the time at which it checks matters potentially
changing the camera should not change the collision
yeah changing the camera back to the old system where I had 1 camera per room
so the issue is most likely what your doing with this new camera
and collision
because that should not happen
the 1 camera per room camera had the same 2 box system but it was 1 camera per room. which did register on player start it triggered the overlap
"OnComponentBeginOverlap and OnActorBeginOverlap events do not trigger if an actor is already overlapping a collision volume when it is spawned"
but it did and has in other setups. which then becomes the question of why
why did it work there and not here when it's a default unreal collision thing
you can probably ask forever, because i'm fairly confident it didn't work
ok. so what you're saying is it's on me which is fine. I guess I'll have to work that one out
i'm saying it doesn't work that way as far as i know, and if it did there was probably something making it look that way
or your character was moved
in the process and started the overlap
I'm saying I did it and know it works and still have an example where that specific feature runs in this game. but that setup has other problems that conflict with how the camera behaves
which isn't part of the discussion of how or when a thing triggers the overlap
well ya thats on you, idk how you got a thing to work that doesn't work
which then enters the question why does it work there and not here which is a valid question
its not because it doesn't
In this section, we will be creating a simple character, room, and camera in preparation for creating the Metroidvania camera system in Unreal.
Pixel art asset pack: https://bakudas.itch.io/generic-dungeon-pack
Chapters:
0:00 Intro
0:45 Project Setup
1:09 Tilemap and Room Setup
5:10 Character Setup
17:40 Camera Setup
are you spawning in one
that works
Do you have an example? A video?
tldr
that guys video tutorial totally sets up the camera so that it triggers when the player spawns in the first room. it's just that he uses a perspective camera and the way he moves it doesn't allow for high order pixel accuracy which I have a lot of other effects that are dependent on screen space and pixel accuracy at a set sub pixel resolution. which again is aside the fact that it does do this elsewhere but not here
idk how they do the impossible, maybe i'm wrong and theres some quirk
"If an actor is already overlapping when the overlap event is set up, it's not a "beginning" of overlap, so the event doesn't fire"
is your character spawned in or placed ?
it spawns from a player start.
"race conditions where the overlap event hasn't fully initialized when the game starts"
In case You want to support my stuff, please visit my Patreon page:
https://www.patreon.com/YourSandbox
I did figure out why it wasn't overlapping on room entry I needed to do an abs on the values I set in box extents because they need to be unsigned but the extents parameter is a standard vector
setting that Z to a non calculated unsigned float of any value larger than the player capsule did the trick. and for the other thing I can just check on player start if it's overlapping the room
look at how people setup IK/FK arms or legs in 3d animation. basically it's that but you're handling the animation logic in the engine. you said you made this in blender right? it amounts to 3 sets of bones all in the same spot with only 1 of the sets controlling the mesh. then you handle how to control the other 2 sets and interp between them
looping on begin allows me to snag the values and it switches the rooms properly so I think it's likely good for now. 1 camera seems much more performant. now I get to rebuild the rest of the rooms that I have. thanks
are you interp the camera ?
yes but I don't love how I'm doing it. eventually I'll move it to C++ but I wish there was a more parent/child way to do it.
i would have an array of points
and keep an index
how would that work. like of the room extents.
so you can go back and forth np
basically you would have an array of locations for your camera
then i would create an actor for the collisions with an index you can set
the problem was with the clamp. you have to do this interp because the orthographic camera for some reason won't clamp it's world location. not even when it's attached to a spring arm and you try to clamp the spring arm
i mean can't you hard set it
but then you end up with this goofy interp on the camera that can track the player with the clamp
My character will start sprinten before I even hold the shift keybind, when I press play. Not sure what I'm doing wrong, this is my blueprints and the variable settings for the input actions. Thanks for your help.
an array of indexes with custom collision actors where you set the index on the collision box
this way you can just say when collide over me, get index 1
and then set the camera to position index 1 of array
that would work. but the people who make the levels aren't so good at the maths. the boxes make it easier because it calculates the bounds automatically and they can just make whatever they want.
whats sprinting boolean default value ?
oh so it just centers on the box or something ?
yes it takes the tilemap set and then figures out the sides and such based on the tilesize of the map
that sounds cool, makes things a lot easier
this function here which is way prettier in C++ but it figures out the bounds of a standard unreal tilemap object
I think I found the issue, in the BP_thirdpersoncharacter the character movement was still set to 500 somehow. I changed it manually to 300. Am I supposed to manually change that though, shouldn't the blueprint do that? PS : these are the settings for the IsSprinting boolean
you can manually set default np
i mean it's built that way lol
thanks it does. I want to make proper doors I think. then it's easier to load/unload rooms to take pressure off the cycles where you'd have tons of guys idlly waiting for you to enter a room
aaahn okay, so eventhough I've set the blueprint correctly, I will still manually need to change the default value in character movement to match the walk speed, correct?
well you can on begin play set it, but initially it will be whatever is in your CMC
as far as correctly think about the fact that this event doesn't fire untill you press the key
ah ye, I get it. The walk speed doesnt work from the start as it's binded to the input action IA_Sprint, therefore he used the CMC walk speed from the start. Only when pressing the shift button it will trigger it. So either hook it up to beginplay as you said, but it's prob best to use the input actions for this. So therefore, set the walk speed similar to the IA_Sprint walk speed. I get it, thank you so much!
You're always very helpful, you've helped me quiet a lot in the past, and I appreciate that! thank you
i like to help when i can, i've programmed a long time so blueprints was fairly easy (still learning)
If you dont mind me asking, how long have you been programming or into Unreal?
I'm guessing quite some time 😄
unreal about 2 years
probably out of that 1.0 -> 1.5 years of actually working with unreal
feels like forever lol
I've only been at it for 6-7 months or so, I feel like I've got a long way to go but really enjoy working with Unreal
visual scripting is pretty fun
You've helped me to learn enumerations and how to implement them, it has come in very handy for my mini amateur projects 😄
anyway, I'll get back to it, thank you again! You're a legend @lofty rapids
how should i implement damping using nodes in blueprint, instead of a physics constraint. so i can have forces make an object stop quicker without making the object go too fast in the opposite direction, or reduce rubber banding when it reaches its limits and gets pulled back
set linear and angular damping
How can I control two characters at the same time? What I want to do is this:
Use the WASD directional keys to control two characters simultaneously. Only the second character will move in the opposite direction.
When I press W for the first character, it moves forward, while the second character moves backward
hey everyone how have you been doing
Trying to spawn item in front of the player character, maybe ~15 ahead. I currently get actor transform and see there is a location ,rotation, and scale. What's the math or process for determining the transform to pass to the spawn actor?
You wanna do it randomly or in some sort of manner
15 in front of the player pawn. This current setup just does +Y, which ... doesn't work if player changes direction. I see the rotatio changing. Just don't know the function for taking and doing the math
you should be able to add movement to the other player and invert the axis
why are you iplementing line channel when you are not using it
location + (forwardVector * distance)
to get player's or whatever 's reference??
You can leave rotation empty and scale on 1 if you don't want to rotate the item in a specific way
Unrelated right this second
ok
i thought you were having trouble that they are spawning even when player is not there
Worked perfect, thanks! Forward vector...
guys do you a way to interact with objects seen in a sceneCaptureComponent2d? Would be great if i can just by using my cursor... do u know a way?
The future of the line trace will be, if the player is attempting to drop an item to a spot within their reach, it will drop it at that location, else, drop in front of their pawn.
also casting a line trace would work, but i still need to direct it using my cursor
It will be single-player
if i have an object and a specific pivot point for that object (these are components), should i parent the object to the pivot point, or the pivot point to the object
ya but the other player is a character or a pawn ?
probably the object to the pivot point, is the pivot point a scene component ?
He's a character, yes, but he acts like a pawn. Both characters are main characters, and both are moving in opposite directions.
yes just add input in the -axis
add movement like you would in your character, but add it to the other one as well
yea its a scene component
maybe use input mode ui only
that would make me able to interact with the UI but i need to access the objects in the real world which the scene capture is seeing
instead of self in the add movement you just plug in your other character ref
Will both characters then realise that the directions are reversed? I'm talking about two gameplay characters.
you keep what you have so the original character still moves
then you add another movement input but reverse the axis
Could you perhaps send me an SS example? It seems complicated because it's the first time I'll be doing something like this.
well i would suggest looking into blueprints and how that all works, have you used bueprints much ?
Not much, but yes 2 mounts
do you know where the move event is ?
Yes, in bp_thirdperson char
yes so you see the add movement input nodes ?
Yes
do you know how to get actor of class ?
the node
yeyes yezx
get actor of class
the other actor class
and plug that into the target of the add movement nodes
and you'll see how to control the other character
but you need to make two add nodes to make them both work
it's the target of the add movement that matters
Yes, i see
15 is small but:
SpawnTransform = Compose(CharacterTransform, FTransform((15,0,0),0,0,0,1,1,1)
learn transforms and rotations, and what it means to compose transforms, rotate vectors, unrotate vectors, etc
it's not magic
how can I change the state of a Boolean variable in an actor from a component of the actor? I am trying to understand how to get a refernce to the blueprint. I have a PickupItem actor which I want to mark as "hidden" such that the player must perform a search before it is revealed to them. After that the PickupItem will be treated the same as other loot in my system.
What does the boolean represent, and what is this component?
The boolean is "bIsHidden" and it point is to determine if the actor will be hidden in game or not once found. In the actor I've set the visibility of the static mesh, so this will tie back into that function to toggle it "on/off"
get owner ?
For better control of veritical height get a Socket location off the mesh... Head, Neck, Spine_5 etc instead of general actor location.
this is what I have atm. no errors, but also nothing changes
your setting the visibility, do you want to set a specific boolean ?
because thats two different things
well, yes, and yes. I realize that this isn't yet changing the boolean value, but its trying to effect the same change I believe I've made in the actor too. Or am I making a mistake in my logic right now?
depends on what your trying to do
Basically make it so that I can hide loot in the game until the PC performs a search for it, then it gets revealed.
whats the boolean your talking about ?
Called bIsHidden, and is implemented in the actor. There's a check box in the details to mark this true or not per instance.
so is this instance editable and it sets the visbility
where else do you use this is hidden
nowhere else, this is a new function I'm trying to add to my system.
and item static is what ?
i see so here when you set the visbility back it doesn't actually do anything ?
It an actor that represents a piece or pile of loot in game which is working as intended. It is tied into the system's inventory already. I'm attempting to add this feature into an existing asset.
is this code running and when ? and is the cast failing ?
If I dont mark it as hidden, the actor appears normally. When checked to hidden it is, but I'm not able to get my logic to reveal it.
I have a input action setup to activate the component event in the first which is producing the print message, so I know everything up til there is working
there is no runtime errors, the cast is happening at keypress I suppose.
put a print string on cast failed
does it show up
ah ha! It does show up as failing
try to printstring the result of get owner
it should turn into display name ?
Ok yes, but I dont want that of course, I want to affect the actor.
i see your not looking for the owner of the component
your looking for some other actor ?
Yes, my original question was how can I change the state of a Boolean variable in an actor from a component of the actor? So the Loot item actor has a few components attached to it for functionality, and I'm creating another one to add this reveal hidden logic
fromj a component of the actor
thats the owner
but your not looking for owner
you want some other actor for some reason ?
the answer is you would get owner cast to to your type
set the boolean
ok but your owner is the character, your not in a loot bp
show your components at the top left
this is not your game ?
Yes, but its based on an asset which I didnt create too.
oh i see, well it looks like your in the character bp not the loot bp
Delegates are a good way to let components tell their owning actor things as well. Bit more generic than linking the actor and component together.
I have a nagging blueprint issue of my own, would like to polish things up with my charge shot but I have a hold-up with the release trigger where going through a door or triggering a boss warning locks its audio component to endless play (read: the sound effect for a full focus charge keeps playing without being stopped or it's reference destroyed). All other cases of releasing the focus charge for launching the attack are unaffected - it's just in these two cases, and potentially a third once I add backtrack blocks.
Any idea of what may be going on?
Side note is that it's a two-part audio sequence - one for the pitch rise during the power build, followed by the main loop for a full charge - and I am not 100% sure if that has anything to do with it. Additionally, it may take a while to get a screenshot of the blueprint as I'm essentially AFK for at least the next three hours (but will post it ASAP in case it helps).
Ugh, got my inventory setup, equipment stuff, drag drop between containers and equipped items... and, need to go back and re-factor my combat system. 🙁
What does everyone use for documentation / flow charts / diagram stuff?
For sure as the game has become more complex, there are aspects where I just don't remember what did what and where things are....
The short answer is, you're not stopping the sound during those things for some reason. Why that is is impossible to guess without seeing your logic layout and how you trigger the sound to go normally vs how it would stop during a door or boss scene.
I think we primarily use Miro at work. Canva also isn't bad.
Only thing I recall on the immediate is that there is a reference error pertaining to the destroyed object that shows in the warnings window following an in-editor play test, and consequently I have not ruled out a potential double whammy from that
Thanks! I'll look them up.
Thank you very much I'll try that !
@dark drum You know maybe how can I implement your code into mine ? With a For Loop ?
I may also need that the actors spawn from the middle of the semi-circle and not the sides
I mean if I have only 2 actors to spawn, I would like to have the 2 actors next to each other but starting to spawn from the middle not the edges
Maybe I just have to reduce the "radius" ?
@next hollow is there a way to remove the shadow from the deleted object? or change it from server-side also? i able to delete stuff from the map but i cant remove also the shadow
Total noob here. What could be the reason why my blueprint function library doesn't want to show up in other blueprints?
Does other blueprints is in the same plugins of the library?
They are in the same folder and not in a plugin folder
WTF I do the same thing in another project and another project works
Could it because of blueprint namespace set in the project settings?
Yea, you'd use a forloop. If you wanted the actors to be at the same angle but going out from the center you can just increase the radius on each loop.
If your going for the edge of the circle, just increase the angle each loop by some angle step. (Angle spread/total actors to spawn)
Hey, does anyone know what did I click in the editor that I don't have the option to move things in viewport by default and I have to switch with G to be able to move actors etc. ?
hello, i'm trying to hide my full body mannequin and unhide the arms. i have since changed the bone names to read "upperarm_r/l" and it still doesnt work. any help?
As far as I know it is just the game view. It shouldn't be on by default
And I don't see any setting to make it be the default
I apologise for yesterday, I overslept. I've set it up like this for now. When I press TAB, the character changes, and I can control the other character. I'm currently trying to set up the second character's movements to be the exact opposite.
That game might do static shadows in such case, not that I know of.
I am facing a wierd kind of a bug, when dialogues are being played with Animation on widget along with sequencer playing cinematics. If I move my console switch from TableTop to Handheld or viceversa the player character loses the input. I solved the problem by applying delay node before and after the animation of dialogue finished. But still in edge case I get a bug if I do the above issues stated and before the cinematic player start I didn't give any input. Help How I can solve that edge case.
ya this isn't going to work, you'll want to do what i mentioned yesterday.
This setup will only possess one at a time, won't move both.
^.^
Yes, I have now called Get Actor of class.
oh ok, well you need it to have execution and then do an add movement input
you know what that is the execution ?
I think I need to connect it with the Enhanced AI move.
the white lines are execution
basically yes
What should i choose actor class? Player0 or player1? Or something?
the other actor that you want to move in reverse
But I have no other character than this.
By the way, I apologise for bothering you. It's my first time participating in a game jam. I'm trying to make it into the top 15 in the competition, to win a prize and improve my skills. The theme given was ‘interconnected’, which made me think of a puzzle game where the same character is connected but works in opposite directions.
what is the other thing you want to move ?
thats the actor you want
i would suggest a bit of blueprints tuts tbh
your not bothering me, if so i would probably just ignore or tell you lol
Thank you for your understanding ❤️
I updated this as an actor.
you want the specific one you want to move
So I suppose I want to control two characters at the same time, but they will act as mirrors.
When one character moves forward, the other must move backward. When one character moves to the right, the other character must move to the left. At the same time, I must be able to switch between these characters.
multiply the direction by -1 to move in opposite for the one you want
how long have you used unreal ?
2 Mounts
ok well have you watched tuts on blueprint specifically ?
Yes, I was mostly doing level design, but I was mostly applying it by watching videos.
i see so you have not done much programming that makes sense
"get actor of class"
it literally is getting an actor of a class
you chose actor
why is that ?
Because I thought which player would be controlled was an actor within the actor class.
I think one problem you are facing that you aren't sure how to fix properly is that you can't control 2 Characters at the same time via Possession.
I understand, I suppose I should give up on this. Because I don't have enough experience, nor can I fully comprehend the information being conveyed.
Right, I'll ask you this:
I don't want to control the character at the same time. I want to control two different characters as character switches. I just want the controls for the second character to work in the opposite way. I have something similar working, but I can't get it to work in the opposite direction.
in the direction you are moving the character multiply that direction by -1
This is working correctly. However, when I change characters, I am unable to retrieve the reference for the second character. ,
set the value of some boolean like this at the time you are changing the character and then negate the vector based on the boolean as the boolean will be inverted each time you change the character.
i mean are you using the same reference or same character for both of these inputs ?
i think he is using some flip flop node in the level blueprint

I think that's the best way to explain it. By the way, you're right, I do have one pair of flip-flops.
when you switch characters i would just posses the one you want, and have the opposite code in the bp
but anyway your code is strange tbh
I believe I need to add a node that can reference the second character within the EnhancedInputAction IA_Move. I also need to combine this with a branch and apply a negate operation with -1 to ensure all controls are interpreted in reverse.
your using the same reference on the positive and negative
yes reference the other character in the move
and go negative values
then do the same in your other character except opposite values
unfortunately i think for me it's hard to help because your not understanding
get actor of class the class of your other bp
do you know what the class is ?
Actually, I understand a little. But I haven't figured out how to get the second character. After all, since it's a copy of the first character, I can't add it with a node.
ok
do like this

this could probably work instead of possessing the other character
switching between the two
but they need to get the reference to the second actor
and add some input nodes
Yes, I can't quite figure out how to reference this second actor.
get it from the scene like the other one and use the select node
i would just show you but in a case like this you learn nothing from it
and it's kind of an injustice to just let you copy/paste it
lol
i mean if it wasn't fora competition i might even send it, but i'm a big advocate of learning the basics
Is this Get Actor of class a reference to my other character?
Character 2 is an exact copy of Character 1.
did you duplicate it ? or spawn a copy ?
Both of them are BP_ThirdpersonCharacter
how did you put them in the world ?
thats a bummer
^
https://www.youtube.com/watch?v=3aLBUDlrids I performed the switch character control with this video.
Hello guys, in this quick and simple tutorial we are going to learn how to swap between characters that you have in your level in Unreal Engine 5.
Follow me on Twitter: https://twitter.com/GorkaGames
Subscribe to the channel: https://www.youtube.com/channel/UCv_n9oioNF6OpzR2dt6E4xg?sub_confirmation=1
unreal engine 5,ue5,swap character,tutorial...
can someone tell me the usage of save game in variables
i do duplicate it
ok so you already have the references
he just need the ref and change the ref based on the flip flop boolean
did you learn anything from this ? or did you just blindly copy it ?
because the reference is already there
you don't need get actor of class
or anything
you have two references
one for each character
it's literally two more nodes to get it working
I think so, yes, I watched it three times to make sure there were no mistakes. I haven't added my own touches to it yet.
do you know anything about references ? or where your two references are in the bp ?
I have a variable called Player1, which is a boolean.
it's hard for me to help when you don't know much about blueprints
you know what a boolean is ?
I set up the switch system in Demo_mapin. The second character is within the level, so yes, I know where it is.
you know where your reference to your other character is ?
Yes, I know the basics such as boolean, float, etc.
how do you know where the reference is, but you don't know how to get the reference ?
Save Game is a flag that can be used in C++. It doesn't actually do anything by default from a BP perspective. It can be used when serializing an entire object to be saved but the functions to do this aren't accessible in BP only.
ııı yes
I don't know how to pull the reference of another character from the level into the BP. I can do it in the level, but I can't do it in the BP.
you shouldn't be using the level bp anyway lol
What!
why it is necessary for epic to expose it for blueprint variables
so personally i would not have them both the same character, i would make a parent character
and use them both as children
with different class
can you tell me from where i should read about it i am not getting any information on it
Well then, I can't figure it out because I made a mistake from the very beginning.
i see the issue your having with the reference