Search Issue Tracker

By Design

Votes

1

Found in

2022.3.3f1

2023.1.1f1

2023.2.0a21

Issue ID

UUM-41181

Regression

Yes

[Android] transform.position fails to set the correct position when used in relation to another GameObject

-

Requirements:

  • Blender needs to be installed
  • .blend files needs to be reimported

Reproduction steps:
1. Open the attached project "ReproProj”
2. Open the “/Assets/Scenes/WhackScene.unity” Scene
3. Build And Run on an Android device
4. Touch the catapult shaft to move the weapon
5. Release the catapult
6. Repeat steps 4 and 5 for 2-3 times
7. Observe the ammo of the catapult

Expected result: Ammo moves together with the catapult
Actual result: Ammo fails to move together with the catapult

Reproducible with: 2022.3.3f1, 2023.1.1f1, 2023.2.0a21
Not reproducible with: 2021.3.27f1

Reproducible with devices:
VLNQA00325, Samsung Galaxy Note10 (SM-N970F), Android 12, CPU: Exynos 9 (9825), GPU: Mali-G76
VLNQA00318, Oneplus OnePlus 7 Pro (GM1913), Android 11, CPU: Snapdragon 855 SM8150, GPU: Adreno (TM) 640
VLNQA00231, Samsung Galaxy A5(2017) (SM-A520F), Android 8.0.0, CPU: Exynos 7 Octa 7880, GPU: Mali-T830
VLNQA00231, Huawei HUAWEI Mate 20 Pro (LYA-L29), Android 9, CPU: HiSilicon Kirin 980, GPU: Mali-G76
VLNQA00494 - iPhone 14 Pro Max, 16.3.1 iOS
VLNQA00358 - iPhone 12, 14.1 iOS
VLNQA00392 - iPad (9th generation), 15.0 iOS
VLNQA00310 - iPad Pro 12.9", 13.4.1 iOS

Testing environment: Windows 10 Enterprise 21H2

Notes:
- Touching the ammo at any point will stop the weapon from moving, and the player should be restarted. Only touch the catapult shaft to move the weapon
- The method which appears to fail in setting the position of the ammo in relation to the weapon - the method (MoveWeaponXAxis()) is found in the class weapon.cs
- The first reproducible version found is 2022.1.0b10, but could not test with older versions to find FAV due to the error “Library\PackageCache\com.unity.render-pipelines.universal@13.1.0\Editor\UniversalRenderPipelineAsset\UniversalRenderPipelineAssetUI.Drawers.cs” Removing library and reinstalling the package did not solve it
- Does not reproduce with Windows Standalone Player or Play Mode
- Catapult prefab is missing when the project is opened with Mac, and also Catapult fails to render even when the prefab is not missing on Mac

  1. Resolution Note:

    Hi, thanks for submitting a bug report. We have managed to reproduce the issue on multiple platforms however only when the players finger leaves the screen (or mouse in the editor).
    Based on this and the code in the project we have verified that the fix is to modify the code in 'Player.cs' so that the position of the object is always updated and not only when the touch input is in the assumed state.

Comments (1)

  1. Davex6

    Aug 30, 2023 17:59

    Yes, by doing what you suggest the ammo does not *seem* to stay on the other side of the screen.
    But it is not a complete fix, since the ball can still be rendered at the original position, prior to moving to the new position.
    Not every time, but quite often given a large velocity is applied to the catapult. This manifests in the ball 'flashing' in its original position. This can not really be seen in the test case, but it is very apparent in my game.
    And, to be honest, what you are saying does not make sense to me:
    '...however only when the players finger leaves the screen'.
    However, just prior to the player's finger leaving the screen, the player's finger *was* touching the screen - yet the ammo stays at the *original* position. This suggests that the ammo is not following the weapon's position correctly as it is being moved.

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.