MCPcopy Create free account
hub / github.com/Virtual-Protocol/virtuals-python / throw_furniture

Function throw_furniture

examples/game/test_agent.py:125–136  ·  view source on GitHub ↗

Function to throw furniture.

(object: str, **kwargs)

Source from the content-addressed store, hash-verified

123 return FunctionResultStatus.ERROR, f"Cannot throw {object} - not a fruit", {}
124
125def throw_furniture(object: str, **kwargs) -> Tuple[FunctionResultStatus, str, dict]:
126 """
127 Function to throw furniture.
128 """
129 furniture = {"chair", "table", "stool", "lamp", "vase", "cushion"}
130
131 if not object:
132 return FunctionResultStatus.ERROR, "No furniture specified", {}
133
134 if object.lower() in furniture:
135 return FunctionResultStatus.DONE, f"Powerfully threw the {object} across the room!", {}
136 return FunctionResultStatus.ERROR, f"Cannot throw {object} - not a furniture item", {}
137
138
139# create functions for each executable

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected