Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Putting server character into ragdoll causes camera issue on client

So... Been messing around with this for a bit now. Tried a number of different methods but basically I cannot get this setup to work. This is the closest I've got... The client can ragdoll just fine, and it shows up on both server and client instances. But when the server ragdolls, it shows up, but causes the client's camera to go nuts.

Any help would be great...

Gif of what happens here: (watch the client instance on the right when the server dies on the left)


And my blueprint logic for this stuff is currently:

Some blueprint graph stuff

For the record - I'm aware I probably shouldn't be multicasting from a RepNotify... but when I don't multicast and either have the SetRagdoll event to Not Replicated, or even just try to set the Simulate Physics within the RepNotify function, I get this result:

https://gfycat.com/InfamousOblongFieldspaniel Note - in this gif the event is set to Not Replicated, but the same result happens if I just move the logic within the RepNotify function.

Product Version: UE 4.12
rdshit.png (187.7 kB)
more ▼

asked Jun 26 '16 at 07:07 PM in Blueprint Scripting

avatar image

6 2 4

avatar image Mithlin Jun 26 '16 at 09:43 PM

I have not messed with this, so I am no expert. I have a few questions & perhaps can help find a solution...

Do you receive any errors in the Output when this ragdoll camera issue occurs?
- It looks like the default camera location either didn't work (failed placement & arbitrarily picked a new and bad location) - Or it's location is based on the character skeleton (origin point?) & for some reason the server ragdoll supplies a bad camera location in this replicated situation to the client (since client-only works fine). - Without errors, this may be hard to track down... but a theory, nonetheless.

One way to make a 'Work-around' may be to build a specific camera script that handles the Player ragdoll: - On Player Ragdoll - Swap camera to previously inactive "Ragdoll camera" (made from a duplicate of the current camera?) - When Player "resumes play" ensure the original non-Ragdoll camera is active & Ragdoll camera is deactivated. - Note: This may allow you to control how the camera behaves on ragdoll; such as a slow pan-away or any other animation to help support the "Game Over: Ragdoll Time" moment, etc.

Good luck & hope this helps. :-) - Mithlin

avatar image apoisonedgift Jun 27 '16 at 04:57 AM

So I do get some errors actually now that I look. Basically there is still some linetraces drawing from the player camera. On the client, these bug out because they can't find the player camera anymore. So it seems that setting ragdoll on the server removes the camera from the client... This is feeling more and more like a bug =/

I will give your work around a shot, though it doesn't quite make sense to me :P Will see what I can do though.

avatar image Mithlin Jun 27 '16 at 05:19 AM

Hmm well, that line-trace failing is odd. Does that error mention anything specific, an actor & component(s) that fail? The character you're using likely has a camera attached to a boom (spelling? - moves the camera closer when it bumps into a wall, etc.) and it may be the boom isn't handled well on the client when a server-triggered ragdoll occurs. This may not be a bug, but an implementation problem on your side. Ragdoll is tricky business, as is server stuff, and you're attempting to do double tricky business. ;-)

Perhaps settings in the player's camera boom component may help, or somehow disable camera boom from impacting the camera on ragdoll.

avatar image apoisonedgift Jun 27 '16 at 09:25 AM

You sir are a genius XD If I put my client into first person mode, the issue doesnt happen... so now I just gotta try and find a work around for that haha. No idea what I'll do there... but that's the beginnings of an answer!

EDIT: Scratch that. I'm an idiot. This reply was premature lol. That doesn't fix it. Still testing.

avatar image apoisonedgift Jun 27 '16 at 09:37 AM

So, ignoring my last comment... the errors that come up are basically suggesting there is no character attached to a controller anymore, like the simulate physics node un possesses the character or something. Most of them are saying that the character ref variable is 'none', and one says something about cannot do widget actions as there is no player attached to the controller. Again, these only come up when the server player goes ragdoll.

I tried using a hovering camera behind the player, rather than the camera boom. Same thing still happens. The camera appears to just move to the ground and can no longer be manipulated.

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

1 answer: sort voted first

Okay... so I tried it out in a few blank projects and it worked... but the catch is - if I try to run the simulate physics from the CONTROLLER it doesn't work. Run it from the CHARACTER and it's fine =/ I have no idea why. Ideally I want to keep as much of my logic as possible in the controller but this is a workaround for now at least. Thanks for your help. If you have any idea why this might be the case that'd be helpful lol but I'll mark this as solved for now I guess.

more ▼

answered Jun 27 '16 at 09:53 AM

avatar image

6 2 4

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question