Esempio n. 1
0
        public IActionResult AddCar(Cars c)
        {
            CarManger mgr = new CarManger(@"Data Source=.\sqlexpress;Initial Catalog=Cars;Integrated Security=True;");

            mgr.AddCar(c);
            return(Redirect("/Home/home"));
        }
Esempio n. 2
0
        public IActionResult Home(bool asc)
        {
            CarManger     mgr = new CarManger(@"Data Source=.\sqlexpress;Initial Catalog=Cars;Integrated Security=True;");
            Homeviewmodel hmv = new Homeviewmodel();

            hmv.cars = mgr.GetAll(asc);
            hmv.asc  = asc;
            return(View(hmv));
        }
Esempio n. 3
0
 public void Initl(CarManger inCarManger, Vector3[] inMovePaht, int startID, float speedFactor)
 {
     speed              *= speedFactor;
     carManger           = inCarManger;
     movePath            = inMovePaht;
     currentAtMovePathID = startID;
     transform.position  = movePath[currentAtMovePathID];
     Run();
 }
Esempio n. 4
0
    public void Initl(CarManger inCarManger, Vector3[] inMovePaht, int startID, float speedFactor)
    {
#if UNITY_EDITOR
        SceneInteractiveManger.RecoverMatShader(transform);
#endif

        speed              *= speedFactor;
        carManger           = inCarManger;
        movePath            = inMovePaht;
        currentAtMovePathID = startID;
        transform.position  = movePath[currentAtMovePathID];
        Run();
    }