Exemplo n.º 1
0
    // Update is called once per frame
    void Update()
    {
        PlayerFleet.UpdateShipPositions();
        List <Ship> ships = PlayerFleet.GetShipsForPlanet(planet);

        foreach (GameObject shipObject in GameObject.FindGameObjectsWithTag("Ship"))
        {
            foreach (Ship ship in ships)
            {
                if (shipObject.GetComponent <ShipScript>().ship.id == ship.id)
                {
                    shipObject.transform.position = new Vector3(ship.x, ship.y, 0f);
                }
            }
        }
    }
Exemplo n.º 2
0
 // Update is called once per frame
 void Update()
 {
     PlayerFleet.UpdateShipPositions();
 }