Class Inventory



    Purpose

    To display items taken by the player on a panel.

    Functionality

    Inventory uses Vector to store all the items taken by the player and shows them on the panel. Wheneven the player takes another new item or remove an item or move the scroll bar, it will update and repaint the panel.

    Structure

    Variables

    vt: This is a Vector used to store the items taken by the player.

    InvDisp: The type is InvDisplay.

    Methods

    addItem(mazeObject) : Add an item to the vector and update the canvas.

    removeItem(mazeObject) : Remove an item from the vector and update the canvas.

    See also

    InvDisplay
    InvCanvas




    [Go to Class Index Table] [Go back to Program Architecture Diagram]
    [Source Code of Inventory.java]