Skip to content

Feature Request: Expose Loot object from GameObject #365

Description

@dustyman145

Currently, GameObject only exposes AddLoot(...), while Creature exposes the full Loot object through GetLoot().
This creates an inconsistency in the API and unnecessarily limits what can be done with GameObject loot from Lua.

With the current design, Lua scripts can only add item entries to a GameObject through AddLoot(...).

That means:

  • no direct access to the underlying Loot object
  • no ability to call existing Loot methods such as SetMoney(...)

Proposed change:

  • Replace AddItem(...) with GetLoot(...)

Alternatively, AddItem(...) can be kept for backward compatibility.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions