Difference between revisions of "ISKernel:keyboard (Object Type)"
Jump to navigation
Jump to search
m (ISKernel:keyboard (Data Type) moved to ISKernel:keyboard (Object Type)) |
|||
(6 intermediate revisions by 3 users not shown) | |||
Line 1: | Line 1: | ||
== Description == | == Description == | ||
− | + | The data type for keyboard control. The methods for this data type sends the emulation directly to the game bypassing all IS UI elements(e.g. console, user made UIs). | |
== Members == | == Members == | ||
* [[DataType:string|string]] '''System''': Name of the currently active system for keyboard input (DirectInput, Win32I) | * [[DataType:string|string]] '''System''': Name of the currently active system for keyboard input (DirectInput, Win32I) | ||
+ | * [[ISSession:bind (Data Type)|bind]] '''Bind['''name''']''': Retrieves the bind with the given name | ||
== Methods == | == Methods == | ||
− | |||
*'''Press['''key''']''': Presses and immediately releases a key | *'''Press['''key''']''': Presses and immediately releases a key | ||
*'''Hold['''key''']''': Presses and holds a key | *'''Hold['''key''']''': Presses and holds a key | ||
*'''Release['''key''']''': Releases a held key | *'''Release['''key''']''': Releases a held key | ||
*'''Type['''text''']''': Types some text | *'''Type['''text''']''': Types some text | ||
+ | *'''Bind['''name''','''key combination''','''command''']''': Binds a command to a key combination, with a given name (see [[ISSession:Bind (Command)|Bind command]]) | ||
+ | *'''Bind['''-press|-release''','''name''','''key combination''','''command''']''': Binds a command to a key combination, with a given name (see [[ISSession:Bind (Command)|Bind command]]) | ||
+ | :'''Note:''' -press or -release is an optional first argument, default will be release if not given | ||
== Returns == | == Returns == | ||
Line 15: | Line 18: | ||
== Examples == | == Examples == | ||
+ | ===Press a key=== | ||
+ | *Keyboard:Press[w] | ||
+ | :This will '''Press''' and release w immediately | ||
+ | ===Hold a key down=== | ||
+ | *Keyboard:Hold[w] | ||
+ | :This will '''Hold''' down the w key until released | ||
+ | ===Release a key=== | ||
+ | *Keyboard:Release[w] | ||
+ | :This will '''Release''' the w key | ||
+ | ===Type some text=== | ||
+ | Keyboard:Type[french toast is yummy] | ||
+ | :This will '''Type''' "french toast is yummy" to the session (will NOT hit enter) | ||
+ | ===Display the currently active system for keyboard input=== | ||
+ | *echo ${Keyboard.System} | ||
+ | ;Output | ||
+ | Win32I | ||
+ | ===Create a Bind command=== | ||
+ | *Keyboard:Bind[fullscreenkey,Shift+Alt+F,fullscreen] | ||
+ | == See Also == | ||
+ | *[[LavishScript:Data Types|Data Types]] | ||
+ | *[[IS:Kernel#Data_Types|Kernel Data Types]] | ||
− | |||
− | |||
− | |||
{{DT-Stub}} | {{DT-Stub}} | ||
+ | [[Category:Inner Space]] | ||
+ | [[Category:Inner Space Kernel]] | ||
+ | [[Category:Inner Space Kernel Data Types]] |
Latest revision as of 00:58, 15 May 2006
Contents
Description
The data type for keyboard control. The methods for this data type sends the emulation directly to the game bypassing all IS UI elements(e.g. console, user made UIs).
Members
- string System: Name of the currently active system for keyboard input (DirectInput, Win32I)
- bind Bind[name]: Retrieves the bind with the given name
Methods
- Press[key]: Presses and immediately releases a key
- Hold[key]: Presses and holds a key
- Release[key]: Releases a held key
- Type[text]: Types some text
- Bind[name,key combination,command]: Binds a command to a key combination, with a given name (see Bind command)
- Bind[-press|-release,name,key combination,command]: Binds a command to a key combination, with a given name (see Bind command)
- Note: -press or -release is an optional first argument, default will be release if not given
Returns
Same as System
Examples
Press a key
- Keyboard:Press[w]
- This will Press and release w immediately
Hold a key down
- Keyboard:Hold[w]
- This will Hold down the w key until released
Release a key
- Keyboard:Release[w]
- This will Release the w key
Type some text
Keyboard:Type[french toast is yummy]
- This will Type "french toast is yummy" to the session (will NOT hit enter)
Display the currently active system for keyboard input
- echo ${Keyboard.System}
- Output
Win32I
Create a Bind command
- Keyboard:Bind[fullscreenkey,Shift+Alt+F,fullscreen]
See Also