Skip to content

prop_physics model scale is not applied clientside causing prediction errors #6405

@RaphaelIT7

Description

@RaphaelIT7

Details

prop_physics that have a model scale are missing their clientside :Activate() call, which is why their model scale has no effect clientside. Running Entity(x):Activate() clientside solves the prediction errors since then the model scale is applied properly.

This issue also exists, when duping a model, as then they have :Activate not called at all, and their server physics also then return to the normal model's physics.

I think the best way would probably be to have a new networked value like m_fAppliedModelScale that is set when serverside :Activate() is called/when the physics get scaled serverside, and the client can then use that variable to apply the model scale clientside for physics, this would also allow dupes to properly work as props might not always like their physics to be scaled and only use it for visuals, or some might set the model scale to 2, call activate to scale the physics, and then change the model scale again, so m_fAppliedModelScale would then allow you to keep track of what the physics should be scaled by and avoid possible issues.

Steps to reproduce

  1. Have a map entity with a prop_physics that has a model scale
  2. Run cl_showerror 3
  3. Walk into the entity and see all the prediction errors

Metadata

Metadata

Assignees

No one assigned

    Labels

    Net-compat breakingThis issue requires breaking network compatibility with existing servers to solve.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions