Skip to content

Confusion of Utilities.MaxEdictBits #1268

@Yarukon

Description

@Yarukon

Current definition of MaxEdictBits is 15

public const int MaxEdictBits = 15;

but edict can only have 16384 (1 << 14) entities
I think it should be defined like this

// Only for networked entities, which are edicts. There can be more server-only entities that aren't edicts, so this is not the max number of entities in the game, but the max number of edicts.
public const int MaxEdictBits = 14;
public const int MaxEdicts = 1 << MaxEdictBits;

// Counter-Strike 2 - max 16384 edicts and 16384 server-only entities, total 32768 entities, which is 15 bits for the entity index.
public const int MaxEntityBits = 15;
public const int MaxEntities = 1 << MaxEntityBits;

and change all reference from MaxEdicts to MaxEntities (except for CFixedBitVecBase I guess?)

Metadata

Metadata

Assignees

No one assigned

    Labels

    untriagedNew issue has not been triaged

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions