Control the movement of characters in the game

I saw a video where a script controls Mario"s automatic customs clearance. How does it control the movement of game characters? Or, how do I tell the progress of the game that I "pressed" a key? I am very interested in this, but I have no contact with the relevant content, so I am not very familiar with it.
are there any related class libraries or materials to learn? Thank you, boss.
expected language: nodejs (preferably) python (next)

Jun.09,2022

http://robotjs.io/docs/examples can use this node library, hoping to help you


currently find the way that python uses the pywin32 library to send keystroke information; nodejs did not find the relevant library, so it seems that nodejs can be extended through c/cPP to write plug-ins such as pywin32 for nodejs.

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1e87c19-46c5b.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1e87c19-46c5b.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?