public void Convert(Entity entity, EntityManager dstManager, GameObjectConversionSystem conversionSystem)
    {
        var robotId = new RobotId {
            Value = id
        };                                    // A component data that has only one float called Value

        dstManager.AddComponentData(entity, robotId);
    }
Beispiel #2
0
 public override int GetHashCode()
 {
     unchecked
     {
         int hash = 17;
         hash = hash * 23 + RobotId.GetHashCode();
         hash = hash * 23 + X.GetHashCode();
         hash = hash * 23 + Y.GetHashCode();
         return(hash);
     }
 }
Beispiel #3
0
        public override int GetHashCode()
        {
            int hash = 1;

            if (RobotId.Length != 0)
            {
                hash ^= RobotId.GetHashCode();
            }
            if (Make.Length != 0)
            {
                hash ^= Make.GetHashCode();
            }
            if (_unknownFields != null)
            {
                hash ^= _unknownFields.GetHashCode();
            }
            return(hash);
        }