Skip to content

Improve compatibility with fast enter playmode #6

@QFSW

Description

@QFSW

Currently, the pool is initialized/cleansed on EditorApplication.playModeStateChanged for the case EnteredPlayMode
This can be somewhat problematic, as if GetObject is called on the first frame of the game, this happens before the event, and thus the pool won't be cleansed yet (resulting in warnings about null objects in the pool)

Furthermore, this means the auto initialize option actually takes a frame too long to kick in, which means that IPoolables may not be initialized

The first problem can be remedied by moving the cleanse into ExitingEditMode, not sure about the second

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions