Search Unity

The code does not work after the Entities update to 0.0.12 -12

Discussion in 'Entity Component System' started by Sashok9203, Sep 13, 2018.

  1. Sashok9203

    Sashok9203

    Joined:
    Jun 3, 2018
    Posts:
    24
    Hello everyone.

    Code (CSharp):
    1.  
    2. if (Markers[index].InCameraFrustumPlanes != 1)
    3. {
    4.     MarkersData MTemp = Markers[index];
    5.     Buffer.AddComponent(PointEntity[index], new InCFP());
    6.     MTemp.InCameraFrustumPlanes = 1;
    7.     Markers[index] = MTemp;
    8. }
    9.  

    The code works in JobParallelFor .After upgrade Entities to version 0.0.12 -12 line " Markers[index] = MTemp;" does not work, because with a second pass InCameraFrustumPlanes = 0 !!!
    End Unity produces an error, because the code tries to install two components InCFP per Entity.
    In Entities 0.0.12 -11 - this part of the code works great.
     
    Last edited: Sep 15, 2018
  2. Sashok9203

    Sashok9203

    Joined:
    Jun 3, 2018
    Posts:
    24
    Great !!!!
    In Entities 0.0.12-13 the code works !!! :) Although there are some innovations
     
  3. Sashok9203

    Sashok9203

    Joined:
    Jun 3, 2018
    Posts:
    24
    After updating to 0.0.12 -15 the code does not work ...
     
  4. Adam-Mechtley

    Adam-Mechtley

    Administrator

    Joined:
    Feb 5, 2007
    Posts:
    290
  5. Sashok9203

    Sashok9203

    Joined:
    Jun 3, 2018
    Posts:
    24
    Thanks for the help !!! I kept thinking that I was doing something wrong. :)