#blueprint
1 messages · Page 336 of 1
when i hit play tho it shows just a black screen
Yeah, cause the camera is at 0,0,0 I think. In your tick function call SetRelativeLocation on the camera component and see if it defaults back to following the spring arm.
try do this and lag target is attached to a spring arm with camera lag on
He can't use the default lag stuff if he wants to disconnect the Z value from the rest.
not the best solution but simple enough
that's what im doing
im startin to get lost in the sauce
i tried dragging camer boom out and then set relative location
but i cant connect that to anything
Not the camera boom. The camera itself.
And you connect SetRelativeLocation to the tick event.
is that the followcamera?
im starting to think i just need to completely delete the default TP blueprints camera stuff
but im worried thatll mess up the input that turns the camera
let me send a full sc
So disconnect both Target and NewLocation from the SetRelativeLocation. And drag FollowCamera into the graph and plug it into the SetRelativeLocation node's target.
that took me out of the black screen void but now it doesnt follow the player
i can just see the player from below map start
i have sent the solution here
im confused tho cuz do I leave the lag target under hierachy with followcamera
and have it under camera boom
is lagboom just cameraboom
so turn lag off on normal camera boom?
yes
attached it but mines like a mountain icon
the screenshot is in ue4 so it looks different
ohhh gotcha
alright just did the BP
let me test
i think i broke somethuing
camera is still under map start
but it does that even when i remove all of the stuff i just added
change it back to relative
oop ur right let me try
which value should I edit for the lag now? just the camera lag in lagBoom?
lag boom
i think its still applying it to XY though
oh wait
nah its not
maybe the value is too low but it just cant follow the player past a certain Z
let me take a small vid
just realized i made a huge mistake
it might just be where i have the camera positioned but it has the cam a little bit below the player
the interp isn't necessary
just connect world z of lag target to the set world location node
i did
it might just be cam position
let me tweak that now that the Z lag is working
no matter how i move cam in viewport it doesnt change
the lag works perfect btw, thank yall
i just need to figure out how to get this cam in a better position to accomodate
im gonna guess its cuz this set the world location straight up
but not sure how to tweak it
move the lag target
that controls z of the camera
and moving the camera controls xy
got it, worked like a charm
thank you and @maiden wadi for your help <33
im making a small game demo for a summer class at my university and its been my first go around at ue5 so its been a trip trying to figure out blueprints
I know C++ pretty well but didnt have the luxury of time to mess with that side opposed to blueprints
Does anyone know why my scene goes completely insane if the Global Illumination is dropped below High(3)? Wasn't happening in 5.4 but is in 5.5...
@full badge one last thing with that lag cam, for some reason when the player has an object wit hcollision behind them it causes it to freak tf out
i think it just has issues seeing under the player in general
seems to freak out any time it has a collision itself
should I do set relative instead
it's the collision check thing
when you change scalability settings for global illumination look at the logs there you will see which cmd is applied to that specific settings, then find difference between 5.4 and 5.5 version
hi, Im debugging atm and cant figure out what Num=0 mean here? Length? Index?
Length of the array
How many entries it has. In this example, the array is empty.
appreciate it, thanks
anyone know if say I have this string below, is there a way to swap the Space for _
Bob Smith
so it becomes Bob_Smith
guessing Id split it at the space and join back together the left and right adding in _
Replaces every space with a _
I need to make a loop test on firebase test lab. Currently I get this error:
The application does not include a game loop intent filter, or the intent filter is not formatted correctly.
Currently I am adding to manifest using UPL like this:
<?xml version="1.0" encoding="utf-8"?>
<root xmlns:android="http://schemas.android.com/apk/res/android">
<androidManifestUpdates>
<insert>
<activity android:name=".MyActivity">
<intent-filter>
<action android:name="com.google.intent.action.TEST_LOOP"/>
<category android:name="android.intent.category.DEFAULT"/>
<data android:mimeType="application/javascript"/>
</intent-filter>
</activity>
</insert>
</androidManifestUpdates>
</root>
But it is not getting added to the main xml, I don’t know why.
Can someone help me resolve this issue?
Question, when making a data asset do you all prefer to add variables defining the structure or just make a struct that houses that information?
Depends on the case. Loose properties in the data asset are fine. But if they make sense to group together, then structs are nicer usually. Specially if they're related to some form of system where you need to pass that related data to functions. You can just pass the struct as a whole instead of every single property.
Ok makes sense so in my case it's the snappable objects to build so the struct makes sense I suppose
Hey gamers, not sure if this is the right channel, but I'm having trouble switching between a Gameplay Camera on my character and one in the world. Specifically, I want to be able to switch between fixed cameras on each player's board. I can't seem to attach the Gameplay Camera Rig to the Board, and swapping the camera results in behavior relative to the initial camera rotation
Anyone know how to account for an object being rotated after being placed when trying to make a pole fall over opposite of the direction when the player runs into it ? Seems to work fine as long as the object isn't rotated but as soon as I rotate it no longer acts correctly.
Figured it out , Combine Rotators node inputs needed to be flipped.
Pretty much everything with rotations can be done with combine and delta rotator
Hey, I’m fairly new to UE, and I’m having a hard time understanding casting, especially the INFAMOUS "Object" input. While doing some research, I came across a video explaining the "Cast to Class" node, and it seems like the perfect solution: no need to find a reference, just pick the right class and go for it. Is there a catch to using this casting node instead of the classic one?
That function just runs the normal cast operation. 😛
That seems hella cursed either way.
Object, casted to a class, through normal "cast" operation.
Personally never touched Cast To Class
And, even if you do use that node, its then impossible to cast an object, which you will need to do at some point.
So, just learn the normal cast nodes. 😛
They do the same exact thing, and have built in valid check outputs.
But, you'd still run into the same exact issues as the normal cast (not understanding how it works)
Hey guys how the heck do you update CPU water collision
there's no GPU readbacks
dynamic mesh don't work with tick
so can't put a sinewave on it
RT is too expensive and crap
and I can't get a sinewave on a basic actor mesh for some reason
was going to update an MPC based off the sinewave on a collision box, then update the PBR
but I can't geta sinewave on the collisionbox
how do?
hello is it possible to find like a friend here that i can ask questions from time to time?
i had a friend that i would ask sometimes and he would point me into directions etc but he doesnt have time anymore
im currently trying to figure out how timelaps work and i have a small "issue" with it imma explain it in a second i wanna tidy up the blueprints real quick
basically i just disabled gravity with a toggle key and when its disabled i want to use a lerp to slowly move the character up a bit but its weird imma show it in a minute
Okay so basically you can either use a linecast node to apply force (check out car suspension) and he will slowly fly up or you can do it the easy way and increase your Z position by a frac every tick
to use a timeline for this you need to move the actors location according to the timeline Z
so when you disable gravity you need to also begin the timeline, which will have a Z AXIS that increases at the speed (set it on the graph), pull off the Z node and add/set the actors movement speed in Z direction
that's it
okay your problem is in the fly condition
it moves the camera a bit up and then jumps down again. when im floating it shoots me up into the sky
when you press G you need to set it to is flying and at the end you need to set to is not flying
you also need to link the actor in the move actor location
also on your branch, you need to switch the nodes
this is the fly function btw
they are backwards
is the gravity scale a variable that is properly linked to the gravity?
yes that part works hold on
when turning the fly off again it launches me up and when i enable it it only moves the camera
Your G key only enables gravity to be 0
and flips the is flying yes
you need to make it so when it presses again or ends it resets the bool to "isflying" false
also the graph might be too short
is it set to 0.88? probably why, as for camera
I dunno make sure it's properly linked to the actor in its whole
btw when i set the second keyframe thats at the end to 50 instead of 30 this happens then it works but its way too high so im now sure what im doing wrong 😄
all the "targets" the blue pin connectors on the nodes need to be set to the correct reference
hm i will check that
its generally odd to me as the curve is smooth imo and yet it kinda is super slow at the beginning and then zips up
you need to set it about 15-20
actually it might just be that the camera is going up firstbut its too slow
to actually pick up the character
so you need to make it go slower and longer
it's probably too short for the increase
50 is fine for height but it will do it super fast cuz its too short
its set to one
you need to move that to like 20
going this way ---------------> not up
also make sure to set is flying to false after so you can't keep flying around
cuz it might reverse but "isflying" is still true
so you will still have no gravity and fly around
i think character movement component will snap the character to ground if the capsule is only a little bit higher than the ground
it feels like this is happening because when i move it a little after it reaches the end something snaps
sec
have you tried to set movement mode to flying
not sure but i think i now know why its launching me after disabling it.
so whenever im flying and it goes up or i disable it and it should go down, its never checking that and always increments.
yes that was the launch issue now imma try the fly mode thing
ok so it works as long as im not on the ground i just need to figure out why now
The thing is, no matter what I try, I’m unable to successfully cast to a basic actor (let's say a blueprint with just a sphere mesh). I understand it needs a reference, so I used "Get Player Character" when casting to a Character, "Get Game Mode" when casting to my Game Mode blueprint, or "Get Controller" when casting to a Pawn.
But it doesn’t work for my sphere blueprint, no matter what variable or node I plug into the "Object" input, and I just don’t understand why. However, I’ve found some working solutions, like the "Get Actor of Class" node or the "Cast to Class" node. It even works if I directly set a variable to fetch the sphere blueprint (so no casting required). It’s just frustrating.
ok this did the trick for me
Get Actor Of Class generally isn't a good solution.
and, the cast to class, still no object, so can't call functions for example.
Send pic, or more context?
I would assume its just a very basic miss-understanding of how the cast node works on your part.
@tulip bear This is a way faster way to add this but for some reason this code won't work unless you jump like guy said, almost like the feet are chained to the ground? works fine if you jump before hitting F key.
It sounds to me your just blindly casting to stuff, without knowledge/ reason.
Such as get character -> cast to cool sphere
@tulip bear Probably something to do with the preset states can't move in Z direction unless in either Isjumping or Isfalling state
in the starter projects
yeah feels like it. im mostly trying to understand how unreal works. i've been programming for a while now and always wanted to get into game dev as its interesting to me and feels like a nice way to express yourself and tell stories. even learned blender before that but my motivation quickly died everytime i tried doing unreal haha but i think im slowly starting to understand how nodes kinda work
Same unreal is a steampile tbh it's very hard to use
I got a revshare im starting if you wana join it, it's for newbies
ill send u link
whats a revshare
where we all work on a game and share whatit sells
ohhh sounds cool yeah im in
add me as friend or join my server
Hi
I want to create a settings save system for my game, things like mouse sensitivity, master volume, music volume, subtitle language, etc. While researching, I saw that some people recommend using GameUserSettings since it’s meant for this kind of thing. But from what I understand, if I want to add custom settings with it, I’d need to use C++ (which I’ve never used before).
In the same post, someone suggested using SaveGame instead, since it lets you create custom variables based on your needs. But then another person said SaveGame isn’t really made for that and mentioned things like the file being uploaded to the cloud by platforms, among other reasons…
So I’d like to know: is there actually a problem with using SaveGame for saving settings like this, and is it something people commonly do? Or would it be better to just follow a C++ tutorial and use GameUserSettings, even though I’ve never worked with the language?
You have to map all the settings to a UI interface and save it for later use there are youtube videos
It surely is a misunderstanding, since everyone else in the world seems to be able to cast without any hiccups! So here I am, on my last try. The blueprint where I’m doing the cast is my player character (BP_Hero). I created an "Object Reference" variable and I'm casting to my BP_SphereTest.
It doesn’t work, and I suspect it’s because I need to specify what actor the "SphereTestReference" is actually referencing. So, I checked "Expose on Spawn" and "Instance Editable" to be able to select a BP_SphereTest placed in the world.
The problem is, I can’t put anything in the Class Details because I get this message: "Editing this value in a Class Default Object is not allowed." I guess it’s because BP_Hero doesn’t exist or isn’t placed in the world before everything is generated, but I’m stuck here.
Well.
Those prints are backwards. 😛
Then, yeah. Like you said.
There is no value.
Since its an object ref (blue like that), you cannot simply just choose it from a dropdown.
Some form of graphing must set its value somewhere.
In which case, a simple like testing/ ideas sort of thing, a get actor of class would be fine, for the quick testing/ understanding.
But, should not really be used in a full game, in this context.
Indeed, they are reversed!
As I mentioned earlier, "Get Actor of Class" works fine, but it still doesn’t solve this casting issue. As you said, I need to understand what I’m missing here.
Like, how to set a reference if I can't modify the SphereTestReference to add this specific actor reference?
In a broader concept it gets dicy/ very specific.
But, in this basic test, you can just get actor of class on begin play, and then set that variable with its output (this is assuming the sphere exists at all times, and isn't spawned later on)
But, if get actor of class still has issues, that suggests you set the wrong class as the target, so it just pulled a random ass actor on the map (once again, assuming this sphere always exists)
WHICH sphere do you care about?
If this a purely you trying to understand casts, and what fails/ whats a success.
You can always swap the reference to be class based, so that you can just use the dropdown of choices.
Rather then runtime finding the test actor.
I know what to do, my question is more related to which approach to use to save the settings, among the ones I mentioned above
I see no reason a savegame wouldn't work.
But, GUS is also already auto managed in every way, for saving/ loading, getting, applying and etc.
and, you wouldn't need crazy C++ to allow BP to do most of the work, if you truly don't know C++ at all sort of deal
I'd personally go the gameusersettings route which I believe uses the ini, means if someone makes a bad choice they can change it in a text editor rather than it being binary data
Hi, im trying to create a Niagara watering effect 🚿, but when I switch tools or destroy the watering_can tool fast 🌱💥 —> the effect keeps running forever, like a broken faucet that forgot how to stop 💧💧💧.
The destruction of that blueprint happens inside of a widget in which the widget says "destroy", so the watering niagara doesnt even have enough time to "destroy" it self properly.
So here's the widget that handles the item switch
when I go inside of this function and I switch item, I can cancel an ongoing process in case I had an item held before that was in the middle of doing something ( this is the best way I can explain it simply )
but this doesn't work, so it fails to destroy that niagara
or instead of doing this, now that I look at it again, I think a new good idea would be to make an entirely new condition inside of the widget to handle unfinished operations, so if you're in the middle of something you can also block/prevent yourself from opening a new task.
ok thats a good idea, I'll do that
that will actually remove a lot of those weird hard references in my ui, so I might need to repeat for all items that have ongoing loading functions like eating, etc.
Unless I made a mistake, it doesn't work because I still have that error tooltip.
The tooltip is always gonna be there, thats not gonna change.
The graph sets it at runtime.
You cannot under any circumstance use the dropdown on object based values (aka, actor, gamemode, component, etc.)
So I have to manually put my player character in the world to be able to set a reference to this variable?
That would "work"
But, not the intended, or expected way. 😛
Since, if the player were to respawn, die, or etc sort of occurrences, the value would be gone, cuz new character.
You need to use graphing to set the variable, like how is currently shown in your pic.
Oh ok I get it, now I can use that reference to cast to my sphere!
And it works at last.
Thanks @next hollow !
so out of interest when making a BP Function Libary function and within the function calling something which wants a context world object thing how do people handle that ?
at the moment I've done it where you pass in the object calling the BPFL function but I oddly get a crash with that
i've read online I can leave the world context pin not connected to anything
You will need to pass in some object, and then pass that object into the world context.
You can leave world context blank, if the thing calling it has a built in world context (aka, actors and the such)
But, since a function lib is calling it, there is no built in world context, they just exist in null space, to run pieces of code.
Only C++ (to my knowledge) can make "automagic" work context pins.
BP must manually input, and use it for stuff like function libraries.
i usually pass in some object could be anything in the world
seem the function does it itself somehow
Didn't you just say it crashes though?
so it did when i tried passing in a object for the world context object
but not passing anything into the pin seems to be fine
I made it!
This is the Dispatcher in the BP_Alert Manager
Ai controller
And BP_Enemy
idk about this get zero stuff, is there more then one in the world ?
better to use "Get actor of Class" if thers only one
Everything works, however I have a little issue: when the player is not detected anymore from enemies, only one enemy keep chase player even if the player are out from sight zone.
Do you know the reason why?
well when is this running ?
i think stimulus will be true for enter and leave ?
What do you mean?
when does this trigger ?
as far as execution, what event is it running on ?
It triggers when the player is detected
put a print string, does it trigger when it leaves the detection as well ?
Anyone ever run into this scenario in blueprints?
BP Function with a struct input (by reference)
Break open the struct -> copy an array inside it (array of integers) and store as a local variable inside the function.
Add an element to the local function copy.
Access the struct reference -> "set members" and choose the array. Set struct array to equal the local updated copy.
Next tick/iteration when you access the same struct by reference the array is not updated.
The array does not appear to update even though I immediately access the struct reference and check (while in the function still) that the length of the array has indeed grown. But then by the next iteration it is cleared out.
I also make sure not to expose pins that aren't being updated in the set members node. Since otherwise they would be reset.
here
"the On Target Perception Updated event in Unreal Engine's AI Perception system will fire when a target is both sensed (comes into perception range) and when it's no longer sensed (goes out of perception range or is forgotten). "
for example, I have 5 enemies: when i'm compleatly out of sight, 4 enemies come back to origin location, but 1 keep follow me
put just one enemy you will see he probably follow you after see
but i wrote what is probably the issue
just read above
It keep chase me yes
So I have to modify the " On Target Perception updated"?
well you would hope that successfully sensed is working and setting the blackboard value
hey, trying to do a dialogue system and it isnt working
Could you explain please? Yes I have the Target Actor in my BB
put a break point on the setting of the black board, see when it triggers
for one thing you don't want <= on the index, because length is one greater then last index, so you just want <
it didnt work
but when you press E your not actually doing anything like showing or changing stuff
the tutorial im following used <= cause they set the talk index to -1
it should be calling the Talk function I implemented
oh wait i scrolled back in vid
i missed the link from true to talk
thanks!
also, on that same note
do you know how to do a kind of scrolling text
or ig not scrolling text, but rolling i guess? where it does one letter at a time
hmm thats interesting you want to write some text one letter at a time ?
on the ui ? or in game world ?
The breakpoint doesn't work here
like in the widget
let me try and find what its actually called
typewriter effect
kind of like undertale or some other rpgs
so it never actually runs ?
it runs it runs,
It happens when the player is detected in the sight zone
yes does it run when they leave as well ?
nice
mmmm toooooo much strange
easy fix lol
However thx for the help 🍺
Lol it doesn't work ahaha: Enemies keep chase me until I'm inside the cone range sight; then if the player go outside range, they stop chase me
So they stop chase me only after entering in their sight range
Hey guys how do I attach a rendertarget to a player class that I only want to render if within a certain hitbox (ie, over/under the water)
im doing some pretty advance crap right now

I've solved with this:
- In the BP_Manager I've created another ED called "On Value Clear",
- Inthe BP_Enemy I've bind the event,
Inside the AI controller I make the check
just saw this, thanks!
what should i do with the previous E press though?
or do i replace it
cause if i leave the previous stuff itll overlap right
sorry im not at my pc to test rn
where is the node that gets all the current available save games so that i can create the typical list of the save games?
there isnt one
It doesn't exist, for BP.
you have to make a list
the "does save game exist" is for the list you make
very simple youtube videos
I'm doing something that there is no youtube video on
someone wanna help?
I got this RT cast that im sampling for an FX module script
the red texture in left
I need to get the height data and spawn particles in niagara at that height, and maybe compare to an RGBA texture as well of the same capture
this is revolutionary tech
it gives large simple sim bodies particle physics without having to calculate advance displacement
or to put simply
water that looks real and does not need the CPU collision
or a cpu sine calc
yeah im trying to figure this out but i cant find the pink set you have
nvm i figured it out but it still does nothing
yeah and where do you store this list
thats the thing
Ended up going C++ with this awesome solution:
This code should work for any platform. .h /** returns a list of all save games in /Saved/SaveGames folder, without the .sav extension (filename only) */ UFUNCTION(BlueprintPure, Category = Game) static TArray<FString> GetAllSaveGameSlotNames(); .cpp #include "Paths.h" #include "PlatformFile.h" #include "PlatformFilemanager.h" TArray<FSt...
How can i extend a bone/joint (or group, wtv) to a specific location?
One of those is windows only, and the other is exceptionally overwritten and not likely to work on some platforms. Unreal already has a semi exposed function you should wrap for BP.
bool UTarrionSaveLibrary::GetAllSavedSlotsForLocalPlayer(int32 PlayerIndex, TArray<FString>& OutSlotNames)
{
if (ISaveGameSystem* SaveSystem = IPlatformFeaturesModule::Get().GetSaveGameSystem())
{
return SaveSystem->GetSaveGameNames(OutSlotNames, PlayerIndex);
}
return false;
}```
That's also an async version if you feel like writing an async node for it as well.
I messed up. I have a blueprint that I saved with an error in it that induces a crash. At such a level that I can in no way load the editor with that blueprint in the project. Any ideas I could try to recover this blueprint?
I set it up so I can apply this bp to any actor but
how can I do a conditional to decide which SFX to play
I want to vary the pitch but its set in stone this way
make a backup, manually delete the bp and redo it.
if you had source control, revert it
Hi can my gameInstance know by any means when a open level command completes? I dont want to ping my gameInstance from the level blueprint.
Rather than using play sound 2d, u can use create sound 2d which provides a object reference through which u can change the pitch. Also, an audio component can work as well.
Im confused, what would I change?
oh woops I didnt send my current bp
I did this which always does the false condition pitch
it ignores the speaking npc == banana guy
tried changing speaking npc to class reference instead
still doesnt work
Now i am confused as to what you are wanting. Sorry. U want the bp to play an audio pitch based on the actor attached/spawned by it?
I'm making a small demo and it'll only have 2 npcs
i want a higher pitch for the other npc and a normal one for this banana guy
I have a BP for banana guy
the pitch will be the same for all instances of banana guy so I just tried to pass that as an overall ==
if its not, then it has to be the other npc
the jumpSFX is just a test SFX
So u can have a variable which is exposed on spawn, and u send the “self” as to whoever is spawning the bp? This way u can tell ur audio bp to do either this or that
im not sure how to do the second part of what u said
i just changed it to be exposed on spawn tho
I want to know how this audio bp is spawned
Great! U r using an interface. Add another variable in the inputs there as a Integer maybe. So for example, 0 is ur npc0 and 1 is ur npc1. Then npc0 sends 0 and npc1 sends 1. Now in the audio bp, u can use this integer to switch on Int and play your separate audios for them. Does this make sense now?
lemme try rq
Yea for starters use integers, but for big scaling u might want to use ENUMS because it will hard indexing and remembering the integers for every npcs.
hey guys, can I get some help please? I got these animations from mixamo, light and heavy attacks. The thing is they move forward instead of staying in place (no, these ones dont have the stay option in Mixamo)
Whenever my character attacks it seems to move forward along with the animation and goes back to the original axis when it ends. This bothers me as it causes glitches when I'm near a wall.
I just want the character to move when attacking instead of the animation
Open the anim sequence, in the details in the left side, find “root motion” and “force root lock” set both of them to true and set the anim reference pose to anim first frame.
I couldnt get the int to work
I tried to make it so I can just edit pitch per npc but Im getting an error
I have my dialogue system set in a component so that whenever I add it to an actor, I can add dialogue in an array and change typewriter effect rate
it'll call the typewriter logic normally based on that
I tried making a variable in my third person class where the widget is created called Speaking NPC that's an OBJ reference
linked it to Get Component by Class
chose the dialogue component
tried to set a Dioalogue Component REF variable that I added to said typewriter logic blueprint
got an error
Accessed None trying to read property DialogueComponentREF"
thanks! It worked!
i just cant figure out how to differentiate the pitch based on npcs
I only need it between 2
Your options are source control, or getting lucky with the backup folder in your project's saved directory.
Eh, got lucky coding my way around the problem and recovered.
Im genuinely lost as to what to do
I have the dialogue_c1 as a component
I can change the typewriter speed and add dialogue per actor this way when I add the component to them
I cannot figure out for the life of me how to add a pitch multiplier that works per actor as well
wait I think I got it
thanks @maiden wadi 🤜 🤛 . will try that one because it looks simpler and more official. and that one works in all plataforms ?
Most. The ones that allow searching anyhow. There are some platforms that have zero ability to do that, so it's just not possible.
im just trying it right now
and the function return SaveSystem->GetSaveGameNames(OutSlotNames, PlayerIndex);
doesnt exist in ISaveGameSystem

O.o What version are you on?
UE 4.27 UwU
Ah. You can do this then for the time being. But yeah a lot has been worked on for that stuff recently.
TArray<FString> FoundSlots;
TArray<FString> FoundSaveFiles;
IFileManager::Get().FindFiles(FoundSaveFiles, *FString::Printf(TEXT("%sSaveGames/"), *FPaths::ProjectSavedDir()), TEXT(".sav"));;
for (const FString& FoundFile : FoundSaveFiles)
{
FoundSlots.Add(FPaths::GetBaseFilename(FoundFile));
}
return FoundSlots;```
is there a way to change which buttons are classed as game and which ones are classed as UI in the player controller class? want to make it so that I can press the esc button while in UI only mode but right now I have to set it to game and UI
No because this isn't how UI inputs work. Anything that is an input event in an actor is a Game level input, these are delegated from the PlayerController through the GameViewportClient.
To have correct UI inputs you need to either have an input preprocessor similar to what CommonUI has, or you need to set focus to the menu or subwidget and handle OnKeyDown to process the event.
I've done some googling and I'm not exactly sure what you mean. There isn't a node called on key down. There's only one for checking if the ctrl key is down, but nothing for other keys. I'm unfamiliar with input preprocessors though, so I'm not exactly sure how that would look.
thanks king 👑 that worked and is much simpler than the one i had
OnKeyDown isn't a node. It's a function override in widgets. And Input preprocessors don't exist in BP.
Yeah. Savegame stuff is nasty. :/ If you have the choice at all and you have even vague plans of doing consoles, I recommend just doing a basic slot system with predefined saves. Managing that stuff on a lot of platforms is exhausting. Sometimes you can't help it and need named saves, but ugh.
im too deep in it at this point
its almost done
but its necessary cause i need to learn
the hardest part was the serializing stuff
i used the GetPathName so all the references inside the actor are automatically restored
that was huge
That is a pretty nice thing to learn, yeah.
Oh my. The game I'm currently playing implemented zooming using FOV. This is wildly nauseating. 🤢
Suppose it is worth asking again if anyone has ever encountered this. It is very strange and screws up my logic.
Can you give some screenshots of the function?
don't do it on E press, you can trigger it whenever you want
I'll see if I can make a simplified example real quick since it is a fairly big function so it is hard to screenshot it properly
Or well actually here are the relevant bits. So I enter the function with a reference to my bullet struct. The bullet has an array of bytes that represent player IDs so it knows which players it has applied suppression to. (So it doesn't continue applying it every tick as it flies past)
I make a copy of the array at the start of the function, run a bunch of logic and then add the ID of the detected player to the copy. Then I try to save it to the struct.
If I try to immediately after print the length of the array I can see that it has gotten bigger. (When I access the struct reference directly from the function input). But on the next tick the array is cleared out when I copy it again and try to print the number of elements.
Ive stared myself blind at this so maybe I am missing something incredibly obvious
it seems that breaking a struct and accessing an array creates a copy so that is why I try to copy it, modify the copy, and then put the copy back into the struct.
your sure bullet is passed by reference ?
This looks fine. I'd AddUnique, but other than that. You can be 100% sure that you don't mess with the struct elsewhere?
i didn't know you could pass by reference to a function in blueprints ?
The little diamond pin.
i see that, interesting
It should be but it might be some other logic outside messing it, I update the position of the bullet prior to that. But it is a bit of a mess. So I'll backtrack further and see if I can find something.
Im just trying to rapidly prototype and I definitely miss the debugging of C++ right now. 😛
the blueprint debugging isnt as useful
IMO I would do some printing right after this function is called to see if this function worked. This looks logically correct, but that isn't saying BP isn't doing something odd. Make sure that the struct's array is correct directly after this function. If it's not updating, this function is flawed somehow. If it is updating, something else is messing with the struct elsewhere.
Yeah that is a good idea. I reckon the problem lies outside of the function now.
thanks for the input
print string, and breakpoints/watch values, thats pretty much what ya got
yeah, but debugging code allows you to view information in a much denser format so to speak
but I will see what I can find out
at least it doesnt seem like I glossed over something obvious within the function itself
simple things like is it even running is a good check
then like mentioned go through and check your values
will do
https://blueprintue.com/blueprint/4u3nqox7
Which is the technically more efficient manner of approaching this? I already have to move my quest system to a data asset base (so the bottom one) because I found out data tables cannot contain actor references (esp. not instanced level ones), which is necessary for a quest system.
one thing i will say performance wise the top one foreach is connected to a pure node, where as the bottom is not, you should cache the results before you loop over it or the pure node will run foreach element in the array
aren't they both pure?
top one finds a key in a map, whereas the bottom one finds a object in an array
i mean wahts plugged into the foreach, you can see the bottom one is plugged into execution
and the top one isn't
but there's only 1 loop in both, and the toarray comes before the loop in the bottom one
since you using an array and contains the lookup is likely O(N), where with a map it would be O(1) like in the top
yes and one has a pure node plugged in, and the other doesn't
this is pretty big difference tbh
I agree, but is there any real way to change it? I'd end up with a map with both values the same
and completed quests is a list of actors ? you could have a map of ids to quest, might make it faster, but tbh contains should be good enough it's just a good performance boost to use a map
a list of data assets
I wanted to use the top system, which would work nicely with a data table, but I can't put references to instanced actors into a data table, only into data assets, so now I'm stuck with creating a data asset for every single quest I ever put in the game
the blue is pure, the green is regular
so when that top foreach runs, every loop it will pull from that pure node and run it
true, marginally faster, but it all adds up when you have many systems
yes it would make a huge difference on a large set of data
well if you think about it, I can't imagine a player having more then 30 quests at one time in an RPG
I never have managed to get more then 15 at once
but it is a good idea to avoid such issues
and that seems like a lot to have at once
wouldn't want such a weird thing to be crashing performance
i would keep the current, and add a map and try it out, so you can switch back if it doesn't work
or if it's being a pain in the ass, atleast you have what works
xD for sure. So maybe I should switch it up again so I use a data asset in place of a data table. ie. an array of the quest struct that can contain all the info. Then a quest giver would need only pass in a quest ID, and that can be found in the DA, and from there it's basically the same as my original approach.
my only issue with this is a data asset is hard to edit like a data table, it's not really meant for it
tbh i have not used data asset, or data table yet
i just use regular variables
i would probably have a map of id's to struct
which would be all my quests
fair enough, but that's not efficient when you want to push updates to users later on
right, i have no idea about that stuff lol i'm still learning
that's what I did have, and just all the data was stored in a data table. Problem I had was the DT can't ref objects in the world
this is the all important button
I could, but that option is greyed out in a data table
i mean can you loop through the data and populate a variable ?
this way you can get the base stuff, then alter it in game
no, because how is the quest manager meant to find reliably the actors that are quest targets? Adding tags to them is not scalable, or performant, and introduces a dependency & lookup nightmare
the issue is you want actors, but you don't want the reference ?
i'm not understanding the problem with this, can't you just pull from the array and populate the array in a map ?
or is it different in a data asset ? im a bit confused
Actor exists in the world, this actor needs to be killed/collected/interacted/etc. to progress the quest. When said actor has something happen to it, it can send a message to the quest manager that such and such happened. However how is the quest manager supposed to link that particular actor (which might be one of many instances), to a quest objective specifically?
Adding tags (of any kind) could work, but that would not be scalable as it requires you to ensure (manually) that the same tag is present in both the quest data, and the actor that is interacted with. A reference is more dynamic and adaptable.
Data tables do not allow references like this, whereas data assets do
a ref does make sense
i'm saying for lookups a map is best, you can populate it from any data
hi, I cant figure out the difference between clear array and remove item, clear says it just clears it entirely, which means no index, no elements, just empty.
But for Remove it says removes all instances of item, which is always the same since arrays can only hold one type, so basically it removes all items, to me it sounds like its the same as Clear?
If you have an array with 1, 2, 3, 1, 1, 1, 1, 2. And you call Remove with 1. You will end up with an array of 2, 3, 2.
You can use a soft actor reference for actors pre places in levels. You'll just need to check its loaded before you do anything with it. It's not always clear from the soft ref if the actor was destroyed though so you'll need something to check it.
An alternative option is to make some sort of actor manager/register that actors can register themselves with using either a name or gameplay tag. In the quest you can then define the name/tag. When you want to get it you check with the actor manager/register to see if it exists, if so, return a ref to it.
you have 3 removal types.
Clear
Removes everything from the array
Remove Item
Removes all items that are identical in the array
Remove Index
Removes 1 specific index
The usecases should be quite clear
I am actually planning on using soft refs because all they are used for is comparison. Never to execute anything on any of those actors. Do soft refs work in a dt?
ooh ho, seems soft refs do work in a data table
ah ok its about equal value of that item? Lets say its an array of type Apple, the array can hold green and red apples, so the remove doesnt remove "all apples", it removes "red" apples?
You shouldn't reference things in a world from static data. You're gonna have a bad day.
ok that clears it up too, thanks guys!
kinda got confused thinking the array can only hold red apples xD
wdym?
You reference some actor in a level in some form of static data using a softref. Essentially using it's path name. Some level designer comes along and deletes the original actor to fix a bug and replaces it with a new one. You now have a different pathnamed actor that can no longer be resolved.
it's along the lines of, you can have an array of strings. That's all the same "type", however it can have multiple values. Using remove item would delete all instances in the array of whatever you put in to remove (eg. "Red Apples"), but it wouldn't remove "RedApples" as they're not identical
and that also get's more complex when you have arrays of structs, where now it's basically an object, with potentially many nested arrays
an array of strings hold "one", "two","three" these are the values, array of integers 1,2,3 values
I see, so as long the items are the same type they can be anything and put into the same array and basically filtered out like this too? Interesting, I find arrays heavyhitters on my brain, especially if it comes to assigning one array inex to another array index.
Question?
This makes the window windowed but the title bar is not shown
arrays are essential data, they make life easier tbh
think of an array like a list. If you have a list of books, that's the "type", they're all books. Now the value is the name of the book
yeah Im scared of that atm, I need structs, but Ill also need to array them.. so Id rather do just arrays for now.
structs are useful to keep data related, so don't be afraid of them
mmm good point. What would be a workaround? I can't think of anything that is computationally cheaper or the same price, and also only every implemented in 1 place (eg. adding tags to actors means it has to be replicated in the quest data)
Is there any known issues with 5.6 or is it safe to use compared to 5.4/5.5
Ill try to get into them once I HAVE to rewrite the entire thing again, which will inevitably happen once I cant scale anymore. Im prepared. For now its just array vs array brainfuckery.
Thanks for the info
interesting, if you set window title, does it show up ?
let me try
Why does it need to be replicated if the actor already exists on the level?
I mean the actor exists in the level and the quest data is static. So both machines can independently look up the same thing.
if I add a tag to identify a quest target, then that has to be identical in the quest data. Also I have many, many levels (currently 3, scaling to ~38)
damn, thats a lot of levels
well we don't have much manpower for an open world game, so the idea is to split the areas into much smaller regions, and make a seemless travel system
that also gives the illusion of real life size to the player
#1388449984768249936 message
We go over the thinking for the levels setup here if you're so inclined for more info (there's chapters to skip ahead if you want)
The whole title bar is not showing with maximize,minimize and close buttons also, looks like full screen but i am in windowed mode
press f11
this is a packaged game ? did you try to set the title ?
yeah with title it was not working, but i am lunching it, and not a packaged game
With f11 it worked when lunched and i pressed the button,
i hate this button will the gamers will press f11 to windowed mode 😢
not a packaged game how are you running it ? in PIE ?
try it in standalone, that will be a better view of it, and i would even test a packaged version see what happens
yeah it was standalone not PIE
If anyone experienced in replication, I will be grateful if you help me out why the client to server to multicast is not working for the player rotation ?
now it does not work for this option
looks cool
ty 😄, lots of logic, not very much art atm
got to find those artists somewhere because we've only 1, and I'm not artistically orientated
i have a bunch of projects, nothing major yet just a bunch of tests and figuring out unreal
perfectly reasonable
i just been using mixamo
eventually i want to try to create my own animations, but i can hardly create a mesh of any kind lol
I have a copy of a pawn (clone) that isn't controlled by the player, but it won't fall and apply root motion constant force didn't work on it (the abiltiy is called, but it didn't move), and I don't know how to normally add movement input for it
weird, i would uncheck the check overrides, see if you have any command line stuff going on ?
@maiden wadi so how would you reference actors in the level in quest data? Or somehow build an identification connection between them?
Really depends. I mean for the identification for me it's a two part issue. Things need a definition. Either a datatable row or better yet a data asset that defines the object with it's icons, gameplay actor, name, etc. And this definition can also hold static tags. And then each instance can have it's own set of special tags.
So say you have a quest where you need to toggle any lightswitch. The static data can tag it as a lightswitch. Cause you don't want to be putting this tag on every single lightswitch, you'll miss a dozen or so easily and it's just upkeep for the level designer.
But now you have a quest where you need to enter a room and toggle a specific lightswitch. You don't want it bugging out by entering the room, leaving and going somewhere else to toggle a switch. So you can tag that specific instance in the level with a special tag for that one quest.
so you would rather a senario where everything that is a quest target gets a gameplay tag, and use that as the identifier in the quest data rows?
Yes. Because not every quest has one target. You should design the system to handle any kind of quest you can consider. And if you tell a player to go kill 20 of something, you really don't want to be populating an array of references to every single instance in the game(and also having bugs from dynamically spawned things). Tags, while not as direct of a reference, are enough of one and can both be generic and unique.
I wasn't intending to. If I want you to kill 20 enimies, it would be a soft ref to the parent class of enemy. But if you need to flip a specific lever, then it's a ref to that specific level in the level.
However I understand what you're saying and it makes sense to me. I have 1 last question, would you say this is particularly scalable?
(left is bp_sodacan) (right is bp_vendingmachine) why only the first can gets a physics impulse?
Some sort of actor manager that you can use to register key actors.
I'm confused. Why does the isValid function complain that the value is none? I thought its' sole purpose is to check that and prevent errors? I'm trying to assign a generic material, if the physmat check fails
Unless your desired quest system is very simple, you'd most likely be better off using uobjects for quests. Data tables are very ridged which can pigeon hole you down a specific implementation, often limiting what you can do as well.
It's because your select node connected to it uses a variable that is null.
scenecapture2d drops fps by 20fps
thats crazy even if i don't use the texture anywhere
just having the actor in the level
Ah, if I check the Physmat instead it works, thanks
Yep, but considering its rendering the scene from another perspective 20 fps probably isn't bad. 😅 I think you can disable the scene capture component though so you could have it disable by default and enable it when needed.
can you enable it, take a snapshot, then disable it ? i might try this but 20fps to me is a lot
i was trying to have an overview look
I believe so. If you don't need to to continuosly update it's probally a good option.
i definately don't want the 20 fps downgrade lol thats too much imo
theres a setting for render every frame, and render on move, rendering every frame is a nightmare but if you render on move thats not to bad, but if you want live your fkd
What size RT? I noted a similar issue in our latest project. It was invalidating VSM and lumen stuff on the rest of the game map when drawing the RT, which was way up in the sky in a black box. Some people have said this doesn't happen in their project but I couldn't manage to find a way around it.
256x256
i was trying to render a top view in the ui like a minimap kind of thing, and it just tanked the fps so i'm looking for another way
i was thinking just have it render on start and move, and just use some sort of tracker points to place dots on the map which can move
kind of shitty work around but it might do what i'm looking for
i am using this command r.VSync 1 but it not works, what would be the problem
Fullscreen mode?
i tried in standalone also still do nothing
In fullscreen mode?
yes tried in fullscreen mode but nothing happens, i am on 5.6,
I'm uncertain if that works in Borderless Windowed. How are you testing that it's not working? Screen tearing or framerate limit not capping?
frame rate limit not capping to 60, my monitor is 60Hz
Actually wait, that command looks odd. One sec.
i also tried this below it shows enable but no frame rate is capping.
Can you do rhi.SyncInterval in the console and see what the value it returns is?
yes you can enable it take a snapshot and disable it.
Capture then untick capture every frame
I do that to take a snap shot with the "camera"
rhi.SyncInterval = "1" LastSetBy: Constructor
This are my settings related to RHI
Hey are there any specific rules to use polymorphism in Blueprint?
Odd. I can't repro the issue in 5.7. My rates from r.VSync 0 and 1
I'm using a class that virtually overrides a function to always return true, coded by Unreal Engine
and somehow it's returning false 😔
when passing by through polymorphism
show code?
Unless you override it, there's no reason it will give different value out of nowhere;
isnt there any node throug which i get monitor refresh rate and then clamp fram rate to it
That's what VSync is for. So no, not really. I'd try to determine why that isn't working.
"Has Hit Result" is a function that's overridden
and virtual
and it's returning false
In this class?
where's the polymorphism?
looks like you are using the generic gameplay event data?
TargetData is a struct?
ahh yeah, but you can't even have UFUNCTION in a struct
by struct I meant class
these are all built in classes and functions
so unless they're poorly coded
my problem must be from somewhere else
@maiden wadi One small question.
Does this overrieds the console commands if it is enabled.
But where is the virtual here? This is a library function.
FGameplayAbilityTargetData? Is that what you subclassed?
I assume that if this isn't returning true for your custom struct, that you're not passing the correct struct at that index of the target data.
You should breakpoint in UAbilitySystemBlueprintLibrary::TargetDataHasHitResult and see what is in TargetData.Data, if anything.
how to set console variables from blueprint and does those nodes work if the game is shipped
Plz help!
so command line arguments are what you pass when you run the exe
"When "Check for Command Line Overrides" is enabled in the Apply Settings node, these command-line arguments will take precedence over the user's saved preferences."
it is what is subclassed
not by me yes
no i am talking about the other ones like r.AntiAliasingMethod
Like I said I would breakpoint that function. Cause you're not getting the right entry if you're expecting it to return true. It's either empty, or not the right struct.
execute console command node
command line overrides is not the same as console command
i don't think but i could be wrong
google says some console commands can overwrite the apply settings
which makes sense
i think you did not got me.
i was saying that like we use command stat FPS when working in editor, can we run such commands while the game is running but from bluerprint,
BTW i did not want to run stat FPS from Blueprint it is taken as example
I know the pic doesn't says much but the point is I am working on a filter that turns on and of some BP actors, but I am wondering if there is a better way to make lots of comparisons like the ones in the picture without making a mess in the graph ? any advice?
Has anyone ran into this before? Was a 5.5 metahuman, updated the project file to 5.6.
There wasn’t a metahuman chat section so asking here
Man I still can't figure out my struct with an array thing. I do not modify the struct's array anywhere else prior to this function call. https://blueprintue.com/blueprint/_kfwed1_/
really bizarre problem
I have an event on an item blueprint to draw the throw trajectory and I'm using predict projectile path. The thing is, on my throwable blueprints, they have different mass, and I think the predict projectile path node only accounts for 1kg mass. Is there a way I can change the mass for the predict projectile path?
Did you check the array directly after this function call?
oh right let me do that real quick. Been stuck in a big refactor all day I forgot. Typical I forget something so obvious.
I can at least confirm that your function here is fine. But I'm also curious if you're accidentally passing a copy to this function?
it does say the array has gotten bigger right after, but then it is again set to zero.
let me double check something since that may be the case somehow
In the end I could not find why the async static mesh does not get an impulse and only the first one loaded does, my guess is that the async is slower than the applied impulse and makes some sort of race condition
https://blueprintue.com/blueprint/g6wc6n0q/ this is what is going on outside (sort of). It does look like the out bullet is a copy but at the same time it works for all the other parameters? Only the array is problematic. If I instead feed the direct reference from the getter into the suppression function (instead of what update bullet returns) then the result is the same it seems
It's the out property.
You passed it by ref into the UpdateBullet. Then passed out a copy and passed that to CalculateSuppression.
let me try again with it
not using the out I mean
it definitely is part of the problem but not using it doesnt fix the problem unfortunately. Saving it the way I showed inside the function still results in it not being saved on the next iteration. So I'll have to go further back it seems.
what a mess I've made
I'll have to keep digging and see if I can figure this out. The best part of game dev is when you get to not work on the things you want to work on. 🫠
Thanks again for the input still!
Hey guys, is it easy to use character blueprint for adding animations or is it better to use animation blueprint?
Need you to expand on this a bit. Why would you use a character blueprint for that over an animation blueprint?
Well I mean for a specific mechanic animation basically like for example combat, or damage, a lot of tutorials that I’ve watched only focus on the character blueprint and not animation blueprint, because they look recommended and that’s why I’m asking?
Im making an action rpg. Characters can walk around a town or dungeon in "field mode" but when touching an enemy I want the scene to transition to an arena where the "battle mode" begins.
Is it easier to have it load a level for the arena and than load the original level, or have the Arena be in the same level and the player will teleport / posses an actor in the arena to fight?
so like a Final fantasy game ?, that tottaly depends on your structure and size of the map
i would have it in the same level or rather a sub level to save load time but if its an open world with a huge map that would be bad, however the loadtime to return would cause annoiance
would start by doing it in the same level to get it working
Need some help with popup widgets! I have a Widget on my Blueprint Actor, I have a class with some clickable elements showing up on it. Looks great and all of that - the issue is this - interactions don't work in a build. Everything works great running in the editor (I can clock on the little X and the widget will close, etc) but in a packaged build, it is unresponsive. Any ideas?
as far as you don't "need" an anim bp, you can do with just setting and playing animations but you won't get smooth blends if your anims don't all line up like you would with blending in an anim bp
i'm just setting and playing animations on some projects right now, with the idea that i'll eventually use an anim bp
but the benefit of an animbp is also i have seen you can do foot ik where you can adjust the feet and legs for different heights
so theres a bonus there
I have a player character, that has a widget UI. this UI has a button, when i activate the button i shoot a projectile. I want to change it so the projectile shoots from another actor instead, how do I do this?
Ive been trying for a while but i cant figure it out. at first i was missing an object reference when trying to cast and could not figure out what to put there.
After some testing i put this inside the level blueprint:
Event begin play->create Widget
Then added a reference to the other actor and connected to the widget, not sure but if i understood it this should be an easier way to reference back to it later so i dont have to cast it.
How do i set this up with the button on the widget?
tag on reply pls
There are a million options. But what is the logic behind getting another actor?
basicly makes it easier to change it later as i dont have to set up angles etc manually but can rotate the actor instead or change where it should spawn easier
I made a reference in level blueprint like this as someone suggested
How do i manage to make the projectile start off at the arrow component off the actor?
Just change logic to get arrow component and spawn it here?
Just....
GetComponent, GetComponentByTag, Cast ->GetComponent ect.
A lot of option
You can change logic, and send your arrow directly in widget.
And get it from DiceSpawner from here.
If i go by casting i cant find anything to put in object
if i go by having the reference, cause i think that works better, how do i use it to actually spawn the projectile? i feel like ive tried everything but cant get it to work. yes im not understanding the casting properly
Just copy the code that sends your projectiles now from the character's side (what do you have there, Spawn, Linetrace, or what?) and play it for the position from the newly passed Actor.
i cant get the actors position tho, thats kind of the issue
im using spwn projectile. when i spawned it from character it worked, but i want to spawn it from another actor instead but that does not work when i do it the same way
how are you going to select the other actor ?
you need a way to distinquish it from the others for sure
idk, thats the issue, i cant figure out how to target it. i did manage to create a reference to it but i still cant use it and i dont know why
do you have one of this class ? or are there multiple of same class ?
I have only one actor
ok do you plan on having more ?
or this will only be the one of that class ?
because if it's the only one of that class then it's easy to get
just get actor of class
but if you have multiple of the same class
you need a way to tell them apart, i usually use id
for instance your class has an id variable thats a string, you can then set it to "thisActor"
then you get all actors, loop through and find the one with that id
or you can use gamplay tags as well
i think you can put a tag on the actor you want to get
ya you can get all actors with tag and get zero
as long as your tag is unique
theres different ways to get a reference, but it depends on how flexible you need it to be
I dont think i need much flexibility
get actor of class should work, just don't have more then one in the scene of the same class
thats the most simply way i use it all the time
i need it to come from the arrow component on the actor tho, and do i still need the cast node?
no you don't need to cast
click on the component and at the top right there is a variable name
when you get actor of class, pull out from that and do get your variable name
whatever the component is
and there you have it
then get its world location
i was just using an arrow component, turned it into an arrow mesh because arrow components only have color
So anim BP is better?
yes for sure, but you don't "need" it, you can still just play animations
depends really on how complex your animations will be
and if they will line up properly
I may have missunderstood so bare with me a bit, but this still doesnt work
what is the name of your arrow component, when you click on it what does it say at the top right as variable name ?
ya you set arrow, you want to get arrow
-set
+get
@jagged moss
Anyone got any idea I hit this finish task here
on my state tree I have it so if task succeeds to move to next state but it doesn't seem to be
it's like it's go stuck somehow
#gameplay-ai might know more about it
I'll try AI first see what they say cause it's more on AI side of things then animation
Im only able to find it as set tho
thats weird
you should be able to get it if the variable name is set
are you dragging out of the return ?
or just right clicking in an empty space ?
your probably not in the right context tbh
drag out from the return value of the get actor of class
this is your actor that your getting
okei it worked now
i either wrote it wrong or didnt see it. i think maybe i search for the name but i had to write it correctly to get the option.
i still dont understand the cast to option fully tho
as far as cast to you need something to cast to anyway
just get the actor if you can
no need for casting, casting just sets it frome one thing to another if it inherits from it
so you would cast on an interaction
because you hit an "actor" but you want your "actualActor"
If i use transform rotation, would it count as the arrow itself rotation around its axis or would it follow the actor its attached too?
I've got an unusual issue. I have a character that is using a navlink to go off a ledge. However, they are overshooting the destination of the nav link and are winding up in a corner, out of the navmesh. How can I get the character to "steer" in the air?
Could someone ELI5 what "sweeping" does? It feel like it leads to strange behavior when I am updating my actor's location, but maybe I am misunderstanding something...
@cunning cloak Says its to help with collision, it checks at every increment if there is collision in the matrix grid
complex how exatcly like i add 100 animations in one character or in anywhere or something else?
You don't want 100 animations it will lag
get every axis (there's 8) and make 3 for each one according to walking/swimming and transition between them that's 24 a state
for walking/crouching/jumping and swimming that's almost 100
but they not being played in the same state
Anyone know/have a reference for what state tree considerations do? I dont' see anything that's popping out for their use case. It looks like it may just be whether the branch should activate (selection utility?)
is there a video how Combat animations are used in State machines in animation BP?
https://www.youtube.com/watch?v=4d5vRYe3bLE combat and all other animations the same
Hey friends! Today we're taking a little dive in to the Anim State Machine - this will be more of a refresher for the intermediate users out there but you'll definitely pick up a new tip or trick! State machines are a great way to animate characters, particularly movement animation. States are mutually exclusive, which is why they are a very nea...
combat just needs collision sockets on weapon that move with the animations
and a simple overlap>>>do damage function
on the sockets...... if theres aweapon in the hand socket the weapon needs 3 sockets on it to detect overlap
could get away with 1 but 3 is better for a sword
well how do i add the damage in the anim_BP, also in the state machine do i need a Enum for multiple attack animations for example light attack 1, to light attack 2 and 3, how to add in one state in the state machine?
Does anyone have an idea as to what could be causing this bug with the world audio resetting?
here is all relevant blueprints
ive been trying to pinpoint this for 3 hours
i just cannot find the issue
it seems to only do this when the typewriter effect speed is lower than 0.075
you got spawn sound not play sound
and by the way your graph is pretty complicated you could make it way simpler by just checking overlap and playing a sound if talk = true
pretty sure if you wanna play a sound every character you wanna get the same speed at which you are printing the text by how you decided the speed and plug that into a play sound function then run that function when you talk
i had it that way so i could change the pitch
and also yeahhh ik its pretty fucked up my bad
i havent gotten around to rerouting it yet
i spent half of yesterday just trying to get it working so its a mess
Is there a way to compare two physics objects velocity before they hit each other? for example Two balls with physics hit each other, I want to get the velocity of both balls and get their length and direction. or would I have to store their velocities before they impact
@Finn you get actor velocity with a node and when it hits then engine should remove velocity automatically but if you want impact you either need to pull from engine or calc how fast he stopped and how fast he was sent flying
I need some math help, cuz it's not my strong suit. I created a system to track and display my ammo, and it works 99% of the time, but I have experienced 1 bug. If the ammo reserve is greater than 0, but less than the ammo needed to fill the magazine (let's say there are 5 bullets in the mag out of 12 but only 2 remaining in reserve), the calculation doesnt work and it spits out the wrong number. Can anyone see a possible fix?
these calculations seem very overcomplicated for what's actually being tracked. I don't see why mag ammo and reserve ammo would be tied together in this way
Well I want to only fill the mag with the amount needed, so if there's a remainder in the mag, the whole mag size shouldnt be removed from reserve
sure, that makes sense irl, but we're coding. do it easy: add the mag back to the reserve. set mag to 0. then try to fill the mag again from the reserve
You know... I cant even be mad, that is just me being silly ahahah, you're so right
And a very easy fix too
I was just thinking very logically about the steps, instead of thinking about how to simply impliment the feature
Thank you
no worries
I was writing up a longer solution before I made the realisation myself lol
That's the thing about code, intuitions are often misleading
@stable coyote dividing 5 ammo in the mag by 12 will give you ~2
unless its recipricol
which case you get less than one
Get the finished project source files here: https://products.infimagames.com/g/fps-tutorial-source-files?utm_source=youtube&utm_medium=video&utm_campaign=unreal_videos
Subscribe to our Gumroad newsletter for exclusive updates, future discounts, and more: https://infimagames.gumroad.com/subscribe
Check out our other work here: https://www.unrea...
he talks about it mid video
Oh yeah, but I already got a fix from meme, just had to think outside the box
I wish there was an easier way to test multiplayer things than bulding the thing and playing on both my laptop and computer at the same time.
real quick question for you guys, im working on a camera system and adding in my own lag with interp speed and whatnot. If I wanted the horizontal movment to be a little snappier but the vertical speed to be slower could I just plug 2 different interps into a make vector or is that gonna cause some kinda confusion with the vector that comes out on the other side?
float interps on the individual components of the camera movement should work fine, yeah
@Finn you can play multiplayer in the editor on one pc
Is there any way to remove localization from key slots used in key bindings in unreal engine ?
Can you show where you mean?
when I used to change languages in a game then key slots also gets translated. I don't want that.
But what key slots? And why wouldn't you want them translated?
Sorry. I'm not trying to be difficult. Just not sure what you mean by key slots. Generally speaking if it's an FText it should be localized. If it's breaking something from localization then you're probably doing something that isn't correct.
key slots are used for key bindings.
Input key selector I mean
Can you show it visually?
Even though I've removed the localization flag. Still it's translating to different languages.
Why wouldn't you want that translated though?
-> it's working perfectly fine when I play in unreal editor but not works well in actual build
-> It's translation is not necessary.
Casting is just a type check. You need to pass the object you are trying to cast which in your case is the projectile you spawn.
You can store the reference from the return value of the spawn actor / component.
You can test in editor right away
You can predict where the ball will be the next frame based on the velocity but IMHO trying to do multiplayer physich especially in bp is a lost cause.
Even for seasoned programmer writing server auth physich is a very difficult task.
The "Empty" probably should be. But you are right that it shouldn't show up when re-gathering text after disabling it.
I want to make a shader/material that will totally flatten vertices after a certain height like a crush effect but in local object space not world space in terms of defining at what height to apply this effect, how would I go about this in the material editor?
is there any solution for that ?
I don't think so? If it still shows up in the gathered text after you disabled it via the Localization Icon next to the FText field, then I would say that's an Engine bug. Are you sure you don't have another FText somewhere that also says "Empty" and you just assume that's this one?
I've checked the translation list in localization dashboard and I didn't get any word called "Empty" in the list.
Then it's all fine though?
But still it's translating bro
Okay, you mean if you change the language in your packaged game, the text still changes from Empty to something else?
Even I've unchecked this and still it's translating
Did you ever localize this in the past?
Yes
Nope
What does it change to?
Did you recompile the localization files after gathering the text?
It's translated to the language that I've selected.
UE doesn't have automatic translations though.
You must have at least localized that word in the past.
It doesn't magically know what Empty translates to.
Also one more thing is that It's also working in editor viewport. But localization works only in standalone mode.
Newer UE5 versions have the option to change the Game Language as a preview setting in the Project Settings or Editor Preferences.
To test localization.
You can also change the language inside the Widget itself at the top to test existing localization.
Yeah Ik
But either way, the word Empty doesn't just magically get localized.
It would also not magically localize in that exact FText unless the Namespace and Key match.
Please make sure you compile the localization files.
fwiw, delete the old ones.
It was likely localized with the engine.
Right, I assume it should still stop if one recompiles the localization?
That I'm not sure on. I'm not sure if the engine ships with different loc files by default that the project just overrides. I'm a little confused why marking it as not localized doesn't work though.
@little helm The other thing on this is that it should still be localized. Not everything is the same in every language even if it's "generic". Take something as simple as the ellipsis. most of the world's languages use "...". But not Chinese. Chinese use "......", specifically six dots instead of three that spans two Chinese characters. Never make assumptions with player facing loc stuff.
Yeah, not localizing these doesn't make much sense to me either.
Why would I want to read "Empty" if I change it to German
If I localize this then it's working perfectly fine in unreal editor but not in shipping build.
In shipping build when I translate it from English to Japanese then back to English then it's not translated back to english.
Even after restarting?
Does sound like the English localization culture code doesn't match.
After exit the Application and after reopen it again then it seems translated
I'm also saving the game settings as well
Does it work in Development Builds?
I wonder if the initial culture code for your game is different than the one applied if you select English.
Didn't check this out
That's only the case only with input key selector. Rest of them is working fine
That might still be an issue though. Maybe Epic's engine provided localization runs on a different culture code.
Just a guess though, but it makes somewhat sense to me that this could be the issue
Maybe depends on whether it's being set to a subculture or generic?
Yeah, En vs En-Us etc.
Bit odd that the system wouldn't just pick the closest correct word though if it's in any subculture.
The initial "Empty" is probably working cause it's just the default text in it.
My game runs as expected with no issues now with physics that's all fine. I tried to change the way the rebounding workined and just couldn't get it to sync up so reverted to the olld way I was doing it. which works
have you test with ping?
I have yes, played with india and usa from australia and vice versa. only input lag.
ye I have a feeling it's not going to be nowhere responsive.
kinda like kicking a soccer ball in pubg
it starts moving after X delay
you'd be wrong
maybe
although ideally you wouldn't be playing with someone who has 200-300 ping in a brawler type game
12-100 ping is extremely playable and reliable to the tee
150 -200 playable but input lag is a thing. 200+ is just asking for problems
my gosh, multiplayer headache 💀
looks responsive enough to me
Yeah physics is fine. took forever to get to to actually work. but got there in the end
I am still learning all the aspect of this engine. probably done a shit load of things wrong. but if it works, it works I suppose
still need to learn how to make server list and menus and game goals and all that stuff
This is my first time attempting multiplayer
if you are using steam you can just get the session info
going to gym 3 - 4 times a week helped me the most with keeping a positive mental.
you just stop thingking about all the negative stuff.
Yeah I have been neglecting my body for a while not going to lie. I am skinny af
"if it works, it works" for sure
there are "better" ways to do things as far as performance and modular structure
but it doesn't really matter if it works well in one way, you don't need to change it
only when these things become a problem...
but i would plan ahead, as changing everything around can be quite a mess.
I'm using FloatingPawnMovement and the AddMovementInput function. Somehow, it seems to ignore all collisions. Is that expected?
My pawn has a sphere collision as default scene root.
If the root component is a sphere collision and it's set to block channels, it should sweep against them on movement.
Anyone help me with whats wrong with my collisions here
the ship col has that
and this actor has this
now my knowladge would tell me the ship should overlap with the box in bottom image as the box collision settings are ship collision overlap
but the shipboundary ignores the actors object type, might be an issue
which one are you looking for collision to respond on ?
so because the ship is the thing moving would I want to do it from the POV of the ship rather then the other way around
it doesn't matter imo, just one way or the other
the lower one
depends really on where you want the code to stay
so bassically when the ship overlaps with the bottom box the bottom actor does XYZ
so when you overlap ship it should respond, does the event not fire ?
so I've got it to fire I've bassically had to do it where the ship col overlaps with world dynamic only and Actor B box col overlaps with Ship
which i'm sure I tried before and didn't work so not sure whats changed but it's working for now how it should from what I can see
figures because the other one is only overlap ship, so it never fires
what you can do is make them both ship objects
it's not really the other is a ship
but this would allow for them to only collide with each other
How do you handle this if you have a pawn base class, but different shapes of pawns in child classes?
Like, currently I have a Sphere collision as default scene root in my base class. But, what if I'd have child pawns that don't fit well into the Sphere collision?
so i was contiplating making a collision object channel for Actor B but for now I'll leave it as world dynamic in terms of ship pov
Hard to get detailed info on the experimental physics prediction stuff so. Kinda just reading all the documentation and doing my best to understand it all
What's the .ini config to not open previously opened tabs, each time the engine opens it crashes due to a corrupt tab
hey all. I'm having a hard time getting setting up being able to click my minimap and move the camera to that location. Is there a sort of formula to follow to convert mouse position to these coordinates
I need help in understanding how does Spline tangent work in UE5?
How to generate Beautiful Spline by Math using BP?
What I'm trying to do
I want to create a Spline that looks like the read line in the image.
The Spline should lie in the center between 2 🟩 concentric circles, and forms a right angle with the segment connecting 2 center of circles.
In the image:
🟥 Output Spline
⬜ Spline Points
🟦 Spline Component Origin
🟨 Measurement
🟩 Help Understanding the structure
What I've got
I've managed to place all the ⬜ Spline Points, but stuck at calculating the tangent to make the curve smoother.
The third picture is what I got now. (the center of circle is also connected just to debug coordinate calculation).
The forth is the blueprint to generate Spline points , and the index [0] when creating the array is the center of circle (to debug).
(for simplicity, I only screenshot half of the points construction, since there would be too many connections)
What I've tried
I've done some research and found the equation to calculate any point on the the curve by given 2 tangent and 2 spline points as follow.
(((2x^3)-(3x^2)+1)P0) + ((x^3-(2x^2)+x)T0) + ((x^3-x^2)T1) + (((-2x^3)+(3x^2))P1)
where T stands for tangent, and P stands for point, and x stands for distance traveled.
But I can't revert this equation since there's 2 tangents in it.
My Questions
- How can I smooth the Spline?
- How does Spline Tangent Vector work in UE5?
- How will the Vector pointing direction affects the result?
- Shouldn't Tangent be a line crossing that Spline point, how did it become a Vector?
did you try setting them to 0?
I'd like to know a good way to detect if an actor was splashed by liquid from a thrown bottle that breaks. A sphere trace wouldn't always return they were hit since it returns the first hit object, right? I was thinking about first checking if the actor overlaps a sphere collision, then if it does overlap, do a line trace or multiple line traces from around the bottle on hit.
yes, currently all the spline point's tangent are all zero-vector
is the spline a component in an actor ?
what you said seem to be a nice solution
Hello - I've got what feels like a basic question and I'm just missing something.
Quick breakdown
I have a modular character with separate male and female meshes
I have Data Tables for both containing all parts except heads/hairs (DT_MaleBody & DT_FemaleBody)
I am trying to use the Data Tables to set the "default" player body based on which gender is selected by the player during character customization.
My main hang up right now is I'm not sure how to make the rows in the Data Table correspond to the actual skeletal meshes on my character. Then I'm also not really understanding how to iterate through the table to use the data to set the new mesh
Edit: I have since renamed my Data Table Row Names to be the same as my body part mesh (so, removed Gender Prefix) (Also added rest of body parts and just left them empty if I didn't want them assigned).
So my solution ended up being to Tag the Skeletal Meshes and then use Get Components By Tag to provide data to match my Data Table to my character blueprint. I can now successfully swap all of my male meshes for my female meshes with the press of a button
ForLoop 1 to (NumPoints - 2)
{
Prev = GetLocationAtSplinePoint(Index - 1)
Next = GetLocationAtSplinePoint(Index + 1)
Dir = Normalize(Next - Prev)
Tangent = Dir * 1000 // Higher value = more curve
Set Tangent At Spline Point(Index, Tangent, Local)
}
got this from ai
What is the most efficient way to translate this UE4 code to UE5's new input action system?
hey
this is my first time doing state machines
this is my logic for Jumping -> Running
this works fine, because it plays the first bit of the jump animation but the issue is that it instantly switches to running animation after even when midair
I want to delay the running animation until the player is touching the ground but unsure how to do so
the other weird thing is that the condition that plays the sound / checks for negative Z velocity is what allows the transition in the first place but it doesnt even play the sound
yes, and the blueprint is in the constructor under that actor
I'll git it a try, I want each side of the curve as close as a perfect circle as possible, I believe that 1000 could be a constant that satisfy.
I found and tweaked out the solution:
Let's say the curve's circle radius is R, and the vector pointing on the circle (red) is V.
It's pretty easy to get the tangent vector of V just by (-Vy, Vx), and thus all that's left is the calculation of the curve strength, or the Tangent Vector Length.
Referencing the post, a circle formed by a curve of n points, the Tangent Vector Length should be (4/3)*tan(pi/(2n)), but after some experiment, this only fits when drawing a full circle, in my case, it's a 1/3 circle.
I slice and place spline points for every 45 degrees, and after some tweaks, the following equation for Tangent Vector Length fits the best.
Tangent Vector Length = R * (4/3) * tan( pi / (180/angle) )
R in the equation stands for the radius of the circle, and angle stands for the angle between spline points, in my case, 45 degrees.
One of those conditions is obviously screwing you up, I think there is a different bool called "is in air". Also wouldn't it be a not falling condition. Look for a not node for the bool
Is it possible that your velocity is zero when you are put into the jumping state so you are put out of the jumping State before the velocity change begins?
The whole concept you're using velocity here seems treacherous because what if the player is walking down a hill, I think in that case he would have negative velocity but still be on the surface
Can someone help? for some reason the top hat is inside the head while the crown is ontop, the socket is right on the top of the head so im not sure why the hat is inside it, i tried messing with the root in blender but it didnt work, am i doing something wrong or is something broken?
i even exported the crown and matched the root points and size but it just wont work
True tbh
although this is only for jump to run so it shouldnt activate if they arent jumping
I fixed this problem tho by just removing all the conditions and making it just if Z velocity is == to 0
im just making this game for a class so i can probably have a shit ton of improvements
this is my first ue5 project in general so state machines have been a bit of a struggle
i have to make all assets my self for the project so i only have 3 animations made
Hello, I'm trying to figure out how the Game Animation Sample has this nice editor that contains all the camera rigs within the camera asset.
I'm using 5.6, and when I make a Camera Asset, all the Camera Rigs have to be separate files, and it's just not as nice to work with.
If I migrate all the camera assets to my project, it converts the camera asset rigs into actual separate camera rig files, so there's something fancy going on in just the game animation sample project?
i think ive gone code blind after 8 beers and no sleep. im prototyping in blehprint
what am i missing here? shoot prints like 5 times then i get
LogBlueprintUserMessages: [BP_PlayerBase_C_0] 37
LogBlueprintUserMessages: [BP_PlayerBase_C_0] 78
LogBlueprintUserMessages: [BP_PlayerBase_C_0] 116
LogBlueprintUserMessages: [BP_PlayerBase_C_0] Shoot
LogBlueprintUserMessages: [BP_PlayerBase_C_0] 41
LogBlueprintUserMessages: [BP_PlayerBase_C_0] -917
LogBlueprintUserMessages: [BP_PlayerBase_C_0] -877
LogBlueprintUserMessages: [BP_PlayerBase_C_0] -835
LogBlueprintUserMessages: [BP_PlayerBase_C_0] -795
LogBlueprintUserMessages: [BP_PlayerBase_C_0] -754
LogBlueprintUserMessages: [BP_PlayerBase_C_0] -713
LogBlueprintUserMessages: [BP_PlayerBase_C_0] -672
LogBlueprintUserMessages: [BP_PlayerBase_C_0] -631
LogBlueprintUserMessages: [BP_PlayerBase_C_0] -591
LogBlueprintUserMessages: [BP_PlayerBase_C_0] -550
LogBlueprintUserMessages: [BP_PlayerBase_C_0] -510
LogBlueprintUserMessages: [BP_PlayerBase_C_0] -469
LogBlueprintUserMessages: [BP_PlayerBase_C_0] -429
LogBlueprintUserMessages: [BP_PlayerBase_C_0] -389
LogBlueprintUserMessages: [BP_PlayerBase_C_0] -348
LogBlueprintUserMessages: [BP_PlayerBase_C_0] -309
LogBlueprintUserMessages: [BP_PlayerBase_C_0] -264
LogBlueprintUserMessages: [BP_PlayerBase_C_0] -222
LogBlueprintUserMessages: [BP_PlayerBase_C_0] -182
LogBlueprintUserMessages: [BP_PlayerBase_C_0] -141
LogBlueprintUserMessages: [BP_PlayerBase_C_0] -99
LogBlueprintUserMessages: [BP_PlayerBase_C_0] -59
LogBlueprintUserMessages: [BP_PlayerBase_C_0] -17
LogBlueprintUserMessages: [BP_PlayerBase_C_0] 24
LogBlueprintUserMessages: [BP_PlayerBase_C_0] -935
LogBlueprintUserMessages: [BP_PlayerBase_C_0] -893
LogBlueprintUserMessages: [BP_PlayerBase_C_0] -853
LogBlueprintUserMessages: [BP_PlayerBase_C_0] -812
LogBlueprintUserMessages: [BP_PlayerBase_C_0] -769
LogBlueprintUserMessages: [BP_PlayerBase_C_0] -728
LogBlueprintUserMessages: [BP_PlayerBase_C_0] -687```
in this case it shoots twice then i start getting negative values from the now - last fired timestamp
is it just a bad idea to do timing stuff like this directly from the input?
what are you trying to do? Make a delay between shooting?
yep
without tracking in tick or using delays. just thought id try doing it directly within the input event
Might be yank but I usually just use bool variables with a timer or something cause it just works lol
yeah i usually use timers
just thought id try this since it would be less variables and no need for tracking
just need the fire rate and when you last shot
maybe its a timing problem with inputs? i dunno
Not sure, probably best to just get it working for now with something simple and coming back to it later
yeah this was just an experiment. i though id gona code blind and not noticing some simple mistake
lol
i just dont get why the value is going negative. its positive for the first x amount of shots
How about burst firing? This wouldn't work.
it could if you made the burst the actual shot and checked for divided time limits to fire x shots over that time
but yeah
awkward
(Certain firearms have a burst mode where a single trigger input will result in more than a single round being fired)
but im not using any burst fire, shooting is like a side mechanics in a break out game
Not a bad idea (your implementation) but it seems to have its limitations
Maybe 8 beers wasn't enough.
lol
now you sort of want bursts. admit it.
ive got a whole system in a plugin that does this stuff perfectly for all kinds of shooting types, burst, delayed hold, bolt action etc
i do now you mentioned it lol
i can pull my plugin into this, but its probably overkill since thats just the "usage" part of the plugin.
but then again the item, inventory and interactions, probably would be useful. since i can handle scores, buffs, etc with the inventory module
oh while im here. im having an issue fading in and out lighs, and their redius
im trying to interpolate their intensity and radius but there is no in between in the light itself
full intensity, or none
Your code?
one sec
ok ive fixed it
@frosty heron what unit is interp speed?
what is it related to?
you pass delta and interp speed to some interp functions
it wasnt fading because the interp speed wasnt high enough, i had to set it to 1000....so im guessing interp speed is milliseconds?
I don't know the math, but higher interp speed = faster transition.
you can't convert that in seconds unit from what I read.
For me, I just use feeling all the time for fine tuning.
afterall if I need something over X seconds, I will use timeline.
I interpolate on tick when I have something that is not fixed in length. E.g rotating head, aiming, etc.
and using 1000 seems like a second
The interp speed determins the length or distance of the transition, and it is not “seconds” nor is there a way to convert this to seconds (1/seconds is how you adjust the playrate of a timeline or something similar by converting the seconds into a float).
A higher Interp Speed value means it will transition to the target quickly by making the transition speed or length shorter.
A lower value will increase the length of the transition.
From the internet.
so maybe its millseconds?
yeah but it's not how that is translated imo.
you do that when you have a fixed time length
but i dont think bp has functions tha take an alpha do they?
i think ive seen one with a alpha and also an interp speed
