Skip to content

Improve entity type confusion in the code base #103

@garsipal

Description

@garsipal

To reduce confusion and clearly differentiate between static and dynamic entities in the codebase, establish naming conventions for each type and their derivatives.

Static Entities

Static entities are map-based. These include models, decals, particles and item pickups that populate an environment.

Current references in the code:

  • entity
  • extentity
  • gameentity
  • server_entity
  • gentities

Dynamic Entities

Dynamic entities include players, NPCs, movable props and projectiles.

Current references in the code (hierarchy):

  • physent
    • dynent
      • gameent
        • monster
      • ProjEnt

Issue

Improve clarity and reduce ambiguity. Use a consistent prefix to separate static and dynamic entities?

Suggested names:

Static Entities

  • entity -> MapProp
  • extentity -> EditorProp
  • gameentity -> GameProp
  • server_entity -> ServerProp
  • gentities -> GameProps

Dynamic Entities

  • physent -> Entity
    • dynent -> Actor
      • gameent -> Player
        • monster -> Npc
      • ProjEnt -> Projectile

Metadata

Metadata

Assignees

No one assigned

    Labels

    criticalA major issue that keeps the project from moving forward

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions