29 lines
905 B
Java
29 lines
905 B
Java
package com.company.universe;
|
|
|
|
public class PlanetaryNebula {
|
|
|
|
private String name;
|
|
private long size;
|
|
private long lifeDuration;
|
|
private long x, y , z;
|
|
|
|
public PlanetaryNebula(){
|
|
name = "myName";
|
|
size = 0;
|
|
lifeDuration = 0;
|
|
x = 0; y = 0; z=0;
|
|
System.out.println("Created Planetary Nebula: " + name + "Parameters: " + lifeDuration + ", " + size + ". Coordination: " + x + ", " + y + ", " + z);
|
|
}
|
|
|
|
public PlanetaryNebula(String name,long lifeDuration, long size, long x, long y, long z) {
|
|
this.name = name;
|
|
this.lifeDuration = lifeDuration;
|
|
this.size = size;
|
|
this.x = x;
|
|
this.y = y;
|
|
this.z = z;
|
|
System.out.println("Created Planetary Nebula: " + name + "Parameters: " + lifeDuration + ", " + size + ". Coordination: " + x + ", " + y + ", " + z);
|
|
}
|
|
}
|
|
|