Sunday, January 2, 2011

Furniture Part 3




So now we can see furniture taken from the furniture screen and put into room 1. Which is the entire point of the screen. Drag and drop from furniture rooms to another furniture room works. Drag and drop from furniture rooms back to player items works. As a matter of fact everything is working now but the actually sorting of the player array. Which is probably what I will do tonight... need to fix the infinite recursion that was reason sorting got removed anyways.

I actually ended up using a variation on John Evans code it fixed all my issues. (New ones popped up later on.)

function roomFurnitureClean(){
while(furnitureImageArray.length != 0) {
if(furnitureImageArray[0] != null) {
removeChild(furnitureImageArray[0]);
}
furnitureImageArray.splice(0,1);
}
}

Daisy

1 comment: