示例#1
0
        public void Execute()
        {
            float radius = Constants.AvoidanceRadiusPlayer;
            int   hash   = GridHash.Hash(Pos, VehicleHashJob.kCellSize);

            CellMap.Add(hash, new VehicleCell {
                Position = Pos, Velocity = Velocity, Radius = radius
            });
        }
示例#2
0
        public void Execute([ReadOnly] ref VehiclePhysicsState physicsState)
        {
            float radius = Constants.AvoidanceRadius;
            int   hash   = GridHash.Hash(physicsState.Position, kCellSize);

            CellMap.Add(hash, new VehicleCell {
                Position = physicsState.Position, Velocity = physicsState.Velocity, Radius = radius
            });
        }