My favorites | Sign in
Project Home Downloads Wiki Issues Source
READ-ONLY: This project has been archived. For more information see this post.
Search
for
  Advanced search   Search tips   Subscriptions
Issue 4: Still having trouble with Room Delete
1 person starred this issue and may be notified of changes. Back to list
Status:  Fixed
Owner:  luisestr...@gmail.com
Closed:  Sep 2007


 
Project Member Reported by eeh...@gmail.com, Sep 27, 2007
What steps will reproduce the problem?
1. Create several rooms
2. Delete one out of the middle
3. Try to select the last room

What is the expected output? What do you see instead?
The problem is that when the deleteRoom function is called, wherever the 
room was the Game class will yank it. The ArrayList: rooms Will update 
acordingly. So if there were 16 rooms, and I deleted the 3rd room. The 
ArrayList is now indexed from 0-14, but I still have a room that has ID 
15. So when I call the getRoom and pass in 15 the program dies. Because 
there isn't an element indexed by 15 in the ArrayList.
 
Sep 28, 2007
Project Member #1 luisestr...@gmail.com
Oops, i changed the getRoom function instead of the delete room. i should be working 
now.
Status: Fixed
Owner: luisestrada115

Powered by Google Project Hosting