OpenRCT2 / OpenRCT2/OpenRCT2

Scenery Update Age Original Bug

Open
#8,780 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

original bug
Dominant language
C++
Stars
16.2k
Forks
1.9k
Avg merge
1d 20h
Merged PRs (30d)
80

Description

Whilst looking at refactoring the tile element flags there is a very odd bit of code in scenery_update_age.

L141 checks for scenery above with tileElementAbove->flags & 7 but that is only 3 quadrants? I think that should be & 0b1111 4 quadrants. I don't quite understand the code though and it needs a bit of a rethink imho.

Checked this against the assembly and this was in the original.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Locate the scenery_update_age implementation and inspect the code around line 141, especially the tileElementAbove->flags & 7 check. Compare its behavior with the original assembly and determine whether the scenery-above quadrant mask is incorrect; done means the behavior and any required tests or validation match the intended original behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
game-dev
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.