matrx.api.api

Functions

change_MATRX_speed(tick_dur)

Change the tick duration / simulation speed of MATRX

fetch_context_menu_of_other()

Fetch the context menu opened for a specific object/location of the agent being controlled by the user.

fetch_context_menu_of_self()

Fetch the context menu opened for a specific object/location of the agent being controlled by the user.

get_filtered_latest_state(agent_ids)

Return a state for a set of agent IDs, filtered to only return the specified properties

get_info()

Provides the general information on the world, contained in the world object.

get_latest_state(agent_ids)

Provides the latest state of one or multiple agents

get_latest_state_and_messages()

Provides all most recent information from MATRX for 1 agent: The state from the latest tick, and any new messages and chatrooms.

get_messages_apicall()

Returns chatrooms and chat messages for one agent, or all agents.

get_states(tick)

Provides the states of all agents (including the god view) from tick tick onwards to current tick.

get_states_specific_agents(tick, agent_ids)

Provides the states starting from tick tick to current_tick, for the agents specified in agent_ids.

pause_MATRX()

Pause the MATRX simulation

send_message()

Send a message containing information to one or multiple specific agent, the agent’s team, or all agents.

send_message_pickled()

This function makes it possible to send a custom message to a MATRX agent via the API as a jsonpickle object.

send_userinput(agent_ids)

Can be used to send user input from the user (pressed keys) to the specified human agent(s) in MATRX

shutdown()

Shuts down the api by stopping the Flask thread

start_MATRX()

Starts / unpauses the MATRX simulation

stop_MATRX()

Stops MATRX scenario