Forum rules - please read before posting.

Custom Input Problem (Left Mouse/Right Mouse)

edited June 2018 in Technical Q&A
I followed the tutorial on input overrides but it only caused AC to make me keep defining controls that I don't want in my game at all, like Cursor Toggle and FlashHotspots. I added InteractionA, mapped to 'e'. No problems there. I added ToggleRun. Both I did with the Unity Input Manager. Now, what I want is to play my custom attack animation with Mouse 0, and my custom block with Mouse 1. I obviously don't want any other type of interactions to occur with left or right mouse click. I made the input override script:
public string swordAttack = "lclick";
public string swordBlock = "rclick";

I added the delegate to Start(). The CustomGetButtonDown function returns swordattack if I press Fire1. What am I missing now, to make this start to work?

I just want E to talk and open doors, drink from wells, ect. Hotspot key basically... Then Left to attack, right to block, and nothing more. I'm fine turning off Fire1 and Fire2 for use in AC. I use it in a different script which is my weapons script which uses inputgetkeydown.

edit: I forgot to add that I did create an empty Manager Object and attached this script, and changed my public variables. Assume inputs are defined is UNCHECKED.


  • Nevermind. There is a setting in the AC editor that I unticked called 'left and right mouse buttons have default functionality'. I solved the problem by unticking those.
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.