Mchapuis / RPG

team project for school
0 stars 1 forks source link

Function hang #14

Closed Mchapuis closed 7 years ago

Mchapuis commented 7 years ago

This "hang"

String str_test_ParseAbility = "Pikachu:pokemon:cat:basic:cat:lightning:60:retreat:cat:colorless:1:attacks:cat:colorless:1:5,cat:colorless:2:6";
Ability ab_test = new test();
final Ability ab_new = ab_test.parseAbilitiesLine(str_test_ParseAbility);
HumanPlayer hp = new HumanPlayer();

// the function need to return the name at least
String name = ab_new.name;
assertNotNull(name);

And here is the Call stack when I pause the program image

Another thread open: image

ananarchie commented 7 years ago

i didn't write the original function but it looks like you're trying to parse a pokemon as an ability, is this what you intended to do?

Mchapuis commented 7 years ago

Frank said the same thing, I changed it but the error was the same