#blueprint
1 messages · Page 41 of 1
Can anyone tell me why this is happening? well, basically I'm doing a line of sight effect, it's this blueprint that creates a series of linetracer according to the tracecount, it works well, but there is a delay, when I move my blueprint, there are delays when updating the transform, but the linetraces are working well, even when I move the point, what could it be?
Is there a way to find the exact node usages of a struct or enum inside blueprints? I know you can use the Reference Viewer to find out which blueprints use those structs/enums. But I need the exact location INSIDE those blueprints. If I have a blueprint that refers to EnumA, and I have 100 functions, I want to know WHICH function refers to the enum/struct. Is this possible?
woah doing that with meshes like that seems kinda nuts
. Maybe the instanced mesh comp isn't updating fast enough?
Try setting the mark render state dirty to true
@lyric oak
To not make it set the pc on fire, do that only on the last index
If anyone can help me out, I for some reason cannot get the contact point of the grapplehook to attach to a moving object. I have tried a lot of things and it's got me stumped. Any help would be appreciated thanks 🙂 https://blueprintue.com/blueprint/yhie0z95/
Please DM me if you think of something I will be at work
I've already done this, turning it on and off and seeing if I could reduce the delay, but it doesn't change anything
you can make it more optimized just by lowering the tracercount
I was talking about not making the state dirty each time an instance is updated
Attach the hook end actor you spawn to the object that gets hit
with the attach actor to component node
so the object that gets hit is an Actor no?
so I cant use that or am I being dumb?
ah, got it
I'll try that real quick though
thanks
so im using the hit detection from the trace
which is an actor
and the grappling actor is an actor
so I cant do that
I appreciate the help though 🙂
So, do you think it's better to change the transformation when I add a new instance? in addinstance there's a Transform parameter...
use the hit component
same issue unfortunately
what you mean?
see the arrow pin on the set node?
it only will get set once the execution flow runs through it
Wha
For storing possible loot objects off an object, should I store them as an object array?
id use a soft object array but other than that, yeah it wouldn't hurt
That way when interacted it randomly chooses a number between 1-10 for item count + random items up to item count
it depends how you have the system set up as to what type you make it
Thank you for the help though @trim matrix unfortunately same issue. I will keep trying after work
Okay. And then is storing on an object fine? IE for weapons have a structure for them that has type, damage, enchant slots, condition, etc.
yeah it can be. again it's all system dependent. you can use actors, data assets, data table rows, what ever really.
use soft refs for things like this tho
And if I add a save game (have to figure that out) do those objects retain those structures values? (Ie are they persistent)
Okay soft refs yea
you'll have to come up with a way to save them.
the save game object only saves what you tell it to, and it won't save just an object reference like that.
if your weapons are made at editor time then they will be persistent
No...
Ah okay a database then
but any values you change at runtime will be need to be saved and handled
For player inventory
a data base also isn't strictly necessary
Oh rip
you absolutely can go the data base route, but you can also just go the save game object route
set it in the same place you are setting the impact point @forest agate
Ty buddy
In class but going to game design lab after to fuck around on my portfolio game more lol
but yeah, you wont be able to just save an object ref to save everything in it. you'd save possibly the item data, and then respawn it on play.
c++ gives you finer control over saving and restoring everything
Yea im just learning bp for class whenever i get to it
(there are also plugins that just save the world state for you if thats an option)
if you've done any significant amount of C++ then the unreal api should be trivial once you've avoided the non standard noob traps
Should be? 
i would only personally go this route if you plan to do unreal in your own time as well though. if it's just for a quick school project, you probably don't need to
Yea I just haven't taken time to look at api yet 😛
We are going next semester to Tokyo to meet with Square Enix for class so want to have a small project to showcase
i can't speak for everyone, and a lot of people severely overestimate their skill with the language, as well as their ability to read the source, and find info.
nice!
I mean if you look at my profile the non unreal game I volunteer on is over 500k lines of code (c++) 😅
I miss SWG
It's pretty good still
Hey guys, Im super new to unreal ive done a gamedev course or 2 haha. Im making a topdown shooter game and im trying to get the character to flow better. if you see games like endless dungeon the new one or suit for hire, the characters top half kinda leads the directional turn and the legs follow, I thought maybe it was aim offset but i can only see tutorials for up and down aim offset and im starting to go crazy because i have no clue how to do this. any help would be aprreciated.
Blend Space is what you want, iirc https://docs.unrealengine.com/5.3/en-US/blend-spaces-in-unreal-engine/ (5.3 version, there are other versions of this page)
can i not set vector parameter values for my text component?
Can you modify mesh/skt/animations all in unreal?
My model I have from someone has an animation set but it doesn't work with all my other ones I own. (They all work with mannequin, etc)
So i got a blendspace and i can move around added animations but its like i want to split the animations or something
might just need to look into your blend space more. afaik it is also possible to split animations so you can, for example, use 1 set of bone animations for the legs and another set for the torso
which kinda seems to be what you're doing already? I don't have a very good eye for this though
and I haven't used blend spaces myself, I just know of them from a friend that has made good use of them
No im not doing this yet, its just a simple blendspace that im using
but if you see when im running around my head and legs are always pointed the same way which is not what i want
Ill keep checking around
Pretty sure its aimoffset
aim offset is a type of blend space
Yeah
but if you look into blend spaces more generally, you'll find more advice and you'll be able to do what you want
Just had to use blend space for post process material lol
My goal is to understand animation and blendspaces but im like uber new lol
there is an #animation channel , might help more
I don't think so
try having a separate Vec with 3d Widget just to visualize it , the copy/paste the value to your Map once it is where you want it
Can also Draw Debug Point/Box/Sphere on a For Each Loop, If you want to see all the points
already doing that but i want the user to be able to drag around the widget to set the location
During Gameplay? or in editor?
Is there a built in tool to copy a bunch variables from one bp to another at once?
in editor
property matrix might help
have you looked into Editor Utility Widgets?>
You could make a widget that would let you build your Map variable
Copy/Paste works nice for me, just have to Create Variable on the Pasted side
Right click on the "non-word" part to see dropdown
it doesn't transfer the default values though
Thanks, I think I'll go with that
well, I think Instancer Static Mesh must be the problem, it must have delays, does anyone know an alternative? And if so, how can I apply it?
It must be the problem
hard to read your pics, try this https://blueprintue.com/
have you considered doing the same effect with a material?
Does anyone know if the editor has a quick key while in bp editor to straight connections (when you are moused over a node)
there is a list of keys in the Alignment tab dropdown
Well, I have no idea of an alternative to InstanceStaticMesh, I tried Procedural Mesh, but I think it's a bit advanced for someone like me, who joined Unreal a few weeks ago, do you have any idea of generating a mesh according to linetrace?
are you remove all instances , and re-adding them every tick?
yep
so you could try adding them once and updating them on tick i guess?
almost that
Add Instance Transforms (Array) is about 20% faster than Add Instance transform (Single), not sure if that helps
q perfect. ty
Anyone know if there is a plugin that will let me zoom in further to bp editor lol
I'll try to use it, thanks
hold Ctrl while zooming
4k monitor?
use blueprintUE you ppl
I think this is just them showing that they're making their code neat
Can I reparent a Blueprint macro library to "Object"?
It doesnt show up in the Class Setings > Parent Class dropdown
simple question
How do i get the x,y values on the right side of the subtract also on the Project world to screen?
Maybe your are using some from Actor in your macro? If all things fail just make a new object macro and copy paste your code over
You can break any struct (blue pins) by either right clicking and selecting "break" or draggin from that pin and search "break"
What is that
pastebin but for unreal blueprints
hello I have a few questions on speed and velocity.
- How do i find the velocity of an imported fbx animation (for e.g a plane flying)
2.How do i find the velocity of an object animated in the sequencer (i.e not possessed by the player) - Is there a node that finds the instantaneous velocity (derivative )
Thank you so much.
At design time or run time?
The easiest approach would be to just store position every frame and calculate velocity as (Position - OldPosition) / TimeStep
design time since I am mostly interested in linear animated content
Probably not, you'd probably have to write some utility that basically does the key frame interpolation and calculates the derivative for you.
If you have access to the slope or tangent of the curve then it'd be simple
Otherwise you'd just have to sample it multiple times and math it out
thanks for the suggestions. most of the suggestions on the net have an answer to this only after possessing the object
What colour would be good for loot highlight
Need one that stands out
And line thickness might be too excessive lol
could always expose those as options to the user! I'd be inclined to go for white or a pale yellow as default - the fact that the loot has a big outline around makes it stand out pretty well, regardless of the colour of that outline
Valid point. Didnt think of making it a setting lol
Right now it's just exposed on BP object
what would i add to this to get started. (i'll find out how to do this in the sequencer and write back here).
The current setup gives me zero.
Are you intending that to be frame rate dependent? It is.
at 24 fps
Vec pos offset x 24 is your velocity
That's pretty gross though. You should write your code such that velocity is an actual variable, then divide by timestep for your offsets
hello am new here but really need some extreme help I am stuck on fixing a pressure plate puzzle and the plates for it and I have very few hrs to get it done but do not know what I am doing
What is the actual problem you are having
I can screen shot it and show it itd be easier
i think the last one here takes you close to where you want
I don't really use debugging, because I don't make mistakes
The last arrow? I think that just takes you out of that function
it took me to the node right after the Add to Viewport
is there a way I can DM them to you as theres several pics of my issue
blueprint debugger window should have the call stack
Hi, I'm having a difficulty when switching from my MainMenu level to the actual game. For some reason, my virtual Joystick isn't working when I open the level via "Play" button while other buttons are working just fine. Joystick is also working as expected when I open the level directly from the Editor. Anyone has any ideas on what it might be?
This is cursed. You somehow have a bool input connected to an int input. This means you have a int value going into both of these but there's no actual int defined.
This is the equivalent
more like UB
This is what you want based on the comment.
Here I think all you want to do is add the cast's As BP Pressure Plate back to the PressurePlates array.
And this also makes the resize earlier a bit pointless as you're constructing the array again anyway.
This will just result in an infinite loop as your loop appears to be calling this function.
Based on what I'm seeing, what you want to do here is drag off from the Array Element and call "Reset Pressure Plate" which then should play the timeline you have in reverse for each of the pressure plates in your puzzle. Get rid of the "Reset All Pressure Plates" call here.
all that makes sense thank you all I am going to try to input it all and see what happens.
now this is my real issue it makes no sense when the bp is the parent actor
i went on window -> debug
doesnt show call stack
only breakpoints
Maybe work it the other way around. Create an event dispatcher that has an integer input in your BP_PressurePlate that you can call when you want it to send out the message that it was triggered (you'd connect this event dispatcher in that empty space you have right now). In your "Populate Pressure Plates" function back in your BP_PlatePuzzle, when you're looping to populate the array with your plates, you can also bind to that event dispatcher and have it call Event Plate Pressed.
You'd need to hook in the Plate Number of the plate into the dispatcher too of course.
lmao unreal removed it in version 5. guess it was too good to keep
i dont think there another way to pull the bp callstack
all the events and things are presetup by the teacher. I would switch the BP parent class to plate puzzle but that only messes everything up
Weird I seem to remember seeing the call stack at some point in 5+
Ok, if you just want to do what the comment says that should suffice... Get the Parent Actor, cast it to BP_PlatePuzzle, drag from the cast node and call the Populate Pressure Plates event, and feed in the Pressure Plate Number.
School making them use CAC ?
Let me preface this by saying I’m new to Unreal. I created an NPC that only moves when not in view of the camera, the AI checks for this using the “Was Actor Recently Rendered” node. (Because the more popular method of converting the object’s world location to screen location and checking if it’s within the screen bounds does not seem to work ...
I'll just drop this here while I wait for an answer, I appreciate any help I can get.
do you have screens or something that shows the problem
could be the bounds
Bounds?
show us the actor and show us the problem happening
go on the mesh
and type bounds
if the bounds go over the wall
then it will assume its being rendered
have you tested it more far away from the wall
put a wall and the actor after wall far away
I'm not sure what you mean by bounds go over the wall.
It's just for testing but it's a big wall a pretty big wall.
hey guys, what I am missing here ? I've set up a timer that basically runs to 0 and you die unless you are on a checkpoint, it works fine but what I am trying to do is that when you are overlapping a checkpoint (static mesh with a trigger box) the timer will be frozen. I thought to do a loop but for some reason is not working?
i loop will freeze your execution. everything in bp needs to execute one node at a time. if you have a loop the execution will be "stuck" inside that loop
the problem is on that if statement
a better alternative is to use "tick" instead
make a breakpoint in it using f9 and check the variable values
You mean the branch right?
yes, also use the player seen variable get
dont take it from the set
put one there separately
that is what i dont understand for some reason it goes like if i wasn't into a checkpoint but the actor is actually overlapping the box
and the other BP is set wit the checkpoint after overlapping
Putting a breakpoint there doesn't let me do anything because the condition was called immediately, so I can't even move the player to test anything.
Hi, just wanted to get some help (please bear with me, if it sounds like i'm asking silly questions it's because i've only been learning the software for a month or so for my Uni work). I have a mesh that basically will damage the pawn on collision, but it only damages once on collision and won't continue to damage over time until the collision event happens again. Does anyone know how I can loop the damage so it will keep damaging the player while they are in the collision radius?
What do I connect it to?
check the variables in boolean
one is true when it should be false
something like this
you are connecting a set variable to the branch
disconnect it
and put there the variable Player Seen separately
Why is the physical material param of this hit empty every time? I know I've got phys mats on these objects.
ty, what is the set node i can't find it
nvm i am stupid lol
I'm sorry but I'm very confused.
I'm new to Unreal, how are you able to tell which variables are true or false? Are you talking about runtime or something I set in the blueprint itself?
Also I told you the part about the NPC detecting the player is working fine, I'm sure my code isn't perfect but the part I have a problem with is the player detecting the NPC, not vice versa.
The player seen part is intentional.
How do I fix the part about the NPC continuing to render even though it's behind a wall?
this is because your booleans are wrong
and i could tell that you connect a set output boolean to the if statement
which sometimes can cause issues
but other than this
you must debug it
normally you connect the output of the set variable if the execution is connected
else is best to just place the variable again
but this might not be the issue
learn how to debug
Pawn sensing was replaced by #gameplay-ai perception
You should use the latter @grizzled roost
Is there a way to mass create blueprints that adds an inherited thing to them (from clicking on meshes and create bp from selection)
I just wanted to set it to true and past along, there, not that it will fix my problem.
could this be that in the overlapping I need to add the playe somehow? I've done with a tick and still it is not recognising the player on checkpoint so it has to be an issue with the overlapping
I know how to debug text based code, this is all very new to me.
Doing this one by one sucks lol
try print string node, print both the Player Seen and the Was Actor Recently Rendered on tick. You will be able to see which one is causing the problem
Again, that part of the code works as intended, what I'm struggling with is the NPC rendering.
You want to cull it or what
I want to cull it when it's behind a wall, which should be happening automatically.
Based on what, are you using world partition? Or are you talking about it being culled when the camera is not looking at it
Make them actors to begin with? 🙂
You could prly use some form of blutility but not sure it worth the effort
I have to do that now. I just have static meshes lol
I'm talking about Frustum culling, which to my knowledge is a default feature of Unreal Engine.
I don’t recognize the name but afaik normal culling in engine occurs when the camera is not looking at something
Yes, that's already working.
But also
Unreal is supposed to cull stuff that's obstructed from the camera by other stuff.
Maybe. I haven’t heard of that though, and it would be annoying to have to force each thing to render because you have an obstacle in between
Not sure where you could find an answer to this, maybe #ue5-general or #level-design
Nothing to do with blueprint afaik
The NPC IS being rendered despite being behind the wall, what to do?
show me the code
I know it's a mess, it's my first blueprint so don't be too mad lol.
@cyan bone
It's just a quick test anyway.
View Frustum
look there
What does checking if it’s been rendered recently do tho?
Also those docs basically say exactly what I said
If not within camera angle (distance, etc.) -> cull
There’s also the question of why you’re doing this
Premature optimization is a bad idea
And if it’s just a test, I’d say you have the result at this point
I'm not optimizing, the game will be a small one anyway, rendering is related to a game mechanic, the NPC only moves when not rendered, like I said in the thread.
So I want to move when not in view of the camera, OR when hidden by an object.
Maybe I didn’t read up far enough
Basically, putting a wall mesh in between the two will not get it culled.
It would need to be at a certain distance or outside the current facing angle of the camera
What you can do if you want is use perception or line traces to determine when it should move
Those you can customize to your heart’s content (some conditions apply 😅)
It's the third line of the post.
But yeah line traces are a great idea.
I used them in Unity but only once, so i forgot about them.
I tend to skim when it’s a bunch of back and forth, mb
Fair.
So I create a bunch of line traces to cover the entire fov of the camera?
Like this, but many, enough to cover everything I see.
Would that impact performance in anyway?
u r making raytracing lol
You could do multi line trace or shape traces even (tho there are no real cone traces out there) or maybe perception with EQS if you want
Depends on how precise you need to be
look at this madness https://forums.unrealengine.com/t/cone-trace-with-proper-distance-steps-and-start-end-radius-size-controls/88194
You will need variables for max distance, start/end radius, a vector, total number of incremental steps you want. In the first part of the blueprint, you first need to obtain the percentage per step and therefore you divide 1 by the total number of steps. From there, you can calculate how far the trace will travel per step. The rest of of it is...
my uneducated guess is that simply obscurign something isn't enough to cull it; how do we know that it doesn't have light interactions or bounces?
I was gonna ask if that's a thing because I only worked with lines in unity, is there a triangle trace? I can stack a bunch of those on top if each other if that's the case.
Yeah they usually make it with 2 spheres or complex maths
the engine won't know this, I imagine there may be some way but I think you have to make sure it in no way impacts the rendering of the rest of the scene
I don’t think so, you have boxes, spheres and capsules afaik
an alternative would be to use a invisible cone mesh 
Do some math to see if the actor is in the camera frustrum and if it is trace whatever shape you want between the camera and the actor to see if it hits anything
do it in reverse
Line trace from the top/bottom/left/right of the NPC to the player
A nice blend^
In what direction? The player could be anywhere.
excepting half-walls, holes, windows, etc, you can do a very simple line trace from the NPC to the player for its "existence"
And no line traces are not generally expensive, thought the draw debug option can be when you have a lot (which is irrelevant for production
lol set the line trace to end at the player vector
or the camera
on a side note, I'm just gonna leave this in here 🙂
Another stupid question, the camera's fov isn't a cone though, it's more like a pyramid shame...?
That’s a BT built-in node ^
oh wow, the BTs have it 😃
Here's a (hopefully) easy question: I'm using this to tilt a mesh based on its velocity. It works great without the RInterpTo node, but when I put that it to try and smooth out some things it just starts spinning like a top.
does your game have 3D movement?
"Bunch of traces lines" plan will have to do.
BT = behaviour tree. Not 3rd party, it’s an #gameplay-ai system
Yeah it's first person.
Oh
I mean can the NPC appear above/below?
in which case you don't need to worry about the real FOV, just the left/right angles
No, I want everything to happen on a flat plane.
In that case you can probably get away with just 2 line traces if you really want
Won't be enough, what if the lines miss the NPCs?
It's not just the location, the camera has to see the NPC, if this is gonna work the lines have to come from the camera, and there has to be enough of them to cover the entire FOV.
Then you have a boolean for both conditions
If you don't mind a little cpp you can make a node that exposes AACtor::GetLastRenderTime()
1 condition: Is there line of sight to the camera from NPC -> Camera?
2nd condition: Is the NPC's position within x degrees of Camera's forward vector.
Since it is on a flat plane, you don't have to consider the "pyramid" of the FOV
Just the left/right angles
I already have half of that implemented, hmm.
I just need a single line trace in that case.
sure, you can get away with that
the NPC's edges might poke out tho; which is why i suggeted from their outer bounds
if they're peeking around a corner
That's fine, adds to the horror.
I'm having a problem with persistent variables in game instances. I'm trying to make it so the game records the date between levels, and changes it if someone interacts with a bed/mattress. I've got the date saved in the instance, but it doesn't increase when I interact with the bed
p.s., sorry if I'm interrupting
I think he's got it
excellent
Just like that new game did it, Lethal Company I think.
Welp, I'll go do that then, I'll check back if I have questions, thank you all for your help!
Esepcially you Zap!
and I get the puzzle to work and the door to open...... when I exit the PIE I get this error!!!!!!
ngl I had to deal with some similar blueprint corruption issues
did this start happening in an unrelated blueprint sorta thing?
I need to fix it but idk how I have 4 hrs til its due and I am sooooo close and I am now crying cuz this is stressful
Your index is probably out of range in that array.get call
Hey,i made this logic and my rabbit must play the death flipbook after 2 hits,because he has 2 lives but he plays it only after 3 hits,also the projectile has 1 damage
Put a break point on that branch and make sure the values are what you expect to see
This should probably also be <= 0
oh shit yeah
This is what the bp looks like for the bed, and I got a thing that shows the date on the ui, but it's stuck on default even if I E at the bed.
i didnt see that ,thanks
this is the UI bp
this is the bps with reset plates idk where I went wrong
that's probably more pressing, can someone @ me later? I can wait
thank you all that helped ngl you all saved me a huge migraine worse than I already have. I just fixed everything and completed everything
hmmm, Can you get a Socket location from a ISM's instance?
Input events are usually meant to be used in the controller or a pawn that the player is possessing. It won't fire in random blueprints unless you "Enable Input" on them to begin with, but this then opens a can of worms as you're now having to code logic for enabling and disabling input on actors.
is there a way anyone can test the obstacle course for me is I sent a zip file for it?
ah, then I'll make the interact key in the player controller
Hi all! does anyone know how i can implement a widget text that will pop up on screen my user hits a object? or possibly know of any good youtube sources for it?
so for example, when my user answers a correct answer, that a door will open, i want to be able to notify them of it 🙂
Use your HUD class and create a function in it that can create and show the widget.
When something is answered correctly (wherever you may have it in your logic) you can do a Get HUD > Cast to your custom HUD class > Call the function to show the widget.
thank you i will give a go now!
Tried it out, changed interact key to fpbp, and it works perfectly. thx
hi, does anyone know how to make an acor respawn when it falls off the map? I have a ball I want to respawn back into it's original position if it falls off the map
I am calling this toggle music event inside the game mode but the target that it is calling is a different one than the one that gets called. I printed the output of this get a copy node here and also printed inside the actor bp to see which one gets enabled. It's not the same although there are literally no steps in between
how can this logically even be?
The toggle checkpoint event literally has a print string after the event node. So nothing else in between
If you have two pulls from the get, each will get its own random number.
what do you mean by two pulls?
If you have a second line coming out of the "GET", then it's going to call the Random Integer In Range twice.
This toggle checkpoint only gets called once. I also thought maybe its being called twice and thus it shows different results but no it's only going through once
I don't get it
the get output value should always be the same?
there is no second line, it's only connected to the target of the toggle checkpoint node as you can see there
No it won't because it's a pure node, it's evaluated each time you pull a value from it.
So if let's say you're printing the "Get" before plugging it into the "Toggle Checkpoint" then the print will pull a value once and get its own random value pulled giving you one result, and the "Toggle Checkpoint" will get its own random value pulled giving you a potentially different result.
Unless you're printing within the Toggle Checkpoint call... Then it should be the right one 😛
Eg. If you do this, then the function and print are each pulling their own copy from the array which each will get their own random value.
ooooo
let me try that
The fix:
this is only for the print to work, right?
but how I have it it actually is working?
Probably 🙂
How can i do this without referencing the exact character? Otherwise i can't open the doors if the logic is not in the characterbp (second pic). Or how can i get rid of the cast.
HUD class is a already created blueprint class or is it HUD widget i will need to create?
ophhh this oen??
Yea
Sublcass that, and you'd update your game mode to use the one you create.
?
hmm
check on tick the z ?
Whats the concern with casting?
if the z goes below a certain number your probably falling off the map
There's a kill z in world settings that does tjhe killing part.
why do i have to answer this every time? i want to keep my classes separate
Lol ok, gl
The answer is interfaces.
i'm using it but it won't work if the logic is not on the characterbp
cuz the character ref is the exact characterbp
I wanna do like that if the line trace hits the hitbox of the decal, the decal will rotate.. how??
My line trace doesn't hit the decal in the first place that's why I gave it a hitbox
but now Idk how to
Interfaces don't add logic, they add an interface. You still need to put the logic on the applicable object. There's no getting around that. If you want a bit more separation, use a component?
Why my line trace doesn't hit my decal and make it trigger the custom event?
If you're using interfaces and still referencing your character's actual bp, you're doing it wrong.
How do I put collision on a decal to make it hittable by a line trace
is your decal on a flat-ish surface?
it seems that you can't, you need a separate mesh / triggerbox that detects the collision https://forums.unrealengine.com/t/possible-to-detect-collision-with-decals/323368/4
I was having the exact same problem. The only solution I could think of is to place an invisible mesh on top of the puddle so it will play the appropriate sounds. I just modeled a simple “collision mesh” for each of my decals and then placed them on top of the puddle decals in my level, made their material use the appropriate physical material a...
Yes on the wall
Yeah, I've put a triggerbox and separate mash. But how to I make the line trace notice that it hit the triggerbox?
.
would it generate a hit event on the triggerbox?
i'm actually not sure if line traces trigger like that.
Well I guess so. Otherwise "Break Hit Results" wouldn't exist
Check your collision settings
Make sure it block w.e channel you are tracing. Eg vissibility
and if Self made the decal, don't Ignore Self on linetrace
if you are rotating it , i assume you made it
Overlap
Make it block
but then every decal would have an invisible box blocking you... anyway it doesn't work
Overlap not gonna stop your trace
block or overlap the thing won't work
Break your hit result, print string the hit components
Also just share your code
It's easier for others to spot the error
It's above
Print string on empty space
Then connect your hit comp to it
It will auto get the display name node
i'm not. i just didn't know how to get rid of the cast. i just found out i can use an interface event to call another interface event. i wish you would have said this
An interface event to call another interface event?
Easy way to not get help in the future
Don't understand why people have to vent their frustration when they can't figure things out
The sun is a lie?
Open console and type show collision
i was calling a regular event instead
Always print string to debug when it comes to collision
You could just call the regular event...
If it's widget u can use widget reflector
I mean, that's fine, but still.
Lemme see if I can fix it
no then i need to cast to the receiver to set the target
vehicles can all share a base class, you don't need an interface
Surely the receiver is just 'self' ?
no because this is in characterbp
It doesn't read the static mesh anyway
Open console in pie and type show collision
Why do you have a single interface both for the character and vehicle?
That's what confused me.
i'm so confused. isn't that how it's supposed to work? one interface talks to both classes
Which pie? You made me hungry now
I know this screenshot is technically from MetaSound but I've got a question regarding comment bubbles.
Is this a clear way of writing out comments? Is there a nicer way to put what I'm trying to say?
It seems to be blocking. For sanity check, make one afloat in space not behind wall.
Pie is play in editor
Trace to the plane only and see what you get
Purple is the decal
No. An interface defines the set of functions an unknown class has. You should implement every function on each class that implements an interface. In your case, I might have BPI_Vehicle which has the methods implemented on vehicles and BPI_VehicleDriver or BPI_VehiclePassenger or BPI_VehicleUser which has methods implemented on things able to use vehicles.
If you have something which can both be a vehicle and use a vehicle, you implement both interfaces.
You don't have a single interface where one half of the objects implement half the interface and another set of classes that implement the other half.
Okay. I found the problem. Basically all the collisions of the meshes of this pack are fucked up and are covering my decal.. it wasn't the decal the problem
my code was okay
lol
but in the end everything will still work the same without fragmenting things to a million pieces will they not?
Sure it will work, but you're not using them correctly.
You can bash a nail in with the handle of a hammer if you really want to.
It'll work, eventually.
Thank you sir ❤️ 
You try any sort of validation on your interfaces, e.g. "Does it implement all the methods?", then it will fail currently because yours aren't designed for that. And that's where bugs occur.
idk the "proper" ways but atleast i'm trying and so far is working 😄
there are not good enough guides out there to show the proper ways. everyone just shows the most basic stuff
idk the "proper" ways
You do now.
Is there a way to have the variables for an actor-component be set from the editor window to another one of the components?
My component AffectedByGravity is what the GravityManageruses to propagate all the effects; I'm wondering how each instance will find the mesh/primitive/character to apply the forces to
So i only implement one interface for each class? BPIVehicleUser for the character and BPIVehicle for the Vehicle?
Something like that yes.
If you make other systems, you might add more interfaces.
But specifically for this, it would be 1 interface per class.
thank you. small progress is still progress
I suggest you copy the one you have, update either your vehicle or character to use the other interface, then delete the methods from each which are wrong.
Hmm but here i can't call the event on character if it's not implemented. what do i do in this situation?
Why would you need to call a vehicle event on a person ?
If the character needs to have the event, it goes on teh vehicle user interface.
If a vehicle has the event, it goes on the vehicle one.
ugh my brain. i need to get reference of the vehicle so i put it on the user because he needs it is what you are saying?
ye nvm i guess it makes sense
Now how would i fix this ugly cast? This cast is the child class of where the logic is
It's easy to say but i haven't fully grasped interfaces yet! Not sure how to use them in every situation
Please be more specific. How!
How demanding 🤣
Interface is simple and straightforward
If something implement this interface, run existing function in the interface
I'm not a native speaker which is not making learning any easier
Interface is not your answer to everything, you need to decide sometime to use component or base class.
Putting interface all over the places is ugly and can be hard to debug imo
U use interface when you want something to run on classes that don't share the same base class
For interaction, it's normally either component or interface
i'm using components but interfaces for characters x vehicles
Easy example is like a door and a light. Both can be interacted, both implement the interaction interface
In your character bp you don't need to get direct ref of the door or light
U simply , for example line trace. Get the actor. It can be either the light or the door.
If the actor have interaction interface then run interacted via interface
Thus communication can be done without the need to get direct ref to the light or the door
Indeed that's what i have done so far. But it's alot more confusing to me with character x vehicle because of the complexity
Do i implement the vehicle interface on the animbp and send the variable though an event? does each variable have to be a separate event?
Should be the opposite... AnimBP should be reading values from its owner, you shouldn't have to feed values into the AnimBP.
Your anim bp shouldn't need to call any logic
Anim notify begin -> get owner -> cast to w.e it is. Run some function
i mean these are on the animbp but the logic is on the vehicle
but i need to feed the value into the animbp. i'm so confused again
lol
The value should be stored on the actor that has the timeline.
Your AnimBP should be reading the value on its Blueprint Update Animation event and setting the value in its own variables.
Broo i'm stupid. I did it like that for some other stuff and not this. My badd. Fixed it. Thank you! Idk why i didn't think about that. ughh 😄
this was so simple but felt so complicated
Now my final cast problem is this in the vehiclebp. not sure how to get rid of this
Hence my first question, what's the concern with casting?
Your mission seems to be getting rid of all cast nodes
yes
Why?
i want to keep my character and vehicles separate
so they are not loaded all the time
Learn cpp so it doesn't get loaded all the time. In cpp land you can freely cast.
Casting to cpp class won't load the class to memory
You can't escape it in bp
You don't use interface for everything, this is not right
What's locomotion anyway?
you see me struggling with bp. what am i even going to do with c++ lol!
character animbp
Well first of all u don't want to make a call to your anim instance
Anim instance just read
Ur bp is what drive the logic
okay, i think i might have an idea how to rework this
Question: I'm assigning an event in a child class of a gameplay ability to an event dispatcher in the parent class. The event fires when my instancing policy is per-execution, but doesn't work when I set it to per-actor. The dispatcher is being called in the parent class event graph, if that makes a difference. Why does setting the instancing policy to per-actor do this?
How could I make this then one have a 1-3 chance to play?
You typically don't want to handle logic outside of the gameplay ability itself. It's meant to contain logic and call to other things, or send gameplay events which other things can listen to, but you really shouldn't be referencing an ability as an object in some other class which is what you would need to do to bind to an event dispatcher within the ability.
So putting some of the logic in the parent class and calling it in a child class is also a no-go?
Things that go through an interface are already replicated? My brain is kinda dripping from my ear already
Oh I think read what you were doing wrong... Within the ability itself should be ok, but you shouldn't necessarily need to do this within a child class. As it is a child class, you can override events and functions of the parent, so where your parent class may be calling that event dispatcher, you can have it just call an event, and then have the child class implement that event how you want it to implement it.
I was thinking of having these event dispatchers also work as a trigger for stuff outside of the Ability System like updating the UI, should I be doing that some other way?
Eg....
I have a parent class "Charge Ability" that has some logic for handling an ability that requires its input held, and then I override what I need to in a child class, like this ForceRepulsion that just needs to handle the execution.
You really shouldn't be using event dispatchers to communicate outside of the ability.
Again, that requires you to have a reference to the active ability and bind to it, which isn't great, and yeah the instancing set up can mess with that.
You can send gameplay events which you can listen to in other classes.
There's delegates that the ASC has for certain things too, like if ability activation failed or was activated successfully.
I thought gameplay events could only be received if the Actor has their own ASC on it, so I wasn't considering those. If that isn't the case then I'll try that. As for the built-in delegates that also sounds useful
yay i managed to get rid of the cast!
Probably best to keep in mind that cast is unavoidable one way or another. The best thing you can do to migitate the drawback of bp cast is to cast to base class
it's not completely avoidable but i can avoid direct casts and use indirects instead in components
that way the primary actors will not stay loaded
afaik
That's not how casting works
It only loads if it doesn't exist. And if you use proper base classes, which you should, the cost is basically nothing
An interface does not solve the issue of the loading either
A hard ref is the cause of it
What im doing is the same thing. Removing hard references
You're still using hard references though. And not all hard refs are bad.
Read: proper base classes
What hard refs do i use?
The one to message your interface? The difference in size between one of those and a proper base class is practically nil.
Put it this way, if you cared about that loss, you wouldn't be using bp to begin with
You appear to have a casting is bad mentality
It isnt
I only try to cast to character not thirdpersoncharacter etc
I guess they are called base classes?
Character is indeed a base class
Point is, don't abuse interfaces. A lot of interface work arounds end up doing the same thing a cast does, and just giving you more implementation cost
Yea there's something to be said about ensuring classes are decoupled, but in some cases it wouldn't matter. Like a door animation blueprint being decoupled from an actor that houses the door that is using it... why? It has to be loaded with it anyway.
I'm not using interface for everything. I only have a few events. I'm just not using a component for the vehicle stuff. Only for character stuff atm
I'm decoupling the character from vehicles. It's a big difference. I'm not trying to decouple vehicle animbp from the vehicle. That makes no sense
As long as you are aware. You made some concerning blanket statements :P
I'm learning new stuff about the proper ways constantly. I'm not saying ik what I'm doing but so far i think I'm doing it right. Not being native also makes it harder to understand
hi all, does anyone know why this doesnt work
ill make the links smaller one sec
the format text isnt showing with a pin :(
if a character has no ai controller it does not respond to either of these nodes, any idea what could be the cause?
its electric something, a plugin
this one, its not super expensive especially if you grab it on sale
this, correct?
ya
thanks :)
You can click the "Add Pin" on the format text and then you can specify the actual variables you want to use and feed in what inputs you want for them.
In your case, you want an "x" variable.
thanks :D
hello! I have this function where I get the Savegameobject from the gamemode using a actor component. Using this method, is the component begin passed in vis Ref or Copy?
is prolly a copy right?
this would be a reference
(outside function)
A copy of the ref
So don't matter in this context
U r still pointing at the same reference
a copy of the REF and not the data itself right ?
Not sure what u mean by the data it self
There's no diff from pic 1 and pic 2
U still get the same object
so my game save can be pretty big.
Yeah don't really matter prob
i dont want to copy the data, i want to just source it (ref)
What u get is a copy of the object ref (pointer/address)
U r not making new instance or anything
ok awesome, that's what i was wondering
Thanks!
now that you explained it, it clicked in my brain that I could have just changed a value inside the function and check if it carries through 😂
slow brain
Not sure with the goal 😄, I normally use game instance to store my savegame objects
i had it on the game inst, but i moved it to the game mode because i think using a component would be much eaier to access
How do I get asynchronous functions? Is there any way I can use an asynchronous function for a continuous action instead of event tick?
If you have a dmgbox attached to hierarchy of a mesh, and you move the mesh with a timeline, will the dmgbox move with it as well or do you need to move it as well ? I do not fully understand it
If you need to do something every frame, then tick is the way to do it.
You can use timers if it's something that you want to happen after a set amount of time.
Timelines act like tick for a certain amount of time, but if you're doing it all the time anyway then you may as well use tick.
Tick can be enabled and disabled, and you can also change the tick rate. So if it is something you want to continually happen for the lifetime of the actor, then tick is usually the way to handle it.
Moving a parent in the hierarchy will move the children with it.
"By binding one or more events to an Event Dispatcher, you can cause all of those events to fire once the Event Dispatcher is called."
Is it ok to have it the opposite way where you have many calls to one function?
I've got a bunch of buttons on the screen, all of which are mutually exclusive and modify the behaviour of the left-click in the game world. Right now I have an enum I'm storing in my playerstate that represents the left-click state, and my controller switches based on that to actually perform actions. Is there a better way of architecting this? I'm conscious I'm creating an enum that will end up having dozens of possible states
The purpose of an event dispatcher is to provide a means for many things to listen for the event so they can do their own logic when that event dispatcher is called.
Many things calling to the one function is nothing more than calling the function which would then just do what it has programmed to do based on its inputs anyway.
hmm as an example, in the future I might want the players health value not only displaying in a HUD widget, but also above their head in using a widget component
would this be a case for a dispatcher?
Yes, you'd have the event dispatcher wherever your health value is stored, and call the dispatcher when you change the health value.
Your HUD and your Widget Component would then need to get reference to wherever your health value is stored and bind to the health event dispatcher, and their bind can then have them update whatever they display as needed.
tyvm
would anyone be able to provide an example of where you would see or use aggregation and composition within a blueprint setting?
some of the examples online seem very foreign to someone who uses blueprints as a hobby
I may not be 100% about this as I'm not well versed with the lingo, but after doing a small amount of reading this is how I understand it:
Composition would be like adding actor components to an actor to give it functionality. An example in your case would be a component that manages health - you can have the logic for adding and removing health, as well as that event dispatcher we were talking about built into that component, including having it bind to its owner's "Any Damage" event to actually reduce the health when damage is applied to the owning actor. This then allows you to add this component to a variety of actors regardless of their base class, and they will all act similarly to managing their damage as you've defined in the component. Change the component, it changes it for all owners of that component. The component itself is useless and cannot exist on its own, but attached to an actor it can perform its function. Destroying the actor that houses the Actor Component also causes the Actor Component to be destroyed.
Aggregation would be like utilizing the game state for handling scores. Many things can read and write from the game state to manage and view the scores, or otherwise "use" the gamestate in such a fashion, but the gamestate can still exist on its own independently from any other actor. You create an association to the game state in whatever actor is using it, but destroying any actors using it doesn't cause the game state to be destroyed. Perhaps a different example would be like having "lights" and "switch" actors - you can create many associations between these actors, but destroying a switch wouldn't destroy any door or vice versa, so they can all independently exist.
Now if you had a "light" that had "switch" child actors (which are components!), you're now creating an example of composition in which case if you did destroy the light parent, all of its child switches would also be destroyed.
You wouldn't necessarily want to create separate actors for everything, but you would likely want to have logic that is shared among dissimilar classes, in which case a component is usually warranted, especially so if it's something that should be instanced per actor so it has its own state, and if the logic/entity doesn't need to remain if the actor itself is destroyed.
If i have an actor that spawns pawns in the world, but isn't the only way that can lead to X pawn existing... would that be an aggregate relationship?
Also the relationship between a pawn and player controller as i understand a P controller doesn't always need a pawn(?) but both need a game mode
Sorry, i will screenshot and mediate while learning 🙂
I don't think so. Spawning an actor doesn't really create any relationship at all between the thing spawning it and the thing being spawned, but if for example, you added in an event dispatcher in the pawn to signal when it dies back to the spawner and you bind to that dispatcher after having the spawner spawn it, you've now created an aggregate relationship. The spawner could still be destroyed and the pawn could still exist independently of it.
There is actually a composition relationship between player controllers and their controlled pawns because the engine destroys the player controller's controlled pawn when ending the play of the player controller, however, a pawn doesn't necessarily need a controller possessing it.
woops, thanks again... it seems kinda simple explained that way
Can I get anybodys advice on this error? everything works as intended but it still pops up every time
Accessed None indicates you're attempting to use a reference variable with no value populated in it. In this case your "CharacterRef" variable. You may have set the type of the variable to be of your Character blueprint, but you need to actually get the instance of the character that has been spawned that you want to reference and set it in that variable.
You are right thank you, I stopped using the character ref and just used a get player character instead and everything seems to work alot better with no errors
You could also try using isValid on CharacterRef before using reference
Why is my sword spawning below my character?
Socket names are correct. I copy and pasted them
looks painful
Ya and infuriating haha
did you add the socket to your skeleton
try renaming it to "SwordL"
maybe thats the problem
cause everything looks correct
I've spent the last two hours trying to figure that out and if its the problem im going to lose my shit.... LoL
Nope
Still impailing him
what the hell
When I drag it into the world its the correct scale. But when I preview mesh in the skeleton its a mile and a half long.
The scaling is set to 1 in blender.
Check Ur socket scale
Trying to figure out loading a game from one level and transitioning to new level, then setting variables on the character. Location, Rotation etc.
My save and load functonality is held in the game instance. Called to from the front end menu on continue.
Anyone have any pointers?
@fallow epoch Did you have to scale your character down when importing?
By loading a game you mean you want to load a level?
I think I figured it out. I had my root bone hidden on my character in blender. I applied all scaling to everything except the hidden bone..... fixing that and seeing if it fixes the problem. I just notices my scaling was not at 1 when I looked at all my bones scaling to see if anything looked off.
@frosty heron Sort of. I am on the main menu map, when I click continue, I want it to load another map. I can do that fine. But it doesnt want to load anything else after the level has loaded.
It should also be loading the character variables.
Can you elaborate more on character variable. Assuming this is single player and not server travel, every non persistent object is destroyed
If you need to save your character variable or stat's. Set them in game instance before opening a new level. You can then reconstruct the character with the variables from Game instance
The only character variables I am concerned with at the minute is its location and control rotation.
Singleplayer yes.
. U can store any type of variable and apply them
Have u figured out how to do save and load to begin with?
yes in a single level.
Just test with saving and loading simple integer if u havent
Singlw or multiple Level is kinda irrelevant . Your savegame object is stored in game instance
U simply load from slot form continue button
Data will be loaded even before u open new map
Ok, Currently, for testing, i have save and load mapped to 5 and 9. All it is saving is the character location and control rotation.
In a single level, i can save, move and load and it works as expected.
When I click continue from the main menu. I am in a different map, I want it to load the correct level (There will opnly ever be one map). Then load the players saved location.
But the game mode, player controller, pawn are all changing on the new level.
And Im just not sure how best to tackle it
You should save the map you want to open too in your savegame object
Continue should open the last map opened or the map intended to be opened
Saving transform is trivial, is no different than saving any other types of variable. Eg an int.
And that is working. But it is getting lost when travelling to new level. As if it happens before the player character is loaded.
No point saving the level to load as it will ALWAYS be the same.
Would anyone know why my BUllet count is not reducing ? First print always gives 11 while second print always prints 12. The event gets called once upon firing a weapon. It then gets the weapon in hands, get the bullet count, reduce by 1 and make new
You'd need your game to know whether it's loading from a save. Basically, you could just set a reference in your game instance with your save game. The game when loading in can check the game instance to see the save data it should be loading if it is valid. If nothing there, do it as if it's starting from scratch.
If valid, have the actors read the data they care about from the save game reference.
So clicking new game, set the save game ref to none... When confirming to continue from a save, set the save game ref and load the desired level.
Sounds like it doesn't work at all then. I'm talking about the value in your savegame object. If you have it in game instance it's persistence and Unaffected by any level change
Once u load it, it's there
Yes. What I am trying to find out is when and where can I apply that variable to the player character
It works, but not on level transition.
If the first thing the load or continue function does is open a new map, it is applying the variables to a character that doesnt exist yet
That's on you to design. Why is the character don't exist yet when you try to apply your values? It would give u accessed none error
You can override Spawn Default Pawn For in the game mode. Have it read the game instance to get the saved transform of the player if the save game ref is valid. If not, use your start spot transform provided as an input in the function.
Open new map, spawn player , apply your saved variable
Your "Get Inventory" function is likely returning a copy of your inventory array rather than a reference to the inventory array.
So for some reason when I export from blender as an FBX it adds a bone above my root bone with a scale of 100
Common problem, seen a lot of ppl with the issue
I don't use blender tho so no idea how to fix it
Unreal unit is cm
Instead changing the unit scale, change from metre to cm
@fallow epoch
This is literally what I am asking how to do
Which part are u struggling with? I would assume you would know how to spawn your player. Are you using game mode?
Yeah. I have two game modes, one for the front end, and one for in game.
I mean only the game mode in the map you open will be relevant
Datura already told you how to do it.
Basically once you override and can get ref to your char . That's when you can load your saved variable
@fallow epoch This was gonna be my next suggestion.
This is my load function currently. Within the game instance.
This works when I am in the level and save and load. It just moves the player to its saved location
That's not gonna work. You only want to create new save game object when one doesn't already exist
Right now u r just creating new savegame object everytime you call load player
You should have a function in your GI called load savegame and promote it as variable.
Your load player will simply be . Get game instance, get the promoted variable -> get hp/transform/w.e
The save game object as a variable?
You should set reference to it once you load it yes. You load once, that's it
I havent fixed it yet but I know for a fact its the FBX scaling from blender to ue5 that is causing the issue.
Your metric is wrong
Unreal use cm not meter
Change it to cm so it's 1 to 1
I did
@fallow epoch This is well documented yes. You need to properly set the scale in blender. Especially when working with skeletal meshes.
Also, wrong channel.
It started as a blueprint problem because my mesh was not attaching properly.
@frosty heron So, The reason I added the create new save game object in the load function was because it wouldnt have a reference to it otherwise.
I am now creating it on init from the game instance. So that would mean it is only ever created once?
Save function
Created if none exist and loaded at main menu
Does save game exist? No? Create new one
Yes? Load it and set ref so u can use that for your character or other bps
Again. This is loading and saving fine when in a single level
Your load player just get game instance, get mysavegame object , get transform. Apply transform
Yea can see the problem why it doesn't work
U r creating new savegame object all the time. Next time you run the function, it won't even get ref to the same savegame object
So why is it loading and saving just fine?
Its probably doesn't do what u think it does
I honestly have no idea.
When I load the map, i can run around. Hit save, move to a new location, hit load. And it loads the previous location. Thats literally all I have implemented it to do.
And I am using the same SaveGameObject everywhere. It is only ever created once.
On gameinstance init
You don't want to do that when savegame object already exist
You don't need to create a new one
Simply load from slot
U will get a return value of your savegame object. That's what you need to use
So get rid of that create save game on init
ok
Create a function in your gi called load game
It goes like this.
Does save game exist? If true , load from slot, promote return value as variable
If false create savegame object. Promote it to savegame variable
Hey Guys im trying to LineTrace on Random points in World
how would i get start origin and end origin when i jsut want it top spawn "Randomly in whole level" ?
basicly "Spawn anywhere in level "
Set after cast
Also I will call it load game instead load player
Or at the very least loadplayerdata. But normally I only have 2 types of savegame.
Savegame for gameplay and savegame for achievements and settings
So I keep everything related to the game in one save file
Also while u at it, should have function to delete game slot too
Or overwrite them
Nah, you would only call savegame when you already load
Or at least call the load function
U will have valid savegame object.
So all you have to do in savegame function is.
Savegameobject -> save game to slot
No no
So I dont need the create save game object and setter here?
Trouble with that is if I try to save I get errors stating its null
how would i get "ranom point in Level" or whatever without using a bounding box ?
Because u never load
@steady night You dont. Only other option would be within radius
hmmm
Yeah exactly. So its breaking in editor. But in game, you HAVE to load before saving.
Is that what you mean?
U should think your savegame the same way u would in any video game u played. Resident evil, baldurs gate, etc
To test is, you have to start from your main menu
Gotcha
And load the slot then open the map
OK.
U can always make a debug function too ofc
If u just want to make a new savegame object but I don't c much point
This is the functionality for the continue button in my front end menu.
Yea u don't typically want to hardcode it
No I know. Just testing
Give me a name of a game
Haha
Well should be the same
Sorry I thought asked the name of my game
When u try to load skylight u see your slots right?
That is basically your slot name
Yeah.
So in main menu whenever u create new game. You can just assign SaveGameX
haha, no i re-read it as soon as I replied
xD
X being the number of last available slot +1
So creating 3 save game will look like this.
Savegame1, savegame2, savegame3 and so on
Or ask the player to input their own slot name 🤷♂️
Skyrim prob let u do that
Yeah I get ya. Not got that far yet.
So on new game, I essentially save immediately with a new slot name
Right now u can hardcode it to test I guess
If u want
ok
It will create .sav file in your saved folder
For my game, I will save the game only when the player finished customisation
I think I am probably going to just use a single player profile.
In Skyrim for example you can have multiple profiles for multiple characters.
Not decided on wether or not to do that yet.
So just using a fixed slot name
What I need to figure out is continue game function.
how dose this Half size work ?
if i want it to include the whole box what do i do .o
Boz Extent is the half-size
Your centre is the size area location, your half size is your size area -> box extent
@frosty heron So how do I go about setting the location of the player AFTER the level has loaded. That's what I don't get
Got it. I think
Might be a hack but I got it working.
I have a bool variable in Gameinstance. bContinue, false by default.
When you click continue, it is set to true.
When the Gamemode for the map loads, it checks the state of said bool. If its true, it loads. Then sets it back to false.
Getting on train brb
Hi all, I'm trying to get an animation to sync and look the same for everyone on the server, does anyone know the reason my blueprint isn't working?
you want to switch the macro to "remote" instead of authority
and for authority it can just play it's animation no problem
Anytime you want to save. Think of it like check points. Or when in skyrim the player press esc and click save game.
You can just get the player character transform and store its data in the savegame object located in game instance
You need to somehow match the time. But practically you can't get them to play at the same time because in network environment there is delay
You can try fast forward the time for the client (which is a drawback it self). Perhaps by accounting for Round trip time and the current position of the anim the server is playing
Other than that prob not much you can do
Also I don't think multicast is the answer here
You prob want server to run client rpc and send the anim time + rtt as a value for the client anim position
hey I've just started with blueprints today following a tutorial to get the third person character to fly
I'm trying to change the max fly speed to go quite high but there seems to be a limit to it no matter how high the value is.
Thanks very much I'll look into that
Actually scratch that, run on owning client will only play the montage for that specific client.
Multiplayer is hard 😔
from a line trace, how can i get the color of the collided objects vertex?
Yeah this stuff is rough lol
They seem to be like .5 seconds out of sync for each client I add aswell
Not the hardest bit unfortunately. If you are doing turn base game it's probably fine. Real challenge is when we have to deal with a game that depend on latency. Eg fps
And I assumed u haven't even simulate lag?
Nope
The rpc prob get called at begin play. Each player begins play are not the same. You can see lag when the screen start in pie.
That's prob what makes them get called in different time and we haven't even put some real latency for real test
I think Unreal uses repnotify to play animations. You can try to sync the time on the rep notify function
Set play at , server anim current position + round trip time
What nodes would help me do that? Sorry I'm still pretty new at this
Hi, I have a widget where I am rewriting the onkeydown function, and the issue is that the gamepad face button bottom is recognized as a left mouse click. Does anyone have any idea where the problem might be? I am using the common UI plugin to track the input method change, and it's for displaying text that disappears when a button is pressed. I don't have any issues with the other gamepad or keyboard keys; it's only when registering the A button. Thanks for your help.
Don't have editor on me but if u can't play anim at certain position then your option is to use anim montage
can anyone help in terms of how I would ensure a timer I run is running on game thread.
currently I get the known issue of assert if accessed outside game thread
Erm, how do I store an actor reference in a widget? There are multiples duplicates in the world but I need that one specific
yes but how do i tell it that one specific actor
I should set these variables in the vehiclebp instead right?
@toxic jay
you can make the Auto Door a parameter with Expose on Spawn = true, so that you have to pass in an Auto Door reference when the widget is created
thank you both, that worked
essentially, i needed 2 refs
one exposed on the actor that spawns the widget and in the widget
yep
much love ❤️
Anyone know how I can hide and show variables depending on whether the enum is on corrosponding thing
and when their hidden they retain the value
Hello.
I would like to be able to remove the gun in the first person template after equipping it, does anyone know how to do this?
Make a new input action to use for the drop, put it in the weapon component and on started, spawn a new copy of bp_pickup_rifle and destroy component self
Basically the opposite of the pickup
only in c++
arr okay thank you
@frosty heron Sorry to ping but is this the "proper" way to do this?
why is trace complex making my linetrace inconsistent?
like sometimes it manages to find something
and other times it completely fails
really jittery
i do need trace complex because findcollisionUV only works if its enabled
So weird i got rid of all casts between character & vehicle. The vehicle is still hard referencing the character, but the character is not hard referencing the vehicle. What is going on?
Variable types count as hard references.
i don't have any variables that reference the exact bp. only one for base class
Base class = Character?
yes
Shrug
Close the editor. Backup your content folder. Delete the character uasset. Load the editor. TRy to compile the vehicle BP. Look for errors!
😄
Literally no errors😭
I don't know what is proper because I always find a better ways from time to time.
I don't agree with setting the wheel from anim bp.
You should just set the steering wheel every frame in the vehicle bp and the anim instance just read from there
the wheel handlers are static meshes in the vehiclebp. I'm getting the references via interface to the characterbp and setting the locations from there. the animbp grabs them from the characterbp
Why isn't the dependency chain like this:
Input -> float steering angle -> steering wheel rotation -> hand placement
Character animbp should just read the locations (assuming hand locations are sockets on steering wheel mesh) and never write anything
why does my character not react to these nodes when the AI controller is set to none? as soon as i set the ai it works fine
i know asked this but it was really late and i think it got buried 😄
Can anyone assist me? So I have a conveyor belt which moves an item along it, the player can spawn/create them and place them on a grid. The issue I'm having is, I have a collision box to move the actor that lands on it but by the time it reaches the 2nd conveyor belt the offset speed is double due to double overlap, how would I get around this?
Doing your grid based building with so many overlaps isn't good
Just clamp with maths
The engine even has built in functions for calculating grids
When using a pure cast to say the gameinstance. What is the difference between using an Is Valid and a branch from success?
https://gyazo.com/93588e2f96f0d7594765e535e630dc0d
why does tracecomplex do this? when a cube shows its collided successfuly, but when it doesnt it means it cant find it. I need tracecomplex on for the project im making.
How would I clamp it?
Show mesh complex collision
I'd guess normal direction
complex collision
I forget the function exactly, but there's one built in for grids
and are you talking about the 2D grid execution macro? or is there another way of doing grids that I don't know of
Ah yeah I was getting confused with that. I don't remember the maths off the top of my head, but it's well talked about
someone can look #materials
Just be patient
i have wheel handler sockets on the vehicle mesh but i'm attaching static meshes to them in the vehiclebp. i guess it's not necessary, i could just adjust the sockets themselves. how would i set it up with just sockets?
I need to write from the characterbp anyway tho for handik. i can't have all logic on the vehicle. Because i'm interacting with the vehicle
In BP's, when you have a big scene (space, forest, city, etc) and want to spawn things, what blueprint is best practice for doing that?
not an expert but different spawner actor blueprints?
like car spawner, npc spawner etc
single player or multi?
@dawn gazelle in the end, using the array was the optimal solution. It made insertion much more smoother at the construction level
guys how can i see the range of my radial damage with falloff
draw debug sphere with the same origin and radius as the radial damage
thanks
multi
that is going to be more difficult than sp :/
I would refer to the multiplayer channe
Hi how do you get an actor to respawn in its original position when it falls of the map
Can someone visualise it for me
Thanks for the reply. I was able to implement it.
I thought I had to use the detach node, but I see I don't have to.
If the game was SP, how would you recommend doing it?
level streaming
isn't there a way to set actor location?
set a killzone with a mesh or something that triggers when they hit it
Maybe idk
i was trying to lead you into the idea that yes, there is a way to do that
Hi, simply want to use LaunchCharacter node with AI, but it doesn't work
Do I need to make a change in the actor details?
have you checked that the event fires?
still not working