protected override JobHandle OnUpdate(JobHandle inputDeps)
        {
            var job = new RaycastJob
            {
                quadrants = _quadrantSystem.GetQuadrantAccess()
            };

            return(job.Schedule(this, inputDeps));
        }
Esempio n. 2
0
        public static JobHandle ScheduleRaycast(CollisionWorld _collisionWorld, NativeArray <RaycastInput> _raycastInputs, NativeArray <RaycastHit> _raycastHits)
        {
            var raycastJob = new RaycastJob()
            {
                m_collisionWorld = _collisionWorld,
                m_raycastInputs  = _raycastInputs,
                m_results        = _raycastHits
            };

            JobHandle jobHandle = raycastJob.Schedule(_raycastInputs.Length, 1);

            return(jobHandle);
        }