Forum rules - please read before posting.

Double clicking to exit room immediately problems

Hi I have a problem with using double click to run interactions on room exits immediately. I have the walk to marker set on the hotspot and not in the interaction, so that the player can change their mind about clicking on an exit and not get locked into the animation, then in the action list I have an input check to see if it was double clicked, if not run the normal sequence of walking to the door, character animation, door sound and finally scene switch, but if it was a double click it goes immediately to scene switch. It works fine but the problem is because there is a walk to marker defined on the hotspot you can very briefly see the character teleport to that spot before the scene switches. Am I doing something wrong? Any help would be very appreciated

Comments

  • What about making a Camera Fade the Scene-Switch before the Teleporting and even puttng a "wait" before it so it masks it even more?

  • Thanks Sound_power, yeah I tried that, it still shows him momentarily teleport to the door, I guess it's because the walk to marker is on the hotspot so he does that before even going through the action list :(

  • Yes - if the Interaction is run instantly due to double-clicking, the Player is teleported to the Walk-to Marker before the Interaction is run.

    I can look into making this behavior optional, however.

  • Thank you Chris, that would be great!

  • Hi Chris sorry to bump this again, I was wondering if there is anything I could do for this issue myself locally? I'm in a polishing phase and everything else is going great but this is the last thing that looks a bit janky, double clicking on 'open' scene exits is fine, it just immediately changes scene, but with doors he teleports to the door marker first and you see it for a split second. I wouldn't want to somehow make it skip directly to scene swap though as there are other things being set before that, so just not teleporting to the marker would be best. Is there anything I could do myself? Thanks Chris

  • edited August 2022

    The behaviour was made optional in v1.75.6:

    • Added: Option to prevent the Player from snapping to a Hotspot's Walk-to Marker in the event of double-clicking
  • Awesome, thank you Chris!

  • Hi Chris, just bumping this again (after more than a year!) I have come back to this issue as I never got around to it before because updating AC breaks my character every time! I'm in a final polishing phase now prior to the release of the demo. I was just wondering if I might be able to manually add that feature to my version of AC locally? I am using v1.60.4

  • Are you looking to make this optional per-Hotspot, or can the snapping be disabled for all Hotspots when double-clicking?

  • Hi Chris, On my scene hotspots I have them set to double clicking does nothing, but for the ones for doors and exits I have those set to Triggers Interaction instantly, would everything still work in that way if snapping is disabled for all hotspots? All of them are set up with a walk to marker, in case the player changes their mind and clicks something else

  • edited December 2023

    It'll bit hacky, as the difference between versions is great - but try this.

    Open up PlayerInteraction.cs and insert the following into line 946:

    bool skipSnapping = (button.playerAction == PlayerAction.WalkToMarker && !button.isBlocking && doSnap);
    

    Then replace (further down):

    KickStarter.player.Teleport (targetPos);
    

    with:

    if (!skipSnapping) KickStarter.player.Teleport (targetPos);
    

    And replace (the first instance of):

    KickStarter.player.SetLookDirection (lookVector, true);
    

    with:

    if (!skipSnapping) KickStarter.player.SetLookDirection (lookVector, true);
    
  • Wow that works perfectly! a very nice smooth transition between scenes now. Always such amazing support for AC, thank you so much Chris!

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Welcome to the official forum for Adventure Creator.