Stride 3d how to make move around the sphere? translating unity 3d code [closed]

I'm trying to move code from unity 3d to stride 3d but I have huge issues as IDE doesn't help me find words when I type as unity 3d does

the unity 3d code that works:

public Transform Planet; // to rotate to
void Update(){
PlanetDirection = Planet.position - transform.position;
planetDistance = MathFunctions.V3Distance(transform.position, Planet.position);
Ray ray = new Ray(transform.position, PlanetDirection);
RaycastHit hit;
if (Planet.GetComponent<Collider>().Raycast(ray, out hit, planetDistance)  ){
transform.rotation = Quaternion.LookRotation( Vector3.Cross(transform.right, hit.normal) , hit.normal);
}
}


this is updated stride code:

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Stride.Core.Mathematics;
using Stride.Input;
using Stride.Engine;
using Stride.Physics;

namespace example1{
public class PlanetaryMovement : SyncScript{
public Colliders PlanetCollider;
public Entity Planet; // to rotate to
//maybe I don't need so much only Simulation
Stride.Physics.Simulation sim;
Vector3 near = this.Entity.TransformComponent.position;
Vector3 to = Planet.TransformComponent.position;
//var result = sim.Raycast(vectorNear.XYZ(), vectorFar.XYZ());
IList<HitResult> hit = new IList<HitResult>();
CollisionFilterGroups filterGroup = CollisionFilterGroups.DefaultFilter;

public override void Start(){
}

public override void Update(){
sim.RaycastPenetrating(near, to, hit, filterGroup);

PhysicsComponent col;
for(int i=0; i< hit.Count; i++){
if (PlanetCollider == hit[i].Collider){
this.Entity.Quaternion.Rotate(hit[i].Normal);
}
}
}
}
}


and the reference with witch I was trying to figure out how to translate my code

EDIT: -Updated the code errors that still exists:

[C:\programming\Stride 3D\example1\example1\Movement.cs(14,12)]: Error: The type or namespace name 'Colliders' could not be found (are you missing a using directive or an assembly reference?)


what I need is to link the HitResult with Planet somehow I don't know what to use to compare them.

• Converting code from an engine to another is not really game development and is more about "code". Code questions should be asked on stack overflow. Aug 24, 2021 at 11:12
• If you ever manage to get your code working, but you have an issue with it, then please update the question with your new issue and we'll help you reopen it. Aug 24, 2021 at 11:21

I think you just forgot to using Stride.Physics; and where vector3 near first letter must be upper like this Vector3 near. In the end you should using Visual Studio because it helps fix errors like these.