Skip to content

Random foliage on replaced collisions bug #2694

@TFP-dev

Description

@TFP-dev

Describe the bug

When you replace collision on model which originaly have random foliage generated on it and this original collision was not loaded by GTA since you started your game, then random foliage will not generate on replaced collision because MTA currently does not use CPlantMgr::SetPlantFriendlyFlagInAtomicMI. However if you first go to place where this model is and then replace collision - random foliage will generate if appropriate materials are assigned in collision.

Steps to reproduce

Scenario 1

  1. Re/start MTA.
  2. Open Map Editor.
  3. Start resource collision_test_resource.zip
  4. Fly there: -2026, 2275, 23.82

Result:
mta-screen_2022-07-28_14-43-29

Scenario 2

  1. Re/start MTA.
  2. Open Map Editor.
  3. Fly there: -2026, 2275, 23.82
  4. Start resource collision_test_resource.zip
  5. Fly back to Grove Street.
  6. Fly back to replaced model and collision.

Result:
mta-screen_2022-07-28_14-47-53

Version

No response

Additional context

PR #2678 fixes this problem.

Relevant log output

No response

Security Policy

  • I have read and understood the Security Policy and this issue is not security related.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions