Skip to content

Destroying structure by invoking Structure#destroy is not logged by Room#getEventLog #139

Description

@astro-angelfish

The API showed that EVENT_OBJECT_DESTROYED can return the any object in rooms is destroyed. But in engine code the structure destroy can only be logged when it is destroyed by creep or nuke attack (in

eventLog.push({event: C.EVENT_OBJECT_DESTROYED, objectId: target._id, data: { type: target.type }});
). I wonder if i need to spend a lot CPU to check if structure is changed or overwrite the prototype of Structure? Or it is just missing in the structure destroy code?

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

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions