Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Updating Shape Of 2D Freeform light works in editor but not in build.

Discussion in '2D' started by ThatDeveloperEsso, Oct 14, 2020.

  1. ThatDeveloperEsso

    ThatDeveloperEsso

    Joined:
    Jul 15, 2019
    Posts:
    4
    Hi, I tried to set up a vision cone using the 2D Free form light.
    6cqQOnvHc0.gif
    As you can from the gif (If it works) it seems to work completely fine. Using ray casts to get the points that dictate the shape of the cone.

    However, if I build the game it remains static in its initial shape (So I believe the update event is fired at least once) but it does not follow the player:
    Power-Cut_e0xxaIyS6l.png
    As you can see from the image the player is separated from the cone, which should never happen.

    Any ideas as to why this occurs? I tried running in dev mode but it doesn't seem to throw any errors.

    Thanks for your time and effort.
     
  2. Venkify

    Venkify

    Unity Technologies

    Joined:
    Apr 7, 2015
    Posts:
    618
    @ThatDeveloperEsso We are aware of the issue and fixing it. Will post an update here once its released.
     
    ThatDeveloperEsso likes this.
  3. myazuid

    myazuid

    Joined:
    Jan 29, 2019
    Posts:
    26
    Hello @Venkify , was this issue ever fixed? and if so, in which version? I have, I believe, the same issue in 2020 LTS (2020.3.37f1). I am updating the shapePath of a freefrom 2D light and the path updates but where the actual light is shown on screen does not update unless you click edit shape in the inspector and click on one of the points in the path. Thanks in advance.
     
  4. Venkify

    Venkify

    Unity Technologies

    Joined:
    Apr 7, 2015
    Posts:
    618
    Hi, sorry for the delay. I believe the issue has been fixed in 2021 versions for URP. We will backport the fixes to 2020 as soon as possible.