pymasep.interface.ui_merchant ============================= .. py:module:: pymasep.interface.ui_merchant Classes ------- .. autoapisummary:: pymasep.interface.ui_merchant.UIMerchant Module Contents --------------- .. py:class:: UIMerchant(relative_rect, manager, container, item_list, sub_application, object_to_init_name) Bases: :py:obj:`pygame_gui.elements.UIPanel` Interface for selecting objects to buy or to take from a container :param relative_rect: Position and size of the window :param manager: Manager (from pygame_gui) :param container: Container of the UIMerchant (form pygame_gui) :param sub_application: the sub application (interface) that will handle the panel :param object_to_init_name: name of the Object or Agent to init .. py:attribute:: sub_application interface application .. py:attribute:: object_to_init_name name of the agent to initialize container .. py:attribute:: selected_item_to_add :value: [] items to add to the container .. py:attribute:: selected_item_to_remove :value: [] items to remove from the container .. py:attribute:: item_list list of possible items .. py:attribute:: label_pos cost label position .. py:attribute:: costs cost UI label .. py:attribute:: list_objects_rect list of possible items rectangle .. py:attribute:: list_objects UI element of possible items .. py:attribute:: list_objects_chosen_rect chosen objects rectangle .. py:attribute:: list_objects_chosen UI element of chosen items .. py:attribute:: add_button UI button to add items .. py:attribute:: del_button UI button to remove items .. py:method:: process_event(event) process event to launch dices if user press the button. :param event: event that could be a UI_BUTTON_PRESSED :return: True if the event has been processed .. py:method:: update(time_delta) Update the UI element :param time_delta: time delta since last call