I have tested on 2020.3.13f1, exists a problem with the shader but it is easy to fix it:
Go to Vortex/VortexLib and change the Shader.Find from (""Particles/Additive"") to this:
lineRenderer.material = new Material (Shader.Find("Legacy Shaders/Particles/Additive" ));
Finally the functions should look like this:
public static void DrawLine(GameObject go ,Transform a, Transform b, Color col, float width ){
LineRenderer lineRenderer = go.GetComponent<LineRenderer >();
if (lineRenderer ==null){lineRenderer = go.AddComponent <LineRenderer>();}
lineRenderer.material = new Material(Shader.Find("Legacy Shaders/Particles/Additive" ));
lineRenderer.SetColors (col, col);
lineRenderer.SetWidth (width,width);
lineRenderer.SetVertexCount (2);
LineRenderer lineRenderer_ = go.GetComponent<LineRenderer >();
lineRenderer_.SetPosition (0, a.position);
lineRenderer_.SetPosition (1, b.position);
}
public static void DrawLine (GameObject go ,Vector3 a, Vector3 b, Color col, float width ){
LineRenderer lineRenderer = go.GetComponent<LineRenderer >();
if (lineRenderer ==null){lineRenderer = go.AddComponent <LineRenderer>();}
lineRenderer.material = new Material(Shader.Find("Legacy Shaders/Particles/Additive" ));
lineRenderer.SetColors (col, col);
lineRenderer.SetWidth (width,width);
lineRenderer.SetVertexCount (2);
LineRenderer lineRenderer_ = go.GetComponent<LineRenderer >();
lineRenderer_.SetPosition (0, a);
lineRenderer_.SetPosition (1, b);
}
I also have checked and recommend you to make some changes:
go to Scripts/Lib/SpFLib.cs go to CreateEnemyBullet function and set speedx to -speedx:
public static void CreateEnemyBullet (GameObject spawner, GameObject parent, string type,float speedx,float speedy){//type= basic
GameObject bullet = Instantiate(Resources.Load("Bullet/" +type+"Bullet"), spawner .transform.position, Quaternion .identity)as GameObject;
bullet.name=type+"bullet" ;
master.setLayer("Enemies" ,bullet);
LookAt2D(bullet,GameObject .Find("Player").transform );
bullet.GetComponent <Rigidbody2D>().AddRelativeForce (new Vector2(-speedx,speedy));
if(parent!=null){bullet .transform.parent=parent.transform ;}
}
and change these scripts from Update() to FixedUpdate():
Scripts/Camera/Main_Controller.cs
Scripts/Enemies/ (all scripts in this folder)