Skip to content

carryRefusal beta ​

Function of @v12-engine/engine

ts
export declare function carryRefusal(world: World, carrier: Entity, item: string, uses?: readonly string[], handed?: boolean): Message | undefined;

Why a carrier may not take an item, or nothing when it may: one more of its group than it may carry (ItemDef.group), or what the game's own rule says (ItemSettings.mayCarry). uses, the parts buying it uses up, by id: they go out as it comes in. handed: it is handed over, and the words say "they". Asked as an item is bought, picked up or handed over; room in the inventory is asked apart (hasRoomFor)