#blueprint
402296 messages ยท Page 579 of 403
And most of the code for the player is in their player controller, I think that may be the issue?
@spring hare it just falls through the floor. I should probably add: I spawn this on the server and replicate
maybe that has something to do with it
@olive sedge Can you show the component tab?
Are you using health to determine if it dies or not? @neon sorrel
Yep, and then just fire a event which goes to the gamemode to respawn them
@spring hare
After the health check do IsValid then Destroy actor
@olive sedge This is my set up and it works if you want to try it
@olive sedge And my projectile settings
Change the initial Speed and Max speed
@spring hare you don't have a collision component at all?
I was wondering on how would I add footsteps to my character
the thing is, I don't have any animation attached to it
it's pretty much invisible
No because i dont need it but change the ParticleSystem if you want a collision component @olive sedge
hm
I do need hit registration. can I even do that without collision comp?
and does that not fall through the floor for you?
If you want the dart to hit something then spawn a thing depending where it hits then you need collision
Im confused by what you mean, I do have a is valid before I destroy the actor in the gamemode there
In that screenshot
@olive sedge No because the mesh has collision enabled
@neon sorrel is that what is Destroying the player?
Thats weird then @neon sorrel
Yeah im genuinly confused
The variable thats being a pain is the actor referance in my player controller
I set it with a cast on begin play in the player controller, and it seems to cast fine. But then once the player dies it cant get the new player it seems.
And always errors
@neon sorrel So your not respawning?
Nope
Sorry I wasnt sure if I clarified this
It does respawn it
The problem it the variable for the actor ref is not being referanced After a respawn
Yeah ill have to hope someone here knows more about player controllers or something
All good thank you for the help
@spring hare could you show the collision / physics options for the mesh?
Can you show me yours? @olive sedge
Have you compiled it?
yes
Update if this helps. So after debugging. Whenever the player gets respawned. This cast fails. Runs perfect the first time, but after respawn yeah
says here I need to enable simple collision but I can't even see an option for that.
Thats just my multiplayer character
@spring hare there is no collision complexity setting on this mesh
Just the name for it
Ah okay
I wonder if the player character somehow changes when you destroy actor ๐ค
@olive sedge Go to your static mesh
i am
Should look like this @olive sedge
Go to your blueprint
oh, this is the blueprint of the mesh
Yeah
now my character becomes a bugged stickman when i try to load the SK_raintrooper through the blueprint
what even could even be causing that??
this is the blueprint atm
I only have the options simple and complex and simple as complex. both don't enable simulate physics for me
it also works fine on the preview
oh nvm
complex as simple
makes sense.
@spring hare still falls through the floor :/
@olive sedge What does your component tab look like
Does anyone know why my camera shake is appearing even when I'm not walking?
@spring hare https://www.twitch.tv/teh_micon
teh_micon streams live on Twitch! Check out their videos, sign up to chat, and join their community.
@olive sedge What does your collision look like?
@worn nebula once you move once, it will start playing the shake but never stop
you need to stop the shake effect when the character stops moving
It does it before I even start walking haha, but yeah i'll set up a bool for that
I guess it triggers inputaxis once when it spawns or something
you can add a printstring and see when it prints it
Can you click on the Prototype AssultRifle tab @olive sedge
Good idea, thanks
Can you zoom in the the Assult tab @olive sedge And all good
@olive sedge Top left there is a button called collision click that then auto collision
auto convex?
@olive sedge yes
@olive sedge Now apply
@olive sedge Bottom right it says apply
@olive sedge It shouldve worked
yes, that's what I've been thinking since I started making this bullet ๐
I might just recreate it completely
@olive sedge Change the collisioon preset to physicsActor?
no change
now hold on a second
it works now, just didn't see
my bad
that latest change did it
thanks @spring hare I appreciate it
@olive sedge No problem
Yeah
gonna stream that again, I tried this earlier and it didn't work
do I need to apply that or somthing?
yeah
I mean press an apply button somewhere I'm not seeing ๐
There should be a reimport button on the top left
Oh that
Right click the folder on unreal
@olive sedge
Show in explorer @olive sedge
And place the file in there @olive sedge
hm, not sure what you mean
it is in there, it's the Prototype_AssaultRifle_Ammo.uasset
Your putting my file in right?
What are you doing? @olive sedge
Is that what you wanted? @olive sedge
Ohhhhhhh my bad @olive sedge
rotate it 90 on the x then click Reimport base mesh on the top left
Okay @olive sedge
I can't import it since it's uasset
Click on the static mesh on the unreal folder @olive sedge
Right click i mean @olive sedge
Then asset action @olive sedge
@olive sedge then export it as a fbx or obj file
@olive sedge Now reimport it with that file
@olive sedge There we go
@olive sedge No problem, You should probly set up a destroy actor after a set amount of time because if a lot spawns it will lag the game
i still havent fixed that bug btw
Yeah, got a guy on the forums that mentioned something usefull that im going to attempt
i showed you, the SKmesh now just shows up as a bugged stickman thing when i "equip" it (the left thing)
@scenic scroll I mean i dont know whats causing the problem
me neither! its sad cause before with the skeleton at least the mesh showed up so it seems i went backwards
i tried to go back and fix the skeleton problem differently
i think i succeeded but idk if that'll allow me to avoid this random bug thing
if not i'm giving up for today its 11am and i havent slept
@scenic scroll Try importing all the meshs again
i've done it a ton of times
didnt work
the SKMeshes also show up properly in editor and even in-game if spawned otherwise but not when i turn into them via blueprint
yeah
i'll do after i test my last attempt
YES
yesssssssssssssss
basically what i did was go back to my bugged skeleton model and reimport the skeleton from scratch
and it worked
@scenic scroll Nice
Hi! Iยดm working with the new water plugin and trying to make a material with buoyancy. In the video
https://www.youtube.com/watch?v=d5Ft7UaYayM approx. time 24:49 , but my material gets an error and I think I have followed along as in the video. What am I missing? Plz help.
Exploring the amazing new water capabilities introduced in Unreal Engine 4.26, Epic Gamesโ Sjoerd de Jong talks you through the basics of setting up an ocean, a lake, and a river. Then, he dives into more advanced features and possibilities that showcase how you can tap into the water rendering through other parts of the engine by making objects...
Lets say I've got a 500 element array and I wanted to copy elements 350-500 from that array into a new array, there's no really fast way of doing that in BP is there?
looking for the equivalent of C++ memcpy
nope, use cpp if you want that level of efficiency
BP wasn't really made with that level of scale in mind
Morning everyone !
@trim matrix Dunno what's been changed, but his water material function thing is different than yours. I'd check out the #graphics channel for materials though.
The pin has changed to require an input. Try an Absolute World Position node.
I spawn a bullet from the muzzle socket of my character's gun but when the character is moving, it triggers collision with the character
I spawn the bullet on the server and replicate, maybe the bullet is replicated when the character is already at that point?
Possibly. It's often best to separate visuals from the actual gameplay test. You can make it look normal, but it keeps that kind of thing from happening.
my workaround for that was to make the bullet spawn a little bit further than the gun , you can't notice the difference with your eyes but it's actually spawning a little bit in front of the gun
@maiden wadi I just worry that if I spawn the bullet on the server and client seperately, it might look like it's hitting but it's not and vice/versa
actually, that hit event also triggers on the server so that can't be it I reckon
You'll find that a lot of multiplayer FPS programming isn't very straightforward in regards to things like that. Hitscan stuff makes it easy. Just play muzzleflashes on each client and let the main firing client choose what it's shooting, do checks on the server for cheating. Projectile complicates things. First of all you shouldn't be replicating projectile movement. It's too fast and you'll end up with correction errors anyway. The best you can usually do is approximate it for all machines and try to line up the rest of the visuals. Again though, owning client of the shooter is often the one with the actual detection, and then the server 'validates' it with cheat detection.
anyone knows where this went in 4.25.4 ?
@burnt anvil Its still there
m i required to change something in proejct settings or something for it to appear ?
Under advance settings go to multiplayer what does it say? @burnt anvil
it opens up editor preferences
Under multiplayer on that window
@burnt anvil Let me load up my one
sure ! thx
Trying to run as a dedicated server to test multiplayer .
planning to host the game on a dedicated servers later on when launching .
If you play as the listen server that will be like running the server
And the client will load up the server and add you to the game
Any idea how to manually place virtual tires? I can't make it right. When I import rigged mesh, wheels have no physic capsules and I have to set everything manually.
ye but thats like having one client and one server , for example oen of them lags while the other doesnt etc ;
@burnt anvil What do you mean?
when server sprints , it sprints just fine in the client window , however , when client sprints , it stutters and lags ; things like that that are solved by run on server or run on client etc
@burnt anvil Thats normal (from what i experienced)
oh wait , do you mean like i can run 3 instances , 1 server and 2 clients and just use the 2 clients to test and ignore the server one so i can just think of it like the dedicated server and ignore that there's a game in there ?
Well logically you run the server on your computer then connect to it on a laptop
i m getting so confused with implementing multiplayer stuff :3 ! thanks for trying to help i kinda have to go right now , family calling for me . BRB . have a nice day ^^
@burnt anvil No problem it is a bit confusing, Have a great day
Anyone had similar problem with importing rigged cars from blender? Wheels have no physics capsules.
@olive sedge Have you saw this? https://www.unrealengine.com/marketplace/en-US/product/easyballistics-plugin
@carmine prawn no but that looks pretty good!
and free and it replicates ๐
at the very least I could look into how they did it I suppose
help me reinvent my wheels then... How do I set this thing up properly?
just to update you , apparently the run as client will start the dedicated server in the background .
Yeah it does @burnt anvil
Sorry JSZ, not my area.
Hey guys, i'm really new to Unreal Engine and it's speficities, i'm trying to build an actor that could detect if a player is in range of its detection, basically a spotlight that detect wether or not the play is in range. From as far as i know a raycast should work for this kind of things, so i tried but i cant get the raycast to work. Did i do smth wrong here ?
thx @maiden wadi @carmine prawn solved it ๐ realy like this plugin
@carmine prawn any way to download this plugin from the marketplace?
my engine is built from source and I can't install into it, seems like
@olive sedge Download it for the Launcher version and copy it over? Gotta have source of the plugin though
@neat mulch I've never seen Request Raycast before. The docs suggest its a Magic Leap specific thing.
You want something like LineTraceByChannel or SphereTraceByChannel
{Line|Sphere|Box}Trace is the bp version of raycasting.
Does the Duration node of a Sound Base Object work?
@surreal peak I'll try that.
In the meantime: Can I set variables on actors I place in the level?
I want to set spawn zones in the level and then set the team name in a string
then when a player spawns a character, I'll just get all actors by class bp_SpawnZone and get the appropriate one for the team
i just set it with flipflop in the level blueprint now but would be nice to know if actors can be parameterized like that
This may help with the plugin question https://answers.unrealengine.com/questions/518976/how-to-install-plugins-in-sourcebuild.html
Yup, it's a fairly standard thing.
@carmine prawn where would I do this?
You need a reference of the actor, and cast to it.
Where you do it is up to you. You can either do it in the thing that is effecting the actor or in the actor itself.
Or any other actor that might be managing things, for that matter ๐
ah, right.. I was thinking I can select the actor in the outliner and then set that variable somewhere
Sorry, I thought you were wanting to do this during runtime. If you mean in editor, just expose the variable by clicking on it's eye symbol in the BP, compile and you should see it in the details panel and do what you just said ๐
Make a variable in your actor, set it to Instance Editable, drag actor instance into world and you'll see the var exposed and editable @olive sedge
@hollow cape yes, this! thanks!
Hello, I'm watching a tutorial to set-up different languages for my game, so far I created a string table for both French and English, now I'm trying to switch to French in game. I guess it's because I'm on 4.16, but it seems that I don't have the node "Set current language", do you know a work around to switch to a different language ? Thank you!
hi, for a game wide timer, is it okay to use the tick from GameState ?
@quartz field if memory serves there were major changes to the localization feature in like.....4.17 or 4.18, I can't remember which
thanks! I guess I'll try to update my version and hope that it doesn't break anything ๐ค
if you're going attempt to simply change version for the project, make sure you back it up
Hey guys I am trying to learn interfaces. Can someone explain to me why this isn't setting the variable? Basically I am wanting to interface the monster health from the battle BP to the Spell BP. I set the current health of the interface to the current health found in the battle BP, then I try to call that to a new variable in the spell BP, however it is 0 everytime. Still trying to learn how interfaces work exactly.
there has to be a reference to the actor you are calling the interface on
also, on the receiving actor, you should have a BPI event
Isn't that still self if it is inside that actor though? Or am I having a dumb moment lol. Also let me google how to do the BPI event thing real quick.
but you aren't executing the BPI event on the same class that is calling it....so how could it be self?
@quasi frost Basically the BPI is a blind event call. The nice thing being you don't need to cast, and you can call events that can have varying functionality across classes since the sender/caller doesn't know (or care) what the receiving class is. However, you still need a reference to the particular actor you want to call the event on.
Alternatively, if you want a reference-less method, you may want to look in to Event Dispatchers, which is basically a "yell" (at least the way I think about it). The sender will blindly, and without a reference, call an event. ANY actor that is "listening" to the sender/caller will then execute an event when that "shout" is received.
That still needs a reference to the one that is yelling
You won't get away from that
Correct, so the receiver will need an initial reference
There is a tutorial pinned to this channel about Blueprint Communication
People that struggle with this should watch it before they continue asking questions.
Announce Post: https://forums.unrealengine.com/showthread.php?101051
This Training Stream takes a look at Blueprint Communication. We find that Unreal Developers of all levels can sometimes struggle through the concepts behind moving data between objects. So in this video we'll take a look at the different ways to make Blueprints talk to one an...
My ue4 keeps crashing when i create Skeletal mesh variable on a structure!!!!
help please!
The problem I am encountering is despite Print String showing I am clicking the X button to close the menu, it doesnt close on my screen. The tutorial I am following is the Drag and Drop with UMG|02|Live Training| The pic below is inside the editor character bp.
This is from the item inventory menu where the button exists.
In-game print string of it showing that it should be working
if you store the widget as a variable when you create it you can use the variable to 'hide' it.
your event is getting fired off, so i'd look at your player editor hud reference and make sure its being set like it should, that seems to be where your problem is stimming from.
Would the easiest way to do that be just looking at the reference viewer and seeing if it is even referencing the hud?
it does look like the ClickedToClose event in the character BP isnt firing so yeah thats the issue
Yeah the Editor HUDReference inside the player BP doesnt reference the Editor HUD at all as when replacing the Editor HUDReference in the Open/Close Item Inventory Menu(the pic I posted with that comment) I cant add the iteminventorylist
I did go and redo all of the EditorHUDReferences through the other BPs that have it and they all work fine just as before so ig Im missing something in those BPs as well thats not communicating from those BPs to my player BP?
Are [Hierarchical]Instanced Static Meshes not reporting any overlaps besides the first / intial one?
So I went through and redid references so make sure they are able to make them to the character blueprint I made and they all are able to be referenced from the character BP but still the custom event doesnt fire. The EditorHUDReference works as well because if it didnt I wouldnt be able to see the inventory items I added. Should I redo the tutorial series and see if starting over changes things or is this maybe a bug?
@exotic cradle If the printstring is showing as it should, but the intended functionality isn't, then the function IS being called. Either the implementation of the function is wrong, or the reference is bad
are you getting any errors when you exit/stop playing?
Did something change since 2015 that may affect this? This is where I am at for this section https://youtu.be/hgyJWHZTKfI?t=693
Training Content Creator Wes Bunn continues showing you how to add drag and drop elements to your UI using UMG.
None.
do this, in the UMG that you're trying to close, create an Event Initialize if you don't already have one, put a delay (5 seconds or whatever), and after the delay call the close function
verify that the function actually works
@hollow cape I see you!
Okay so now I am getting an error upon closing in relation to the Editor Character Reference.
is it an attempted to access none?
You are correct
put a printstring on the cast failed of that cast to EditorCharacter, and test
Yeah that fails which would explain the other portion failing as well
Than idk what else it would be
well what do you have it set as
check your gamemode, and also check your world settings gamemode override and make sure something isn't overridden there
ohh. That may be the problem than actually because I started with the 3rd Person Example template and when that character clicks on a cube it loads a new level and has the player possess a pawn in the new level so I set the default pawn for the project to None
Oh...
bada bing
so you need to figure out where/how to store that var. Possibly PC or something like that
So than when I switch levels the gamemode knows which pawn class to use or did I read that wrong?
So upon the third person template loading set the default as ThirdPerson and when the Editor Level is loaded set the default as the Editor Pawn
well it depends on your settings
but if you have an override to set the default pawn class to none, then the pawn class will end up probably being the default UE4 pawn class which is nothing
you either need to store your var somewhere else, or you need to have all your potential pawn classes inherit from your own custom class (inherited from pawn at minimum), so you aren't casting to the specific pawn class, but the parent pawn class
maybe somebody else has a good way to handle this
so i made this basic dash bp
but the problem is when i dash off any ledge
my character keeps flying forward
how can i gradually decrease the speed once im off the ledge
So even with this upon level loading it cant reference the character in the iteminvetory UI? Yeah so as it turns out the Editor
try posting in animation text channel @trim matrix
theyll be able to help
so, if im close to a ledge, and if i dash over the ledge, the momentum will stay persistent and my my character would continue to move forward way more than id like it to
not sure how to fix that
So I put PrintStrings on all things that are being cast to see what fails and these two are what I got. The first one is inside the Editor Character and the second is in the ItemInventory BP so I probs need to make my own gamemode besides the default UE third person template one to get this to work since if Im not misthinking this its not switching the controller or the character from the Project settings since those are default set to third person which would be causing this?. @hollow cape
I honestly never thought just getting an X button to work would be this much well...work xD
@trim matrix i did
wait
ill go download recording software real quick
wait i just wanna make sure
the root component is the only thing i need?
just get something like screen to gif
it updates all the red actors locations then once it destroys im trying to get it to increase the integer value yet sometimes it goes down or it doesnt go up at all it works with one blue ai
so its printing out each actors kills instead of as a whole?
@odd ember ok so i downloaded screen to gif
playback seems slow tho
will it be fine once i export i
you can increase the framerate
no it will stay exactly the same
it's a gif
not a movie
you can also speed up the time between the next frame
I usually do that
alr
@trim matrix
i laso tried to set target relative location to 0 and it still pulls me to the same place
not really sure what you mean by that
do i need to stop the gravity for this to work?
what do you want to happen
to dash a set distance
im having a issue where. i prep stage one logic in a if statement through blueprint. once i hit left mouse button it run to check to see if any of these bool been set to true but since im using random in range to set the true state. when i click the left mouse button it run through both branches and end level one with out c hecking if i click on the second actor. is there a way i can set up mouse detection click or should i be running this in a while loop
gradually slow down towards the end
yea but the problem is the dash pulls me to the same place
use set actor location with a timer
probably because set relative location on root is the same as set world location
I would surmise that anyway
root doesn't have a relative location
because it is root
you find a different method
this is how i set the bools for the above. it set once the event get calls thru the random gen. not sure if im setting these values up correctly. doing this to figure out how everything works together.
well i was using character launch node which worked fine until i tried it off the edge xP
I gave you something you could try
but in any case
you'll need to use the forward vector of your actor
to add direction
ok so i returned the code back to what it was before
and the dash just flings me off the map completely
i think its the gameengine actually
thats acting up
ill try reseting it
nope, somethings messed up
i dont know what i couldve changed
where should i even check
hello Guys
How can I create a Super Slow Motion with black & white post process effect.
slow down time, spawn widget
how?
can you change a delay during its proccess?
can someone tell me why i dont have pass by reference checkbox in my macro
or help me find how to set an input to pass by reference
Theres a slow time node somewhere, not sure exactly what its called. But I know it exists
and you can also just apply a white and black overlay with a widget and textures
how can I call the post process by blueprints
iirc, the checkbox isn't there because you ARE passing in the reference. I may be wrong, but I believe all ||but a few variables such as array/map/set items|| variables are refrences
I havent experimented much with that, so im not sure
is there any way to get the camera out of a pawn and then add a widget only to it? (instead to viewport) cause this current code i got here works but the hud stays on even in freecam / third person which i dont like
try increment int, or make your macro return a number
i found it
it was under set by-ref
not set integer
thanks for explaining pass by reference to me
Question: How do I make a new Image Object Reference in a widget blueprint
I want to duplicate an image, but can't find out how to either make a new one or duplicate the old one.
here is a picture
it appears in the top right of that pic, you are changing Delay, ๐ค
may be yes
did you manage to dig up anything?
hey i know macros are like ways to compress your blueprints into one blueprint to declutter your construction script or event graph but whats the difference between that and functions i know you can call certian variables only in the event graph or macro but is that the only difference
change of question: how would i add a widget to the viewport but so it only shows in first person? (not in freecam or in 3rd person)
wouldnt you have the targetjust be the camera of the first person?
then use a seperate camera
or make a remove parent thingy to remove the hud from the camera
problem with this part is that the freecam is the same camera entity as the first person so this one i can't do
there's only 3 cameras in the scene (map camera (for seeing the map) editor camera (for building vehicles) and vehicle camera (vehicles)
but the freecam and first person are both the same thing, i assume that being the brick camera manager
keep in mind tho this is just assumptions i'm very new to ue4
so i might be underestanding wrong how these cameras work
same
figure out how to remove a hud and add that to the end of the script that switches to free cam
?
i dont have access to the freecam script, that's a vanilla script and i can't edit those, i can only add my own
due to modding limitations
so i'd need to add the camera in a way that only works in first person
also for testing purposes, how would i add a widget to a specific camera anyway? all the tutorials i've seen only add it to viewport so i dont know
general question , in multiplayer games , should i put the player health variable in the controller or the character blueprint ? right now it's in character bluepriont and when any player takes damage all players healthbard drop ...
i need your help
so as you can see there are two white cubes, one is above center of head and other one is below of center head
when i try to subtract above cube with head, it return 40
but when i try to subtract second cube with head, it also return 40
the problem is that i want to check if the cube is above from head or below from head
@burnt anvil Depends on the game. If you want it to be able to be thrown away, put it in the character. Controller is for personal client variables that no other client needs to see that don't get discarded when you kill off a character. PlayerState is for the same, except that it's where you put things that all clients need to see. Health is usually done in the Pawn.
i mean 40 is vector lenght @maiden wadi
@maiden wadi thanks man ! you've been really helpful ๐
@gritty elm Get the look at unit direction from the head to the cube. If the Z is positive, it's the upper cube, if it's negative, it's the lower cube.
I'm usually in here and active a lot more, but I decided to participate in the GameJam this time around. So very close to being done, and there's still over two and a half days left.
only joined a couple of days ago and you're always her helping ! appreciate it ^^
can't figure out how to get a specific player health in multiplayer . been trying to do this for over 5 hours now lol
everytime i pick up a medkit or take damage it affects every player in the game lol
It's likely just the logic train. Multiplayer can be rough to get a handle on. You're trying to heal a character via a medkit?
@burnt anvil Is this via a client's key press?
Like. Client presses "SomeKey", and then heals themself?
on collision , you pick it up and it heals immediately
Ah, that's easier. What kind of logic do you have for the pickup?
I'm creating a widget, and adding it to viewport. But it doesn't show up. I assume it's being removed I have seen it for like a frame but I can't find what blueprint is removing it.
Any suggestions on how to debug this?
Are you sure he's set to visible?
on collision , the medkit adds X value to the character's health then destroys itself
@wind void Any Construct or PreConstruct events in the widget?
yea a PreConstruct
@burnt anvil Paste your collision stuff. Will be easier to help.
@wind void None of it has any form of RemoveFromParent calls on it?
Oop, had a missing node so instead of setting a child to invis, it made the entire widget invisible.
Ty ๐
Been there done that. My blueprints are a disaster this week. Rushing so much.
told you x)
tried a bucn hof thigns , this is what i have now but it's taking away helath from everyone .
You should not execute this on everyone
you mean the custom event replication ?
Yes
@burnt anvil First off, never mix execution lines like that. You'll end up with some crazy unintentional behavior. Second. You don't want to execute that on all. You just want it to run on the server.
Your health should be a replicated variable, so changing it on the server changes it on all.
what do you mean by mixing lines ?
It's not linear
You should use reroute note to make it more clear (I assume it's that)
Also, do yourself a favor and make a function in the character that you can call to add to health. This way you can just add some random number in a single call and that function can handle the clamping and such. Otherwise you're going to need that clamp everywhere you ever alter the character's health.
this is the only case in the whole game where health is increased so i didnt care that much about doing it that way to be honest .
much cleaner . i see !
I would like to attach my camera to my weapon scope (socket), when I press the scope action. The problem is that it doesn't work like it should (the camera isn't at the right place). I tried to see the location of both sockets I got on this BP, and both return the same location? What's wrong?
Your camera is going to face left if you attach it there.
Well no, give me a second I will give you two screen
Sorry for the flood
I can't see what's wrong here
@maiden wadi ran that on the server only , and printed my health values . turns out it's going correctly on the server side now . it's just the HUD that's not working which led me to think that it's decreasing all player's healthbars together for all day ... ๐
alright ill try it
but it seems like my forward vector is messed up
cuzz the code from the tutorial worked fine when i did it the first time
but after trying it again after "move component to" node didnt work
the code kept launching me backwards
same spot again
@minor merlin Definitely odd. I'm not sure what's going on there. I normally make weapons their own actor with their own camera for easy ADS transitioning with SetViewTargetWithBlend.
this time it was off the map
I gonna check this
when it goes to B i want it to interrupt anything A was doing, how?
@rough jay can you explain in other way?, i mean please explain more
yep, so A has a couple of timers on it which is why when i press B the timers still run and do their functions
when i flip it to B its still running
maybe the "Gate" node will help you at the end of your delays
make a branch after delay node, so when you reach to B, set the bool value to false, so it won't run
i'm getting so annoyed with this
the game wont recognize my input
i click start
smash the "O" key
and no connections light up
@rough jay try this, and make sure the default bool variable should be false, so when you run first time, it run
this has never happened to me in many maps and due to it i have wasted so much time testing thinking the code didn't work
i dont underestand what's going on
why could that be happening?
@scenic scroll in which type of bp you are working?, is it level blueprint or other?
@scenic scroll Does your Player Controller also use the O key?
how can I make an actor less affected by gravity?
i'm in the level blueprint
I have a projectile that basically immediately falls to the ground.. I could make it fast but I just want it to float farther without being faster
I don't underestand what you mean, i haven't edited the player controller (this is a mod) and on other maps the o key worked fine
try any key instead of O key, check if it works
for example this code here is from another mod / map and it works just fine (the connections light up when i click O)
alright
@olive sedge https://www.youtube.com/watch?v=NfX14Y0Eyks&ab_channel=AlenLoeb or search google "ue4 reduce gravity"
i changed it to any key and no matter how many keys i mash it doesnt light up
are you using level streaming?
could this other blueprint (from another object) be causing this?
i dont know what that is so whatever it is set to in default
yes, try to disconnect overlap functions, and try again
thx g33k 4 showing me more abt booleans
If that blueprint uses the O key as a keybind, then yes.
@scenic scroll also try this when you are debugging the code, so if game quit, then it mean your button action works
Input always goes to the latest actor with input enabled, then Controller, then Level, then Pawn.
it didnt seem to make any difference- also i realized in this project i cant even walk (in the one that works i can walk around / move) but not in this one
so it does sound like the imput is just somehow turned off
do you setup the game mode correctly? in world settings and project settings?, and make sure you set your correct pawn in your gamemode
@gritty elm I don't know why set linear velocity target works for that cube
it wants a physics constraint component when I want to use it
so you should physics constraint component in that case if you want to change gravity, you can also google "ue4 reduce gravity"
both projects have an identical gamemode (default since this is a mod)
so what is the issue right now? do you have character in your level? when you press play?
@gritty elm i've done this before but haven't gotten any good results
there is no character (that gets added into the game by itself) but in the working project when i click play i can move the camera around with WASD and stuff and imputs work while in this project i can't do either (making it impossible to test and i think that might even be preventing the script from working when i put it in the real game)
I'm useless there. Zero modding experience besides changing portraits in Baldurs Gate, which seems mildly irrelevant.
@scenic scroll see your game mode, make sure it is set to correct game mode, if you don't have ,set it to game mode base, which is default game mode
ok, create a new game mode by right click on content
let me know when you created your own game mode
@scenic scroll ok, create a spectator pawn by expanding this tab
search for spectator pawn
done
open your game mode that you've created, and change default pawn to your spectator pawn that you've created
after this, change game mode override to your game mode that you've created
when you press play what happen? are you able to move W,A,S,D camera? or only input not working?
i can move the camera with mouse but i can't move with WASD
(in the other project i could)
try this in your level blueprint or in your spectator pawn that you've created
also do one thing, open your spectator pawn that you've created, and do this:
Anyone knows the best swim system that works well with the new UE4.26 water?
and check if your game is quit or not @scenic scroll
it worked now!
ok great
wait what... look at this
hold on
something weird is happening
so WASD works now so imput is working but when i click "O" the connections still don't light up as if it wasnt registering it
@true valve watch this full unreal dev video : https://www.youtube.com/watch?v=XHugDXx6c5c&ab_channel=UnrealEngine
Get a peek at the upcoming experimental Water tools releasing in UE 4.26! Ryan Brucks will start with a breakdown of the new Single Layer Water shading model and then show how Water Bodies create cohesive water features. We will then go over new features such as Gerstner Waves, Fluid Simulator, Caustics generator and how they can be connected to...
@scenic scroll please do your input stuff in your pawn, your pawn is responsible for handling inputs
you can copy paste your code from level blueprint to your pawn, since this is the solution i suggested
I can't because the pawn is handled by the vanilla game (this is a mod) i don't have access to the real pawn
also in the other map (which is also a mod) the code is in the level blueprint and it works
if you don't want to use pawn, you can also create your own custom player controller exactly you created your pawn and assign this player controller in your game mode
your player controller is also responsible for receiving inputs
guys this nodes make a rotation for the y axies, but the problem is it does 360, i wanted to make a limit for it so it can go a max of for example 90 degree etc etc, im sure it sound easy, i thought that too, tried to use the clmap but it does not do what i want, and i watched all the tuts on google and they do it on a filed of view and worldrotation which set the world rotation not change it smoothly ( it set, does not move the camera until it reach its desired degree angle )
help
@scenic scroll if you don't want to use custom pawn, you can create player controller, and handle all input events from player controller
if i make my code in the player controller then in-game the code won't work because the game will use its own (vanilla) player controller
remember, this is a mod
help
@grizzled garden for rotation you need to clamp the angle, not just clamp, since rotation is clamp to -180 to 180 etc
what is the issue you have
coz im using addlocation node
what the issue? i have explained everything above, it is that i cant limit it, it is 360 degree rotating
i want it to be limited to a number
like 90 degree or 50 etc etc
i used clamp and it is not the correct choose here, unless i add extra nodes
you are using add rotation, so it always add that, can't you use set actor location instead?
you want to rotate the actual player camera view? like we rotate the camera using mouse?
yes
please remember, if you want to rotate your camera, always do this :
it always rotate your character main camera that is shown on monitor
ok
you can also use function called get control rotation, it return you the current camera rotation
pawn is possessed by the player, player controller is responsible for handling your pawn, and your pawn receive inputs actions from player controller
@gritty elm It doesn't show you any swim system, it's only about the new water
@true valve for swimming system, you need to understand the concept of physics volume in unreal
ok
I currently have a system but trying to find a better one.
If the new water system has any feature that could benefit
@grizzled garden you can get the current rotation of your object, and check if it's rotation is greater than any x value before changing rotation of object
@true valve https://gumroad.com/l/ParkSwimPack, also google "ue4 swim system", you will find videos, and market place content
you want to rotate your main camera or your character camera? can you explain what you are trying to achive?
the camera
as u have seen im working with it only
but it is complex issue
why i cant limit it to 90 degre?
you can limit it, can you share screenshot how your player looks in level?
what camera or object you want to rotate, please share a screenshot object in level, so i can understand and help you
it is invisible. the object i want to roate is the camera on the left, in the component tree, exactly under spring arm
@grizzled garden try this, and for rotation limit check using "in range " function
ok
also use set and get relative rotation, not world, but this depend on your requirements
yes
the cube is your camera component, the all rest of code is same
yes
Hello! I was wondering if anyone could help me with a blueprint runtime error I've been having. I've made a character selection menu and created a persistence using a game instance I found in a template. Everything runs smoothly but I keep getting this error. Any suggestion on how I could fix it? Thanks in advance !
Not working, I'm just gonna put a camera on it. but there's another problem : I want the bullet to be fired from the muzzle so without socket it's gonna be difficult to do that...
when you get the error you can click on the white text to get taken to the routine that caused the error, it looks like one of your functions is trying to access a camera (either directly or by a var) that its having issues with being the camera its attempting to access is returning a value of 'none' (i.e. empty)
I apologize for the amount of questions but its my first time doing something like this-
I'm making a mod and I've got this effect for a helmet visor assigned to a widget that uses this code (activating when you put on the armor)
Problem is that the widget stays on even when i'm in freecam or even in the building editor (its a building game) as well as when driving a vehicle in third person and its extremely annoying, i don't know how i could make it only show when in first person!
check to see if the first person camera is set to active, if not, set the huds visibllity to hidden or collapsed, i'd do this in your camera switch routine, so when they switch to one of the other cameras, it toggles it right then.
@scenic scroll oops forgot to include the @
i do not have access to the camera switching code due to this being a mod (and me not having access to the vanilla code) would it be possible to do that but in the level blueprint?
@mild fossil use "is valid" node before getting your actor, if it is valid then do stuff, so it won't return nullptr
@scenic scroll yes you can remove your widget by using this function
use get all widgets of class, select your widget you want to remove or call function inside or anything
or either set visibility
@scenic scroll if its built in you should still be able to access the camera switching (assuming that the first/third/access car is all key triggered) by adding a event to fire when they press the key that causes the camera to change, the camera itself is part of the player so you should still be able to access the camera and see if its active, then its just a matter of doing something like i've done here for toggling two different huds:
if fp camera active -> show hud, if not active -> hide hud
(mines a toggle between two hud widgets)
Thanks for the reply @orchid garden and @gritty elm . I tried following the link but nothing related to PlayerCamera shows up
@mild fossil please watch this video : https://www.youtube.com/watch?v=5d87aoNt-Dg&ab_channel=MathewWadstein
What are the Is Valid Nodes in Unreal Engine 4
Source Files: https://github.com/MWadstein/wtf-hdi-files
i'll try this one first because the removing from parent one sounds like it wouldnt be possible to put it back when the camera switched back
this is whats throwing the error:
heh, i love those WTF is videos he did
@orchid garden use it like this
also @gritty elm and @orchid garden thanks a lot for the help :)
i was just helping @mild fossil pinpoint the error he was getting
There's a handy "validated get" which you can also use
You can right click a variable node and use "convert to validated get", which basically makes it into an is valid with a builtin value pin
this is apparently also slightly more performant than using a separate get and is valid
so to check if the camera is active how would i reference a camera like this? it says its in my level but it's not a camera i have added or can access (i assume the vanilla game added it)
Thank you @orchid garden and @gritty elm giving a try
create a reference to the vehicle then get a refrence for the camera from the vehicle refrence @scenic scroll
@scenic scroll after getting reference to your camera, do logic like this, if it is active it return true, so if true you add widget, other wise remove that widget
the vehicle isn't something i can access either, its a vehicle from the vanilla game which code i do not have access to, also i assume the camera isn't exclusive to the vehicle since it's one of the three only existinc cameras and the other two are map (bird view of the map) and editor (the building editor)
i appreciate it but the problem is i cannot access this since the camera is from the vanilla game and not present in my UE4 project so i dont know how to reference it
normally i reference objects i dont have by creating a copy in the same place and then deleting it so they call for them, but in this case the path is odd and i do not know how to reference it
this is the camera path
@scenic scroll to get your vehicle, you need to get the vehicle first, then inside from you can get camera or whatever you want to get and want to do
help
@grizzled garden use set relative rotation instead of add local rotation, like i already show in above screenshot : #blueprint message
i dont know if it's gonna work but i will try thanks
the enitre example or only that node u mentioned?
@gritty elm
but set relative location will set location not rotate until that rotation
which is not what i want
you need to do exact like i did, in your screenshot you are using clamp axis and a disconnected branch, which not work
but urs is not what i want
no, it works exactly like add local rotation, since we are adding +1 to current rotation and setting to that rotation
ok
i'm looking in umodel and there isn't any vehicles i can reference to find the camera, i'm really lost
would it be possible for me to get the camera off of the player controller at the start of the game, store it, and then if it changes i hide the HUD?
@grizzled garden also watch these videos how rotation works in unreal : https://www.youtube.com/watch?v=b39XZfLK-J0&ab_channel=Azulechaos
https://www.youtube.com/watch?v=02INWmAktn0&ab_channel=MathewWadstein
https://www.youtube.com/watch?v=Lmd0XCEyqog&ab_channel=MathewWadstein
Don't forget to like and subscribe!
What is the Set Actor Relative Rotation Node in Unreal Engine 4
Source Files: https://github.com/MWadstein/wtf-hdi-files
What are the Actor Rotation Nodes in Unreal Engine 4
Source Files: https://github.com/MWadstein/wtf-hdi-files
@gritty elm thanks
@scenic scroll yes it is possible, can you explain more how you are changing camera views?
like i said before, I am not changing camera views xD
this is a star wars modification for a game that someone else made, i don't have the original code, so i have no idea how they change camera views
i have a console i can use to get info and umodel to look at the game files, that's all
if you need any info to help me that i can get with the console or umodel i'll get it but that's all I have i dont have the original code
thats what i was suggesting for the first person camera, sense the hud is based on first person view, get a reference to it, check if its active, if not hid/remove the hud for the helmet, if active show/add hud for helmet.
@scenic scroll does it works? : #blueprint message, since you are in level, you can press play after you can eject your player and you can see what types of objects are in level, so you can try this method
Would it be possible to do that method but with the player controller itself at the start of the game (the player spawns on foot and in fp camera) to get the fp camera?
(also sorry for the many questions and all that)
also @orchid garden i underestood that. The problem is getting the reference itself because since the camera isn't in my editor i need to get the reference at runtime
@scenic scroll when you open the player you should be able to see the camera like so and you'd know what the camera name is for the fp camera:
is the image showing? i just get some funky "working" icon showing :/
i said before i dont have the player in my project, the player is in the vanilla game I don't have access to it, if i wanna reference anything from the player i need to make a code to get a reference at runtime
My project literally doesn't have any player, its just a map. I put the map in-game and then in-game the player appears, but in the editor there is no player
your project should be using c++ in that case, you need to view and modify source code in order to do that
i do not have the source code, if i did it would be easier xD
basically i'd need a code that was like
on start: get player controller > get its camera > save it
on tick: if camera =/= saved camera > hide HUD
your using their mod tools for the game?
there is none
ah
altho if you're wondering the creator said he's fine with modding, just not supporting it yet
but yeah i dont have any access to the source code
if you can get ahold of the creator perhaps he can tell you what you'd need to access to get a reference to the cameras?
i doubt that would be possible he isn't very reachable (i tried back when i started modding the game never got a reply)
I wonder tho- is there any code that would allow me to get the current camera of a player controller? because if yes then i think i could do it- i just dont know what that code would be
you'd need to know the name of the camera unless they did general names like in the example i tried showing (fpcamera, tpcamera) without the name of the camera it'd be abit difficult I think...
this is the result of doing "/getall cameracomponent and /getall cameramanager
they should be all the cameras in the scene
problem is like i said i cannot reference them since they aren't in any path i can replicate in folder structure i think
so i take it there aren't anny commands that allow you to get a reference to the current active camera of a player controller?
The error is gone now which means that my Player Camera is not valid.. All the interactions are now disabled. Any suggestions on how I could connect my is not valid? Really appreciate the help. Thanks!
@scenic scroll where you in first person mode when you did the getall CameraComponent ?
@scenic scroll when your just as the character, it should show you the cameras for your character, like it is here for mine:
let me try in first person :0
i'm in first person, i get the same cameras as before
if i had to guess.... id say:
it looks like it might be using the same camera for the different modes.
i know, but i still don't know how to reference it. Like i said before, i can reference objects by making an object with the same name in the same path, referencing it, then deleting it before i import it into the game, but that camera doesn't seem to be in any path i can replicate
Also if it's the same camera for all modes i can't use this method to disable the HUD anyway :0
which leaves me back at square 1 :')
well... a sloppy method till you can figure it out would be ... setup a key that allows the player to show / hide the hud when the helmet is on.
i tried that before and it didn't work although that was probably my mistake
say, would there be a way to make the hud like- a physical object?
the fp camera is nothing more than a camera on the head so
maybe there could be a way to just put a plane inside the helmet in front of the camera with the HUD on it?
yeah there is a way to add widget displays to a object but i haven't done any of that myself, i don't think they can be interacted with though
not a problem this widget isn't interactive
Is there a way to make my lowpoly assests smooth shading? Instead of its flat shading ?
Like how we do it in 3d modeling programs
Thank you for the help earlier. It has brought me closer to solving the problem
the plane inside-helmet idea worked! also thanks a lot for trying to help me!
Anyone able to look at a weird cast problem im having, been trying to look through the forums for help but no luck
you really need to post screenshots for that
just post your screenshots. you'll get much faster help that way
My player spawning issue is fixed, it just seems that now my player controller cant assign the new player ref. This runs on begin player in the player controller
I used a isvalid node on the player controller and runs fine before respawn, after respawn it cant get the controller
I reckon your entire setup is kind of wonky because you continue to use stuff like get player character
use get controlled pawn and test on that instead, if anything
it's not
if you've killed your character, then your character is dead
also why you can't cast in this case
there is no character, very likely that you're spawning it incorrectly
how do I make collisions more bouncy? I can't find the property
I told you to look at the function in the game mode
it is set up in such way that you can handle all spawn logic in there
and you avoid pitfalls like these
Yeah I did, and was just a bit confused by the override. Ill have to look at documentation for it more
there is really nothing to get
it executes when you spawn or respawn the player
just put your logic in
use the player controller reference you get from the function itself
But it only executes on a custom respawn node right? I saw there was like a 'restart player' one?
cast it to your particular player controller
it executes no matter what
if you don't override it, it means it just does its default stuff
which is spawning a acharacter
if you override it and leave it blank, nothing spawns
it's really not rocket surgery you just gotta listen
or you can continue down this road of hack upon hack that keep causing you issues, your choice
Yeah im just looking at it and I get newplayer and StartSpot, One controller the other a actor ref. Is actor ref the old one or new one?
As output nodes from that overide
if you hover over both those pins, they will tell you which class they are
you don't need to use either of them, but they are provided for ease of use
now
Interesting alright, let me experiment a bit with it I think I get it somewhat.
if you want, you can cast the new player, which is a player controller, to your own player controller, and then hook it into a spawn node
this has a benefit you can get nowhere else: you get to setup automatic bindings for all delegates in your player controller, in your player character
nowhere else does UE4 allow you to do this without dynamically binding delegates
Ah alright, I think I got the player controller part right here, and just setting up the new pawn if im doing that right
you're not
you're not actually spawning anything
you have to handle the spawning manually
you need something like a Spawn Actor From Class node
Wasnt sure if I could do that before the override or not.
So hmm, what about the spawn transform then? Since I cant change the inputs and put something custom in
you were given a start spot from function were you not?
True yeah, I already hooked that into the spawn actor
@scenic scroll Hey how are you doing that material?
so that should work well
So its triggered on respawn right? How exactly would I go about doing that and making sure the engine knows im respawning it? Same way as before, destroy actor and posses a new one?
Or restart player node maybe
is your game singleplayer or multiplayer
Primarily multiplayer. Might add a small singleplayer but thats later
so in this case you're looking to restart your player
there are other considerations you need to ensure before then, for instance is it legal for the player to spawn?
Cant I just use simple booleans before the respawn node to check for that?
but tbh at the level I've seen with your stuff I'd say multiplayer in general is slightly above your skill level
you can try and do that with booleans sure, but it needs to factor into a greater respawn system
the system should handle downtime between respawns, know when each individual player is ready for respawn, and when they're ready, spawn them at the correct space
all of that will be a complex tangle of delegates and conditional branching that you need to wrap your head around
but it is the way to do it
and it is only going to go downhill if you attempt to hack it like you have previously
ignore the top texture sample its just the bottom one (both are the same i just made the bottom one a bit smaller to adjust for the camera distance)
Anyone have experience with aim-offsets?
Is there any way I can scale camera shakes globally?
I want to apply a value to all of my camera shakes before they play.
@neon sorrel Still having trouble with the respawn?
Ah okay
Just facing issues with get player character returning null
odd bugs
I may just move all of the player controller stuff into the actor if thats a easier way to do it
Might be
Well, from what I can tell. That way all I have to do is respawn the actor
If it never interfaces with the player controller, then its all condensed into just that.
It worked before with another character I had, swapped it out and changed some stuff and now this
Its odd but meh
Yeah
what would be the best way to make rockets fly like this: https://youtu.be/kVSswbUP3g0?t=301 ?
The most epic battle scene of DISTRICT 9, Exosuit vs Human Soldiers.
The Exosuit is a mechanical bipedal suit system that was used by the alien species (nicknamed the 'Prawns') in the 2009 sci-fi film 'District 9'.
As shown in the battle scene, the Exosuit's armor is able to withstand projectiles fired from small-calibre human weapons, althou...
(I am interested in those crazy cool trajectories)
a small amount of constant rotation should achieve that type of spinning trajectory
guess it depends on what parts of it specifically you want to emulate
well, it's for mobile, so it should be relatively cheap performance wise
you could probably also use a sine wave or something as an offset on its motion
I just want for rockets to fly on random'ish cool looking trajectories like seen in the video (with smoke trails). Let's say one mode is when you locked on several targets and rockets fly toward the targets on such trajectories; another mode is what you don't have target lock and they just fly so many units forwards and explode either on collision or on timer if they didn't hit anything.
you'd offset it along its forward axis based on the sine wave so you'd achieve a kind of a waving movement pattern, if you combine it with another wave on the other axis which is offset from the first wave it might also look like a spin
it doesn't look like sine wave though in the video
yeah it looks like it flies straight up and then just does some kind of hard banked spin
if you wanted to replicate that exact pattern then you could probably have some kind of a calculation on its position
so how do I move the rocket actor in BP in such manner ?
for example if you calculate a trajectory straight to the target, instead first the projectile flies at an upwards angle
is it just lerp between locations ?
as it reaches the midway of the trajectory, you'd then have it do a spinny move and head down directly on the target point
you might have to experiment a bit to find out what works best
I'd start with something simple, like having it go upwards and then come kind of crashing down from above
then you can start adding into it, so that for example it does that spin as it turns to come down
So I found out why my cast may not be working, When casting to MPS_MasterBP, it seems that after the player respawns the pawn gets changed to MPS_MasterBP1. So that could be causing a issue. Is there any way to cast to that specific actor?
So is it grabbing the parent instead of the child? @neon sorrel
Is it asking the player what class it is then spawn it or is it spawning a set class?
Its just spawning a new class of that same MPS_MasterBP, destroying the old, then possesing the new
Maybe I should destroy the old one before spawning a new one? ๐ค
Probaly because it seems to try and possess the old one when it dies
Ill give that a shot and see hm
Yeah
Bad news, doesnt change anything :/
I don't suppose there is a way to make my static mesh slightly opaque for a few millisecs?
I want like the immune for a few secs effect you see in games after you take damage. But idk if it's possible without changing the entire material.
Set the material render opacity?
Or swap materials
to one with a lower render opacity
@wind void Material opacity is what your looking for
Yea, but is there a way I can set that in blueprints without making a new material and just swapping between the two?
@wind void this might be more of a #graphics question cuz you need to set up a transparent (or masked-opacity) material with a parameter that drives it. On the BP side, you create a Dynamic Material Instance (there's a node for that) and affect the parameters of that material.
The downside is your object will permanently be a transparent material which has performance implications, so using BP to swap between two materials (opaque and transparent) is actually not a bad approach.
This is just IMO. The #graphics channel has more collective experience than me
@wind void Yeah @tight schooner Said it the best, or even if you dont want to do that searching on google, how some people did it will give you a great idea on how to do it
Tried another workaround with that cast, no luck :C
This pending kill thing is such a annoyance
@wind void if you dont want to take a performace hit with transparency could always just flash it white.
@wind void
@neon sorrel when you cast to an class your not selecting a specific one, you are just letting it know its that type. if you need to get a specific one, you can use somting like get all actors of class(bad way) or start tracking your actors in variables for reference.
casts are a bit like a validation, ok that actor is of this type, I can do stuff that class can do and have access to the variables and such that class has
@ocean radish Sorry for the late reply. Thats sorta what im doing, Im casting to the actor and setting it as a variable so I can use it later. But when I respawn it cant cast to that actor anymore for some reason I keep getting pending kill errors.
What exactly are you casting?
Some Variable?
Do you update that variable when you respawn your character?
PendingKill means that you are trying to access a pointer to an Actor that is already marked to be destroyed.
So probably the previous pawn
Im getting a referance to the actor from the player controller, so I can use grab variables from it.
That runs on begin play in the pc
One moment, let me grab a screenshot
I put it into a function to be used later
for ease of use
That's too early
BeginPlay shouldn't have a proper pawn yet
You have other functions for that
Like OnPossess
Which would also call again if you get a new pawn
Was about to ask if there was any node to detect that and yeah forgot about that.
Thats handy
Also, that RPC I see in your screen is kinda wrong
BeginPlay on the PC already calls on Server and the owning Client
Why the RPC then
You can just do "IsLocallyControlled + Branch" and spawn the HUD then
Yeah. I didnt think about that there generally I didnt plan a respawn system much so for solo work It worked enough to spawn a hud that way and I just left it at that.
Has nothing to do with Respawning a HUD
The Logic is wrong to begin with :D
You might even end up spawning two HUDs for Clients
That may be why I was getting a odd blur issue earlier, Had the blur on the hud show up stronger than It should have
I'll look into that some and hook up the appropriate on possess event
I was actually just thinking too. Instead of using get controlled pawn, Couldnt I just use possesed pawn from that event?
Hi guys, i'm messing around with ball physics. I'd like to add a Magnus effect to a ball dependent on where it is hit. To feel like natural and organic, like a tennis ball with effect.
It does not seem easy, and I cannot find exemples on how to do so. Any one would be kind to help ?
Thanks !
I was actually just thinking too. Instead of using get controlled pawn, Couldnt I just use possesed pawn from that event?
Yes, but that should be the same
Alright ill rig some stuff up and try it out. Thank you!
@solemn parcel whats the main thing you want, just the look, so the rotation?
@ocean radish Yeah, the 'air' rotation, not the ground curve used with friction
@ocean radish
in my client level I have openLevel with the IP of the server and on the server I do openLevel of the serverLevel. That does seem to work, the client loads the client level, says he's connecting but everything stays black
@ocean radish I want it to effect the trajectory, yes
Just a normal ServerTravel to the same map should work.
@solemn parcel think thats gonna be pretty hard work, not sure you could even do it in BP properly, beyond me on knowledge on that one
Hm, pretty sure I did that in the past once. You can do that by doing two things, I think:
- Shoot the ball into the new projectile direction, e.g. point you hit to center of the ball.
- In addition to the normal forward movement, apply an additional acceleration to the right/left of it.
@ocean radish Thanks for your help !
@surreal peak 1. I didn't totally got the first point, but should the ball be used as a ProjectileMovement for this ?
- Wouldn't this just push the ball in a certain direction on a straight line ?
@surreal peak I tried that. It seems to load the level but not fresh. I still got units in the level which are then kind of broken
Something like that
I guess if I were to make a proper image, the Green and Red line would point into the same direction on the start
So more like this, ignore the thinner red line
@solemn parcel , well yea, gravity would pull it down to create the arc, then you could add extra acceleration in any axis, then setup some fake rotation, thats actually really good
Idk if there is math to calculate the exact shot power, blue acceleration etc. to hit a point that sits exactly in the green arrow head.
But I assume there is
@surreal peak @ocean radish Appreciate it guys. I'm gonna work on this today. Thanks !
ha i didnt do anything, but no worries heheh
I'm a new, so i'll take some time to understand the meanings of everything and work on it !
@ocean radish You where here to help, that's a already good enough ๐
And yeah, you could use the ProjectileMovementcomponent for this
@surreal peak The projectile movement component does not work with Simulating Physics as far as I know, so makes me really limited on the 'physics' simulation
This is a singleplayer project, right?
Actually no
If not, then forget about Physics
No Physics, at all, despite non-gameplay visual fluff
You can't sync physics over network properly
Good to know ! Thanks !
You can fake a lot of physics by simple vector math
Like the Projectile movement Component can have Gravity added to its velocity
And also bounce off of walls
Without touching actual physics simulations
Yeah i checked all of this
You already gave me enough information for me to work on probably for days
thanks !
Interesting, for some reason I cant get the value of my player ref now in the hud, even though I delay spawning the hud for a few seconds after the player ref is set
Cast goes through just returns null
And if I check if my pawn is locally controlled always returns false, as well. Maybe because its in a player controller? ๐ค
@surreal peak I have this in my game mode. It seems to me the server is travelling but not taking the clients with it
the clients seem to be stuck on the old level
Is the GameMode set to SeamlessTravel?
this happens if seamless is off
and when it's on, it's like nothing happened
like no one travelled
Cmd: servertravel l_testmap
LogPackageName: SearchForPackageOnDisk took 0.044s to resolve l_testmap.
LogGameMode: Warning: CanServerTravel: Seamless travel currently NOT supported in single process PIE.
this is seamless
How would I go about displaying information on a curved screen? I have the following, and would ideally like to be able to display UMG onto it.
@olive sedge Buddy, you can't use SeamlessTravel in the Editor.
That's literally what the message tells you
You have to start a Standalone version of the Game to do that
e.g. rightclick the UPROJECT file and hit LaunchGame.
(or package)
I figured I want non-seamless anyway
Uff, the 3D Widget stuff is basically doing that, but doubt it allows you specifying your own Mesh. I did that once for a Client who wanted to display UMG on a curved screen.
but I'll try a client/server build
But that's ages ago
Are you targeting Steam?
no
Hm okay.
It's generally preferred to use SeamlessTravel
But up to you
Steam requires it
ok
An overview of how travelling works in multiplayer.
When you want to end a multiplayer game, and start a new one
I guess I misinterpreted that
Hmm ok, how complex was it when you set it up?
this is if you want to completely end, I guess
Yeah,
Hm, not sure anymore. The 3D Widget Component is a Mesh Component and they put that Widget on a Mesh. If you have C++ experience, I would look at that.
I think iirc I copied the whole thing into a new component and exposed the mesh or so.
Or maybe just inherit from it. Not sure. Def check your options first
I've got some limited c++ experience, not really enough to make that work though. Other option I was thinking of was using a render target and just displaying that on the mesh
Since it doesn't require 2 way interaction, only displaying information.
Yeah
So you reckon I try and create a new component which is just a duplicate of the widget component and see if I can change the mesh?