Questions about having a NPC move between scenes

  • #20, by irinahuw_Tuesday, 29. May 2018, 15:50 6 years ago
    thank you so much for your patience and help!
    Yeah, set = teleport. It seems you are telling the character to walk somewhere first & then teleporting the character when it reaches the destination, which is correct if you want it to walk somewhere first. Now the question is: can the character actually reach the destination position?
    i added a picture again for this, because i cannot make it work. first i send the character (only "biber" now, no other characters involved) to the scene border and then i set it to another scene, as you can senn in the picture. imo the character should activate its walk animation and go to the position i am telling it and then change scenes. but instead it stays in its standing animation and weirdly hovers over the scene to the position... what could it be? i do have assigned all walk animations in the character tab.
    Also, I'm confused as to why you are using multiple outfits. Each outfit has built in idle, walk, talk & random animation sections. They also have a character animation section which allows you to add animations that should be played manually via the play animation action part or via Lua script with the startAnimation() function.
    the many outfits come from trying out a lot of option whenever something did not work, xD
    but i am using now only the character "biber".

    and for the dialogues: definitely need to have a closer look at them, i have set them up very roughly for now. thank you!


    Newbie

    49 Posts


  • #21, by sebastianTuesday, 29. May 2018, 15:53 6 years ago
    The "hovering" could only come from the walk animation. Maybe the direction for the "right" walk animation is not set correctly or another animation above in the list is set to right but has no moving frames.

    Did the "Biber" at least teleports to the new location after he reaches it?

    Thread Captain

    2346 Posts

  • #22, by irinahuw_Tuesday, 29. May 2018, 16:02 6 years ago
    The "hovering" could only come from the walk animation. Maybe the direction for the "right" walk animation is not set correctly or another animation above in the list is set to right but has no moving frames.

    Did the "Biber" at least teleports to the new location after he reaches it?
    Of course you are right, it had to do with my weird outfit management. Had some old outfits which i deleted now.*facepalm*
    And yes, teleport works fine so far!

    Thank you guys, learned a lot about visionaire again!

    Newbie

    49 Posts

  • #23, by irinahuw_Wednesday, 30. May 2018, 11:20 6 years ago
    hello, it's me again :,|

    i have another question:

    when the NPC switches scenes but the player/maincharacter overtakes the NPC and changes the scene before the NPC, the NPC does not show up at all.

    is there a way to avoid this? i would be fine with something like "blocking" the maincharacter/player to do anything & wait for the NPC to leave.

    Newbie

    49 Posts

  • #24, by afrlmeWednesday, 30. May 2018, 12:16 6 years ago
    you cn prevent player interaction by wrapping action parts inside of begin/end cutscene action parts or hide/show cursor action parts. The former can be skipped with the ESC key on your keyboard & the latter disables all key input.

    Now you have to keep in mind if you use begin/end cutscene wrappers that you don't update positions, conditions or values inside of them because if the player skips them before the engine has updated them then they don't get changed. You could include the send character to position inside of the cutscene wrapper & add the set position action part afterwards to force them to the new position in case the player skipped the walking part.

    begin cutscene
     send character to x, y position and wait
    end cutscene
    set character position or set character to object

    for hide show cursor it doesn't matter if you place all action parts inside because it's an unskippable cutscene.

    hide cursor
     send character to x, y position and wait
     set character position or set character to object
    show cursor

    Imperator

    7278 Posts