Ejemplo n.º 1
0
    // Start is called before the first frame update
    void Start()
    {
        Rigidbody = GetComponent <Rigidbody2D>();

        RocketService       = GetComponent <RocketService>();
        GravityService      = GetComponent <GravityService>();
        MainThrusterService = GetComponent <MainThrusterService>();

        InitialPosition = Rigidbody.position + new Vector2(Random.Range(-30, 30), Random.Range(-30, 30));
        InitialRotation = Rigidbody.rotation + Random.Range(-25, 25);
    }
Ejemplo n.º 2
0
    // Start is called before the first frame update
    void Start()
    {
        if (Plane == null)
        {
            Debug.LogError("Plane null!");
        }

        Rigidbody = GetComponent <Rigidbody2D>();

        MainThrusterService       = GetComponentInChildren <MainThrusterService>();
        ACSNozzleAssemblyServices = GetComponentsInChildren <ACSNozzleAssemblyService>();
    }