Internet/Local/Hotseat working (still need to test for bugs). ALso get an RPC error because we switch scene...
This commit is contained in:
parent
c95b8186ab
commit
c4909db2a5
654 changed files with 18133 additions and 39 deletions
24
addons/awesome_input_icons/classes/InputIconTextureRect.gd
Normal file
24
addons/awesome_input_icons/classes/InputIconTextureRect.gd
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
## This is a textureRect that takes an action name and automatically loads the proper icon
|
||||
class_name InputIconTextureRect extends TextureRect
|
||||
## The name of the action, it has to exist in the InputMap
|
||||
|
||||
## The name of the action in your InputMap, it has to be an existing action
|
||||
@export var action_name: StringName = &"":
|
||||
set(value):
|
||||
action_name = value
|
||||
_update()
|
||||
|
||||
## The Index of the event, if you have more than one event in the same action.
|
||||
## You can use negative numbers but not a number bigger than the number of events
|
||||
@export var event_index: int = 0:
|
||||
set(value):
|
||||
event_index = value
|
||||
_update()
|
||||
|
||||
|
||||
func _ready():
|
||||
_update()
|
||||
|
||||
|
||||
func _update():
|
||||
texture = InputIcon.get_icon(action_name, event_index)
|
||||
Loading…
Add table
Add a link
Reference in a new issue