December 2004
Beginner
432 pages
10h 17m
English
Next, you should think about a problem that wasn't all that important when you were writing the Blockers game but could present itself as a problem now. What if you had three or four different objects that all used the same texture? In the Blockers game, you simply would have loaded the same texture three or four times, which does indeed work; however, I'm sure you can realize that the extra “wasted” space can't be a good thing. Instead of having a system like that, wouldn't it be so much nicer if you had a “cache” of textures so that whenever you created one, you would never re-create it again? That's what you should do now.
Building this object pool is actually pretty easy because you can use one of the ...
Read now
Unlock full access