You may never have heard of the ancient toy known as "StarCraft I", because it came out—it's scary to say—in 1998. In this strategy game, you had to select a race and play as either Terran, Protoss, or Zerg. Let's remember vacuum-tube-based StarCraft by creating representatives of all three races.
Hello, StarCraft!
- 6
Locked
Comments (23)
- Popular
- New
- Old
You must be signed in to leave a comment
Lunita
12 January, 03:56
This was way easier for me than the other with the parenthesis. I should have started with this. 🙄
+1
niraed
7 October 2022, 17:51
Kerrigan, Tykus y Zeratul están orgullosos de este ejercicio.
+2
Stephen Engelhardt
18 October 2021, 07:36
I got the solution just fine, but I'm wondering: is there a way to create the new object and assign the name in one line instead creating the object in one line and then giving it a name in the second line?
+2
Alvaro Avas
15 September 2021, 01:14
tedioso, pero necesario.
+1
ImDevin
25 March 2021, 22:32
wow tedious! :)
0
Java_Mooood
16 October 2020, 18:04
Create object , use the object reference (cr) to call the string name and assign to unique name
Car cr = new Car();
cr.name ="uniquename";
+2
jordan
20 September 2020, 19:40
for
Terran w = new Terran();
why must we put the () at the end?
0
Lunita
12 January, 03:42
Because "Terran()" is actually the constructor method. A constructor is a special method to initialize objects. We need to write the method's name followed by two parentheses ()
0
Matt
5 August 2020, 18:15
Thanks for the steering! The first lesson, Getting started with classes: writing your own classes, constructors concerning the Cat class and your comments worked. I am wondering whether the goal was to create an object or a variable addressing an object
0
Kristen Kinnear-Ohlmann
19 April 2020, 17:49
I really whiffed on this one. I totally was not getting how to solve this and had to look at the hints. I think it's because I expected the code to be more optimized so I went for the kind of solution I would normally write.
+2
Yuvavimal Java Developer
11 December 2019, 14:55
Create 5 Zerg units, 3 Protoss units and 4 Terran units.
Give them all unique names.
how to solve pls hint me friends
0
NightroWave
22 March, 09:32
You need to use .name
(ObjectName).name="ProtossName";
0