enzodine

I have problem to create public void in gunmaninput script,
I want to call attack, jump and other using game object button.

and not use keyboard or mouse control

please help me
enzodine
Posts: 2

Mitch

For using GameObject buttons with the Gunman/Hitman asset packs, I strongly suggest using the InControl Unity Package.

Each input scripts contains optional compiler directives for InControl and Rewired control schemes.

#if IN_CONTROL
using InControl;
#elif REWIRED
using Rewired;
#endif

Define either InControl or Rewired globally using the Scripting Defines field in Unity's Player Settings, or define it at the top of each Input script (ie: GunmanInput.cs)

This method is best because you can seamlessly switch between On Screen controls and Bluetooth Gamepad controls.

InControl in particular has excellent support for on-screen buttons for Mobile games. It is what I use myself! :)
User avatar
Mitch

Mitch
Posts: 970


Return to Unity