Announcement

Collapse
No announcement yet.

Changing Movement Mode of one character affects other characters

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Changing Movement Mode of one character affects other characters

    Hi everyone,

    I'm working on a game where you can switch between 3 characters at any point during runtime. The 3 characters are children of a master character BP and share the same functionality. This master character BP is based on the ThirdPersonBP from the normal template.

    I have a CharacterSelect blueprint with the following functionality:

    Click image for larger version

Name:	Switch2.jpg
Views:	1
Size:	101.0 KB
ID:	1205417

    On Event Begin Play I get the references to all characters in the level like this:
    Click image for larger version

Name:	Switch1.jpg
Views:	1
Size:	170.5 KB
ID:	1205418

    Then when the Player presses 1,2 or 3, it possesses the appropriate pawn:
    Click image for larger version

Name:	Switch3.jpg
Views:	1
Size:	240.5 KB
ID:	1205419

    I also have a simple water blueprint that changes the Movement Mode of the Character on overlap:
    Click image for larger version

Name:	Water.jpg
Views:	1
Size:	233.3 KB
ID:	1205420

    Here's the issue:

    When Movement Mode for one character changes, the Movement Mode for the other 2 changes as well as soon as I possess them! If I jump and switch in mid air, the character STAYS in mid air. If I set the Movement Mode of one character to Swimming...the Movement Mode of any possessed pawn will also change to Swimming.

    Is as if the Character Movement that I reference is changing at the parent level and not the child level (even if I specifically reference the child)

    Please take a look at this 1min video to see what I'm talking about:


    Can anyone tell me what Im doing wrong here? I want to have one character swim, while the others walk / jump independently.

    Really appreciate any help!

    Thanks!

    -J
    [WIP] Procedural City Generator | RPG AI
    [MARKETPLACE] Animal Behavior Kit | Space Shooter Template | Procedural Foliage Tool | Procedural Park
    [FREE] Modular Road Tool | Action Platformer Template | Radar BP | Free Birds | Procedural Buildings
    Join our Discord

    #2
    Sorry, I'm not going to be much help in this area. However, you could really make one unique game with those "features"

    Found this on answerhub, but it's yet unanswered: https://answers.unrealengine.com/que...haracters.html

    Edit: Also found this, which might be worth checking out: https://answers.unrealengine.com/que...en-not-po.html
    Last edited by Amsirahc; 01-13-2017, 03:19 PM. Reason: More Information

    Comment


      #3
      Originally posted by Amsirahc View Post
      Sorry, I'm not going to be much help in this area. However, you could really make one unique game with those "features"

      Found this on answerhub, but it's yet unanswered: https://answers.unrealengine.com/que...haracters.html

      Edit: Also found this, which might be worth checking out: https://answers.unrealengine.com/que...en-not-po.html
      Thanks for the links Amsirahc. In one of the threads they solved my "falling problem" by checking "Run physics with no controller" on the Movement Component. I also tried assigning an AI controller and that worked too!

      I'm still having the issue of the Movement Mode being shared between characters. I got an answer from another user in the Answer Hub - it looks like the Character class shares its movement mode among all children. If this is the case, then its not possible to have a character swim while another runs .

      If anyone has found a workaround for this, please let me know!

      Thanks!
      [WIP] Procedural City Generator | RPG AI
      [MARKETPLACE] Animal Behavior Kit | Space Shooter Template | Procedural Foliage Tool | Procedural Park
      [FREE] Modular Road Tool | Action Platformer Template | Radar BP | Free Birds | Procedural Buildings
      Join our Discord

      Comment


        #4
        Glad I could at least help find a partial solution!

        Originally posted by CoquiGames View Post
        If this is the case, then its not possible to have a character swim while another runs .
        That really sucks! Are you able to change your Cast to ThirdPersonCharacter to Cast to Player Character (your child actor class)?

        Comment


          #5
          Originally posted by Amsirahc View Post
          Glad I could at least help find a partial solution!

          That really sucks! Are you able to change your Cast to ThirdPersonCharacter to Cast to Player Character (your child actor class)?
          I tried changing the cast to the individual characters (children) and it didnt work. I even tried resetting the movement mode on character switch and it didnt solve it either. I decided to restrict the switch only when all characters are idle to avoid the issue. Not the best solution but it works for now .

          Here is the end result, if you are interested:




          If anyone is interested in getting the code to do this, you can download the template and take a look at how I solved it - https://forums.unrealengine.com/show...ion-Platformer
          [WIP] Procedural City Generator | RPG AI
          [MARKETPLACE] Animal Behavior Kit | Space Shooter Template | Procedural Foliage Tool | Procedural Park
          [FREE] Modular Road Tool | Action Platformer Template | Radar BP | Free Birds | Procedural Buildings
          Join our Discord

          Comment


            #6
            I'm bumping this thread because this bug still exists. In my case, I'm setting the player to Swim when entering the swimming volume. The bug is that it sets ALL players to swimming, even if they're not connected (connecting clients have their movement mode set to Swimming over and over).

            So the bug is that when the Movement Mode is changed, it's affecting ALL clients in the game. I'll submit this later, but it's really easy to test for yourself, I got this bug happening on a new blank project.

            Comment

            Working...
            X