
# -> Get banner
item replace block -29999985 2 -29999985 container.0 from entity @s weapon.offhand

# -> Get banner item data
data modify storage overly_realistic:lay_figure_menus banner_item_data set from block -29999985 2 -29999985 Items[{Slot:0b}]

# -> Get banner name
data modify storage overly_realistic:lay_figure_menus banner_item_name set string storage overly_realistic:lay_figure_menus banner_item_data.id 10

# -> Copy over banner_pattern data
#data modify entity 00000001-0000-002b-0000-00010000002b item.components."minecraft:banner_patterns" set from block -29999985 2 -29999985 Items[{Slot:0b}].components."minecraft:banner_patterns"

# -> Set banner type bit
function overly_realistic:players/non_setting_triggers/events/event_100062/set_banner_type with storage overly_realistic:lay_figure_menus

# -> Remove player's banner
item replace entity @s weapon.offhand with air
