#blueprint
1 messages · Page 137 of 1
but you may want to consider your weapon being an actor, up to you
if you want a weapon to be a bundle of mesh, collider, sound, abilities, particles, make it an actor.
use the same event, can you move at all ? did you try the setting ?
just use the event you had because it works, the x and y axis are correct right ?
when you press the keys you get 1, -1 ?
there is any way to call the player enhanced input from another actor?
You enable input in the actor,.
On that same note, is there an easy way for AI to directly call input events? It'd save a layer of events that way.
Thanks for the replies, Adriel.
adding the maping context or?
I still can't, I think my blue print may be beyond saving, btw the character you used, was it a new player character?
Partially. There are three things required to gain input into an actor.
You need the input mode to be Game or GameAndUI.
You need the enhanced input context mapping applied, this is just a filter basically. The real usecase is meant to allow conditional input frames on top of existing ones.
And you need input enabled on the actor.
For the last one, three classes are exception to this. The PlayerController, The Level Blueprint, and the player's possessed Pawn. All three of which are considered separately when building the input stack along with actors that have had input deliberately enabled via EnableInput.
ya it was fresh character
i didn't used enhanced input, but it should work
it's not moving at all ?
did you try hard coding the values ?
Ty for the reply
@obtuse minnow Since you read C++, this function in particular is useful to look at.
cant really code
thats pretty clear
you may want to watch some basic tutorial on node and how they work, what events fire when, variables, functions stuff like that
its just pushing the input component into the stacks ya?
whenever you activate the input
Correct.
I think I should do a new character, this character is in too much of a mess
It's managed internally to avoid that.
if you start fresh, disable gravity, set the gravity scale to 0.0, then set that setting i showed you, you'll be able to move up/down as well as left/right forward/back after you set the correct movement in the bp
just have to put it in the code, are you using a template ?
i just used a blank character in a blank level to test it, but it shouldn't matter
also, there is any way to get a value from 0 to 1 depending on how much you press the key in the action value. Instead a 0 or a 1
with IA
Wait but I was avoiding to code as I was going to do it all in blue print
well theres no need for c, bp is fine, just choose bp
You said code though
i mean it's code in a sense, but i see what your saying i meant blueprints code
Usually an axis mapping. You use them for things like gamepad trigger keys and such.
Ah ok my apologies, can I see your Bp as a reference?
it's suggested to use enhanced input system like you did i just did what i did for test
also you can use the up vector, and right vector
but here i just hardcoded the movements
and the scale is like it should be 1 or -1
but float mapping shouldnt also give that smooth values?
Axis is the float mapping
oh ok
but then Im doing something weird
because action value never gives me something different from 0 or 1
What key are you testing it with?
Shift
Shift has no middle states. It's pressed or not.
oh
The only thing on a PC with variable axis is usually MouseX and MouseY
For real axis usage, you usually end up on Gamepads with triggers, and analog sticks.
I did as you saw but the character wouldn't move, nor do I know to how to do up and down
Neither
but thats weird because in unity you can get the raw value from 0 to 1 in keycodes
maybe they are simulating that
with a lerp internally or something
you character shows up tho ? or you dropped it in the level ?
They would need to be. Keyboards aren't made with half states. Your keys trigger when you hit the actuation point.
ye they probably do that
thats why I was looking for that in unreal
but I can simulate it with the trigger time I guess
You could probably extend the input component with a new setting for that. Or just turn it into some sort of macro that houses a local float to maintain the lerped state for an interp to
that could be a cool feature
Shows up
I will look into doing that
ya see what a new character does idk why the add movement input just wouldn't work or what kind of settings you would need to change
but a normal character
you just plug that stuff in
like i said tho it looked like most of your stuff was working as far as the enhanced input goes
1, 0, -1 is expected
So im trying to implement a beam weapon in a project and I'm using a line trace that shoots as fast as the engine will allow to see if the beam is hitting anything. The issue is that with fast mouse movements there is still a huge gap between the hits and if there were another player between them they would not be hit. You can see this in the video, with the red line traces. One thing I did to cover a bit more ground is to connect each hit with the preious and trace that as well (pink traces) to see if there was a player along the path that was missed. However that only works if that player was at the same distance from the shooting player as the previous and current hits. If they were closer or further away they would still be missed. Any ideas on how to solve this? I wasnt able to find any tutorials for beam weapons either.
In general your choices are to use a sweeping capsule. As this would sweep along the moved path each frame.
Or you can save the last trace done the previous frame. Then in the next frame, determine your new trace, and then fill in the gaps from the old to new with some simple lerp vector math. Save the results of all of the traces, filter them down into single targets so you don't apply damage twice.
what should i do then?
show what you have ? you still using the same thing ?
i thought thats what you were getting from the axis values
so that part was correct
you just needed to get the input correct
do you have your own animations and skeleton for a fresh character ?
So the lerp you're suggesting would look like the left one correct? If the two red ones are the hits I could lerp between them and shoot the blue traces? For the capsule sweep I dont quite understand how that would solve the issue. From what you described I understand that to perform the blue capsule sweep on the right example, but that would miss all the green space infront of the hits and all the space behind aswell, excluding the capsules thickness.
Although I'm not sure sweeps can rotate?
The capsule sweep is not a really good idea. It would extend from the weapon to a very long length It would work, but you would need to save any swept movement each frame, along with a tick check to see if it's overlapping damageables, filter and apply and then clear the list. Bit messy.
But yeah the first one is what I mean about lerping the traces. You should be able to artificially fill enough space to make up for the gaps at least as far as a normal player would care for distance.
oh yea I see what you mean with the capsule sweep, that would indeed be quite messy but also the most accurate
though Id have to test its performance
It should be as simple as some basic lerping of the start and end direction vectors. Add as many sections as you feel necessary. Also remember to test this with t.maxfps 30 or so for best covered results.
game is already bottlenecked by cpu frame time
yea
Oof
also using general movement component which is heavy on calcs
Pick up some profiles. Best part of gamedev. 😄 Shaving off miliseconds and keeping logic intact.
The editor itself adds like 5-10ms so make sure to test perf using a packaged build. It appears as slate in unreal insights.
Fun note, you can shave off most of the editor time by just minimizing it in the background. The majority of it is slate and extra viewports, which won't run when minimized.
oh good to know cause in that case it wouldnt be a big issue, current frame time hovers around 9-12ms limited by cpu
oooof
(in editor)
lets see the breakdown
profile with launched game, not as good as cooked but closer
you can just right click uproject and hit launch game
Can also do it in Standalone.
I'm a perf nut for my systems, i got my 1D physics down to 0.1 ms/frame with 1,000 devices but haven't been able to test with a big mix of devices yet.
in editor
actually standalone is broken atm cause of some settings, another team member is taking care of that so I have nbo idea how to fix it. But we did do profiler tests and the majority of the frame time was the General Movement Component plugin
how many pawns moving around?
in the test I think it was two
what
O.o
nope i714700k
That's insane. I'd be vaguely curious to see those profiles.
But on that note, a few extra traces won't harm much.
yeah there's no way 2 movement components does that
I'll try to get back to you on that but might take a few days
can GMC have movement physics defined in BP?
not sure, but we turned off physics simulated movement and are using our own movement implementation with GMC
I think it can tho
I mean is the code that's running on tick to move things and trace etc written in BP?
when you say your own movement implementation is that BP?
oh yea we use BP for everything
that theres ya problem most likely
the framework of GMC is probably doing almost nothing but your BP movement is eating you alive
I did wanna look into cpp when the new Mover component comes out in 5.4. Hopefully that should solve it
have some cpp experience but none with game dev
What is the point of GMC anyhow? Seen it a couple of times, never looked at it.
I think it's like CMC but more general and more exposed to BP
it just takes care of replicated movement which can otherwise be a pain in blueprints
dunno, I just use physics for everything lol
./impossibel to do in bp
Cause XB1 and PS4 already can't handle CMC, lets add BP to it? O.o Nope.
I mean it's possible, for varying definitions of "working"
you could be an insane person and replicate the CMC in bp but that'd be silly.
wait I need a skeleton?
I love BP. I do a ton of work in it. But there's some things that just don't belong. Like this wildly looping shit I'm doing for procgen maps. 😄 And Character movement.
also this is all of our (dev teams) first project in game development so we all dont really know what we're doing
xd
its fun tho
I'm also still traumatized by performance issues. We recently spent a year optimizing for consoles.
well you need a character
I did my first draft of overlapping model wavefunction collapse in BP
it was..... uh, slow
now it can do a 100 x 100 in like 5ms, trying to cut that down though
I catch myself doing things in BP I already cleaned up on the other project and cringe... buuuut, it's a prototype, we fix later, right? 😂
This prototype was all BP, I'm still trying to move it all over lol
https://youtu.be/Datugg_ZS3E?si=iKYObYAIbQjuwiZa&t=282
.....what if I told you I was using a cube
Im trying to make a player controller with the enhance input system and this is working but I dont know how to adjust my walk speed
I tried multiplying the scale and the vector but neither changed it
ig that works is that your character for now a shape ?
your movement should still work just fine
Move that code into your character BP
What you have can work but it's awkward
PlayerController =/= The Thing That Makes Your Pawn Do Stuff
maybe actor forward * movementspeed ?
but normally i do that with set max walk speed
so that it still goes smooth from a to b
How are you trying to adjust it?
default settings on CharacterMovementComponent has very high acceleration, so it hits max speed very quickly
What are you after?
Hey yall, how sensible is it of have custom functions in actor components, then use those components as identifiers for different actors (as opposed to having a cast to each time)
ty
yup that's a great way to go
I'd at least have the component do something
if it's just a tag then use a tag
I've recently started using actor components about a month ago and they're a life changer for prototyping
yeah they're great, just about all I do in C++ is subsystems and actorcomponents
subsystems are extremely helpful yea
I've literally never made a C++ actor For Real™️
i use subsystems for networking logic
such as authentication
made one after looking at a few guides on epic games auth
yea, this one was in c++
anyways, ty
I use subsystems for engines or scenes.
ProjectileSubsystem, VisionSubsystem, stuff like that
Im trying to learn how to make a player controller in UE using enhanced input mapping and then continue following an older tutorial, but I see that component on the character now
Input is automagically enabled on your possessed pawn, you can just slap input events on it
look at the template projects
It should?
note the shape won't be your collider
visuals only
CMC wants to use that capsule as the movement collider, full stop.
ya you can just put a shape in there it should still move
something must have been set wrong or something with your character
a fresh one will most likely work if you set it up correctly
would it be a problem I used the character parent class or was that ok?
i mean thats what you want a character, you could use a pawn otherwise
you want to control it so i would use one of the two
but a character works just fine
These?
no just the startup template projects, 3rd person, 1st person, vehicle, etc
how do i resolve this conflict i want to keep my tryroll version and discards main whato i delete and what do i keep
what is tryroll ?
this isn't #blueprint specific maybe a different channel
i was gonna say #engine-source
That’s for modifying the source code
makes sense i wasn't sure if thats what they were doing
question, would this be a problem? I thought this meant this this is the main player controler the character would use, not AI
just hit x on that, set your controller in the world settings
and then the controller possesses the character that you have set
spawns it and posses it
using the controller you set
i'm pretty sure thats if your not possessing it it uses ai, idk much about it
but you don't need it to make your character move
so for some reason my W takes me left and my S right
well for one thing i would just start with one axis
I wanna figure out up and down
because your using right vector
i'm guessing
try the up vector
howd you do that lol
nothing , wouldnt go up
What is Vector Up?
you go up right?
well I can go up and down, but not left and right yet
I can float!
question, how do I set a level main camera?
like without needing it to be in a character
depends
There's all sorts of automagic stuff going on, I'd start by seeing what happens if you have a camera actor in the level and no camera component on your pawn
There might be some in-built stuff for camera selection that'll just grab it
if not, you'll need to set some camera as your view target
well I'm planning to have my camera be not part of the player character its gonna stay still while the player moves all around
for some reason it went full fps when the player had no camera componet
yeah defaults to actor transform
what do you suggest I do?
will the camera always be still ?
yes
so it won't be moving ?
yes
you can set the location of the camera on tick
how so? in the camera actor?
Is there a way to convert the 3d size of an object to its size in the viewport?
hello, I have this actor (rock) in my scene that I want to move around and keep in its altered location after the sequence has elapsed. but it keeps reverting back to its default state (second image).
there may be a better solution but that would work
How should I adjust my "FindNearestRoom" function so all rooms are connected? At the moment I just use the Find Nearest Actor node
You can see the two rooms on the right aren't connected to the main dungeon
would i have to use minimum spanning tree stuff
in your character
oh it worked :D, thank you so much
In short, you take it's world space bounds and project each corner to screen space. Then use those points to get a min/max to make a Box2D out of.
all tho that worked, if you run into any problems or want something more performant you'll have to do some camera manager stuff, idk how to do that i only know how to set it like that
i'm a bit indecisive on this, mostly because it'll determine the flow of the dungeon. i currently have a "Connectors" int on my dungeon room component, should I just keep drawing paths to new-nearest dungeon rooms until the amount of paths equal the connectors?
I don't think that would work mostly because there will still be a very good chance of room clusters being disconnected. How can I ensure that each room has a possible path to one specific room? Maybe A* stuff?
I just need to figure out how to do invisible borders
so your character doesn't go out of the screen ?
will you always be that distance or can you zoom ?
same distance
just put some shapes around it
the character will bump into them
this takes a little bit to get right
you got to really work on setting the camera and everything just right
and if you want to change it your f'd
guess I need to figure out then how to have certain objects pass said shapes
well i would probably go ahead and spawn them in
calculating based on distance of camera
probably some magic numbers will get you a good box
this way you could zoom in and out
to get your view just right
or you could do some maths
and clamp the players location
well I guessI could just have them spawn in, after all its simply just flying objects that hurt upon touching
Actually need to ask, how do I set a default animation to a character?
any suggestions guys, I would really appreciate
i usually make an animation bp that has a state machine for movement
so you can have other animations
but i think you can just set an animation if you just want one
i think you need skeleton for that stuff
Yeah that's what I'm trying to figure out, I'm giving them an idle since the model I'm currently using is also used for a bunch of animation assets I have
is it a skeletal mesh ?
it worked!
but idk how you would go about changin that dynamically
i would suggest an animation bp
you can do some wild stuff with one of those
MST would be good
you can combine delaunay triangulation with an MST graph
How do you find the "set found list"?
you can set that up with delegates
Side note, creating a binding is typically not a great practice. It runs on tick, and if your value doesn't change, the UI still has to redraw
in both cases, delegates are predered
that's why I said side note.
Then delegates (event dispatchers) are the best case. you can use this resource https://www.youtube.com/watch?v=r20VEPH_e0o
*Notice Description Contains Affiliate Link
Event Dispatchers are yet another way to communicate between blueprints, much like interfaces or casting, but with some differences. In this video I cover many topics pertaining to Event Dispatchers, such as what they are, how to use them, and what scenarios they are commonly used in. Event Dispatche...
Working on a Simon Says like game. I want to store the Simon's sequence in an array. I know to clear the array first - but how do add specific numbers to it? For example, if the first index = 3 and the 2nd = 5, how do I store that?
are you looking for something like this?
I have a light that turns on red when when overlaped. I want it to turn blue when overlapped and if a switch has been flipped. How do I do this? Gate?
no it is not guaranteed
really, i haven't encounter it not happening in the same frame. (i might be wrong tho)
Thanks! I'll try this.
yeah, it's' not guaranteed.
good to know, thanks for correcting me
well you could use a bool bSwitchOn to detect when the switch is on or off
Thanks for the reply. Its actually a bit more complicated than this. I send commands through OSC. When I send the value "0" I want the actor begin overlap to trigger the custom event A (red). When I send the value "1" I want the actor begin overlap to trigger the custom event B (redblue). How can I achive this?
not sure i understand your question entirely
but your event dispatcher can take in a variable as an input
can you ELI5 what your end goal is? without explaining what your process is
what if instead of making InteractionRange a float var, you make it a function GetInteractionRange
and in that function you calculate what the interaction range is, and output it as a float
yeah, each actor overrides it
Make the function virtual. i don't know if you explicitely need to make it virtual in BP. one sec
oh nvm i see the actor needs to calculate it, not the component
well, you can do so via a interface
not easily lol
it's the equivilant of dumping and redrawing the entire UI each frame
if you want the equivalent, just calculate it on tick?
unless you can just calculate what the interaction distance is on the AC, then an interface on the actor is probably the best way
which seems more anoying, because in each actor you'd have to implement this function
would it? you can code some generic things
like distance from pawn to actor
actors health
actors mental state and well-being
and have boolean checks to see if it should consider these in the final calculation
like an interface? 😉
i have never use the function pointer in c++, how does it work?
i think im going to look into it. might make my life easier
so the function that is dynamically determied by the class has the return the same type
i am just realising how many situations that would have helped me 🥲
thank you for the explanation
Figured it out
@pastel garnet does this make sense?
well I can tell what your trying to do so I think it makes sense
lol I meant how would you achieve this?
hello, I'm currently trying to replicate the shooting done in the game, I was thinking ray cast but I'm not sure if thats the best way, any suggestion on what I can do? https://youtu.be/cWiT-VuPgMk?si=OWEXlmuNq-r0dEKh
Sin & Punishment: Star Successor gameplay for the Nintendo Wii.
Played on the original console and recorded with Elgato Game Capture HD.
► Wii playlists:
All my Nintendo Wii videos
https://www.youtube.com/playlist?list=PLljauD_hVEDKLPInzEAxvJvyDc4ZUe15y
► Facebook: https://www.facebook.com/10minGameplay
#SinAndPunishmentStarSuccessor #wii #ga...
get hit result under cursor
spawn projectile at the gun towards that location
should I make the gun a seperate actor?
Hello, I tried to replicate the WASD movement from thirdperson template on a new project. I've set up gamemode, created BP_PlayerCharacter and have its enhanced input cast to playercontroller. All done in PlayerCharacter BP. I've checked IMC setup and InputAction as well.
The movement works fine, but the pawn does not seem to rotate when pressing wasd accordingly. anyone know what I am doing wrong?
well, I never had any need to make a weapon an actor
if what I see in the video is all you want I don't see a point in that
I have an inventory system so my weapons are uobject with a soft reference to a mesh
the weapon specific stats are also in there as referenced data assets
without the inventory you can skip straight to just the data asset
can I ask how I can achieve this?
it's straight up a node in UMG
@bitter star keep the code you already have and have a bool that tracks the switch state then perform the RED code or BLUE
actually it might even work outside and just use the player controller
not sure atm
yea, pretty sure that's the case
not on unreal right now
ideally yes as it make it easy to make other gun types
umg?
unreal's ui designer
wait its not a blueprint node?
it is
I was wondering if it was an UMG specifc function for a moment but then remembered it's part of the controller
so you can use it there or in your character
in what way would it offer an advantage
yea it's a linetrace but it traces from the camera to whatever is under the cursor
you'll probably want to just do it by channel though
why's that?
well, I assume you want to just shoot at anything that blocks the visibility channel
Hello friends! Is there any way to limit the gameplay tag choices in editor ui for params when writing a blueprint, as we have with UPARAM(meta=(Categories="abc")) in c++ ?
not just at specific object types
yes, while holding projectiles will shoot forward
How do I set a text render to display the entires in an array (integer array, so I want to display a string of numbers). I did a for each loop, looping through the array and printing each array element - but the text didn't change.
you are setting the text to every entry sequentially until the last one in one frame
can I ask how I would use the other inputs and outputs?
you will need to append or add text widgets (one per entry) to a vertical box or something
break hit result for the data inside
it'll give you a location
it's a struct
What would I do here? I'm looping through and saving each element as text in a new array. I want to then display (set Text) all of the text, in order from the Text Array.
having a separate actor (base class) allow you to define common functionality all guns will have like firing, reloading etc. and you can define animation montages to play when firing and reloading or basic locomotion animation blueprint that gets swapped out when that weapon it active (being held). there are other cases where you would like a separate actor it depends on the project which is why i said "ideally" you would want that.
try this out
I feel like logic related to weapons should not actually be in the weapon itself, particularly reloading and firing are character functionality, though I can think of more extreme cases where it would make sense.
thankfully there's no amo
As for data having it in an actor is unnecessary and less convenient to work with
well the character will be the one calling said functions in the weapon like firing, but i get the reloading part. still it all depends on your game
Yea, and I gotta say the actor setup is the most common I've seen
I can't enter the string array into the text render. The text render only accepts text not strings. :/
convert from string to text
No luck. The text just disappears.
I'm really just checking stuff - I can do break points.
is there any item in the array?
...that's the thing. It doesn't appear there is. Ugh.
I'm trying to add a specific number to a specific index point.
But that isn't working I guess
is notes played -1 a valid index. I would suggest adding print statements everywhere until you spot a problem
more importantly you cannot set an array element that doesn't exist
Notes played starts at 1
you will need to add what you want to the array in order
or populate the arrray with placeholders and replace
Gonna try that. I think I was getting confused because I was storing integers in the array and was worried it would return the index not the element
though I do need to make an actor for the bullets at the very least
hit scan weapons you don't need that but projectiles yes you do
yep, you could just have particle effects for visuals only
for this type of game probably the right choice
but I need to aply damage
you are already hit testing for the location to shoot at
you are getting an actor and component reference right there
@undone bluff and @pastel garnet you two rule. Thanks. That did it - just using Add instead of Set Array Elem worked.
wait really? but I want to apply damage only if the bullets are hitting and the bullets still come out even if an object isnt being hit
if the player places their cursor over an enemy and clicks, do you want that to be a guaranteed hit?
or should they be able to miss if the enemy moves away
can miss
yea, you will need the projectiles then
should I keep what I'm doing? will the channel thing still work?
yea the point of that is to determine where to shoot
what about my projectile BP?
that'll be actually dealing the damage then
so all the bullet will have the apply damage, spawn sound and fx
yea, though muzzle vfx and sfx don't need to be in the projectile
what can I do though for getting the bullets from point a to b?
well moving something is kinda gamedev basics and extremely widely covered
but unreal has a projectile movement component you can use if you want
oh right this
yea, every frame linetrace towards the target location by the distance you want to move per second in cm multiplied by deltatime, if nothing is hit move there
that's all there is to it
I'm off now, good luck
is this where i can ask for help if im stuck on something?
Is there a way in UMG to create an animation object to give to any selected component?
For instance, I am making things pulse using a simple scale x,y from 1 to 0.9 and back to 1 over 1s.
Rather than create a million animations for each components, can this be streamlined?
depends on the type of help you need
im having an issue with a damage system I just implemented. I have health setup and its working and I have it where both the player and enemy will take damage but no matter what value I put for my damage it just dies in one hit. If someone could help me that would be amazing
Why my characters spawn properly but i can't control it and my camera is on the floor ?
You need to show your code aka the default value of your health, how much damage you deal to your player and where the "death" logic is and how you coded it
I'm struggling with a starting point for this so hopefully someone here could give me an idea.
How would I do an ledge hang check the best way? Since I need the player to only grab edges of platforms and not in the middle I assume I might need to or even three checks?
E. G.
- So there is nothing above the ledge
- Another one checking where the ledge is
- a third that the player aren't on ground
I'm not sure if this is the best solution?
Crossposting is against the #rules, avoid that please.
Sorry, But i have this issue for 2 weeks now and nobody can't help me 🥲
Its been new things all the time.
Every step you take is a new thing
Still no reason to crosspost
Is there any way to access the skyatmosphere settings inside blueprints? For PostProcess you can make settings, but the SkyAtmosphere is not allowing that?
Im very confused how to change the properties at runtime._.
I might be slightly dumb but you can just easily set each individual value.
Not so dumb afterall ™️ 😄
Not sure about this maybe someone can answer me xD I,ve been doing UE for a little while now and I cant see why this isnt working lol its so simple i think
So on BeginPlay i run Custom Event to set IsAttacking to true simple right.
Sounds ok so far
But it isnt True?
can you highlight the one in the outliner on the top right?
I have highlighted the Variable in the Editor when playing
am I doing something wrong here?
I can't get the event dispatcher to fire from the anim notifies
neither Event nor Binded return any tick
Nevermind worked it out for some reason when I "lock" the editor to show a specific details tab it doesnt seem to update when theres any changes after i unlocked it and reclicked on the actor it showed updated values, I thought it updated in real time. So seems you cannot see a variable value change if you lock the details tab on an actor, seems weird.
Guys what's the node to get the active camera please ?
Need some help from you guys. Trying to create a tcg like mtg arena. Is there a way to create an array of data table's rows?
There is a node called Get Player Camera Manager, which returns a Camera Manager reference. This allows you to get and set certain values of the Active Camera tied to the Player Index, regardless of whether or not the Active Camera is part of the player referenced. (Took from internet)
hey
i want to make a clip on a white background appear images one by one with alpha effects ,can i make it in unreal or do i need an editing software?
Already check that but there's no "Get Active Camera" or something along those lines
What are you trying to do?
Just to print the name of the active camera because I have an issue for 2 weeks now that I can't solve (check #multiplayer convo if you want) 🙂
Datatables are pretty much a static map with a name for the key and a struct for the value.
As an FYI, there's a tick delay before a possession is finalized. If a player joins the game and creates its own character and the same tick you destroy what they currently possess and have it attempt to posses another character, it'll fail. If you character already has a pawn and you destroy it, you'll need to wait a tick before you can have it possess a new pawn. 🙂
Edit: I assume this is the issue you're trying to resolve.
How to solve that issue / wait for 1 frame ?
Let me find the beginning of the convo so you can see the whole issue I have for 2 weeks now
pretty much yea. It's only really an issue if the controller has already attempted to possess a pawn in the same tick which can happen when they first join a game and a character is automatically spawned.
#multiplayer message Here it is 🙂
Longest convo of the year
Yea what I've described is most likely the issue. If you have to destroy an already possessed pawn, you can call a timer by event for next tick and have it call a function that creates the new character and possess it the following tick.
So i do that in my "Spawn Player" function ?
The only reason I know is because I was working on something a few months ago where as as soon as the player character was spawned, I unpossessed the default pawn, created an AI controller, made it possess the now unpossessed pawn and had the player controller possess a generic pawn. It ended up where both the player controller and AI controller thought they possess the same pawn. (which of course isn't possible lol)
Most likely yea.
Lol thats pretty weird . Well good note to make i guess
Not sure if this will help but this is what I did when I experienced something similiar. Not multiplayer though and this was just in the character BP.
Yea it is. Took me a good day to figure out, it was driving me insane lol.
Glad we have simple pawns and pawn setup 😆
I'm not sure to follow how to do that on my side as my spawn logic is in a function 🤔
and you're using "Delay Until Next tick" which isn't available in functions
Move it out
you can use a 'Timer by Event for Next Tick'.
The hardest bit you would have to deal with is getting the character ref as you won't be able to return it on the initial function you have.
Edit: having said that, i don't think you actually use the return value anyway.
but I can't link an event to it as I can't create events inside a function, so that's what i have currently
Like so ?
Something like should work.
i already converted the function to an event, is that good ? 😄
This would probally end up failing if you have multiple player controllers that need a new pawn.
Slight revision. Needed to handle the is not valid pin lol
So esensially, it'll handle destroying/unpossessing old pawns first, and then the following tick, create and possess new pawns.
What's the purpose of your "Pawn Required" array ?
Its in the name
It's an array of the player controllers that need a new pawn.
Pcs without pawns
is the set timer by next tick a 'called once' thing ?
so its automatically unbound after the call ?
I guess it is
Yea, just called once.
Checking if the timer is valid probably isn't needed though with it being called the next tick.
@main lake The suspense of waiting to see if it works is killing me. 😛
Now everything is broken in everly level 🤣
What happens?
Maybe a stupid question, but how do I make a this arrow mesh not rotate along with the character?
Right now it follows the movement of the character, but I want to control the rotation independently.
I can't seem to just drag it above the capsule.
You could change the rotation from local to world on the arrow.
No character is spawned nor controlled 😄
Does the create pawn function get called?
Where would I do this? Don't see an option for it under details.
Turns out you can't. o.O Odd you can't set it's transform like other components.
what component can you do it with? Could just make it a child of such a component if that is a thing.
You can add your own arrow component.
Don't see an option for local/world rotation even for that component.
Ah, that is how you got it. That can be done directly for the mesh.
Testing..
the function "SpawnPlayer" is being called and the print "SpawnPlayer" is being printed but not the last print "End SpawnPlayer".
And I guess it's because of the IsValidtimer Handle being false as the first time it's null
oh my bad
that's my mistake because your example was using the "false" output
I was just about to say that. 😛 But yea, if it's on true it would never start the timer.
Ok for the Host, it calls both "SpawnPlayer" and "Create Character" however i can't control him
On the client however I'm still in the ground and no character is being spawned
How do you add inputs to the player? on begin play in the character? If so, it probally needs to be moved to 'OnPossessed'. (with a check that it's been possed by a player controller)
Yes in the beginplay, that was like that when I created the project, i didn't touch it
Yea so when the character has spawned, it won't have a controller until its possessed so it would fail. Move it to the on possessed, that should solve the no control issue.
As for this, I can only assume, it attempts to possess the character on the client before it's actually been created.
Now on the server I can control the character and move around without any issue (but my health red hearts aren't there anymore), and on the client I still am in the floor
Assuming the data for the hearts is stored on the player controller, its probably being initialized but its been possessed again.
As for the client, I'm not sure other than having the client spawn the character and then possessing it but I'm not sure if thats best practice. It'll probally be best to ask in #multiplayer for that one.
Nope the data for the hearts is stored in my BP_ThirdPersonCharacter
Show how you handle it.
On the 'OnRepHealth' you check if PC Core is valid. How do you set this in the character?
Hello, is there an easy way of printing out any struct as a string? I remember seeing a plugin that converts any USTRUCT in JSON format, but I can't recall the name
nvm it's a default UE JSON plugin
The PC_Core has the BP_HUD which is the HUD containing the widget called BP_GameHUD which contains the healthbar that i call the dispatcher for so the Widget can receive that dispatcher
That doesn't answer the question. How in the character do you set a ref to the PC Core?
yes
You need to move it to onpossed.
Yea, anythng that gets the controller should be moved to the onpossessed.
To be honest you should probably move a lot of that logic to a “run on owning client”
That’s possibly why your server is working but your client isn’t
Get player controller for example will act differently if you call it server side as opposed to client side
I'm kinda confused I'm not gonna lie 😄 Because putting it in "Event On Possess" which is already in PC_Core, it doesn't make sense to save that in a variable in the PC_Core itself 😄
how ?
Sorry, to clarify, anything that gets the controller on begin play should be moved to the on possessed.
but OnPossessed is only inside PlayerControllers 😄
OnPosses runs on server side too
there's no Event on Possess in ThirdPersonCharacter
well you generally want to bind input in controller anyway
And TBH anything you expect should be running locally (like binding inputs) after that event that was just posted if follow it up with a run on owning client
that runs on server only. For the binding to work, it must be run in the targeted machine
Cause that will only fire server side
So you wanna then fire anything client on its owning client
That was a local function variable that was a copy of the struct.
And that might be where begin play is tripping you up. Begin play fires server side and client side and it doesn’t look like your making a distinction when your trying to bind input
So like this ?
what the heck is that
Your gonna wanna pull off from the new controller, you already have it don’t need to get it again
Event possessed tells you the player controller that possessed it
I understoood nothing 😄
Yea but as Cold said, it only runs on the server so you'd have to call on owning client. So when that calls you know the server has possessed the pawn and can then call a function on the owning client to add the UI.
There ya go almost
I used OnAcknowledgePossesion from controller which is an event that run on client side. On top of that, the pawn is guaranteed to be ready
so that's where I do the binding
Make a function now that “runs on owning client”
And then setup your input, hud ext
Don't see why you need to cache or cast
I'm soo tired after 13 hours of work but maybe you can try this if you don't want to use OnAcknowledgePossession
On Possesed -> Run on owning client -> Bind there
shouldn't even need to touch the controller
Do we have access to that in BP?
nope
That explains why I couldn't fine it lol
Yea, it sounds like it would be useful.
its called RecieveControllerChanged 😅
😅 good to know
Probably wasn't. The game instance delegate was there, but it was still C++ only.
Hello Guys, firstly sorry for my bad English.
I want to make a Chaos based choppable tree system. I don't think I can achieve this using Foliage. If I create a tree in the form of BP_Tree instead of Foliage Tool and use them in my open world game, I may experience a significant performance loss. What is the best solution for this?
It's really hard to do in BP only. I did this by subclassing the foliage HISM component in C++ and made a system that spawns a BP to replace HISM instances when they're interacted with.
When you go to chop a tree instance, you replace it with a BP version.
I wouldn't say it's hard, just a lot of moving parts so it's easy to forget something lol.
Not sure, I had a reason for needing it in C++. I wanted to use the normal foliage painter to place it in the level.
I did it through an actor component. Paint as normal but on begin play (or even in the editor) add the special component to the actor it creates (with all the ISM components in it) Just a case of having a list of what BP an instance needs to be replaced with when looking at/interacting with.
Cant you simply replace the hism instance with an Actual™️ actor?
I never finished the system I was working on but this was the main part. The top branch is for instances that should be swapped out for a BP. The bottom one if for a generic item pickup. I have maps that use static meshes as the key (not totally happy with this) and the actor it should be replaced with. For the pickup, instead of an actor, it uses the item object that should be added to the interactors inventory.
Id prob have that class loaded to avoid async waits but yeah
Probably an already spawned actor tbh
I used soft references so it wouldn't load 100+ classes even if there not actually in the level.
100+ ouf
scalability was in mind haha
1 base tree -> swap mesh -> win
The system I set up was for any instance mesh so it could be a stick, door, tree etc...
Im just animating the ism instance 😆
Very simplistic luckily
Atleast for now
Prob gonna do VAT om them later
It was pretty cool as NPC could intract with instances as well using the same system and pickup random items off the floor lol.
Whevener inget back to that parked project 😦
Yeah thats how ive made mine aswell
everything is an ism really
Except buildings
Why not?
So NPC is ISM, which picks up item which is ISM etc etc
Didnt imagine enough of them to care about the overhead i guess
Just made me think of NPC's carrying NPC's carrying NPC's. 🙃
Tried to keep things data driven aswell
So all new buildings/upgrades/new productions etc is just DT rows
I need to start doing that more often. I tend to use use Maps where something like a data asset would probally be better.
Use maps of data assets.
DTs of maps of DA
Yeeeeah
Just for the extra indirection /j
I should get into DA's more tho on a serious note
I end up with DTs always and its .. well.. it is what it is i guess
I love DAs.
We started to make everything that is a "thing" into a definition. Which is essentially a DA with a layer or three of inheritance. EG all things inherit from a core DA that has the basics like the name, icons, etc. Then more specific DA child classes for more specific things.
Lyra inspired huh
Currently my DTs point to a Class which is 3 layers of inheritance, covering all scenarios up untill now
Kinda. More datatable inspired. As in inspired not to have datatables, pointing to datatables, pointing to more datatables.
I never touched DA but seems like I can't avoid it anymore. How would you describe DA? Is it like a struct with static data?
Untillllll now, were i need a meta item that can be added to other items
DA is more like a static mesh. It's a static asset with static data.
Spawning it to trigger their "use" feels weird and clunky.
So like struct that can't be instanced and hold static data?
Kinda I guess. Never associated them with a struct in that way, but same manner.
Much better than a struct in the sense that you pass them around as pointers too, so you're not copying data everywhere.
Can have pointers to DT Rows afaik
Kinda. You can in C++.
Some ppl say there are bug associated with DT
You can have a struct that has the datatable and rowname. Kinda the same thing.
And for bp you'd just make a small getter
Borderline combative to use DT
What's the bug?
Have never encountered any using DTs. I just find them very rigid and frustrating sometimes.
No idea, never come across it but Laura mentioned it multiple times
Hello everyone im fairly new to unreal and am struggling with a big issue in relation to level streaming, i have a hub with level sequencing to move the camera towards specific places in the hub for settings menu, level select etc. When i load the first level from the hub it changes the camera view of the firstperson character controller to lower than what it is supposed to be(I believe this could be an issue with the camera manager). I believe this issue is coming from the angle and position of the level sequence before switching levels being at a different angle/height.
In the picture the left is the view in game and the right is the actual view we are wanting.
Ignore the high video memory my laptop isnt plugged in right now
Probably BP struct related
This probably caused by different resolutions for the windows.
Nah the camera itself is at the top of the first person controller however the camera in the scene is lower than it i will send a photo of that when im able to
is there a way to make the default capsule component of the character to be horizontal and not vertical?
Hi guys I have this problem, this code are connected to Event Tick when I die, I want that my character camera follows a spline line to see my body dead from above, the movement works good but the camera never rotate, even if I connect the Along spline rotation or set it manually with set world rotation never rotate. The math logic of the rotation I have here is only a rule of three to gradually rotate it down until it reach the end of the spline but does not influence
Is the camera set to use control rotation?
how i know it?
It's in the settings on the camera. I think it might be use controller yaw and use controller pitch.
Yeah it was that. I checked all the camera settings but didn't see that, thanks ❤️
If you want to keep it enabled, you can instead set the control rotation on the controller to update the camera.
Nice to know, but I don't need it, this only activates when character dies so the game ends
Hard to say initially. I'd assume it's a non trivial issue due to the fact that the capsule is the root. So rotating the capsule would rotate the entire actor, which would likely require some substantial edits in the CMC to account for the difference.
4.X had BlueprintType but not 5.X, should I just inherit from Object?
Need context. What doesn't have BlueprintType in 5.X?
class BlueprintType does not exist in 5.X documentation
it is for struct exposed to BP
It still exists
why wouldnt it exist in 5.X anymore
I cannot find documentation of it nor can I find it on the menu to choose class to inherit for a new c++ class.
well usually you put that in the USTRUCT Macro
besides, thats more like a #cpp issue
well I just need a way to use struct in Blueprint
You mark the USTRUCT with the specifier.
ah.
I am sending some data from external process via UDP and need to receive it on Unreal side
the specific configuration of bytestream is not set at this point and I want to set everything else then define deserialization method on the struct
dumb question- how does one add a post process blueprint for an animbp? I see that the default mannequin has one but I don't see any place to hook it up. in the character blueprint itself I see a checkbox to disable it but that's it... google is getting me nothing but post process volumes..
the 'post process' is just a linked animbp
I think
I haven't actually looked at the new third person template haha
you can specify a post process animbp in the skeletal mesh so maybe they did that
so both ways work
So I've got a blueprint that takes its world position, and uses that to mask out the "snow" in this material I have here in the screenshot. However, if I have two of said blueprints, it can only pick up one position at a time, as you see in the image. Is there anything I can do to have that mask/world position be added together?
the actual skeletal mesh asset, not the skeletal mesh component, to be clear
ok yeah, nice! this is exactly what i was looking for
I'm working on my character's jump charge. I want it so that when my character is falling before the jump is performed, the charge will be cancelled. My jump charge doesn't seem to be resetting itself?
well you set it to 0.0, then set it again after the branch
so that branch is pretty useless as is
IA triggered executes every tick
I only really know the bare minimum of Programming, a lot this was guess work
okay so scrap the tick here
on triggered do your charge increment
(after a branch that checks if the character is falling)
and multiply the amount you add to the charge by delta time but I assume you are already doing that
on the false of the branch you can then reset the charge to 0
elapsed seconds will give you how long the key has been held down, but if you want to cancel the charge if the player leaves the ground at any point then this is the way to go
Ok Thanks I'll give that a go
ah, actually the other way around
is falling true > cancel charge, false > keep charging
If I create a BP that loads certain stuff to a data table - will I be able to preview it (the data loaded into the table) in real time when I start simulation?
or you can use a 'not boolean' node
you mean load a datatable from like a csv?, you can't 'load stuff into it'
i can't load a list of actors from a scene?
no you cannot store instance references in a table
they are static
you can store asset references and positions (not at runtime)
:/
I am not sure if you can write to it with some editor utility
but I've seen it done with external software
it kinda ruins my plans
like a blender scene written to a csv and then imported as a datatable in unreal
and then that data was used to place assets
tldr version, open world game, level has "delivery spots" that are placed in the level as actors, I wanted to load the entire list of "delivery spot" actors to a list and randomise one when the delivery is picked up
arrays won't cut it
that doesn't actually sound problematic
I mean - I want to load the list from the level when the game loads
I don't want to have it in the database as in I don't want to add those manually
I don't understand
what's wrong with making a table of potential delivery spot actors and picking a random one to spawn?
runtime?
Pretty sure yeah
Glorified TMap
Not sure why one would want it at runtime tho
Editortime i can understand
im confused why an array isn't suitable for a list of delivery spots, given that a TArray is a list
This is even one of those times where get all actors of class would probably be good to use 😛
TActorRange 😉
Have a delivery spot manager actor component on the game state then have your delivery spots register themselves in the manager. (Possibly a set to prevent duplicates) When ever you need to get one you can get the manager and get one.
Never! Lol
Hi, when I jump and switch characters in my game (possess other pawn), the last character is still in the air, how do I "force physics simulation" on the last character so that he can fall to the ground even if I don't possess him anymore ?
manager as in what exactly? a data structure of some sort or a bp?
Actor component.
and how it would be stored?
each delivery point actor has a name and xyz coords
my approach might be flawed. im improvising a lot.
i found a solution
I would use a map and use the name of the delivery point as the key and the value being the delivery point actor itself. You can always get its world location from it when you need it.
thanks, i cant check that now as im outside but will have a look shirtly
Map requires unique key:-/
It does but it sounds like he's given them each names. If there are going to be duplicate names, I would just have each of them have a GUID which is used as the key. It sounds like there's just wanting to get them at random so would probally only need the values.
basically its a dropoff point for a parcel delicery. there wont be any gps system so the buildings will have their unique addresses
i mean im happy with any solution that just works
Gotcha, ok thats fine then
If you're going to be giving them unique names anyway, i would just use name as the key then. Gameplay tags might not be a bad option though depending how many you'll have.
PostManager ->RegisterAddress (FName(or Gameplaytag), ActorRef)
Beat me to it with the gameplay tags lol.
Gameplaytags will be easy to sort
ill read about it as soon as i get home
Region.City.Street.Number
Then you can ask for everyone in Region or Region.City
Etc
Using GameplayTag Queries and whatnot
You wont regret it
Cause it’s set to BlockAll
Not overlap
but then the character will fall through landscape
See what I want to make. When the boat comes on landscape instead of water I want to disable input for boat
Don’t use the landscape for that
otherwise boat will also be controlable on landscape
Put a collision volume on the landscape
so what should i use?
But collision would be box or sphere whereas My landscape is curvey
Doesn’t matter, just scale the box up
At some point the floor is too close to the surface for your boat to work anyway
Alternatively, line trace for hits instead of overlap
yeah That I know For that I would also need the box around the corners as I didn't wanna generate line trace for every frame
Line traces are not expensive
Really?
You could also make a box overlap, that when the boat gets in, it starts line tracing for precision
I am making for mobile will it impact too much?
yeah that i want to say above
Doubt it. The expensive part is drawing the debug on screen, but that doesn’t make it into the game
Okay I will try Linetracing then
any point of advice to tell if the player is pressing the opposite move directions or if it let go of the movement buttons?
Does anyone know what the Field Notify tick box on a variable is? Something to do with broadcasting it's changed. Can't really find any info on how to use it though.
is that on any var?
as In tag for each of those?
I'm going to have ~50-100 points
It looks like it.
then the hieriarchy is probably not that deep^^
I'm in 5.3, i think it was added in 5.2.
floats don't have it on my end
but yes, a tag for each
I'm in 5.4 so I win
identification must be done anyways, so wether you type FNames once, or add Gameplaytags once, it'd be the same job
I don't have it anywhere, what var is yours?
Oh it's just inside widgets. o.O
but that's going to be manual labor for each of those, right
Yea, is the name actually important?
@dark drum
well.. kind of. the player will have to navigate by the name, there will be no markers on the map/gps
FName or GameplayTag is manual labour
GameplayTag is then selectable from a list
FName is not
You can also import a list if you want
avoids typos and human errors
Yea i've already found that, doesn't really tell me much about how to use it. However I found a topic on UMG View Model that mentions it but from reading through that I have a feeling it's not fully exposed to BP.
see if this is worth a damn https://youtu.be/wBWVbdVAR64?si=zCuNB57nQJH5gBO7
Hi guys, in this video we will be looking at how to use Field Notify in Unreal Engine 5.
======== Donations ========
https://www.patreon.com/GamiumGamers
======== For Questions ========
https://discord.gg/FBz3amt
======== Instagram ========
https://instagram.com/gamiumgamers
======== Personal Instagram ========
https://instagram.com/srvmsd
I always forget about this but yea. It's a config file so can be edited externally to make all the names.
guess that's it x)
Yea, it's the add field value change delegate.
wait just to be sure (sorry, it's confusing, I'm pretty new). I will be able to place an actor in my level, give it appropriate tags and that's it?
Yea, assuming you've set it to register with the manager i mentioned.
Why this is not showing landscape but showing the water plane I am showing (when I am on landscape)
Something like this but more specific of a use case and instead of using a name, you use a gameplay tag.
Welcome to this tutorial on how to create an actor manager system in Unreal Engine 5! In this video, we'll go over the basics of setting up the system using Unreal Engine's powerful Blueprint visual scripting language.
Whether you're a beginner to Unreal Engine or an experienced developer looking to better manage actors at runtime, this tutoria...
awesome, thank you
because the water is being hit first. You can make a custom collision channel where only the landscape is colliding
I am checking every tick so why it is hiting water plane even when on landscape
draw debug, you're likely still hitting the water volume
there is no volume. I am just using a plane with water material
or plane
You should too, you know 😄
draw debug, screenshot, show
Haha, I didn't fancy having to explain how to use gameplay tags. 😛 To be fair, I've used many things for keys in my manager components lol. GUID, Names, Gameplay Tags, even used Int Points, all depends what needs managing. 🙃
Yeah I found One thing when I start from landscape it always show landscape string even when I go anywhere and same when start from water it always show water plane
okay wait let me show you
then you might not be tracing every tick, show the rest of the code
INT POINT!? did you push your tiles to a actor manager 😱
I only saw your trace on landscape, willing to bet you're never changing the start/end locations
It was technically an inventory system so the item position in a grid lol.
🤔 and if you start on water it does water the entire time?
Yeah
run the game in simulate and see if you can actually see where the line trace draw debug is
Wait I am showing you a new thing 😂
Boat is there but the trace is at player start. I didn't know what i did just now
earlier it was okay
I think the trace is not attached to the boat
prly cause of the get player pawn
put this on the boat
the code
and just use self for actor location
hi guys its been weeks and i still cant figure out how to create blueprint for spawning coin waves like subway could anyone help i just want to know how to implemet number of waves space between coins space between waves and random integer between min and max coins per wave
i even quit unreal because of this
YouTube spawn actors in a grid. That'll get you started.
i followed every single youtube video there proplem is they spawn in tiles and i spawn them in open enviroment
i really hoped that i could do it like them
Well it's a starting point. One piece to the puzzle. So what do you mean by spawn in open enviroment?
like this
So all im seeing is a grid, 3 by X. (Assuming you want them on the tracks)
yea its 3 axis on left and right and forward for y
you could just create a spawning function that creates them in a location in a uniform way, then just pass the location to the function it would build out , by wave do you just mean a few in a row ?
yea but random int for each wave
wdym random int ? for what ?
i want to spawn them in waves
you can do a for loop and just inc a vector a certain amount for each one
Finally I am feeling like a developer😎
yea how do i do this
it's basically just a loop with a step, you have a starting vector, loop x amount of times, and foreach one add to the x or y (whichever your using) keeping a running total as a vector
and just use a variable as a spacer
ok you mean for each loop right
no probaby just a normal for loop
you just want them in a straight line ?
what about curves and stuff ?
ok and yes
that will be more difficult maths for curves
na this is advanced
it's not to bad you just x, y a certain amount you can simulate a curve
but i would start with just spawning them in a row
This gets you this.
thank you so much
Just to clarify, there's probally hundreds of tutorials that show you how to do this. 😉
btw what is size x and size y
Int Point that's been split. Spacing is a 2d Vector split.
what I can do so that if the hitting actor is landscape then do this or that
Branch?
prly better to use a cast
if hitting actor is landscape then true?
I'd do hit actor -> cast to Landscape -> do stuff
on Cast Failed you can cast to your Water bp
if you end up nesting too many casts in a row tho, you may need to switch to an interface or a dispatcher
Yeah it worked
No i just wanna cast once
now this is what i call real tutorial trust me all the previous tutorials cant do it like this❤️
is there safe mode or something? UE crashes because exception in construction script
You can maybe modify an ini file to load a map that doesn't have that actor on it
Well if you liked the screenshot, I have some actual tutorials on my YT channel. 😉 The camera system might be up your street with the sort of game you're making.
Is it normal that in editor when you stop testing your game the destroy event of characters is not fired?
This seems a bit weird to me, as all other destroy events seem to be fired
What am I missing here?
can you give me your channel link
Click on my face. 🙃
That’s weird 🙃
Damn, that's one nice bridge alright. Good fit, apparently!
I'm not ashamed to say that went over my head. 😅
2 years ago, on your sandbox channel x)
Oh that channel lol. I decide to dedicate my time to something more important lol. (UE)
Noted! ;P
is there something like try/catch or something in BPs? i want to prevent crashing during compile of construction script
I don't believe so.
this should have a simple solution, but im just too dumb and inexperienced. this is a movement system and i can only get it to work when oriented in one of the axis.
Win+shift+S to take snapshots
Why are you using Get instead of just plugging in the action value
why are you breaking out those get forward and get right vectors
input to add movement input should be axis value x vector
You need to connect all 3 of the values from the direction vectors (recombine them into a vector). When you split it, you're only getting the affect in a single direction.
For example, forward could be 0.5 on the x and 0.5 on the y.
oh, let me try that way. altough according to someone in yt comments, this is how its supposed to be done because its relative to my camera/vr headset. altough i dont see why it would differ from traditional camera
I'm not sure what they're talking about. o.O
still not fully working, but atleast its now usable as i can walk forward and backwards into any direction, just cant strafe. would you have any idea how to fix that? tho that can be a problem for the future as strafing isnt a big concern for me this early on.
The right vector is the one that would do strafing. Show your updated setup.
tried like this and also connecing the forward vector to both of them (and unlinking the right vector) neither worked
Does anything happen?
nothing aside from what i mentioned previously. now it works going forward or backwards, but strafing doesnt work
Check you've setup your input context mapping correctly. You might not have set it up for the right key.
already checked. other one is in oculus touch (L) thumbstick X-axis, other one is oculus touch (L) thumbstick Y-axis
both of them are axis1D float. and those should be all the relevant settings
You probably need to use this one and only have one input that handles both forward and right movements. (The IA would need to be set to 2d)
guys ezy thing but why it do not work...
I want that when my enemy has 0 live and still collides with me he dont give me dmg
I am using this in order to move the rotation of an static mesh (which is a door), but it doesn`t rotate, but I can go through the door, does anyone know what is happening exactly?
Debug it. Make sure the boolean is being set with a breakpoint. After that breaks Breakpoint on the apply damage and make sure it's false on the same instance.
you're getting forward for both
get right for the strafe one
like this? cause now it only goes forward no matter what direction i point the stick
Read this code
you're saying "Move in Camera.Forward based on MoveY, also move in Camera.Forward based on MoveX"
when you should move Camera.Right based on MoveX
Replace the direction vectors of the controller for your cameras direction vectors.
Yes this is a better way to do it since it won't try to move up when looking up
Third Person Template. 😅
thank you guys!
wait where did you get the input x and y. with the 2d thumbstick axis it wont give me those.
Right click on the axis value and split, assuming you've set the input action to be 2d.
aparently if i switch my view to player colision, I could see the doors being rotated as they should, and if i switch back to lit, i see like on player colision, on the perfect rotation, why is this happening and how could i fix this?
i must be getting too tired. i just tried splitting it 10 times and didnt give me the option. i probably was not hitting the pin when clicking. my bad
You need to mark the render state as dirty for the last instance you update in the given tick.
thank you so so much, its now working flawlessly
and how exactly do i do that?
i will find it out
On the update instance node, there's a tick box called mark render state dirty, tick it on the last instance you update. This will trigger it to update the visuals based on the new transform data you've set.
Can someone do this and send screenshots, pls idk how to do it. Create interface>on begin play call that interface>the receiver prints string. My main problem is getting a valid reference
Whats the use case? Why an interface?
Like this M
With this setup I can move around with the host but the hearts don't display properly, and for the client still same issue he doesn't spawn and his camera is in the floor ☝️
but does that array index help ?
because basically when I am generating the room, I am adding the return value into an array, and I thought it would reference only that specific door, what do you think?
There's no point storing the instance indexes as you can just get the index count from the instance mesh component.
On each level loaded, it has specific information
Wanted to use casts, but the the reference is the problem
