Forum rules - please read before posting.

Press X to Talk: Simple Keyboard Interactions?

edited February 2016 in Technical Q&A
I'm toying around with a side-project that uses direct keyboard control and was wondering how much of AC supports keyboard interaction before I need to start custom scripting. The goal is to create an interface similar to the new King's Quest or Grim Fandango, where my character approaches a hotspot before they can use one of the interaction keys.

Presently, I can walk the player over to a cube, where a trigger will detect the player's presence and continuously checks for the E key to start a cut-scene. However, this method has a hard time detecting the input key and I generally have to mash E to make anything happen.

This seems like a fairly rudimentary problem since I've been walking up to NPCs and pressing X to talk since Final Fantasy in the 80's, but any push in the right direction (or the appropriate section in the manual) would be a great help.

Comments

  • AC's well-equipped to emulate Grim Fandango's way of playing.  You'll want your Hotspots to be detected by your player's presence, rather then the mouse cursor.  This'll involve making to your Player prefab, as covered in the tutorial here.

    To trigger a Hotpost interaction with the keyboard, map a key in the Input Manager to an button named "InteractionA", which serves as a left-click.  The Settings Manager lists any available inputs that your game can make use of - including ones to cycle left and right through multiple hotspots and interactions if appropriate.
  • Ah, thanks! At the very least, I got that one interaction to work.

    The rest of my project looks like it'll need a lot of custom scripting to get the interface working, so I should probably buckle down and learn C++ already. :P
  • I've made a little project using AC and the 2D character controller that comes with Unity's standard assets, and even that works pretty well I must say, though using the built-in direct controls should be the best choice, least amount of scripting. Good luck!
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.