How to Simulate Key Press for Scripts?

Started by Ahsipanda on Thu, 08/04/2022 - 07:24

Topic category: Help with MCreator software

Last seen on 09:42, 4. Aug 2022
Joined Aug 2022
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
How to Simulate Key Press for Scripts?
Thu, 08/04/2022 - 07:24

Hi, I'm fairly new to MCreator and I'm not sure how I can create a script with this mod.

Ideally, I'd like it so that it can control the player's movements and keystrokes without the player having to input (say maybe it can walk around a farm for example).

How can I use MCreator to make it so that pressing a key will start running the script so that it will say hold "d" for 10 seconds, then "a" for 10 seconds.

Thanks