Skip to content

Replace RayCastBlocks calls #170

@midspace

Description

@midspace

Update calls to RayCastBlocks to use MyAPIGateway.Physics.CastRay.

https://github.com/midspace/Space-Engineers-Admin-script-mod/blob/master/midspace%20admin%20helper/Data/Scripts/midspace.adminscripts/Support.cs#L105

  MyAPIGateway.Physics.CastRay(start, end, out info);
    var hitGrid = info?.HitEntity as IMyCubeGrid;
    return hitGrid?.GetCubeBlock(hitGrid.WorldToGridInteger(info.Position + headTransform.Forward * 0.01))?.FatBlock as IMyTerminalBlock;

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions