[logic]
active = ph_button@has_card

[ph_button@has_card]
anim = idle
tooltip = tip_open_key_three
on_press = ph_button@need_card %=remove_item_no_news(key_number_three) +key_number_three_done% 

[ph_button@need_card]
anim = idle
tooltip = tip_need_access_card
on_press = ph_button@need_card
on_info = {+actor_has_lim_teleport_card} ph_button@actor_card

[ph_button@actor_card]
anim = idle
tooltip = tip_need_access_card
on_press = ph_code@locked_up %=remove_item(lim_teleport_access_card)%

[ph_code@locked_up]
code = 161188
on_code = ph_button@unlocked %+start_scene_lim_teleport_x5%
tips = jup_b205_tip_door_decode

[ph_button@unlocked]
anim = idle
tooltip = st_lx8_button_press_true
on_info = {+open_door_lim_teleport_x5} ph_button@no_card %=anim_obj_forward(redlim_door_3)%

[ph_button@no_card]
anim = idle
tooltip = st_lx8_button_press_true
on_press = ph_button@no_card
on_info = {+close_door_lim_teleport_x5} ph_button@locked %=anim_obj_backward(redlim_door_3)%

[ph_button@locked]
anim = idle
tooltip = tip_need_access_card
on_press = ph_button@locked
