Well the backgroundobject class is mostly done. I want particular things in a particular preset spot on all size tanks. So the heater is always going to be on the left mostly; the filter on the right.. the glue on the sides of the glass of the aquarium.. but while I thought I had it all right, I had forgotten some things. The filter has to have a particle effect.. hmm. some decorations might have effects to.. so how do I code that in? I kept trying to find ways, but it broke down to what was easiest.. I simply pass the constructor a integer value, then depending on that integer, it gets a particular particle effect initialized for it or not. Amazingly simple, and much easier than other ways I was trying.. Same thing with sound effects. Of course, for those items with particle effects, I want those effects to not just ‘pop’ on when the object first hits the screen, so I gave myself some wiggle room with 2 integers: begin draw position, and enddrawposition. THis way, when I’m doing my testing, i can set the begin draw to say -100.. so 100 pixels before the object is actually drawn, I can start its particles and move the emitter with the object so it looks like it was running the whole time.. same with the end.. that way when the filter dissapears offscren the bubbles dont magically disappear.
Its kinda interesting how after a few months, with projects building on projects, you go back and start to catch the little details. I look at Kollectiv now and think.. I shoulda done this.. I could have done that.. Why did I do it that way?!
The basic outline of the class is done. Tomorrow I need to pick up on and work on coding the update methods and the draw methods. These should be relatively straight forward. I’ll run through my list<> and ‘update’ each object.. if it determines the object is within the screen area, or within my drawing boundaries, it flags it as drawable with a bool. This way when it comes to my draw routine, i can cycle through only objects whose draw flag is true and only draw those.
Enemies are going to work mostly the same I think, but I do have some more planning out to do for them. They are definately some more complex little critters.. =/