Ignore:
Timestamp:
Sep 13, 2010, 1:24:54 AM (11 years ago)
Author:
sam
Message:

Allow for different priorities in game and draw tick levels.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/entity.h

    r170 r210  
    2424
    2525protected:
    26     typedef enum
    27     {
    28         GROUP_BEFORE = 0,
    29         GROUP_DEFAULT,
    30         GROUP_AFTER,
    31         GROUP_DRAW_CAPTURE,
    32         // Must be the last element
    33         GROUP_COUNT
    34     }
    35     Group;
    36 
    3726    Entity();
    3827    virtual ~Entity();
    3928
    4029    virtual char const *GetName();
    41     virtual Group GetGroup();
    4230
    4331    virtual void TickGame(float deltams);
    4432    virtual void TickDraw(float deltams);
    4533
    46     Entity *next, *autonext;
     34    Entity *gamenext, *drawnext, *autonext;
    4735    int ref, autorelease, destroy;
     36
     37    enum
     38    {
     39        GAMEGROUP_BEFORE = 0,
     40        GAMEGROUP_DEFAULT,
     41        GAMEGROUP_AFTER,
     42        // Must be the last element
     43        GAMEGROUP_END
     44    }
     45    gamegroup;
     46
     47    enum
     48    {
     49        DRAWGROUP_BEFORE = GAMEGROUP_END,
     50        DRAWGROUP_DEFAULT,
     51        DRAWGROUP_HUD,
     52        DRAWGROUP_CAPTURE,
     53        // Must be the last element
     54        DRAWGROUP_END
     55    }
     56    drawgroup;
     57
     58    static int const GAMEGROUP_BEGIN = 0;
     59    static int const DRAWGROUP_BEGIN = GAMEGROUP_END;
     60    static int const ALLGROUP_END = DRAWGROUP_END;
    4861
    4962#if !FINAL_RELEASE
Note: See TracChangeset for help on using the changeset viewer.