feat: Add core manager scripts for camera context, player input, special tiles, and a powerup inventory UI.
This commit is contained in:
@@ -97,22 +97,22 @@ func handle_unhandled_input(event):
|
||||
KEY_KP_1, KEY_1, KEY_KP_2, KEY_2, KEY_KP_3, KEY_3, KEY_KP_4, KEY_4:
|
||||
var mode = LobbyManager.get_game_mode()
|
||||
var is_restricted = GameMode.is_restricted(mode)
|
||||
match event.keycode:
|
||||
KEY_KP_1, KEY_1:
|
||||
player.activate_powerup(0) # FASTER_SPEED
|
||||
KEY_KP_2, KEY_2:
|
||||
if is_restricted:
|
||||
player.activate_powerup(1) # AREA_FREEZE (Restricted)
|
||||
else:
|
||||
player.activate_powerup(2) # BLOCK_FLOOR (Free)
|
||||
KEY_KP_3, KEY_3:
|
||||
if is_restricted:
|
||||
player.activate_powerup(3) # INVISIBLE_MODE (Restricted)
|
||||
else:
|
||||
player.activate_powerup(1) # AREA_FREEZE (Free)
|
||||
KEY_KP_4, KEY_4:
|
||||
if not is_restricted:
|
||||
player.activate_powerup(3) # INVISIBLE_MODE (Free)
|
||||
if is_restricted:
|
||||
match event.keycode:
|
||||
KEY_KP_1, KEY_1:
|
||||
player.activate_powerup(0) # FASTER_SPEED
|
||||
KEY_KP_2, KEY_2:
|
||||
player.activate_powerup(3) # INVISIBLE_MODE (Ghost is now 2)
|
||||
else:
|
||||
match event.keycode:
|
||||
KEY_KP_1, KEY_1:
|
||||
player.activate_powerup(0) # FASTER_SPEED
|
||||
KEY_KP_2, KEY_2:
|
||||
player.activate_powerup(2) # BLOCK_FLOOR
|
||||
KEY_KP_3, KEY_3:
|
||||
player.activate_powerup(1) # AREA_FREEZE
|
||||
KEY_KP_4, KEY_4:
|
||||
player.activate_powerup(3) # INVISIBLE_MODE
|
||||
# KEY_R:
|
||||
# player.auto_put_item()
|
||||
KEY_Q:
|
||||
|
||||
Reference in New Issue
Block a user