> cat /wizhelp/rooms
> _
======================================================================== Room Creation Basics ======================================================================== Rooms are the fundamental building blocks of areas in PKWAR. BASIC ROOM STRUCTURE: ```python from lib.models.entity import Room, Exit from lib.models.enums import ExitType def load(): return Room( name="unique_room_id", description="What players see when entering.", short_description="Brief mode description" ) ``` ROOM TYPES: Room - Standard room RandomRoom - Drops items on entry SearchRoom - Players can search for items Shop - Buy/sell functionality ADDING EXITS: ```python room.exits = [ Exit("north", "destination_room_id"), Exit("east", "another_room", ExitType.DOOR), Exit("secret", "hidden_room", ExitType.HIDDEN) ] ``` EXIT TYPES: - PATH: Normal passage (default) - DOOR: Can be opened/closed/locked - HIDDEN: Must be searched for DESCRIPTION ITEMS: ```python from lib.models.entity import DescriptionItem room.description_items = [ DescriptionItem( name="fountain", aliases=["water", "pool"], description="Crystal clear water flows endlessly." ) ] ``` RANDOMROOM EXAMPLE: ```python from lib.special_rooms import RandomRoom room = RandomRoom( name="treasure_vault", description="A glittering treasure chamber.", drop_chances={ 'coins': 70, # 70% chance 'weapon': 15, # 15% chance 'armor': 10, # 10% chance 'healing': 5 # 5% chance }, base_coin_range=(500, 1500) ) ``` SEARCHROOM EXAMPLE: ```python from lib.special_rooms import SearchRoom room = SearchRoom( name="ancient_library", description="Dusty tomes line the walls.", search_items=[ ('teleporter', 'mike/tele'), ('heal_200', None), ('coins_500', None) ] ) ``` SPECIAL FLAGS: - no_teleport: Blocks all teleportation - light_level: 0-100 (affects visibility) - area_name: Groups rooms into areas FILE NAMING: Save as: /lib/wizrooms/<yourname>/<filename>.py Example: /lib/wizrooms/gandalf/tower_entrance.py ========================================================================
> _