#blueprint
402296 messages ยท Page 814 of 403
?
yup just asking
yeah that's exactly what i wanted to do x)
thx kaos and the guys for ur help ๐
Anyone have an idea on how to grab variables from another actor?
I have a On Component Begin Overlap for other actor.
I've set Other Actor as a variable. I assume I can cast to ThirdPersonCharacter and set it to Other Actor on Object? However, from there, how do I call for example, that Other Actor's armor variable, so that I can calculate damage correctly.
Just cast the OtherActor to ThirdPersonCharacter then get the variable.
You don't need to save the ref to a variable or whatever
Yes that would be the good/general way to do it.
The main difference would between the approaches would be
Casting
On overlap, check if OtherActor is a ThirdPersonCharacter. If it is, get its armor value, then apply damage.
Interface
On Overlap, call IArmor::GetModifier on OtherActor, do math, then call IDamage::ApplyDamage on it as well.
Although, the damage causer shouldn't care about armor. Armor should be handled in the damage system by the damagee.
Unless you have some weird effect like "Causes 3x Armor Value as Damage"
oh good point actually.
I do have a weird value though, since I'm operating off the Dungeons and Dragons ruleset, but yeah. Good point. I'll see if I can workshop something up on the Event AnyDamage side.
THAC0?
That probably makes everything super simple compared to what I was trying to do
@slate pondJust use the DamageTaken modifier on the victim's side
OnTakeDamage, HP = HP - RawIncomingDamage x DamageTakenModifier
I'm still praying for the day that components can just automagically implement interfaces on behalf of the owning actor
Although a component is sorta already an interface + state so...
I do interaction by component and not with an interface.
Doesnt work with
-get owner - does implement interface X -> if no, add interface
?
That doesn't sound right at all but I might be wrong
Yeah at that point you might as well just handle the interface there. What I'm talking about is just slapping a HealthComponent on an actor and having it handle damage, with the actor not even necessarily knowing anything about it.
Why doesn't GAS just get component by class? speed?
That's pretty interesting, so it doesnt own an ASC until it gets asked for its ASC?
so the map doesn't start with 100,000 ASCs floating around
so im playing a sequence from a blueprint but it only plays once. how can i tell it it play forever
and no i cannot place it in the level and do it that way sadly
i need it in this bp to reference and start/stop
So I noticed textures change (decrease quality) depending of the distance of the player, there's any way to increase this distance a little? Was looking on google but can't find anything about this
Scalability settings?
Thank you guys for the help but I just found my problem, I was using texture group 2d pixel (because I want to use a pixelated texture and preserve the pixels), but for some reason this makes the texture bug a lot when you apply it to a mesh lol
I'm trying to change the name of one if my variables, but supposedly i already have one with that name "CharactersInBuilding".
I want to change the one with "2" and remove that "2".
There's no variable with that name, does anyone know what may be happening? i already compiled again.
Try restarting the editor. Sometimes unreal doesn't update that a variable has been deleted or an input added
Yes, I had that problem before. Restarting should fix it.
Hello @brazen merlin i come to you in a time of need i cant seem to find the input modifier you showed here https://media.discordapp.net/attachments/897096790757748750/933866789153157160/unknown.png
it's just a float value set as a variable
It will determine how 'fast' the movement occurs, or rather how much distance will be covered in that input
oooh okay
why is this read only
its an animnotify blueprint
possible to make it read and write so i can access it in another blueprint?
yep. What Sparta said. I called it InputModifier, but you can call the float variable whatever you like. You need to make it in your BP_Kart class since that's where MoveForward gets called.
yup :3 btw uh shall i put it into update or the initializion?
set the default value of InputModifier to 1.0 in the variable details. No need to use a setter node here. In your HackerItem class, when the Hit event fires, you are getting this variable and changing the value to -1.0, then delay, then back to 1.0
ahh alright :0 but is it like a float * float as i cant seem to select a Float using a custom name
what?
How would I do a line trace from the player camera?
if its for gun sights, i think its a bit trickier than just a line trace
so you just need a line trace from camera? specifically just that? nothing else is going on?
seems like a total noob question, but -- i basically have a need for a volume with a blueprintable enter/exit step. Does some actor like this exist somewhere? I feel like I'm completely missing something
you have OverlapEnter and OverlapEnd events for actors
If I know what I'm doing (which I don't), yes
you've done line traces before? like from the player facing direction for example?
first person shooter?
alright
well you need to get the forward vector of your camera for starters, there are plenty of "how to do line trace" for unreal out there, you want the camera actor specifically though
@brazen merlin aha! TriggerBox + ActorBeginOverlap. Looks like that will work. Thanks for giving me the pointer in the right spot.
Im testing basic AI Behavior Tree, a simple run to player. Ive got it all set up, except its not working. What am i missing
how do you detect when it reach the limit, actually i just did a (RootYaw >= 90) set isTurning and then if isTurning is true interp RootYaw
curves allow for better blending
they do like that
yeah
it never actually does anything with the MoveTo piece which seems to indicate it is getting nothing for the TargetLocation
so if i don't have turn anims i'm a little bit.. f*cked ? ๐
no, its getting a value, just the AI isnt moving to that location
never touched it tbh.. 
selector will only run a single branch
so that should be a sequence then?
ok, so i changed that. i can see it firing on the MoveTo, but the AI still arent moving
you need some sort of a decorator for the actual condition
so this should work... and i see it firing both now, but still no movement
yeah, really simple flat square and the green covers teh whole thing
other than its shape, all its settings are default
yep, custom controller. nothing special. its only function is to test AI Behavior so it has a single node on it
well single node... graph
which calls the RunBehaviorTree
yes
fwiw both red/blue characters are AI, i spawn at player start
you can see me changing position
also fwiw this is a blank new project, top down, the only thing that exists is AI behavior items already posted
so, we can see the vector is correct, and we can see it execute both nodes in the tree
that seems to indicate the tree and task and blackboard are correct
not sure what you mean by step
all these nodes turn yellow back and fort
wonder if the characters are stuck in the floor geometry, going to move them up a bit
moved. no change
testing
no moveforward node specifically but ill set it up to move to other ai
character
default
tried that, nothing
does this matter
ok. ill try that. i did replace the default navmesh, so it might have borked it up
yeah, 200 wouldnt even make it to the other character, they are 1000 apart exactly
but thats just the bruch
brush
the box itself covers everything, and you can see the gree
yeah, UE5
umm... i dont know how to create a new recastnavmesh. it looks like its an actor
so that could be the problem, it might be linked somehow to the original/default navmesh that i deleted before i created this navmesh
brb rr
back
not that i can tell. i assume you want me to delete it firt
checking
no, it did not
and the green is gone, which seems to be drawn by the recast
ill create a new navmesh
How would I display the out hit of a line trace in a string
ok, as soon as i dragged the new navmesh on the map it creatd a new recast
no change, AI still just stand there
nope
did a search of simplemovement
nope, but ill give that a shot
Why is this line trace inverted with the camera?
Yes
When you say camera location you mean what I have now?
Not sure if this is the place to ask this question. Anyone run into problems trying to use action "cast to bp motion controller"?
you have the location, but you need to produce an offset by using the forward vector
Ahh that makes sense
i tried an AI MoveTo node, but im having issues setting it up.
Heyo, here with what i hope is an easy one.... Opening project, all its set to do is open a menu widget... and the cursor is jumping to top left screen. Hoping its a common one, but not had great luck on google!!
Not sure if this is the place to ask this question. Anyone run into problems trying to use action "cast to bp motion controller"?
that cast doesn't look like its bp motion controller
yea, but cast to bp motion controller was not on the list to choose from
@slate pond Is this what you were talking about?
the action i used gave me a warning. The tutorial i followed called for cast to bp motion controller but it was not in the action menu to choose frome
like how did you make the float just be a name as a blueprint?
so per that output, its working, except the characters arent moving lol
newvar0 is the blue one btw
i thought maybe the animation was broken, but i checked and all the stuff is there. its the default animation blueprint
i didnt think so, but considering anything at this point
this is exactly why i didnt want to test in my actual projected. wanted to keep it super simple
sure
You should really watch a video on bp variables
default AIController - no change, and i still get the same Success output
at this point weve taken the behavior completely out of the scenario, so whats left. it would seem the characters themselves
checked characters on map, they are Movable
been following this https://www.youtube.com/watch?v=uEd-USZfJxU tutorial on a basic character controller for a vertical slice, I cant seem to find any option he has enabled that my project doesnt but I have no pawn movement on mine what am i missing that might be assumed to be turned on for the tutorial?
For our first series, we tackle one of our all time favorite 2D game: the excellent metroidvania Hollow Knight! Explore with us the intricate design choices behind the character controller!
https://www.patreon.com/Lucid_Tales_GDP
00:00 Intro
01:37 Character Controller Analysis
04:06 Walking
09:17 Jumping
16:39 Final Showcase
Hollow Knight Pro...
is that in the character?
i dont know where that detail section is at
lol duh one sec
static
Hello friends, I'm kinda new to UE and I'm having issues with a save/load thing. I don't wanna butt in someone else's question here but if anyone with a big brain could help out that would be amazing; I've been at this all day
well i seriously appreciate the effort. at this point i feel like i should just recreate the test project and do it all from scratch again. who knows
UE5 bug maybe?
ok will do thanks again for monstrous effort @slate pond
You can't hook up the switch this way. The movement result would only be valid if you check it on the On Success or On Fail outputs.
why? i had a separate print for each output
not doubting you, just dont understand why it would matter
I made a comparison clip of my screen and a tutorials screen
So either on fail or on success.
i see what you mean... but in this scenario if it was failing it wouldnt even get to the switch since the fail wasnt hooked up
i found out how to make one i called it ReverseInput only thing i get tho is Get or Set Reverse Input
I made a comparison clip of my screen and a tutorials screen
yes it would.
ok, good to know
well ive already deleted the project, so ill put that check back in if the new test project runs into the same proble
thanks for letting me know
d'oh <_>
yep, lol... i have a problem with starting things over and over and over again. im doing good on my actual real project, have only started over twice
once i get to a point where ive figured out a bunch of better ways to do things, it feels messy so i start over
ive done pretty good resisting that urge
when you drag a var from the variable list out into the graph, you have those two options, get or set, based on what you need - that's how you use variables
anyway, good night ๐ thanks again
what exactly are you expecting that isnt happening
Im trying to get the print string on the 2nd image to play
that is all
the button works on the first image and plays the first print string
Is anyone here particularly good with reading crash dump files?
is the function in your "Inventory" bp?
Yes

