hey all,
I have a bug in my code and really need help. In the code that i´ve post here you can see if I eat a student that the student wil come back after a few seconds, but there is the problem if I eat a second student befor the fist student is back there wil only come one back and not two.
I hope you guys understand what I mean and I hope you could help me to fix this problem/bug
privtate int studentDelayCount;
public concierge(Counter pointCounter)
{
counter = pointCounter;
studentDelayCount = 0;
}
public void act()
{
checkNewstudent();
}
if(canSee(student.class))
{
eat(student.class);
newstudent();
}
private void newstudent()
{
studentDelayCount = 250;
}
private void checkNewstudent()
{
if (studentDelayCount > 0) {
studentDelayCount--;
if (studentDelayCount == 0) {
createNewstudent();
}