honestly no idea why it wouldnt work. when you press play, do you see the flow go through it at all (the red line thing)
I dont see any flow, no
which implies the exec isnt actually 'entering' the function, but i cant see any reason why. its not like you got anything complicated there
oh, on the top when running your game, you have a drop down in which you have to select what your monitoring
yes I do, I forgot I turned it off earlier
mb
I see the flow for the first part, just not the 2nd
no clue. sorry. its like 2+2=5 for some reason. i dont see any logical reason it wouldnt trigger the second print
is not executing the function evidently
i have something like 40 functions in my main project and ive never had that happen
Yea ive been stuck for a little while now
thanks for trying
try creating a new test function
good idea
with no pins
are you getting any errors?
Hello everyone. I'm a new guy to Unreal Engine 4, and I bumped into a Blueprint problem for Text Switching in Widgets.
@supple bane try creating a custom event that executes the function in inventoryBP and then try calling the custom event on clicked instead
Oh man, I'm nowhere near to inventory. You guys seem to know your stuff. (:D)
I managed to change text with BP interfaces for actors, but not text switching when activating an event like opening and closing doors.
@peak solsticeWhat causes Open Door to appear?
Ive solved the problem, thanks for the help
Id love some help if anyone can assist. Is anyone here particularly good at reading crash dump files? I am currently having an issue with my shipping builds. What is happening is I can Play the shipping build 1 time, as soon as I exit and go back in its an immediate crash and just says "Fatal Error". I do not have this issue at all when I am launching the game using "right click on Uproject > Launch Game" I also do not have any errors in the editor either in my output log when doing the same repro steps.
@peak solstice As far as I know you have to remove widgets from display when you want them gone
you have a remove from parent node
where should I insert remove parent for names?
I used event tick, maybe it's that causing it?
I'm kinda new to UE too lol
same
yeah maybe you don't want whtaver you're setting there firing off every frame
I made it far to know how to make Press Vs Hold same button for prone and crouch
Is there an alternative for Event Tick?
I forgot to show this.
Should there be a branch here in this?
um, maybe a collision when you get close to the door?
i don't know what the situation is exactly
I prefer Box Collision Overlaps over LineByTrace via FPP Camera
for activation and widgets
what if you have a delay as long as the door opening/closing animation in between checks?
idk, maybe someone with a bigger brain can help tbh
currently it sumps my entire magazine because both ammo and max ammo are set to 25 by default, how would i make it only use the shots i have fired
Doors are activated by an Input which is (X) or [E]
if u gonna reply pls tag cos im gonna be off discord ty
oh @peak solstice try looking into the flip flop node
and have it go from open to closed
tried moving it from the list onto the graph and it dissapears after wanting to connect it
@peak solsticeYou have 2 states, whether or not the door is open and whether or not the door is in range to show the popup.
When player enters trigger area, show the popup. When they leave, remove it.
When player activates the door, set bDoorIsOpen to NOT(bDoorIsOpen), then change the popup widget text and play the door opening timeline, both based on the current state of bDoorIsOpen
does anyone know how to get a specific actor from "get all actors from class"?
Pretty new to messing with arrays,
can anyone help me understand why this isnt working
why print strings or are they only for tests?
tests
gotcha ๐
@supple bane you only anything about texts for object names by any chance?
know*
im not sure what you're asking
check my screenshots above and see
You can use an array "Get" but that means you need to know the index of the actor you're wanting to get.
What is the unique thing about the actor you're wanting to get out of the array?
im doing it with names more as a test, ill be switching to getting the item class
the characters movement component
What's not working about it? You could also check to see if the strings being fed into the comparator are the same by putting them into a print string as well.
Ok, but all the rest of those actors have the movement component too, yea?
yeah, it's just affecting the first actor from the "get " node
it doesnt proceed to 'scan slot for items' so im guessing its just having trouble accessing the inventory slot array
So that looks like you have nothing in your array currently if it's stopping there.
not in that case
In the actor array, what actor is it that you want to pick out specifically? What is it about them that makes you want to get that one? Are they close to you? Are they the target of an attack? How are you supposed to know which actor it is you want to interact with?
thats what I thought
but that shouldnt be the case
What are those objects?
That's a bad idea. Widgets shouldn't be used to hold game data, instead they should only represent data of something else. Say, an inventory component.
That aside, those Inventory Slots, they exist already in the widget itself (like you see them in the design view?)
im hitting a actor, to which i apply a actor component to slow the walk speed of the actor, but since im using the "get" node it only applies the effect to the actor who spawned first, im trying to figure out how to apply the effect to the actor that the projectile hit ( photo for reference)
no, they are only added through the construct script
So then they are only variables?
yes
Hi all, I want to replace the reference of a replicated actor componant from an inheriting child BP class. Should I do this on ConstructionScript? And what happens to the events that are bound by the parent class, will they still be bound to the new reference?
then there's no data
^
they are all just from the inventoryslot class
if the variables don't have any script added to them, they are just a shell
So you have a reference to the actor that was hit before you apply this effect and I'm guessing you're adding this slow debuff component to the actor that was hit. If that's the case, you should probably just be able to get the owner of the component and there's your ref.
i'll try that
May need to cast it to your enemy class for now, but you may want to think about using an interface.
so why can I not get the array now but Ive been able to before?
because the string that you are looking for isn't added to the actual array
the item info is
If those "Inventory Slot #" only exist as variables, and they do not have a widget assigned to them (like you can store the return variable of a create widget node in them) then they are effectively null. Adding those variables to an array when nothing is populated in them is like adding nothing to the array.
it would be easier if you used a struct
So I cant run code through individual slots?
This scenario, I have a widget I've added to another widget. This variable would be valid.
If I created a variable manually, like this "test" one...
wait nvm im stupid
It doesn't have any widget assigned to it.
So they exist in the heirarchy of the main widget you're looking at?
Is there a way to get the gamemode of a level prior to loading the level?
cant get anything from a level if its not loaded
Well, I misspoke. I want to load it, configure it, then switch into it.
So, it should technically be loaded into memory.
please clarify the "its"
I didn't say "its"
..
I'm not sure what clarification you want
load gamemode or level? configure gamemode or level? switch gamemode or levle?
yeah it works, but it's affecting the first actor, im trying to find a substitute to "get all actors of class"
I want to place the umap into memory. But NOT switch to it. Then, I want to access the gamemode that is tied to that umap. Change some things and then switch to the umap.
So, load the umap. Configure the GM associated with the umap, then actually switch to it afterwards.
Getting the owner of the component should be what you need if you are adding the component to the actor that you're wanting to apply the debuff to.
i dont get why you need to change things about the gamemode when the level isnt loaded, it should already have the settings. If you're trying to pass data between levels, you need to use game instance.
Can I bump this about replacing my actor component reference from a child class
Because I don't want my GI to have 239482374902387 variables for my game. I want things to be isolated. There shouldn't be a running count of things that don't even need to exist unless needed.
Maybe a silly question, but have you added the main widget to the screen before executing the scanforitems function?
I add it to hierarchy then remove from parent onBeginPlay
yeah it doesn't let me homie
Doesn't let you what?
well you still cant affect anything about a level if its not loaded
So there is no possible way to load the map into memory and NOT switch to it immediately?
maybe, but not by bp
im trying to reference the function that i made in the actor blueprint but it requires a reference to the actor
how do I get rid of this Return node in this interface function? I made an output then deleted it and now this return node won't leave... do I really have to delete the function and remake it? 
Get the owner of the component, not the actor that you're using getactorofclass from.
ok, now what?
this is what it shows
i see
That's the only way I found to do it myself ๐ข
so sad... I have a bunch of stuff in the implementation already
I'm stumped on this one. You can check the length of the array before the loop, and it'll probably be 0 as that would be the only reason why that loop doesn't execute. If it's 0, that means the array has no values in it.
how do I check the value?
/ length
Length node
Yep
yea it came out as 0
when I scan the array from inventoryBP i get 6(which is whta im looking for)
No.
Oh lol. realized it had already been answered.
Yeah and expanded upon.
Hey guys! Does anyone have any suggestions on how to load another level when when say all ai on a map are slain? Say kill 10 enemies then you get a popup for the next level?
In your game state, do get all actors of class "Enemy" on begin play. The length of the array is the total number of enemies in the level - store that length in a variable on game state. When you defeat an enemy, do a call to game state to subtract one from that stored variable, and check if that variable is <= 0 (less than just for ensuring it gets called) and if it is, display your popup for the next level.
^This but self registering Enemies instead
It would work the same way, but would suddenly allow several "waves" and whatnot
Guess its out of scope of the quesiton
way to go Squize
I'd go with the dispatcher. Then tie their death to increment a counter in the game state. Each death the game state checks if the number of deaths equals the amount required set in the GameMode.
thinking overly flexible as always
well since we're all saying our opinions on the matter... I would have the enemy broadcast their death (allows you to have other things to listen to this if you want) and keep track of deaths in game instance since you are changing levels. I say game instance because you can post final score of total kills but still work with per level kill counts for changing the level.
is that Gizmo from Gremlins?
Baby.Yoda
any ideas on why this is inaccurate?
is that Gizmo from Gremlins!?
Ye ๐
inaccurate how
just different from the actual array
thought it was an Ewok, another idea stolen by lucas films
define "actual array"
what is the "actual array" i this context? what your widget is telling you?
sorry im having trouble explaining it
it comes from the actual inventoryBP
instead of getting called from a reference
if I call the length from inventory itself, I get a length of 6(which is what im looking for)
if I call it from anywhere else, it comes back as 0
My guess would be that you're using a variable named "Inventory" without setting the actual instance of an inventory that it needs to be set to.
Likely has errors aswell due to access none
no thats not it
Question numero dos: Is this multiplayer?
no
and yes i am getting this error
Datura was right
hm
What do I win? ๐
lol
Blueprint Editor with hookers and blackjack
So you need to set that variable before you try to access it ๐
onbeginplay?
A reference variable is by default empty/null/nullptr
or construct?
Beginplay sounds more reasonable
k
being an inventory
dont really have any knowledge of your setup so cant really give good reliable advice in such context
its all guesswork
Thank Datura! ๐
it works now, thank u both so much
What would be the best way to create a melee system for different weapons? Like, should I make all the weapons different blueprints, then put the coding in each of them for how they work?
maybe better to have a parent class since they are all melee, then child classes modify the parent setup - collision, mesh visual, etc
try to list out all the features you want, then see what are common across all weapons
That is really good advice. Thanks! I'll take a look at it.
Is there any way to get any of these inputs in an Actor Component?
Or what would be the most proper way to handle this.
this has yet to be defined
Like, should I just put all my inputs on a Controller BP, and then have this pull the events from a cast?
i suppose. Player inputs usually go in Controller or Character/Pawn
you dont really want it all over the place, but maybe you do ๐
Yeah, I have everything setup in my Character atm
I'd rather move it to a Player Controller
then what's with the question about actor component?
I wanted to have controller inputs do stuff in the Component
I didn't have a central area for controls yet, so I'm going to work on that now
would still think its better to have the input event not all the component
is this mp?
Yes
ah that makes sense
you can still have inputs on character
or mix between controller and character
Yeah, currently it's all on character, but I think for Organization sake, it will be best for me to put it all on a controller BP
That way multiple characters can have the same control inputs already done.
usually you want movement and such on the character, while non-character specific inputs like opening menu are in controller
What about something like an attack?
anything that needs to talk to the character to do something, would go there
menu, push to talk, things like that are on controller
those areNT character dependant
Ah, okay. Makes sense.
So like the player controller can still use inputs even when the character is destroyed or whatnot?
right
That makes a lot of sense
they cant move, but they can still open menus
Yeah
cool
is it the root?
I'm doing a Melee attack system for a specific weapon on a component. In case I want to swap my way of attacking, I just change components out. That's the best idea I came up with.
Not sure what root means in this contex, but I'm editing the event graph for my first person character blueprint
also, im pretty sure the sets are functions, not var
sounds good to me - whatever weapon is held can pass its data to the character or whatever to adjust things like anims, damage vars, etc
I was wondering, would I call animations on the Character, or do it in the Component?
we're talking locomotion anims yeah?
No clue. Probably?
like different idles?
idle, walk, run, jump - those are locomotion
Yeah
Then yes, the one offs
your weapon holds all of that
both types anyways
you can have a function on your character to call the attack - get damage, play montage, etc - and you'd have vars for the inputs for that function
the vars are set by whatever weapon is currently held
Sweet. I guess my next question is, how do I hold an animation on a frame I want until I release a button in a Montage
Sounds more like a locomotion state then
what mean "hold"?
You could also use sections in your montage which loop until you release your button
Like, I have a sword swing anim, and at the build up for the swing, I want to keep that pose until I release my attack button
Something like
Press Button -> Play Montage (with Sections -> Play until loop, which repeats)
Release -> Play Next Section of Montage
How would I choose where it stops and loops?
yeah i supose sections would also work ๐
you set these sections in the montage
So when making a smooth crouch event, I set my capsule half height. I currently don't have a crouching animation, and shifting my capsule half height basically moves my entire character (i.e lowering it will lower my character through the floor, increasing it will make my character go into the air). Is this just something that needs to be compensated with using an animation and shifting my mesh's z-axis? It seems my hitbox works as intended, so I can still walk and actually crouch under things, but visually my feet are in the floor
i sorta skimmed this ๐ I read "smooth crouch" - you should use a timeline to interp the value
I did that
https://www.youtube.com/watch?v=nTMDQhrOfVU&t=205s
Shortly shows montage sections
Most descriptions you find are using the old interface, but this might help
Quick introductory example of using a montage for an attack combo!
Thanks
then something is wrong with the setup
?
my crouch works, it's just the tidbit where visually my character's feet goes through the floor
oh i see, so the mesh looks odd but the collision is alright
exactly
not that i know how, but you could use IK on the legs so they are responding to the geomtry
I'm asking if I need to just use an animation and change my mesh's z-axis or if I'm just doing something wrong overall to be moving my whole character
I'll look into that in a bit, since I've never heard of it ๐
lol i mean ive not done a crounching 3rd person character before
I'm first person ๐๏ธ
oh, but there's a player mesh
yep
ive done fps, but you cant see your feet
I was thinking that I'll just be hiding my body anyway
but for the sake of learning I've not set that
still the idea of using IK in engine to calculate legs as they crouch since its dependent on the collider update
The movement is based on the capsule that you are using
If it is reduced in size, its main priority is to have the bottom of it on the ground, it basically ignores the mesh, for which reason it gets pushed into the ground
Just having an animation that suits the height of the capsule that you set works
How would I loop part of the Montage?
that's where i was thinking your setup was wrong ๐
sidenote, does it sound proper to use bps for character/widget/scene control flows and use c++ for things like calculations/inventory management/etc.?
oh dw, you were right, I didn't make it clear that it worked haha
you missed this #blueprint message
Doing VOIP setup, new players joining the server don't have the sound attenuation so their voice goes cross map?
Let me quickly check one of my projects
Yeah unfortunately its not explicitly mentioned in that video
Yeah this didn't end up being the issue ๐
Yeah its more to do with the BP but cheers I'll post it there
Basically something like that
You can ignore the "End" Section
All you need is Default -> LoopStart (Loops)
LoopEnd
I think this works?
I just don't exactly know how to set this up in BP
I've done anim montages before, but not with sections
hello everyone,
i am trying to call events from an actor that i saved inside a variable. I find the actor through a linetrace from the mouse, basically its the actor that is currently under my mouse-cursor. I checked already that the variable gets set correctly. But neither the cursor-overlap nor the on-clicked event get fired. any idea what the problem is?
Oh wait, I think I got it. It just keeps looping until the animation montage finishes
Sweet, I got it working. This is very nice.
you can also define which section it should play next with this
What does that do?
You can switch to an arbitrary section in your montage if required
Like switching from Loop back to Default
just as an example
you can change which section to play next. For example, you have a combo montage of 5 different punches, they can play sequentially, or you can specify the section of the 5 to jump to
Loop back to Default is a good example, very handy
Ah, okay. Sweet
Is there a way to prioritize a Montage, so another one doesn't trigger? Like right now I can hold down my attack, but if I do something else while doing so, the anim montage for that will play over it.
you could block it by checking if montage is already playing
anim montage should play over locomotion, you can override locomotion using slots
you do need to cache the locomotion and blend the slot using layered blend per bone
I think theres a Tutorial on YT for montage priority
Handy if you want to be able to prevent montages from playing at the same time, but still allowing it to cancel them in certain ways
I'll probably need to do this for other things down the line
oh, different montages... what Squize said
What needs to be the Target for this?
if you use multiple slots, you'll need to control the layered blend per bone to prioritize which plays of which
Ah, I guess a better question is what is an Anim Instance?
get your Mesh, from that get Anim Instance
its the anim bp instance on your character mesh
Is that something that needs to be set up beforehand?
Its the "framework" how your character handles animations
Third Person Character from UE4 has a pre-built if you are using that one
I think I got it working
Does anyone here have any ides on how to calculate the diffrerence between two numbers? Lets say i have two ints 22 and 8 and i want to get the difference between them so from 22 to 8 it 14
minus then absolute
Thx it was the absolute node i was looking for ^^
Hello. How can i add a trail to a Pawn, if its moved by the Character with Contorl rig?
Is box trace much more expensive than 4 or 5 linetrace ?
Thanks for all the help today everyone. I made a good amount of progress on my project, and everyone here has really helped me understand a lot of things I haven't before.
hay can someone help me with something basic? I'm just trying to get a widget to work, I made a button on the widget and I'm trying to click it but whenever I play in editor, the button wont register anything, like the button doesnt exist even though its on the screen, I have an onhovered event, but even though the mouse cursor is hovering over it, its not doing anything on the blueprint at all.
Did you set the input mode?
Yeah, when you display the widget, use that afterwards and select the widget
I just added the widget directly in front of the player camera
is there a better way to do it?
Is there any reason why you did it that way or was that just a general attempt of displaying the widget?
just a general attempt
i didnt know how to do it properly, i want these buttons to always be on screen
Aight gotcha
If you want it to be displayed right at the start
Event Begin Play -> Create Widget (Pick your widget class) -> Pull the return value out and use add to viewport
This just makes it visible on your "Camera"
If you want to interact with it you need to use "Set Input Mode UI Only" for example
ok well that made the widget work but disabled the touch controls
so now when the widget is focused by the mouse it wont accept any touch input
how do i have both going at once so i can touch the button
via Set Input Mode you can define whether you only want Game Input, UI Input or Both at the same time
Might work when using both
Did you try focusing it? Not really familiar with touch input tbh
yeah doesnt work
must be a limitation of ue4
cant have touch input and ui working at the same time
which is retarded
it should work
might have to make a custom touch input hud
Seems to be a common issue when googling it
https://answers.unrealengine.com/questions/541635/touch-buttons-dont-work.html
Maybe this works no idea, but there are a few posts on the ue forum, you might find a suitable answer
thank you i'll take a look
nah the answer there didnt work for me
apparently the canvas in the widget block touch controls I'll have to remove that from the widget
Someone know if it's possible to set texture hue through blueprint? Not a material, a texture
this would normally be an instanced material parameter?
not sure exactly what you mean
I want to recolor a paper flipbook but since it doesn't use materials IDK how to access the HUE from a texture
I want to set this value using blueprints, is this even possible?
This is exactly my problem, I must change the texture, not a material because flipbooks can't use materials, only textures ๐ฆ
well, I have no great ideas then
I'm pretty sure flipbooks use a material from what I can see here
never touched this stuff
I'll keep trying, just found a "cast to texture" node, maybe this will work... anyway thank you for the help!
Uh, I'll try asking at this channel, thank you for the tip ๐
Hi, what is the best way to sort a list of float? contained by a map or a datatable
smaller to bigger for example
Manually
there is no other way? what if your table has 20-40 lines?
What about it? Just sort it xD
ok I see, through this node right?
probably not if this is a struct from a datatable
I don't see any other node sorting.
I can still get an array from the datatable no?
Get Datatable Rows,
then you need to fetch the data
store it in an array, and make a function for sorting it
I see, thanks for the hint, I'll start working on it!
Hello How are everyone
good morning
how can i get nearest actor
then find the second nearest actor then third actor etc?
From what I'm reading it looks like you're gonna have to get all relevant actors, then compare the distance of them and order them that way
For example
This I believe gets the closest distance
What I'd try is to find something that orders the actors based on the 'get distance to' node
Had a function for this a while ago
This sorts the actor array based on distance
@velvet forum
if you only use distance for comparison
use distance squared instead
ur cpu will thank you
How much does it matter ?
Any comparisons on it? Is it.. twice as fast? ๐
yeah its a good habbit to pick the better/faster method slightly less accurate but wouldnt matter here
how do I go about creating a child of an anim blueprint using a different skeleton? ive done it before but ive completely forgotten. >_<
if i have cats and dogs id rather avoid having two fairly similar anim blueprints to manage if they can just share one parent
think i managed it
Depends on your game I suppose.. I have separate animations for male and female characters cuz they move a lil differently. I'd pry keep cats and dogs separate too for the same reason
Compiling shaders are too slow than usual. I Tried to comple 120 shaders and that took 1h, 120 shaders before was just 3-4 minutes or even 1 minute sometimes.
Hello
https://streamable.com/t6j62v
look thats work !!
thanks
Sweet๐
120? O.o Whenever our tech artist changes stuff, it's immediately 6k to 30k. ๐ 5900x noms on them though.
Nice to see there's not only Green players around
Hey I am trying to try some networking on Unreal. I am playing as a client but whenever I play it. It does give me the control over the default main player
what might be the issue?
Thank you very muchhhh ๐๐๐๐
Why is it so complicated to get a simple variable from another blueprint
Hi guys
I need to iterate thru an array of vertices.
The assumption is that the vertices are all in sequential order, ie positioned next to each other on the actual static mesh.
How can I sort the array so that this is accomplished?
Sort
anyone know how to make sliders snap to certain points througout the slider?
so it snaps to like 0% 25% 50% 100% etc
Just a guess, set value is between x and y -> 25% and so on?
hm?
set these setting
if you want it 0 to 1, make step size .25 and max value 1
np
my main fear is idk how to save all these options lol
like will they reset after they restart
or does ue4 auto save those
video settings
those wont, but default value will
yeah
have you used Saved Game ?
How do I use the Save Game Object in Unreal Engine 4?
Source Files: https://github.com/MWadstein/wtf-hdi-files
does anyone know what causes widgets to return invalid...?
my progress bar that very clearly exists has decided to not be valid.
are you looking for it on Construct? add a 0.0 delay before looking for it sometimes helps me
If it returns invalid then it doesn't exist
accessing it via interface. I'll add a delay there real quick to make sure, but it wasn't being accessed until 5~ seconds after play
I've had that problem too, where I'll set it as a variable between create widget and add to viewport, but it will be return as invalid everytime for no reason
yeah, still invalid lol
ooo, sometimes my widgets get bugged , I have to save and restart project and things work different
Hi folks, I am not sure if I am doing something wrong or if I have discovered a bug. Instances of my custom widget placed in other widgets are not updating their visuals when I make changes to the custom widget. Specifically, I can access a button widget that I added to the custom widget via blueprints and define functionality for it. But the ...
I would check that you're assigning the widget correctly
It's kind of difficult to say from the screenshot, but it's always possible you're not using the same variable, or the initialization runs after the point where you try to access it (you can for example use Print nodes to see what order stuff runs in)
yeah debugging it now, really irritating bug because it's initialized on begin play and isn't called until I click on something
That sounds like it should work then, assuming the object with the begin play is initialized
So beyond that it might be not assigned into the variable
:)) i know 120 it's not much at all ,but i used that to make a compare.
I was able to isolate this error to this part of my blueprint.
The player controller might not exist when it runs
Since I think that would be accessing an array to get it
it runs when i click a ui button
Try disconnecting the spawn node and see if it still errors out
Project restart fixed Widget problem?
yup, im working with widgets now and have to restart a few times an hour
IVe tried that, im still getting the same issue
Its an array thats causing the error
Is the class ur spawning doing something with an array at beginplay?
@visual dune if you disconnect the spawn node and it still errors out, this is then not the cause for it
also I mean disconnect as in remove the exec pin :)
Oh, i tried that and yeah it doesnt crash
I will look for anything
Yeah I think Squize is onto something if it only crashes when the spawn runs :)
Yeah i tried spawning a different actor and it didnt work, so i gotta find the issue with my actor
Its weird because it only crashes when compiled to a shipping game but doesnt when tested in editor.
Things happen a tad different in shipping game
The root issue is not checking validity of index ur trying to access
U45 doesn't let you click on errors and jump to the problem ?
#ue5-general would probably know
Hi kaos, i setted up everything (curves, turn anims) and tried what u told me, it seems to work for the detection but i'm struggling with retrieving curve values etcc to interp the root yaw, everything i tried just doesn't do what i want ๐ any chance you help me pls ??
I took the epic sample to understand how they do with curves but yeah they got the same issue
i setted up my curves like that
TurnAnim is a metadata so i can detect if a turn anim is playing
Hi everyone, I am trying to do a RepNotify on a struct variable but when I am using the "Set members in MyStruct" node, the OnRep function only get's called on the client and not on the server. Is there a workaround for this? I am using Unreal 4.27
Why would you need it called on the server ? Server is setting the struct var, no?
It is not getting called on the listen server* So the host does not see it
Do other clients see it ?
If not, then it doesnt sound like you're replicating anything
Yes other clients see it
Guess its a #multiplayer problem then
Ok thank you
Does it sound reasonable to surround "waters" and "lakes" with a spline to attatch any dock/fishinghut to , in a city-builder ?
oh i see, so that you have "build points" specifically around water sources
yeah.... somehow you have to check if the building placement is within the proximity of the spline or whatever...
thats fine, i'd use a manager for that and just check all the splines really
what about physical materials?
"getclosestLocation to world location" works wonders ^^
hmm... well i could but ... troublesome?
i'd still need some weird snap logic for it i think
i dunno how your system all works, i was thinking of a line trace when the player tries to place it
then you could line trace for that physical material
of the "area" the building would require
per meter..... so you need to check multiple spots? could still determine that through physical material i think, just need enough checks to satisfy that there is enough water
im thinking of the Settlers games actually, but they show a grid of dots that range from red to green to inform you of building spots
thats my inspiration, mostly
so do you show build spots?
No, that part i removed
alright well, physical materials seems like a direction, or else go with spline
id lean on physical materials for the fact that if you change the water shape you wont have to update a spline as well
So I have a Actor that refills a players Gas, but the issue is that it checks every tick for the IF part. I want it to smoothly add gas to the tank, but don't really know how to do that without event tick.
there's a few traces going on while moving it around
well looks like you already got spline going?
Figured just using splines would solve alot of it, and avoid some weird edge cases
like the X rotation while doing Y makes Z happens ..
spline is just... spline ๐
you could use a timer instead of the tick event
basically you start the timer when the overlap happens, and invalidate it when the overlap stops
https://www.youtube.com/watch?v=qc5WpNq7RFg
i think i have a picture of this setup
with physical material and traces, wouldnt I need to orient it to the direction of the ocean aswell? Along with moving it to a "desired % of water/land split for the building"
see thats the parts i dont know, because i didnt build your building manager system dealy ๐
its just an Actor following the mouse world location x)
Here ya go, replace the custom events with your overlaps
so intricate!
Dude, thanks! This is great!
but don't use world delta as time, if you want to update 10 times per second you go with 1/10 = 0.1
trace is just checking for "landscape" or "water" tag
then what about spline?
if all traces hit, and are of the correct tag, i accept the location
I dont have the spline yet, was just looking for ideas on it ^^
oh, that's for those that need land and water?
How can I make line traces pass through the character?
nice try Squize, but this is #blueprint ๐
busted !
dont allow the character to block it
you can pass an array of characters/actors to ignore
When I tried that it didnt work
yea, or remove the character from the trace channel at all
but then, you just need like at least 40% of each right? give a 20% fudge?
Yeah that sounds reasonable
can tune them as you need
and probably a side that fixed needs to be Land (for entry point)
i was thinking that too, didnt know if you want to do that, but yeah
so first row of traces needs to hit land, then the rest split 40% with 20% give or take
maybe not in half, but definitely a side
Ill try that
i'd prefer not doing the splines really
procedurally making them very nice would be,.. a challenge
is it grid like? the way you trace check?
yes
so if its a 4x4 building, you just need the first column for water and the last column for land no?
first column being the "front" (or whatever you call it)
Exactly
seems less error prone to ignore the middle then
Hmm
i guess unless its a really long building...
that actually makes sense in many ways ๐
structurally speaking right?
foundation height determines the difference in terrain that i accept accross the entire building area
Yes i am
On water im aligning to water surface, and checking depth to ensure building reaches
you both should meet for a candle light dinner
well i hope it works in execturion
what kind of candles?
This doesn't ignore the player when looking at the line trace draw for some reason
megascans
i'll probably be late then ๐ฅฒ
because you don't set the array when it's not connected to the execution flow
set out actors isnt pluged in
your get actors isn't getting anything and the set is not connected
and you may have to pick a class
Geez i missed everything
Is there a way to quickly check what other levels are loaded?
not in blueprint
so close. Wrong sides. Ty for the help!
im trying to make a projectile that chains to enemies after initial hit, any tips?
I know this system sucks. What should be done differently
what are you trying to do
You're basically not using the gate at all, you're just making your own gate with the boolean
Thats what I thought
thing is idk how id check and see if the player presses "e" in the gate
Well what happens if they HOLD e?
Right now, yeah. I'm just wondering what you're trying to do with Tick at all
In short im trying to make a interaction system
for a button or something like that
I guess what I'm saying is, if you can only spawn while overlapping, just delete tick, delete the gate, rename your bool "IsOverlapping" and you're golden
overengineer
my speciality !
Doors are not your friends in my game
Hey Guys I need some help i want to make if the player loses the same level restarts but i don't know how so can anyone help plz?
This one?
ik
yes
Usually Open Level
Open level
Is there a way to change how much force an object moves with if you're using SetRelativeLocation?
Other than just speeding it up
I dont want it to move faster, but if an object gets hit by this I want it to get absolutely fucking rocked
You could implement Physics.
The other object is already phys enabled
Heya i have problem with this error
it already gets moved by this, I just want it to get moved MORE
dosnt checking Sweep make it collide ?
Nah sweep makes it stop when it hits. This thing should stop for nothing
ok
The part of that code
EventHit, add impulse to the other actor.
Have you tried adding force or yea Impulse.
Ach, I knew that would work, but I had hoped there was a better way
how do you get this debug info on screen?
Do you know if there is a node to modify ISO, shutter speed, aperture etc, from blueprint
Got it - " ' " key
If you click the Make Post Processing Setting , you get a list of ALLL the setting in Details Window
how does one make so you can make a actor bounce to a set location
Depends on the use case.
You can add a projectile movement component to it and launch it, or interpolate it's movement yourself in it's tick.
making it so it moves to the closest actor upon hit
Like picking up coins or something?
like chain lightning
projectile hits actor then chains to other actors
Oh! My brain is in literal mode. I took bounce literally.
been there
Uh. Basically just an iteration loop. Choose first target. Get targets around first target, run through a distance check to get the closest, make sure it hasn't hit that target yet, return closest non hit target. Repeat for that target, repeat for that target, etc.
that part i understand, is the actual movement part that i don't get
anyone know how to get a microsecond in blue print?
on duration put .001
I'm trying to pass a microsecond as data to an SDK
not trying to wait for a microsecond
so microsecond as a timestamp
c++ works as well
i see something called fraction nano but unsure of what it is
that's beyond my knowledge, sorry
it's alright, thanks for your help!
Hello guys, could someone tell me how to make the camera in flying template like in the third person character template, I mean when you move with mouse the camera moves as well
you mean that the camera locks to where the mouse is at?
What are you trying to do?
Getting the microseconds that passed between two date time stamps
I'm not sure you're going to get much finer than Milliseconds in BP. C++ has access to the actual tick count, which registers the time in 100ns increments.
yes
like when you move with mouse the camera moves as well
and looks from different angle
Hey guys, in today's video, I'm going to be showing you how to move the camera around the player while they are moving without it effecting the direction in which the player is walking, or moving, in. This will create a free look system that you see in PUBG, The Last of Us 2, Hitman or Assassins Creed.
#Ue4 #UnrealEngine4 #Ue4Tutorial
_________...
is this what you are looking for
Any idea on how I can add the object itself to an array in the GM without having 10 Add nodes depending on the enumeration item selected in the Details panel in unreal editor ?
Like I do have 1 node set for the Roll Call Triggers, but I don't want to have 10 things like that for each element of the enumeration, I don't know if it's possible ?
oh thanks
try to plugin all to one add node, if that doesn't work you can use a "append" node, drag from the input array and choose "make array"
then add all your items to the temporary array that you append to the other one
wait you got 10 arrays where you want to add the same item too?
no
I want to add the object itself to the right array depending on the selected item in the Enum
like so ?
yes
Thanks
now you should be able to connect the arrays
you most likely don't need your switch node at all then
you connect your arrays to the enum values
and use the output of the select as input for the add to array node
like so ?
yes
thank you
What's your camera in the set node? When I try to plug a cine camera component or a camera component it's not working
that was just a normal Camera Component in a blueprint
i never messed with cine cameras, dunno if it has a post processing part or not
Oh okay, there is two "set post process settings" node
I would rather not Messe with them but unfortunately noraml camera are missing certain physical element like foacal length
I need help with text switching for Widgets. Open will not disappear when doors are opened
I'm using a BP_Interface called Get Name
What is your Widget Hierarchy?
Yes, I need help with it
Widget appears on Overlap begins, disappears when you leave box collision, that works. My issue is when I open the door, the previous default text (Open Doors) when door is closed will not disappear when I open the doors. It is hiding behind Close Doors text
My widget is called Name_Widget
If your widget hierarchy only has one textblock, then you're adding that widget to the screen multiple times.
So is the issue the Interface or Widget with Binding?
Explain Widget Hierarchy, I'm very new to UE4
Widget Hierarchy is the list of widgets you've added in the designer. It's a nested hierarchy of widgets.
More likely the issue is that you've added that widget to screen more than once.
If I remove the On Component Overlap Begin from this branch, I remove the text switch problem but I will end up with no default text when first time arriving to the door prior pressing X
@maiden wadi
What do I need to do here?
Nothing. If that is your hierarchy, then your widget is most likely getting added to screen multiple times. Where do you create and add this widget?
@maiden wadi
I added the widget to the door's collision.
Xbox Button Widget works fine, so does it's color changes when pressed
But the other widget the Name one is broken
Yeah. Multiple components are going to overlap on that. So you're adding several widgets to screen on overlap.
You need to create a widget, set it in that variable like you're doing, but before you create it, check if the pointer is valid and in viewport.
So component overlaps...
So it acts like an event tick?
No.
Your character by default has at least two components. More if you've added any. Anything with collision in that door's overlap type will trigger that. So if your capsule and your skeletal mesh trigger the overlap, that's two overlaps.
The casted actor will of course pass for both, because both belong to it when they trigger it.
My character has even more components, It has box collision on both arms plus an FPP camera on its head
Should I replace On CompnentOverlap Begin?
You just need to control your widget creation.
Between the cast and the Create there needs to be logic checking if the widget was already created and put in that pointer. If widget is not valid, create it and add it to viewport. If it was valid, check if it's in viewport. If it is not in viewport, add it to viewport without creating a new one. If it is created and is in viewport, then do nothing, it's already where you want it.
how would I set a toggle for an axis mapping, basically im using a trigger on a controller to zoom into something, and on release i want it to do nothing, which is happening, but the next time i press the trigger i want it to zoom out, or maybe press a button to actually toggle it, maybe A, either way all ive been able to get to happen for an AXIS mapping is zoom in or out only, im assuming its because its on tick
Ive tried the flip flop, tried doing an action mapping instead but I just cant figure it out, I can sort out the rest of the code but a toggle is really throwing me off
checking if widget is valid?
How do I do that? Do I add branches with boolean variables?
IsValid the pointer you've put it in.
flipflop sounds like what you'd want really . How come it didnt work?
you just gotta gate the tick
for the flipflop
so it only happens once per "press"
@peak solsticeShould look vaguely like this.
how
only "gate" ive seen is a timer, but that isnt really what im getting at
like a Do Once really
right
which is reset on 0 input
I've been making my Melee system on a Actor component. Is there a way to do an Overlap Event/Overlap Check in there?
which then again can toggle a second bool, which acts as your flipflop
so along the lines of this?
sequence and 3 branches and 2 bools..
Oh wow, looks nice, I'll give it a try tonight after work. Will you be up here tonight by any chance?
Hmm, let's say I wish PhysicalMaterials had additional properties (EG "CollisionDamageMultiplier" which tells actors how much it hurts to hit it). How would I go about adding those fields?
Considered:
- Subclassing PhysicalMaterial (doesn't seem to be a legal option when applying the physmat to a Material)
- Having a map somewhere from PhysicalMaterial to an additional SMaterialProperties struct (kinda gross, requires upkeep for each new material, where would I put it?)
I'm pretty sure I had working subclasses of physicalmaterials before? What issues did you have with it
Doesn't even show up as an option in the relevant menu
oh thats good to see, i was actually getting in the right direction of that, i was just about to add a variable after checking some things and go that route
That's because you haven't made an asset with that bp
the not nodes i might not have tried but thankyou so much
You made a class but no asset
Physical materials are like data assets. You create assets that live in the editor like meshes and textures, and choose those, not the base class.
How do I create an asset from it?
Uh. Try misc, data asset? Or you might have to create a regular one and reparent it. I don't remember
No dice...
This is actually something I've tried before, creating in-editor (not in-level) instances of BPs, I struck out trying to figure out how and used a worse system
That's easy if you parent from udataasset